5.9 Functions Of Time Data Types
202
FXCPU Structured Programming Manual
(Application Functions)
5.9.3
MUL_TIME(_E)
Outline
This function performs multiplication of time data.
1. Format
*1.
Output variable
2. Set data
In explanation of functions, I/O variables inside ( ) are described.
Explanation of function and operation
This function performs multiplication(
×
) using time data stored in devices specified in
and
, and outputs the operation result expressed as time data to devices specified in
.
Cautions
1) Use the function having "_E" in its name to connect a bus.
2) When handling 32-bit data in structured programs, you cannot specify 16-bit devices directly, different
from simple projects. Use labels when handling 32-bit data.
You can specify 32-bit counters directly, however, because they are 32-bit devices.
Use global labels when specifying labels.
3) Even if underflow or overflow occurs in the operation result, it is not regarded as an operation error.
However, note that the accurate operation result cannot be obtained in this case.
("MUL_TIME_E" outputs "TRUE" from ENO.)
FX
3U(C)
FX
3G
FX
2N(C)
FX
1N(C)
FX
1S
FX
U
/FX
2C
FX
0N
FX
0(S)
Function name
Expression in each language
Structured ladder
ST
MUL_TIME
MUL_TIME(_IN1,_IN2);
Example:
Label 3:=
MUL_TIME(Label 1,Label 2);
MUL_TIME_E
MUL_TIME_E(EN,_IN1,_IN2,
Output label);
Example:
MUL_TIME_E(X000,Label 1,
Label 2,Label 3);
Variable
Description
Data type
Input
variable
EN
Execution condition
Bit
_IN1 (
)
Head word device which stores time data to get multiplication
Time
_IN2 (
)
Multiplication data, or head word device which stores such data
ANY_NUM
Output
variable
ENO
Execution status
Bit
*1
(
)
Head word device which will store the operation result
Time
MUL_TIME
*1
Label 3
Label 1
_IN1
Label 2
_IN2
MUL_TIME_E
EN
ENO
*1
Label 3
X000
Label 1
_IN1
Label 2
_IN2
s1
s2
d
s1
s2
s1
s2
d
Содержание 09R927
Страница 2: ......
Страница 234: ...232 FXCPU Structured Programming Manual Application Functions Revision History MEMO ...