clockDayTimer (Functionblock) |
Top Previous Next |
clockDayTimer is a simple repeating timer. It has a start- and stop time. When the start time is reached, the q output will go true. Q will go false when the stop time is reached. This will repeat every day.
Input: enable : BOOL (Default: FALSE (Timer is NOT started)) Timer is enabled when enable is true.
start_hour: INT (-1 .. 23) Default: -1 (not used in comparison) The starting hour.
start_minute : INT (-1 .. 59) (Default: -1 (not used in comparison)) The starting minute.
start_second : INT (0 .. 59) (Default: 0) The starting second.
stop_hour: INT (-1 .. 23) (Default: -1 (not used in comparison)) The ending hour.
stop_minute : INT (-1 .. 59) (Default: -1 (not used in comparison)) The ending minute.
stop_second : INT (0 .. 59) (Default: 0) The ending second.
Output: q : BOOL When start time is reached, q will go true, and it will go false when the stop time is reached
Declaration: FUNCTION_BLOCK clockDayTimer;
Example: INCLUDE rtcu.inc |