Technical data

Table Of Contents
IEC Functions
System Software for S7-300/400 System and Standard Functions - Volume 2/2
A5E00739858-01
26-9
Description FC35 SB_DT_TM
The function FC35 subtracts a duration (format TIME) from a time (format DT) and
provides a new time (format DT) as the result. The time (parameter T) must be
between DT#1990-01-01-00:00:00.000 and DT#2089-12-31-23:59:59.999. The
function does not run an input check. If the result of the subtraction is not within the
valid range, the result is limited to the corresponding value and the binary result
(BR) bit of the status word is set to “0".
Parameter Declaration Data Type Memory Area Description
T INPUT DATE_AND_TIME D, L Time in format DT
D INPUT TIME I, Q, M, D, L, Const. Duration in format TIME
RET_VAL OUTPUT DATE_AND_TIME D, L Difference in format DT
You can assign only a symbolically defined variable for the input parameter T and
the output parameter.
Description FC40 TIM_S5TI
The function FC40 converts the data type format TIME to the format S5TIME. The
value is rounded down during conversion. If the input parameter is greater than the
S5TIME format allows (greater than TIME#02:46:30.000), the result S5TIME#999.3
is output and the binary result (BR) bit of the status word is set to "0".
Parameter Declaration Data Type Memory Area Description
IN INPUT TIME I, Q, M, D, L, Const. Input variable in format TIME
RET_VAL OUTPUT S5TIME I, Q, M, D, L Return value in format S5TIME