4 ms·
> A simple fix is to just use the previous power value if ever: the cadence is non-zero and the previous power is non-zero and the current power is zero. A slig
by flak48 6y ago
> A simple fix is to just use the previous power value if ever: the cadence is non-zero and the previous power is non-zero and the current power is zero. A slight improvement is to keep track of the slope and factor it in when calculating the predicted value.
Looks like somebody rediscovered the Kalman filter without realising it :)
I recall implementing one for an IoT device, to de-noise gas sensor readings a few years ago.
Pretty fun read. Makes me wish I could gather the courage and patience to get back into hacking on embedded stuff