![background image](http://html1.mh-extra.com/html/omron/trajexia-cj1w-mch72/trajexia-cj1w-mch72_operation-manual_742454319.webp)
How-to’s
Section 5-1
308
5-1-6-6 Using registration in application programs
There is one axis command (
REGIST
), and two axis parameters (
MARK
and
REG_POS
). With these commands and parameter, you can control and use
the registration functionality in BASIC programs.
•
REGIST
captures the axis position when a registration signal is detected.
The available settings depend on the axis type. Refer to section 4-2-200.
•
MARK
is a flag that signals whether the position has been captured or not.
For the second registration input of the
Encoder Interface
, the parameter
MARKB
is also available. For more information, refer to sections 4-2-152
and 4-2-153.
•
REG_POS
holds the captured axis position. Only if the
MARK
flag signals
that the position was captured successfully, you can regard the
REG_POS
value as valid. For the second registration input of the
Encoder Interface
, the
parameter
REG_POSB
is also available. For more information, refer to
sections 4-2-198 and 4-2-199.
The picture gives the sequence of executing the commands and the
registrations of the sample program below.
BASE(N)
REGIST(0)
WAIT UNTIL MARK=0
loop:
WAIT UNTIL MARK=-1
PRINT "Position captured in: "; REG_POS
REGIST(0)
WAIT UNTIL MARK=0
GOTO loop
Position
t
Registration Input
REG_POS=xxx
The trigger is active
MARK=0
REGIST(0)
REGIST(0)
MARK=-1
MARK=-1
MARK=0
MARK=-1
REG_POS=Pos1
REG_POS=Pos1
The trigger is active
If the trigger is
not active,
the registration is
ignored
The position
information is
available
Содержание trajexia CJ1W-MCH72
Страница 69: ...Specifications Section 2 4 58...
Страница 83: ...FINS commands Section 3 4 72...
Страница 147: ...All BASIC commands Section 4 2 136 AXIS 1 AXIS 0...
Страница 277: ...All BASIC commands Section 4 2 266...
Страница 278: ...267 SECTION 5 Examples This chapter gives 2 categories of examples and tips How to s Practical examples...
Страница 371: ...360 Index...
Страница 373: ...362...