DCMD_PTPD_GET_TAI_UTC_OFFSET
Get the offset from TAI to UTC
Synopsis:
#include <dcmd_ptpd.h>
#define DCMD_PTPD_GET_TAI_UTC_OFFSET __DIOF(_DCMD_NET, 18, MyTAIUTCInternal )
Arguments to devctl():
| Argument | Value |
|---|---|
| filedes | A file descriptor that you obtained by opening /dev/ptpd |
| dcmd | DCMD_PTPD_GET_TAI_UTC_OFFSET |
| dev_data_ptr | A pointer to a MyTAIUTCInternal structure |
| n_bytes | sizeof(MyTAIUTCInternal) |
| dev_info_ptr | NULL |
Description:
(QNX Neutrino 7.0.4 or later) This command gets the offset from Internation Atomic Time (TAI) to Universal Coordinated Time (UTC). TAI doesn't account for leap seconds, so the offset is the number of leap seconds inserted into UTC, as reported by the master clock in the Precision Time Protocol.
Note:
In order to use this command, you must specify the -K option when you start
ptpd or ptpd-avb.
Input:
None.
Output:
A filled-in MyTAIUTCInternal structure, which is defined in <dcmd_ptpd.h> as follows:
typedef struct {
uint16_t currentUtcOffset;
uint8_t currentUtcOffsetValid;
} MyTAIUTCInternal;
The members include:
- currentUtcOffset
- The number of leap seconds inserted into UTC.
- currentUtcOffsetValid
- Nonzero if the currentUtcOffset member is valid.
Example:
See also:
DCMD_PTPD_DELAYMS, DCMD_PTPD_DELAYSM, DCMD_PTPD_GET_PDELAY_INTERVAL, DCMD_PTPD_GET_TIME, DCMD_PTPD_INFO, DCMD_PTPD_SEND_SIGNALING_MSG, DCMD_PTPD_SET_PDELAY_INTERVAL, DCMD_PTPD_STATUS
devctl() in the QNX Neutrino C Library Reference
ptpd, ptpd-avb in the Utilities Reference
Page updated:
