Converting Single-Precision Real Number Radian To Angle - Mitsubishi MELSEC iQ-F FX5 series Programming Manual

Melsec iq-f fx5 series
Hide thumbs Also See for MELSEC iQ-F FX5 series:
Table of Contents

Advertisement

Converting single-precision real number radian to angle

DEG(P)/DDEG(P)
These instructions convert a unit of angle from radians specified by (s) into degrees (DEG.), and store the converted angle in
the device specified by (d). The DEG(P) instructions can also be used as DDEG(P).
Ladder diagram
(s)
Setting data
■Descriptions, ranges, and data types
Operand
Description
(s)
A value in radians to be converted into a value in degrees or
the head device number storing a value in radians
(d)
Head device number storing a value in degrees acquired by
conversion
■Applicable devices
Operand
Bit
X, Y, M, L,
SM, F, B, SB
(s)
(d)
Processing details
• These instructions convert a unit of angle from radians specified by (s) into degrees (DEG.), and store the converted angle
in the device specified by (d).
(s)+1
(s)
(
Single-precision real number
• The conversion from radians into degrees is executed as follows:
180
Degrees = Radians 
• The table below shows the related devices.
Device
Name
SM700
Carry
SM8020
Zero
SM8021
Borrow
SM8022
Carry
Operation error
Error code
Description
(SD0/SD8067)
The specified device value is -0, denormalized number, NaN (not a number), or .
3402
7 APPLICATION INSTRUCTION
452
7.7 Real Number Instruction
(d)
Word
U\G T, ST,
T, ST, C, D,
C, LC
W, SD, SW, R
(d)+1
) rad
(
Single-precision real number
Description
Condition
The absolute value of the operation result
The operation result is true "0".
(The mantissa part is "0").
The absolute value of the operation result < 2
The absolute value of the operation result
Structured text
ENO:=DEG(EN,s,d);
ENO:=DEGP(EN,s,d);
Range
Data type
Single-precision real number
Single-precision real number
Double word Indirect
U\G
Z
LC
(d)
)
Operation
128
2
The value of (d) is the maximum value (2
numbers and the carry flag SM700 turns on.
The zero flag SM8020 turns on.
-126
The value of (d) is the minimum value (2
numbers and the borrow flag SM8021 turns on.
128
2
The value of (d) is the maximum value (2
numbers and the carry flag SM8022 turns on.
Data type (label)
Single-precision real number
Single-precision real number
Constant
specification
LZ
K, H
128
-126
128
Others
E
$
) of 32-bit real
) of 32-bit real
) of 32-bit real

Advertisement

Table of Contents
loading

Table of Contents