Skip to content
This SDK only works with devices released within the past 3 years. We regularly optimize and update the SDK to ensure compatibility and performance. We do not guarantee compatibility or provide technical support for devices older than 3 years.

# DD_DATE_TIME_CONFIG

### Structure Definition

C++C#

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    typedef struct _dd_date_time_config
    {
        unsigned int iSize;
        unsigned char dateFormat;
        unsigned char timeFormat;
        unsigned char timeZone;
        unsigned char enableNTP;
        unsigned short ntpPort;
        unsigned char daylightSwitch;
        unsigned char recv;
        char ntpServerAddr[DD_MAX_URL_BUF_LEN];
    } DD_DATE_TIME_CONFIG;

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    [StructLayout(LayoutKind.Sequential, Pack = 4)]
    public struct DD_DATE_TIME_CONFIG
    {
        public UInt32 iSize;
        public byte dateFormat;
        public byte timeFormat;
        public byte timeZone;
        public byte enableNTP;
        public UInt16 ntpPort;
        public byte daylightSwitch;
        public byte recv;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 260)]
        public byte[] ntpServerAddr;
    }

### Function Description

Time and date configuration structure.

### Member Description

Member | Type | Remark
--- | --- | ---
iSize | unsigned int | The length of this structure
dateFormat | unsigned char | Date format, the value is `DD_DATE_MODE`
timeFormat | unsigned char | Time format, 12 represents 12-hour system, 24 represents 24-hour system
timeZone | unsigned char | Time zone, value is `DD_TIME_ZOME_NAME`
enableNTP | unsigned char | Whether to enable NTP synchronization service
ntpPort | unsigned short | NTP Port
daylightSwitch | unsigned char | Only n9000
recv | unsigned char | Reserved.
ntpServerAddr | char[DD_MAX_URL_BUF_LEN] | NTP server address

Error Code