ViStatus _VI_FUNC niSync_SetTimeReferencePPS (ViSession vi, ViConstString terminalName, ViBoolean useManualTime, ViUInt32 initialTimeSeconds, ViUInt32 initialTimeNanoseconds, ViUInt16 initialTimeFractionalNanoseconds);
Sets the selected time reference of the device to PPS (pulse per second).
This function is a nonblocking call that returns immediately regardless of the state of the time reference selected. Selecting the time reference is a system-wide (per device) configuration that persists after the session exits. The time reference is not reservable; the last call to select the time reference takes precedence.
![]() |
Note
|
Name | Type | Description |
---|---|---|
vi | ViSession | The session handle that you obtain from niSync_init. The handle identifies a particular instrument session. |
terminalName | ViConstString | Specifies the terminal that contains the PPS signal. |
useManualTime | ViBoolean | Specifies whether to use a user-supplied time or the OS system time to set the board time when the module receives the first pulse. After the first pulse sets the board time, every subsequent pulse is interpreted to be received one second later, and the function adjusts the board time accordingly. |
initialTimeSeconds | ViUInt32 | Specifies the seconds field of the time to set the board time to when the module receives the first pulse. Only use this parameter if you set useManualTime to TRUE. |
initialTimeNanoseconds | ViUInt32 | Specifies the nanoseconds field of the time to set the board time to when the module receives the first pulse. Only use this parameter if you set useManualTime to TRUE. |
initialTimeFractionalNanoseconds | ViUInt16 | Specifies the fractional nanoseconds field of the time to set the board time to when the module receives the first pulse. Only use this parameter if you set useManualTime to TRUE. |