I was playing around with the accelerometer data trying to code a tachometer app that computes the inertial speed by integrating acceleration data. But I can't get it to produce a "fluent" value yet.
Is my understanding correct that the accelerometer works at a fixed 80ms interval? What happens if I change the polling interval with Bangle.setPollInterval() from the default 80ms to say 40ms? How often will the Bangle.on('accel',...) event be triggered and what data will it deliver?
Also, my impression is that the g.drawString() and g.drawLine() commands take a lot of time and thus may interfere with my velocity calculation. Could that be true?
Are there any more specs on the accelero that is used, like zero-level drift and stuff like that?
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.
Hi,
I was playing around with the accelerometer data trying to code a tachometer app that computes the inertial speed by integrating acceleration data. But I can't get it to produce a "fluent" value yet.
Is my understanding correct that the accelerometer works at a fixed 80ms interval? What happens if I change the polling interval with
Bangle.setPollInterval()
from the default 80ms to say 40ms? How often will theBangle.on('accel',...)
event be triggered and what data will it deliver?Also, my impression is that the
g.drawString()
andg.drawLine()
commands take a lot of time and thus may interfere with my velocity calculation. Could that be true?Are there any more specs on the accelero that is used, like zero-level drift and stuff like that?
Thanks.