So you can't do above 100Hz. I'm not sure what happened with 400Hz but maybe it failed with out of memory before it got started.
The Accelerometer does have a built-in FIFO which we don't actually use at the moment.
It might be possible to change the Espruino firmware to use it, but also you could probably use accelRd to read the data directly from the FIFO at a much lower level, and then you don't need to change PollInterval at all.
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.
require("Storage").getStats()
Ideally if you're writing data that fast, you could look at writing binary data - see the second example on https://www.espruino.com/Data+Collection#flash-memory
It looks like we don't support a poll interval less than 10ms (100Hz): https://github.com/espruino/Espruino/blob/8f3a9cb52/libs/banglejs/jswrap_bangle.c#L2487
So you can't do above 100Hz. I'm not sure what happened with 400Hz but maybe it failed with out of memory before it got started.
The Accelerometer does have a built-in FIFO which we don't actually use at the moment.
It might be possible to change the Espruino firmware to use it, but also you could probably use
accelRd
to read the data directly from the FIFO at a much lower level, and then you don't need to change PollInterval at all.