Added set time callback with optional offset for BACnet TimeSynchronization services (#691)

This commit is contained in:
GauiStori
2024-07-16 22:28:03 +02:00
committed by GitHub
parent f2686a441a
commit fda3cb5e82
7 changed files with 132 additions and 8 deletions
+15
View File
@@ -15,9 +15,24 @@
#include <stdint.h>
#include <stdlib.h>
#include <time.h>
#include "bacnet/basic/service/h_ts.h"
#include "bacport.h"
#include "bacnet/datetime.h"
/**
* @brief Set offset from the system clock.
* @param bdate BACnet Date structure to hold local time
* @param btime BACnet Time structure to hold local time
* @param utc - True for UTC sync, False for Local time
* @return True if time is set
*/
void datetime_timesync(
BACNET_DATE *bdate, BACNET_TIME *btime, bool utc)
{
return;
}
/**
* @brief Get the date, time, timezone, and UTC offset from system
* @param utc_time - the BACnet Date and Time structure to hold UTC time