Mitsubishi Electronics QSERIES Smoker User Manual


  Open as PDF
of 1204
 
7-231
HEX(P)
1
2
3
4
6
6
7
8
7.11 Character string processing instructions
7.11.14 Conversion from ASCII to hexadecimal BIN (HEX(P))
(3) Accurate processing will be conducted even in cases where the range of devices where the
ASCII code to be converted is being stored overlaps with the range of devices that will store
the converted BIN data.
(4) If the number of characters designated by n is not divisible by 4, "0" will be automatically
stored after the designated number of characters in the final device number of the devices
which are storing the converted BIN values.
(5) If the number of characters designated by n is "0", conversion processing will not be
conducted.
(6)
ASCII code that can be designated by includes from "30
H
" to "39
H
" and from "41
H
" to "46
H
"
.
Operation Error
(1) In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and
an error code is stored into SD0.
Characters outside the hexadecimal character string (that is, characters that are not in the
range of from "30
H
" to "39
H
", or from "41
H
" to "46
H
") have been set by .
(Error code: 4100)
The range for the number of characters designated by n following the device number
designated by exceeds the relevant device range. (Error code: 4101)
The range for the number of characters designated by n following the device number
designated by exceeds the relevant device range. (Error code: 4101)
The number of characters designated by n is a negative value. (Error code: 4101)
Program Example
(1) The following program converts the character string being stored from D0 to D4 to BIN data
and stores the result from D10 to D14 when X0 goes ON.
[Ladder Mode] [List Mode]
[Operation]
D12
D13
D11
D12
D13
D14
D11
31
H
(1)32
H
(2)
33
H
(3)34
H
(4)
35
H
(5)36
H
(6)
37
H
(7)38
H
(8)
41
H
(A)
39
H
(9)
D10
0 0
H
A
H
9
H
8
H
H
7
H
6
H
5
H
4
H
3
H
2
H
1
H
b15 b8b7 b0
b15
b12
b8b11 b7 b4 b0b3
+1
42
H
(B)32
H
(2)
41
H
(A)31
H
(1)
38
H
(8)
43
H
(C)
0008
Value "0" is automatically stored in
the area outside the range of the
designated number of characters.
+1
+2
1A2
B
S
D
b15 b12 b8b11 b7 b4 b0b3
b15 b8
b7
b0
S
S
D
S
S
S
D
Instruction
Device
Step
D1
D2
D3
D4
36
H
(6)42
H
(B)
35
H
(5)32
H
(2)
41
H
(A)37
H
(7)
31
H
(1)33
H
(3)
39
H
(9)
37
H
(7)
D0
0
H
0
H
9
H
7
H
3
H
1
H
7
H
A
H
2
H
5
H
B
H
6
H
b15 b8b7 b0
b15 b12 b8b11 b7 b4 b0b3