Skip to content

DD_DAYLIGHT_INFO

Structure Definition

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
typedef struct _dd_daylight_info_
{
    unsigned char InMonth;      
    unsigned char InMday;       
    unsigned char OutMonth;     
    unsigned char OutMday;      
    unsigned char InWeekIndex;  
    unsigned char InWday;       
    unsigned char OutWeekIndex; 
    unsigned char OutWday;      
    unsigned short InYear;      
    unsigned short OutYear;     
    unsigned short enable;      
    unsigned short type;        
    unsigned int InSecond;      
    unsigned int OutSecond;     
    unsigned int offSet;        
} DD_DAYLIGHT_INFO;
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
[StructLayout(LayoutKind.Sequential, Pack = 4)]
public struct DD_DAYLIGHT_INFO
{
    public byte InMonth;
    public byte InMday;
    public byte OutMonth;
    public byte OutMday;
    public byte InWeekIndex;
    public byte InWday;
    public byte OutWeekIndex;
    public byte OutWday;
    public UInt16 InYear;
    public UInt16 OutYear;
    public UInt16 enable;
    public UInt16 type;
    public UInt32 InSecond;
    public UInt32 OutSecond;
    public UInt32 offSet;
}

Function Description

Daylight saving time configuration structure.

Member Description

Member Type Remark
InMonth unsigned char Which month does DST begin?
InMday unsigned char The day when DST begins (valid in date format).
OutMonth unsigned char Which month does DST occur?
OutMday unsigned char On which day DST begins (valid in date format).
InWeekIndex unsigned char Week number in which DST begins (valid in week format).
InWday unsigned char Day of week to enter DST (week mode is valid).
OutWeekIndex unsigned char Which week DST occurs (valid in week mode).
OutWday unsigned char The day of the week when DST occurs (valid in week mode).
InYear unsigned short The year when DST begins may not be useful, but putting it here just aligns the structure, so it is retained.
OutYear unsigned short The year when DST is not in effect may not be useful, but it is kept here so that the structure can be aligned.
enable unsigned short Whether to enable the daylight saving time function.
type unsigned short Daylight saving time setting method: week or date mode.
InSecond unsigned int The second offset (0 to 86399) during the day of entering DST can be converted into hours, minutes and seconds.
OutSecond unsigned int Output the DST second offset within a day (0 to 86399), which can be converted into hours, minutes and seconds.
offSet unsigned int Daylight saving time offset (0 to 86399) seconds.
Error Code