EasyManua.ls Logo

Delta Electronics EXIO14RAE - Page 142

Delta Electronics EXIO14RAE
157 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Appendix D Use of Application Instructions|DOP-EXIO Series
Revision March, 2008, Doc. Name: 2007PDD23000014 D-61
Mnemonic Operands Function
ASCI
S
D
n
Convert Hex to ASCII
Bit Devices Word Devices
X Y M S K H KnX KnY KnM KnS T C D E F
S
D
n
y Note:
1. Range of n: 1 ~ 256
16-bit instruction (7 Steps)
ASCI
Continuous
execution
32-bit instruction
- - - -
y Flags: M1161 (8/16 bit mode switch)
Operands:
S
: Start device for source data
D
: Start device for storing the converted result
n
: Number of bits to be converted
Explanations:
1. 16-bit conversion mode: When M1161 = Off, the instruction converts every bit of the hex data in S
into ASCII codes and send them to the 8 high bits and 8 low bits of
D. n = the converted number
of bits.
2. 8-bit conversion mode: When M1161 = On, the instruction converts every bit of the hex data in
S
into ASCII codes and send them to the 8 low bits of
D. n = the number of converted bits. (All 8
high bits of
D = 0)
Program Example 1:
1. M1161 = Off: The 16-bit conversion mode
2. When X0 = On, convert the 4 hex values in D10 into ASCII codes and send the result to registers
starting from D20.
X0
ASCI D10 D20 K4
M1001
M1161
3. Assume
(D10) = 0ABC H ‘0’ = 30H ‘1’ = 31H ‘5’ = 35H
(D11) = 1234 H ‘A’ = 41H ‘2’ = 32H ‘6’ = 36H
(D12) = 5678 H ‘B’ = 42H ‘3’ = 33H ‘7’ = 37H
‘C’ = 43H ‘4’ = 34H ‘8’ = 38H
4. When
n = 4, the bit structure will be as:

Related product manuals