EasyManuals Logo
Home>Mitsubishi>Controller>MELSEC-Q/L

Mitsubishi MELSEC-Q/L User Manual

Mitsubishi MELSEC-Q/L
850 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 #545 background imageLoading...
Page #545 background image
543
BSIN, BSINP
1
2
3
4
4
6
7
8
7.12 Special function instructions
7.12.29 BSIN, BSINP
Function
(1) Calculates the SIN (sine) value of value (angle) designated by , and stores the sign of the operation result in the device
designated at , and the operation result in the devices designated at +1 and +2.
(2) The value designated at is a BCD value which can be between 0 and 360 degrees (in units of degrees).
(3) The sign for the operation result stored in will be "0" if the result is a positive value, and "1" if the result is a negative
value.
(4) The operation results stored in +1 and +2 are BCD values between -1.000 and 1.000.
(5) Operation results are rounded off from the fifth decimal place.
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.
Program Example
(1) The program example below calculates the SIN of 3-digit BCD data designated by X20 to X2B, and outputs a 1-digit
BCD part to the integer part from Y50 to Y53, and a 4-digit BCD fraction part from Y40 to Y4F.
Y60 is turned ON if the results of the operation are negative. (If a value has been set at X20 to X2F that is greater than
360, it will be adjusted to be in the range from 0 to 360.)
[Ladder Mode]
[List Mode]
Error
code
Error details
Q00J/
Q00/
Q01
QnH QnPH QnPRH QnU LCPU
4100
The data specified in is not a BCD value.
The data specified in is not within the range from 0 to 360.
––
4101
The points of the device specified in exceed those of the
corresponding device.
–– –– –– ––
S
D D D
+2
D
S Integer part Decimal fraction part
.
D
SignSIN
+1
D
S
D
D D
S
S
D
Processes so that the input
angle is within 360° ( )
Executes SIN operation ( )
Outputs the integer part of the operation
result to a display device ( )
Outputs the decimal fraction part of the
operation result to a display device ( )
Outputs the sign of the operation result
by ON or OFF ( )
1
2
3
4
5
Step Instruction Device

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

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

Mitsubishi MELSEC-Q/L Specifications

General IconGeneral
BrandMitsubishi
ModelMELSEC-Q/L
CategoryController
LanguageEnglish

Related product manuals