Dint_To_Str(_E) - Mitsubishi Electric MELSEC FX Series Structured Programming Manual

Hide thumbs Also See for MELSEC FX Series:
Table of Contents

Advertisement

FXCPU Structured Programming Manual
(Application Functions)

5.1.14 DINT_TO_STR(_E)

Outline
This function converts double word [signed] data into string data, and outputs the data obtained by
conversion.
1. Format
Function name
DINT_TO_STR
DINT_TO_STR_E
*1.
Output variable
2. Set data
Variable
EN
Input
variable
_DINT (
ENO
Output
variable
*1
In explanation of functions, I/O variables inside ( ) are described.
Explanation of function and operation
1) This function converts double word [signed] data stored in a device specified in
outputs the data obtained by conversion to a device specified in
Double word [signed] data
2) In "Sign data", "20H (space)" is stored when the input value is positive, and "2DH (-)" is stored when the
input value is negative.
3) "20H (space)" is stored in high-order digits when the number of significant figures is small.
Example: When "-123456" is input
-123456
Double word [signed] data
4) "00H" is automatically stored at the end (high-order byte of the 6th word) of the character string.
62
FX
3U(C)
Expression in each language
Structured ladder
DINT_TO_STR
Label 1
_DINT
X000
DINT_TO_STR_E
EN
Label 1
_DINT
Execution condition
Conversion source double word [signed] data
)
s
Execution status
String data after conversion
(
)
d
ASCII code for billions place
ASCII code for ten-millions place ASCII code for hundred-millions place
ASCII code for hundred-thousands place
ASCII code for thousands place
ASCII code for tens place
Automatically stored at the end of the character string
FX
FX
FX
3G
2N(C)
1N(C)
DINT_TO_STR(_DINT);
Example:
Label 2:=
*1
Label 2
DINT_TO_STR(Label 1);
DINT_TO_STR_E(EN,_DINT,
Output label);
Example:
ENO
DINT_TO_STR_E(X000,
*1
Label 2
Label 1, Label 2);
Description
High-order byte
Low-order byte
ASCII code for millions place
ASCII code for ten-thousands place
ASCII code for hundreds place
00H
ASCII code for ones place
High-order byte
Low-order byte
20H (space)
20H (space)
31H (1)
33H (3)
35H (5)
00H
5 Applied Functions
5.1 Type Conversion Functions
FX
FX
/FX
FX
1S
U
2C
ST
Data type
Bit
Double Word [signed]
Bit
String
into string data, and
s
.
d
Sign data
String
2DH (-)
String
20H (space)
20H (space)
32H (2)
34H (4)
36H (6)
FX
0N
0(S)
1st word
2nd word
3rd word
4th word
5th word
6th word
1st word
2nd word
3rd word
4th word
5th word
6th word

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fx-kp-ok-e09r927

Table of Contents