
Series 30i/31i/32i-MODEL A
PMC Supplemental Programming Manual
01 '05.12.26
H. Yonekura
New registration
B-63983EN/02-8
EDIT
DATE
DESIG.
DESCRIPTION
14/32
DRAW.NO.
3.1.4 Writing a P-CODE Macro Variable (Low-speed Response)
[Description]
Using this function, you can write value to a P-CODE variable or an
extended P-CODE variable for macro executor.
P-CODE variables #10000 to #19999
Extended P-CODE variables #20000 to #89999
For details of the P-CODE variables and extended P-CODE variables,
refer to the following manual.
- "Macro Compiler / Macro Executor PROGRAMMING MANUAL
(B-63943EN-2)"
[Input data structure]
Top Address +0 (Function code)
60
+2 (Completion code)
-
(Need not to be set)
+4 (Data length)
L=6
+6 (Data number)
N
(4 bytes)
N: Custom macro variable number
Signed binary format in 4 bytes length (note)
+10 (Data attribute)
M=0
Reserved
You should set 0 to this field.
+12 Mantissa
D1
(4 bytes)
Signed binary format in 4 bytes length
+16
+17
Number of decimal places
D2
(2 bytes)
Signed binary format in 2 bytes length
D2 = -1, 0 to 8 (Floating-point type)
D2 = 0 to 8 (Integer type)
NOTE
The data length is 4 bytes instead of 2 bytes.
You should set values to D1 and D2 when the custom macro variable is
expressed by the following formula.
[P-CODE variable] = D1 × 10
–D2