-
• #27
I installed the Languauges app - could not spot any additional menus anywhere to choose miles or km.
It just sets it up according to your country: https://github.com/espruino/BangleApps/blob/master/apps/locale/locales.js#L86
-
• #28
About kms and miles, I think the language or the country might not be the best approach. For instance, I'm a froggie, so French language may trigger kms, but I use English language on the watch and therefore call for miles, but I live down under and the metric system is the reference since 1980. I'm in favor of letting the user choose, rather than assuming. Or, assume, ok, but let open the possibility to change it anyway.
-
• #29
letting the user choose, rather than assuming.
Absolutely. Thats the point of having the locale and language modules.
This sort of stuff must be configurable by the user. -
• #30
With regards to distance accuracy on the RUN app I have done some real world tests.
I have done any experiment with only taking every 1oth fix to calculate the distance delta. This worked better but still not right.
I have a loop round the backstreet, top of the next road and back. Initial attempt using the existing Bangle calculation came out at 560m. Considering I hade only recorded 320 steps I knew this was iffy.
I changed the calculation to the
Equirectangular approximation
as per:
https://www.movable-type.co.uk/scripts/latlong.html
I have used this before and found it pretty accurate on Kitchen Combo and WayPointer.function radians(a) { return a*Math.PI/180; } // distance between 2 lat and lons, in meters, Mean Earth Radius = 6371km // https://www.movable-type.co.uk/scripts/latlong.html function calcDistance(a,b) { var x = radians(a.lon-b.lon) * Math.cos(radians((a.lat+b.lat)/2)); var y = radians(b.lat-a.lat); return Math.round(Math.sqrt(x*x + y*y) * 6371000); }
Changing to this calcualtion I then recorded 336m. Where my AmazFit Bip recorded 0.24 miles.
This is much more beleivable but I need to test against a dedictaed hand held GPS over a longer distance as I know the Amazfit Bip GPS is said to have some issues. -
• #31
@Fteacher if someone wants to submit some changes to
apps/locale/custom.html
so that you choose the locale but then get a bunch of options which you can tweak to suit you then I'm very happy to merge it. It's not a big deal for someone to implement.@HughB thanks - that sounds like a much better approach - please could you submit a PR? I don't know quite why I thought Bangle.project would work :(
I remember now that when I'd done the
route
app there was a scaling factor applied (which is just a hackier version of what's done in your code): https://github.com/espruino/BangleApps/blob/bf44683bfe2640f9cbfdebb2f9d140b7250531a4/apps/route/custom.html#L78-L81And unsurprisingly the scale factor for the UK ended up at 0.6ish, which is exactly 336/560
-
• #32
Will do a PR maybe tonight. Want to do a 1 mile test against a Garmin Etrex first.
-
• #33
Lunchtime testing.
Etrex 1.3m
Amizfit 1.27m
Run 1.2miles - but I suspect the locale is truncating and not rounding.I also noticed the distance is in meters to start with (as in 560m) . Then it switches to miles (as in 1.1mi) - very odd.
Currently I am avoiding the GPS gitter by taking every 10th fix. I will try at every 5 seconds and then 2 but feel a fix every 1 second is bound to introduce errors - due to the snowflake effect I described earlier. I this an update every 5 seconds is enough in practice. Every 10 secnds is too long if you want to see it flip over when you are running.
3 Attachments
-
• #34
Just done a pull request for Run v0.03 - which fixes the distance calculation. I have tested against a Garmin Etrex and an AmazFit GTS 2.
-
• #35
Hi, I'll go and run to try it... as soon as I'll feel better. Sick for now.
About the customs and locale, that's a different topic, but some apps may require different personnal data (like min and max HR, weight, age, and so on) to be more accurate in producing more detailed analysis (calories burnt on a run, quality of the sleep, and so on). I know, some of these things are not implemented yet but...
All that leads me to think that there could be an app to setup all the watch settings to the user (time zone, name for a greeting message, and the extra infos that are deemed necessary for other calculations). Maybe an app that works once on first boot, just after the Welcome app. Clearly secondary, but to be considered at some point of polishing the details, no ? -
• #36
Short confirmation of already reported observations:
tested v0.02 on a longer walk yesterday and compared with app on phone.
phone 2.93km = bangle2 4.7km
phone 6.03 km = bangle2 9.7km
Thats both a factor of 0.62HR was much too low definitively (39-45). My wife had plausible values on her bangle2.
How would I test v0.03? I see only v0.02 also in development app store. (not really important, can wait)
-
• #37
That's just a conversion from miles to kilometres. 2.93 miles is 4.72 km...
But maybe that's been talked about before. I haven't really followed this thread.
-
• #38
To test 0.03 you will need to refresh your local repository after Gordon has merged my pull request. I only submitted on Saturday, so hope Gordon is enjoying his weekend.
Aha - but in the meantime it is available on my loader at:
https://hughbarney.github.io/BangleApps/#run -
• #39
Yes, I am sure something like that will emerge from the planned Android app.
-
• #41
lot of the recent progress I see your name involved.
I think its more that I comment on a lot of posts (perhaps too many for my own good), and ask a lot of questions.
-
• #42
Re-reviewing the run app and more various feedbacks on running with Bjs2.
GPS: I downloaded agps and went out for a gps fix. It got it within 15 seconds, while doing warm up (moving the arms), awesome ! I started the recorder app, but it was out of gps for a few minutes of the run. Therefore the results are biased. I ran 8.295kms with the Garmin watch and 8.127kms with the bjs2. I'll try again.
BT HRM: I used a bthrm (polar), the bjs2 and the garmin watch (no wrist hrm). There's a concurrent use of the Polar ! The bjs2 clearly took over and had access to the bthrm during the whole run, whereas my garmin struggled to connect to it once in a few minutes (whereas it usually connects without any issue).
The recorder app Recorded my track. I couldn't download the track from the app loader before deleting the previous other runs (see attached screenshot).
In the settings I asked it to track my HR through BTHRM. So after running we can tap on "view track" to get the infos. We can check quite a few infos, but not the technical ones (pace, distance, hrm). We can check the speed, but it is expressed in meters per second rather than in kms/h or miles/h. Afterwards, it is possible to export all the data in different formats that can be exploited in different apps, all good.
The run app finally. I think the number 0 shouldn't have this little bar in the middle as it reduces its readability. I'm never sure wether it's 0 or 8. I have good eyes, but while running that's another business.
I already expressed my views about what's important and what should be tweakable in the app, maybe another running app is a better option. I won't get the spare time to learn how-to and then code it, but getting rid of cadence and steps and take this space to increase the size of everything else is a great step forward. If we then have the possibility to switch between kms/h andminutes/km, this would be enough for me to put the Garmin back in a drawer. The HR zones during the race/ avg speed so far and so on, it's been discussed. And also a summarize at the end of the run that can be checked. Well, if someone feels like coding this app, I have time for testing and desire to do so.
1 Attachment
-
• #44
@Fteacher @myownself. I agree with you both about where the RUN app should go in terms of LIEV feedback. Steps is not really interesting to runners - it could be a setting though (show steps/ show pace now / show last mile pace etc).
- I think the RUN should have PACE_NOW (generated from the GPS) - however the essential issue is getting the GPS into pedestrian mode otherwise the varianance of the speed detection will be all over the place. We are currently struggling to get some of the GPS CASIC commands to work. An alternative approach would be to make note of the mile or km timstamps and then show last mile pace. Similarly the PACE now could be calculated over the last 50m on a rolling basis. I would not trust pace worked out just on the basis of two points 20m appart though.
- I think the RUN should have PACE_NOW (generated from the GPS) - however the essential issue is getting the GPS into pedestrian mode otherwise the varianance of the speed detection will be all over the place. We are currently struggling to get some of the GPS CASIC commands to work. An alternative approach would be to make note of the mile or km timstamps and then show last mile pace. Similarly the PACE now could be calculated over the last 50m on a rolling basis. I would not trust pace worked out just on the basis of two points 20m appart though.
-
• #45
@johan_m_o: as far as I understood its about lat/lon distance calculation and just accidentaly the same factor as km/mi for our distance from equator.
@HughB: v0.03 really made the difference:
Phone 5,40km, Bangle 5.4km!! :-)
Also steps got much better with 2v11: Mi3-band (worn besides bangle) 8000, Bangle 7842. Thats about 2% differnce, wich is quite ok (and also all the error could come from Mi3, we dont't know)Still heartrate is completely broken for me. As said I plan to dig deeper into this soon.
Is there already an recorder for raw data of the HR sensor? Otherwise I would need to start with this. Shouldn't bee too difficult with the accelerometer recorder as an example I hope.Update: Typing the above text brought step counter to 8240.
So people: do particiapte in forms! - as good as any exercise ;-) -
• #46
I have looked at a lot of papers. I remember one was a particularly good overview, I will see if I can dig it out again @Mi.
If you can find that, would be great.
also some of the more novel features we can extract.
What do you have in mind here?
While we must get the basics right first, it might make sense to incorperate in data collection already. I can measure and record SpO2, so do plan to record this for data sets also and see if it can be predicted from bangle2 data. -
• #47
The very latest Bangle.js firmwares do have much improved heart rate monitoring now, but I think while running there will still be issues until someone can come up with an HRM algorithm which uses accelerometer data to discount false readings
-
• #48
Ah good. I see the commit "significantly improved beat detection using peak finding and zero c…"
Thanks -
• #49
@Gordon I've upgraded to 2v11.44 I do trust you about the process being much better but I don't think the HRM results are close to kind of ok yet. I feel bad about showering your optimism. I'm sitting still and whatever the position of the wrist band on my wrist or front arm the hrm is between 80 and 105 when it should be between 56 and 59. Or is it just my device ?
@HughB , @myownself and @everyoneinsterested, do we open a different thread to discuss this other app ? I think Gordon's app is a nice base whose main screen could be modified, there could be an extra screen accessed through swipe up/down to access to what myownself described (completion state of specific running activities).
@HughB I'm far from the technical aspects you described. I don't know how Gordon's app gives the pace as kms/min regularly (it looked very plausible during my last run), but this can be used to give the pace as kms/h, no ? -
• #50
@Fteacher and you're on a Bangle.js 2, and using the Run app? How long did you give it? The HRM gives a confidence level and I believe the run app just ignores that, giving you whatever value it has even if it's not sure it's right. At least in my tests on a variety of devices, heart rate seemed pretty reliable about 20 secs after starting if I keep my hand still. If I move my arm around then the heart rate goes way out, but at least the confidence value drops to 0 so then apps know it's not a good indicator of the actual heart rate
Obviously anyone's welcome to jump in on this and improve the HRM code, but right now all I can do is get it working well for me.
I installed the Languauges app - could not spot any additional menus anywhere to choose miles or km.