Whenever an uplink is received via a LoRa Basics Station gateway which doesn't gave GPS time available, the fractional second of the receive time is missing in the reported gwTime of the rx_info element.
Example:
It seems the fractional part of the rxtime (as float) is not properly scaled to nanoseconds before it is cast to int64.
Note: rxtime in Basics Station is the radio receive time (xtime) converted into UTC. This conversion is susceptible to UTC synchronization issues (e.g. NTP not functioning correctly, or large/asymmetric network latencies in case of LNS-based timesync) and therefore must be used with care by any consumer.
Whenever an uplink is received via a LoRa Basics Station gateway which doesn't gave GPS time available, the fractional second of the receive time is missing in the reported
gwTime
of therx_info
element. Example:It seems the fractional part of the
rxtime
(as float) is not properly scaled to nanoseconds before it is cast toint64
.https://github.com/chirpstack/chirpstack-gateway-bridge/blob/6897fe56c2b8e631632fe2ed37e4d6dbd903f563/internal/backend/basicstation/structs/radio_meta_data.go#L80-L86
This PR fixes that.
Note:
rxtime
in Basics Station is the radio receive time (xtime
) converted into UTC. This conversion is susceptible to UTC synchronization issues (e.g. NTP not functioning correctly, or large/asymmetric network latencies in case of LNS-based timesync) and therefore must be used with care by any consumer.