Arithmetic instructions
409
Part III FP Instructions
Variable Data type Function
s1 DWORD dividend, 32-bit area for BCD data or 8-digit BCD equivalent
constant
s2 DWORD divisor, 32-bit area for BCD data or 8-digit BCD equivalent
constant
d DWORD quotient, 32-bit area for BCD data (remainder stored in
special data register DT9016 and DT9015/DT90016 and
DT90015)
For Relay T/C Register Constant
s1, s2, s3 DWX DWY DWR DWL DSV DEV DDT DLD DFL dec. or hex.
d - DWY DWR DWL DSV DEV DDT DLD DFL -
No. IEC address Set If
R900B %MX0.900.11 for an instant the result calculated is 0.
Data types
Operands
Error flags
Example
In this example the function has been programmed in ladder diagram (LD) and structured text
(ST).The same POU header is used for all programming languages.
POU header
All input and output variables used for programming this function have been declared in the POU
header.
Body
When the variable start is set to TRUE, the function is carried out.
LD
ST
IF start THEN
F53_DBDIV(dividend, divisor, output_value);
END_IF;