Omron SYSMAC CJ Operation Manual page 216

Sysmac cj-series programmable controller motion control unit
Hide thumbs Also See for SYSMAC CJ:
Table of Contents

Advertisement

All BASIC commands
4-2-161 MPOS
204
/i
Example
A satellite receiver sits on top of a van. It must align correctly to the sat-
ellite from data processed in a computer. This information is sent to the
controller through the serial link and sets VR(0) and VR(1). This infor-
mation is used to control the two axes.
MOVEMODIFY is used so that the position can be continuously
changed even if the previous set position is not achieved.
bearing=0 'set lables for VRs
elevation=1
UNITS AXIS(0)=360/counts_per_rev0
UNITS AXIS(1)=360/counts_per_rev1
WHILE IN(2)=ON
MOVEMODIFY(VR(bearing))AXIS(0) 'adjust bearing to match VR0
MOVEMODIFY(VR(elevation))AXIS(1)'adjust elevation to match
VR1
WA(250)
WEND
RAPIDSTOP 'stop movement
WAIT IDLE AXIS(0)
MOVEABS(0) AXIS(0) 'return to transport position
WAIT IDLE AXIS(1)
MOVEABS(0) AXIS (1)
/i
Type
Axis parameter (read-only)
Syntax
MPOS
Description
The MPOS parameter is the measured position of the axis in user units
as derived from the encoder. This parameter can be set using the
DEFPOS command. The OFFPOS axis parameter can also be used to
shift the origin point. MPOS is reset to 0 at start-up or after the controller
has been reset.
The range of the measured position is controlled with the REP_DIST
and REP_OPTION axis parameters.
Arguments
N/A
Section 4-2

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sysmac cj1w-mch72

Table of Contents