Contains the GPSTime class that represents time as GPS
LeapSeconds
()
Determine the number of leap seconds.
The purpose of this class is to provide a place to store leap second
information. It has two methods: one to get the number of leap seconds at
a given time and one to get the next leap second.
.. note:: Leap Second Information
The number of leap seconds is accurate through 31 Dec 2020, which is
all of the planned leap seconds at the time of writing (30 March 2020).
There is no leap second planned for 30 Jun 2020, so the next possible
leap second is 31 Dec 2020 23:59:60. This class will need to be
updated as future leap seconds are planned.
gps2utc
(gps_time
:Union
[GPSTime
, datetime
])
Convert GPS Time to UTC Time
This function adjust the GPS Time using the number of leap seconds to get
the UTC time.
Parameters
gps_time : Union[GPSTime, datetime.datetime]
The current GPS Time
Returns
datetime.datetime
The UTC Time
utc2gps
(utc_time
:datetime
)
Convert UTC Time to GPS Time
This function adjust the UTC Time using the number of leap seconds to get
the GPS time.
Parameters
utc_time : datetime.datetime
The current UTC Time
Returns
GPSTime
The GPS Time