Time stamp in CLUE data?

For CircuitPython issues, ask in the Adafruit CircuitPython forum.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
summerij
 
Posts: 27
Joined: Mon Jul 13, 2020 1:38 pm

Time stamp in CLUE data?

Post by summerij »

Hello. I'm new to CLUE. Is there away to add a time stamp to the data? I'm looking to sync recorded accel/gyro measurements to pics from a GoPro. Thanks.

User avatar
kevinjwalters
 
Posts: 1025
Joined: Sun Oct 01, 2017 3:15 pm

Re: Time stamp in CLUE data?

Post by kevinjwalters »

In CircuitPython, time.monotonic_ns() gives you the time in the form of the number of nanoseconds since the board was powered up. There's no real-time clock (rtc) to maintain the time and date. You could use monotonic_ns() and perhaps supplement it with a clapperboard type procedure where you shake the camera/CLUE in a certain way with a few repeats to give you some syncronisation points in the collected data. That would be useful both at the start and the end, the latter give you way to check/adjust for any minor differences between camera fps and the CLUE's clock.

CircuitPython interpreter occasionally goes off to do other things so if you want very accurate timestamped data collection, a C++/Arduino program would be superior. Display updates are by far the worst offender here.

There's some more detail on time in Adafruit Learn: Arduino to CircuitPython: Time and CLUE Sensor Plotter in CircuitPython: Time in CircuitPython.

Locked
Please be positive and constructive with your questions and comments.

Return to “CLUE Board”