Справочник Пользователя для Mitsubishi Electronics QCPU

Скачать
Страница из 1204
7-228
ASC(P)
7.11.13  
Conversion from hexadecimal BIN to ASCII (ASC(P))
ASC(P)
Function
(1) Converts the BIN 16-bit data stored in the area starting from the device designated by 
 to 
ASCII by treating the BIN data in hexadecimal representation.  Then, stores the converted 
data into the area starting from the device designated by 
, for the number of characters 
specified by n.
: Head number of the devices where BIN data to be converted to a character string is stored (BIN 16 bits)
: Head number of the devices where the converted character string will be stored (character string)
 n
: Number of characters to be stored (BIN 16 bits)
Setting 
Data
Internal Devices 
R, ZR
J
\
U
\G
Zn
Constants
K, H
Other
Bit
Word
Bit
Word
––
––
––
––
––
––
n
––
Process
High
performance
Redundant Universal
Basic
Command
Command
ASC
ASCP
n
n
ASC
ASCP
S
D
S
D
S
D
S
D
S
D
+1
+2
+3
+6
When "15" is 
set for n
1
H
2
H
3
H
4
H
+1
+4
+5
+7
5
H
6
H
7
H
8
H
F
H
E
H
D
H
C
H
A
H
9
H
B
H
6
H
BIN data
+1
+2
+3
+1
+2
+3
ASCII code for the 1st digit
ASCII code for the 2nd digit
ASCII code for the 3rd digit
ASCII code for the 4th digit
b15
b8b7
b0
ASCII code for the 1st digit
ASCII code for the 2nd digit
ASCII code for the 3rd digit
ASCII code for the 4th digit
ASCII code for the 1st digit
ASCII code for the 2nd digit
34
H
 (4)
33
H
 (3)
32
H
 (2)
31
H
 (1)
38
H
 (8)
37
H
 (7)
36
H
 (6)
35
H
 (5)
44
H
 (D)
46
H
 (F)
42
H
 (B)
00
H
43
H
 (C)
45
H
 (E)
36
H
 (6)
39
H
 (9)
4th digit
3rd digit 2nd digit 1st digit
4th digit
3rd digit 2nd digit 1st digit
4th digit
3rd digit 2nd digit 1st digit
b15
b12
b8
b11
b7
b4
b0
b3
S
D
S
D
D
D
b15
b12
b8
b11
b7
b4
b0
b3
b15
b8b7
b0
D
D
D
D
D
D
D
D
S
S
S
S
Number of 
characters 
designated by n