Omron CP - PROGRAMMING MANUAL 05-2007 Programming Manual page 527

Cp1h/cp1l cpu unit
Table of Contents

Advertisement

Floating-point Math Instructions
Description
Flags
Precautions
494
Area
DM Area
Indirect DM addresses
in binary
Indirect DM addresses
in BCD
Constants
Data Registers
Index Registers
Indirect addressing
using Index Registers
DEG(459) converts the 32-bit floating-point number in S+1 and S from radians
to degrees and places the result in R+1 and R. (The floating point source data
must be in IEEE754 format.)
S+1
S
R+1
R
Radians are converted to degrees by means of the following formula:
Radians
180/ = degrees
If the absolute value of the result is greater than the maximum value that can
be expressed as floating-point data, the Overflow Flag will turn ON and the
result will be output as
If the absolute value of the result is less than the minimum value that can be
expressed as floating-point data, the Underflow Flag will turn ON and the
result will be output as 0.
Name
Label
Error Flag
ER
Equals Flag
=
Overflow Flag
OF
Underflow Flag
UF
Negative Flag
N
The source data in S+1 and S must be in IEEE754 floating-point data format.
S
D0 to D32766
@ D0 to @ D32767
*D0 to *D32767
#0000000 to #FFFFFFFF
(binary)
---
---
,IR0 to ,IR15
–2048 to+2047 ,IR0 to –2048 to+2047 ,IR15
DR0 to DR15, IR0 to IR15
,IR0+(++) to ,IR15+(++)
,–(– –)IR0 to, –(– –)IR15
Source (radians, 32-bit floating-point data)
Result (degrees, 32-bit floating-point data)
.
Operation
ON if the source data is not recognized as floating-point
data.
ON if the source data is not a number (NaN).
OFF in all other cases.
ON if both the exponent and mantissa of the result are 0.
OFF in all other cases.
ON if the absolute value of the result is too large to be
expressed as a 32-bit floating-point value.
ON if the absolute value of the result is too small to be
expressed as a 32-bit floating-point value.
ON if the result is negative.
OFF in all other cases.
Section 3-14
R
---

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents