
181
Part 4 Commands
PRED (Read current position)
Command, declaration
Extension condition
(LD, A, O, AB, OB)
Input condition
(I/O, flag)
Command,
declaration
Operand 1
Operand 2
Output
(Output, flag)
Optional Optional PRED Axis
pattern
Position
number
CP
[Function] Read the current position of the axis specified in operand 1 to the position specified in
operand 2.
[Example 1]
PRED
11
10
Read the current positions of the X and Y-axes to
position No. 10.
[Example 2]
An axis pattern can be indirectly specified using a variable. An example of specifying
the operation in [Example 1] indirectly using a variable is shown below.
11 (binary)
3 (decimal)
LET
1
3
Assign 3 to variable 1.
PRED *1
10
[Example 3]
LET
1
10
Assign 10 to variable 1.
PRED
11
*1
Read the current positions of the X and Y-axes to the
content of variable 1 (position 10).
182
Part 4 Commands
PRDQ (Read current axis position (1 axis direct))
Command, declaration
Extension condition
(LD, A, O, AB, OB)
Input condition
(I/O, flag)
Command,
declaration
Operand 1
Operand 2
Output
(Output, flag)
Optional Optional PRDQ Axis
number
Variable
number
CP
[Function] Read the current position of the axis number specified in operand 1 to the variable specified
in operand 2.
Axis No. 1: X-axis, Axis No. 2: Y-axis, Axis No. 3: Z-axis, Axis No. 4: R-axis, Axis Nos. 5, 6:
Additional linear movement axes
[Example]
PRDQ 2
100
Read the current position of the Y-axis (axis 2) to
variable 100.
184
Summary of Contents for X-SEL PX
Page 1: ...Operation ManualSeventh Edition X SEL Controller PX QX Type Tenth Edition ...
Page 2: ......
Page 8: ......
Page 14: ......
Page 410: ...383 Appendix 386 ...
Page 452: ...425 Appendix 5 428 ...
Page 559: ......