NVlabs / FPSci

Aim Training Experiments
Other
70 stars 23 forks source link

Handle Arduino time-base roll over in event logger #318

Closed bboudaoud-nv closed 3 years ago

bboudaoud-nv commented 3 years ago

This branch adds support for managing roll over/wrap of the micros() timestamps used in the event logger Arduino firmware. Notably it fixes a bug wherein samples collected after the 4294.967s (~71.5 min) mark following a hardware reset/timer wrap are ignored/incorrectly logged until either the device is restarted or the logger script is relaunched.

It is worth noting that this fix does not handle time logging/correction correctly for the edge case of 71.5 minutes elapsing w/ the device connected/reporting with no events at all. Fixing this will require a FW update for the event logger platform.

jspjutNV commented 3 years ago

I think this is nearly ready, we probably just want to do a quick test to make sure my latest changes haven't broken anything.