I have an instrument that stores timestamps the microsecond level, and I need to store those timestamps as part of collecting information from the instrument. Note that I do
I am struggling with this same issue, in that I have a project where I have picosecond resolution timestamps. My source data is in "time_t" format, i.e. second since epoch + picoseconds + UTC Offset.
The best solution I have found is to work with "decimal seconds since epoch in UTC" as my time format internally, and only use DateTime as a pretty print object, to extract locale/formatting up to 1 s resolution, and then manually manipulate the string to include fractional seconds.