Div (/); Ny-Series Instructions Reference Manual (W560 - Omron NY532-5400 Reference Manual

Ny-series
Hide thumbs Also See for NY532-5400:
Table of Contents

Advertisement

DIV (/)

The DIV (/) instruction divides integers or real numbers.
Instruction
DIV (/)
Division
Variables
Name
Meaning
In1
Dividend
In2
Divisor
Out
Output
value
* If you omit an input parameter, the default value is not applied. A building error will occur.
Bit string
In1
In2
Out
Function
The DIV (/) instruction divides dividend In1 by divisor In2 and outputs the result to output value Out.
In1 and In2 can have different data types. However, use the combination that data types to include are
existed. If they are different, calculations are performed with the data type that includes the range of all
of the data types. For example, if In1 is INT data and In2 is DINT data, calculations are performed with
DINT data. Here, the division result is DINT data.
If In1 and In2 are integers and there is a remainder, the remainder is truncated.
Refer to Data Type Ranking Table and Casting Rules in the NJ/NX-series CPU Unit Software User's
Manual (Cat. No. W501) or NY-series Industrial Panel PC / Industrial Box PC Software User's Manual
(Cat. No. W558) for the including relationship on data types.

NY-series Instructions Reference Manual (W560)

Name
FB/FUN
FUN
I/O
Description
Dividend
Input
Divisor
Output
Output value
OK OK OK OK OK OK OK OK OK OK
OK OK OK OK OK OK OK OK OK OK
OK OK OK OK OK OK OK OK OK OK
Graphic expression
(@)DIV
EN
ENO
In1
Out
In2
(@)/
EN ENO
In1
Out
In2
Valid range
Depends on data type.
Depends on data type.
Integers
2 Instruction Descriptions
ST expression
Out:=In1/ In2;
Unit
Default
*
---
---
---
Times, durations, dates,
and text strings
2
2-189

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents