FC6A S
ERIES
MICROS
MART
L
ADDER
P
ROGRAMMING
M
ANUAL
FC9Y-B1726 26-15
26: S
CRIPT
Data type conversion
Square root
ROOT( )
Square root of is returned.
• This can only be used for data type F (float).
Sine
SIN( )
Sine of (-1 to +1) is returned.
Specify arbitrary formula to represent angle (units in radian) for argument .
• This can only be used for data type F (float).
Cosine
COS( )
Cosine of (-1 to +1) is returned.
Specify arbitrary formula to represent angle (units in radian) for argument .
• This can only be used for data type F (float).
Tange n t
TAN( )
Tangent of (-1 to +1) is returned.
Specify arbitrary formula to represent angle (units in radian) for argument .
• This can only be used for data type F (float).
Arcsine
ASIN( )
Arcsine of (-1 to +1) in radian value (-Ï€/2 to +Ï€/2) is returned.
Specify arbitrary formula for argument .
• This can only be used for data type F (float).
Arccosine
ACOS( )
Arccosine of (-1 to +1) in radian value (0 to π) is returned.
Specify arbitrary formula for argument .
• This can only be used for data type F (float).
Arctangent
ATAN( );
Arctangent of (-1 to +1) in radian value (-Ï€/2 to +Ï€/2) is returned.
Specify arbitrary formula for argument .
• This can only be used for data type F (float).
Conversion from
Angle to Radian
RAD( );
Value of is converted from degree (°) to radian, and the value is returned.
• This can only be used for data type F (float).
Conversion from
Radian to Angle
DEG( );
Value of is converted from radian to degree (°), and the value is returned.
• This can only be used for data type F (float).
Function Format Description
Conversion from
BCD to Binary
BCD2BIN( )
BCD value of is returned in binary value.
• Data types W (word), I (integer), D (double word), and L (long) can be used.
F (float) cannot be used.
Conversion from
Binary to BCD
BIN2BCD( )
Binary value of is returned in BCD value.
• Data types W (word), I (integer), D (double word), and L (long) can be used.
F (float) cannot be used.
Conversion from
float to Binary
FLOAT2BIN( )
Float value of is returned in binary value.
Values after the decimal point is truncated.
• Data types D (double word) and L (long) can be used.
Conversion from
Binary to float
BIN2FLOAT( )
Binary value of is returned in float value.
• This can be used with data types D (double word) and L (long).
Conversion from
Decimal to String
character
DEC2ASCII( , )
Decimal number value is converted to a character string, and store in order with
as a first device.
• Data types W (word), I (integer), D (double word), and L (long) can be used.
F (float) cannot be used.
Conversion from
String character to
Decimal
ASCII2DEC( )
Character string is returned as decimal number value.
• Data types W (word), I (integer), D (double word), and L (long) can be used.
F (float) cannot be used.
Function Format Description