14.6 ABCD (Conversion: Decimal ASCII → BCD)
■
Ladder diagram
■
Available operation units (●: Available)
Operatio
n unit
bit US SS UL SL SF DF
i ● ●
■
List of operands
Operand Description
S1 Starting number of the area that stores an ASCII code
S2
The area that stores the data that express the number of ASCII codes to be converted and
conversion direction, or the constant
D Number of the start of the area storing the BCD value that is the result of conversion
■
Available devices (●: Available)
Operan
d
16-Bit device:
32-Bit
device:
Integer
Real
numbe
r
St
rin
g
Index
modifie
r
(Note 1)
W
X
W
Y
W
R
W
L
W
S
S
D
D
T
L
D
U
M
WI
W
O
TS
C
S
TE
C
E
IX K U H SF
D
F
" "
S1 ● ● ● ● ● ● ● ● ●
S2 ● ● ● ● ● ● ● ● ●
D ● ● ● ● ● ● ●
(Note 1) Only 16-bit devices, 32-bit devices, and integer constants can be modified. (Character constants
cannot be specified.)
■
Outline of operation
● This instruction converts up to 8-character ASCII code string into BCD data.
● The ASCII code stored in the area specified by [S1] is converted into BCD data and stored in
the area specified by [D].
● The number of ASCII codes (number of characters) to be converted and conversion direction
are specified by [S2].
● The resulting BCD data should have half the size of the source ASCII code string.
● The maximum value of the data size to be converted varies with the operation unit. (US: 4
characters, UL: 8 characters)
14.6 ABCD (Conversion: Decimal ASCII → BCD)
WUME-FP7CPUPGR-12 14-19