RTC_SET (set real-time clock)
The RTC_SET instruction sets RTC (real-time clock) data to the RTC module information.
Languages supported: Function block diagram, ladder diagram, structured text.
This instruction applies to the Micro810, L20E, L50E, and L70E controllers.

RTC_SET

Parameter | Parameter Type | Data Type | Description |
---|---|---|---|
Enable | Input | BOOL | Instruction block enable.
|
RTCEnable | Input | BOOL |
|
RTCData | Input | RTC | RTC data information: yy/mm/dd, hh/mm/ss, week as defined in the RTC data type.RTCData is ignored when RTCEnable = 0. |
RTCPresent | Output | BOOL |
|
RTCEnabled | Output | BOOL |
|
RTCBatLow | Output | BOOL |
|
Sts | Output | USINT | The read operation status. RTC_Set status (Sts) values:
|
Parameter | Parameter Type | Description |
---|---|---|
Year | UINT | The year setting for the RTC. 16-bit value, and the valid range is from 2000 (Jan 01, 00:00:00) through 2098 (Dec. 31, 23:59:59). |
Month | UINT | The month setting for the RTC. |
Day | UINT | The day setting for the RTC. |
Hour | UINT | The hour setting for the RTC. |
Minute | UINT | The minute setting for the RTC. |
Second | UINT | The second setting for the RTC. |
DayOfWeek | UINT | The day of the week setting for the RTC. This parameter is ignored for RTC_SET. |
RTC_SET examples
RTC_SET function block diagram example

RTC_SET ladder diagram example

RTC_SET structured text example

Provide Feedback