Todtosec - Omron NY532-5400 Reference Manual

Ny-series
Hide thumbs Also See for NY532-5400:
Table of Contents

Advertisement

TodToSec

The TodToSec instruction converts a time of day to the number of seconds from 00:00:00.
Instruction
TodToSec
Convert Time of
Day to Seconds
Variables
Name
Meaning
In
Time of day Input
Out
Seconds
Bit strings
In
Out
Function
The TodToSec instruction converts the time of day in In to the number of seconds from 00:00:00. The
converted value is in seconds. The value is truncated below the seconds.
The following example is for when In is TOD#12:0:0.999999999.
LD
TOD#12:0:0.999999999
In
Out=abc
Additional Information
Use the SecToTod instruction (page 2-630) to convert the number of seconds from 00:00:00 on January
1,1970 to a time of day.
NY-series Instructions Reference Manual (W560)
Name
FB/FUN
FUN
I/O
Description
Time of day
Output
Number of seconds from
00:00:00
TodToSec
EN
ENO
In
TOD#12:0.0.999999999
TOD#0:0:0.000000000
LINT#43200
Graphic expression
(@)TodToSec
EN
ENO
In
Valid range
Depends on data type.
0 to 86399
Integers
OK
ST
abc:=TodToSec(TOD#12:0:0.999999999);
abc
s
[
2 Instruction Descriptions
ST expression
Out:=TodToSec(In);
Out
Unit
Default
Hour, min-
TOD#0:0
utes, seconds
:0
Seconds
---
Times, durations, dates,
and text strings
OK
2
2-625

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents