Why does Fw.Time have u32 seconds and u32 micros? #4426
zimri-leisher
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
As I work on adding better support for Fw.Time objects to Fpy, I'm wondering why Fw.Time is designed to have a U32 seconds and U32 micros, instead of just U64 micros. Doing the math, U64 micros can represent every single microsecond for the next 500,000 years, whereas U32 seconds and U32 micros can only represent the next 130 years. Most of that is because of the huge amount of redundant ways of specifying epochs. Also, in several places:
fprime/Fw/Time/Time.cpp
Line 141 in 589871a
It also makes comparison more difficult to perform. I usually just end up converting everything to U64s internally.
Beta Was this translation helpful? Give feedback.
All reactions