Summary
Creates a DATE_AND_TIME string using the entered time of day, then stores it in the specified address.
You can Write to TIME_OF_DAY type if you register a device/PLC tag.
Format
SetTOD (device address, TIME string)
Device address: TIME_OF_DAY type tag
TIME_OF_DAY string: fixed string (preview only)
Hours: numerical value (Range: 0 to 23)
Minutes: numerical value (Range: 0 to 59)
Seconds: numerical value (Range: 0 to 59)
Milliseconds: numerical value (Range: 0 to 999)
Example expression:
SetTOD("[w:[PLC1]TagName]","01:02:03.004")
In the above example, write "01:02:03.004" to TIME_OF_DAY type device "[w:[PLC1]TagName]".
When the value for the
Milliseconds field is 0, it is not output as part of the TIME_OF_DAY
string.
For example, 01:02:03