EasyManuals Logo

Mitsubishi MELSEC Q Series Programming Manual

Mitsubishi MELSEC Q Series
1296 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #649 background imageLoading...
Page #649 background image
7-275
RAD(P)
1
2
3
4
6
6
7
8
7.12 Special function instructions
7.12.13 Conversion from floating-point angle to radian (Single precision) (RAD(P))
Operation Error
(1) In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and
an error code is stored into SD0.
• The contents of the designated device or the result of the addition are not "0", or not within
the following range(For the Universal model QCPU, LCPU): (Error code: 4140)
0, 2
-126
| Contents of designated device | < 2
128
• The value of the specified device is 0.
*3
(For the Basic model QCPU, High Performance model QCPU, Process CPU, Redundant
CPU) (Error code: 4100)
*3: There are CPU modules that will not result in an operation error if 0 is specified. For details, refer to 3.2.4.
• The result exceeds the following range (Operation results in an overflow)
(For the Universal model QCPU, LCPU)
2
128
| Operation result | (Error code: 4141)
• The value of the specified device is 0, unnormalized number, nonnumeric, and ± .
(For the Universal model QCPU, LCPU) (Error code: 4140)
Program Example
(1) The following program converts the angle set by the 4 BCD digits at X20 to X2F to radians,
and stores results as 32-bit floating decimal point type real number at D20 and D21.
[Ladder Mode]
[List Mode]
[Operations involved when X20 to X2F designate a value of 120]
Inputs an angle to be converted
into a radian value ( )
Converts the input a 32-bit
floating-point real number ( )
Converts the converted angle into
a radian value ( )
1
2
3
Step Instruction Device
X2F
BCD value
0
D0
120
X20
Conversion
to BIN
BIN
b15
b0
BIN value
120
Conversion to
floating-point
FLT
Conversion
to radian
D11 D10
RAD
D21
D20
120 2
.
094395

Table of Contents

Other manuals for Mitsubishi MELSEC Q Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Mitsubishi MELSEC Q Series and is the answer not in the manual?

Mitsubishi MELSEC Q Series Specifications

General IconGeneral
BrandMitsubishi
ModelMELSEC Q Series
CategoryController
LanguageEnglish

Related product manuals