Can the callback get the 'raw' values based on which the decision is being made? That way we can dig in and try to find patterns to get it closer to real.
The raw values it works from are just the accelerometer values, so you can take a look at the accel event. However you can tweak the step counter from JS - check out Bangle.setOptions - https://banglejs.com/reference#l_Bangle_setOptions with stepCounterThresholdLow and stepCounterThresholdHigh...
I noticed the callback function doesn't seem to be in the right context.
Can you give me an example? this is set to Bangle on all the events that get queued up. If you need this set to something else then you should be able to either use arrow functions, or the _this hack you suggest...
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
The raw values it works from are just the accelerometer values, so you can take a look at the
accel
event. However you can tweak the step counter from JS - check outBangle.setOptions
- https://banglejs.com/reference#l_Bangle_setOptions withstepCounterThresholdLow
andstepCounterThresholdHigh
...Can you give me an example?
this
is set toBangle
on all the events that get queued up. If you needthis
set to something else then you should be able to either use arrow functions, or the_this
hack you suggest...