Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # global variable:
- timestamp_cycles = 0
- # per message:
- # get 32-bit timestamp (in cycles) from message and unwrap it:
- timestamp_cycles += ( msg.timestamp - timestamp_cycles ) & 0xffffffff
- # convert to timestamp in seconds:
- timestamp = timestamp_cycles / 200e6
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement