5- 110 5- 110
5 MELSEC FUNCTIONS
5.20.4 Subtraction of clock data DATEMINUS_M
The specified time data is subtracted from the specified time-of-day data.
Function definition
BOOL DATEMINUS_M (BOOL EN, ANY16(3) S1, ANY16(3) S2, ANY16(3) D);
Argument Name
IN/OUT
Description
EN IN
Execution condition (Function is executed only when the
result is TRUE)
S1 [0] Hour (0 to 23)
S1 [1] Minute (0 to 59)
S1 IN
Time-of-day data from
which data will be
subtracted (ARRAY [0..2]
OF ANY16)
S1 [2] Second (0 to 59)
S2 [0] Hour (0 to 23)
S2 [1] Minute (0 to 59)
S2 IN
Time data that will be
subtracted from data
(ARRAY [0..2] OF
ANY16)
S2 [2] Second (0 to 59)
D [0] Hour (0 to 23)
D [1] Minute (0 to 59)
D OUT
Subtraction result
time-of-day data
(ARRAY [0..2] OF
ANY16)
D [2] Second (0 to 59)
Return Value
Description
BOOL Execution
condition
Example of use
(* When execution condition X0 turns ON, the time data specified in TimeData2 *)
(* is subtracted from the time-of-day data specified in TimeData1, and the
*)
(* subtraction result is stored into Result.
*)
DATEMINUS_M (X0, TimeData1, TimeData2, Result);
Corresponding MELSEC command
DATE- (Subtraction of clock data)
For the usable data type, refer to "3.2.2
About ANY type".
Содержание MELSEC L series
Страница 1: ...Programming Manual Structured Text ...
Страница 2: ......
Страница 73: ...4 33 4 33 4 ST PROGRAM EXPRESSIONS MEMO ...
Страница 297: ......