● The result (ASCII code) should have twice the size of the source data.
■
Conversion example
H 0004
H 0000
DT10
[S1]…DT0 H ABCD
H 0002
Example 1) Operation unit: 16 bits (US, SS)
[S2]…DT1
DT2
DT11
DT12
DT13
DT14
H 4443
H 4241
DC
BA
(characters)
Example 2) Operation unit: 32 bits (UL, SL)
[S1]…DT0 [S2]…DT1
[D]…DT10
DT10
[S1]…DT0
H ABCD
H 0002
[S2]…DT1
DT2
DT11
DT12
DT13
DT14
H 4443
H 4241
DC
BA
(characters)
[S1]…DT0 [S2]…DT1
[D]…DT10
DT3
Example 3) Operation unit: 16 bits (US, SS)
DT10
[S1]…DT0
H 1234
H 5678
[S2]…DT2
DT1
DT11
DT12
DT13
DT14
H 3433
H 3231
43
21
(characters)
[S1]…DT0 [S2]…DT2
[D]…DT10
DT3
[D]
[D]
[D]
H 3837
H 3635
87
65
[i]…US,SS
[i]…UL,SL
[i]…US,SS
■
Precautions for programming
● The two characters that make up one byte are interchanged when stored.
● Converts two bytes as one section.
①② ③④
⑤⑥ ⑦⑧
③④② ①
[S1+1]
Hexadecimal data
[D+1] [D]
[S1]
Conversion result
⑦⑧⑥ ⑤
[D+3] [D+2]
14.3 HEXA (Conversion: HEX → Hexadecimal ASCII)
WUME-FP7CPUPGR-12 14-11