Download Print this page

Mitsubishi Electric MELSEC iQ-F FX5 Programming Manual page 448

Instructions, standard functions/function blocks
Hide thumbs Also See for MELSEC iQ-F FX5:

Advertisement

Number of specified digits (characters) and conversion result
(n)
(d)
D200
D201
D202
D203
D204
D205
D206
D207
D208
(1): Do not change
Bit configuration when (n) is K2
D100 = 0ABCH
0
0
0
0
0
D200 = ASCII code of B = 42H
0
0
0
0
D201 = ASCII code of C = 34H
0
0
0
0
Precautions
• When outputting data in the BCD format for a printer, for example, it is necessary to convert binary data into BCD data
before executing the ASCI(P) instructions.
• Whether NULL (00H) is stored after the last character or not depends on the ON/OFF status of the output character number
selector signal SM701. When SM701 is off, NULL (00H) is stored. When SM701 is on, the original data remains.
• Depending on the ON/OFF status of SM701 and SM8161, the number of devices occupied by (d) differs.
SM701
ON
ON
OFF
OFF
• When RS2, HEX, or CCD is used, the extension flag SM8161 is common to other instructions. When using an instruction
described above and the ASCI(P) instructions in the same program, make sure to set SM8161 to ON or OFF just before
each instruction so that SM8161 does not apply to another instruction.
Operation error
Error code
Description
(SD0/SD8067)
2820H
The device specified by (s) or (d) exceeds the corresponding device range.
3405H
The value specified by (s) is other than any of 1 to 32767.
8 APPLICATION INSTRUCTION
446
8.8 Character String Operation Instruction
K1
K2
K3
"C"
"B"
"A"
"C"
"B"
"C"
(1)
1
0
1
0
1
0
1
1
A
B
0
0
0
0
0
1
0
0
4
0
0
0
0
0
1
0
0
4
SM8161
ON
OFF
ON
OFF
K4
K5
K6
"0"
"4"
"3"
"A"
"0"
"4"
"B"
"A"
"0"
"C"
"B"
"A"
"C"
"B"
"C"
ASCII code
1
1
0
0
C
"0" = 30H
"A" = 41H
0
0
1
0
"B" = 42H
2
"C" = 43H
0
0
1
1
3
Number of devices occupied by (d)
Number of letters
Number of letters  2
Number of letters  1
(Number of letters  2) + 1
K7
K8
K9
"2"
"1"
"8"
"3"
"2"
"1"
"4"
"3"
"2"
"0"
"4"
"3"
"A"
"0"
"4"
"B"
"A"
"0"
"C"
"B"
"A"
"C"
"B"
"C"
"1" = 31H
"5" = 35H
"2" = 32H
"6" = 36H
"3" = 33H
"7" = 37H
"4" = 34H
"8" = 38H

Hide quick links:

Advertisement

loading