event_example.c
Go to the documentation of this file.
141 // Initialize the NTAPI library and thereby check if NTAPI_VERSION can be used together with this library
152 if ((status = NT_EventOpen(&hEventStream, "ExampleEvent", NT_EVENT_SOURCE_CONFIG | NT_EVENT_SOURCE_TIMESYNC_STATE_MACHINE)) != NT_SUCCESS) {
179 // As we have opened the event stream with the mask NT_EVENT_SOURCE_CONFIG | NT_EVENT_SOURCE_TIMESYNC_STATE_MACHINE
186 printf("Event received: Timestamp clock set: New time: %lld\n", (unsigned long long)hEvent.u.timeSyncStateMachineEvent.timeStampClock);
195 printf("Event received: Timestamp config change: New time: %lld\n", (unsigned long long)hEvent.u.configEvent.u.timestampWrite.data.ts);