5.8 Functions of Time Data Type
5.8.4 Division
5-183
5
APPLICATION
FUNCTIONS
DIV_TIME(_E)
DIV_TIME(_E)
Operation Error
No operation error occurs in the execution of the DIV_TIME(_E) function.
Program Example
The program which performs division ( ÷ ) on time type data input to and , and outputs
the quotient of the operation result from in time type.
(a) Function without EN/ENO (DIV_TIME)
[Structured ladder]
[ST]
g_time2:= DIV_TIME(g_time1, g_int1);
(b) Function with EN/ENO (DIV_TIME_E)
[Structured ladder]
[ST]
g_bool3 := DIV_TIME_E(g_bool1, g_time1, g_int1, g_time2);
s1
s2
s1
s2
d