439
Basic Program Examples
Section 11-2
Sample Ladder Program
11-2-6 Positioning (Absolute Movement or Relative Movement)
Overview
This sample program sends a positioning command to a Servo Drive con-
nected through MECHATROLINK communications.
Execute this sample program only after starting MECHATROLINK communi-
cations (establishing a connection), executing the Servo Lock function, and
verifying that the Servo Lock is engaged.
In addition, when executing ABSOLUTE MOVEMENT, establish the origin by
performing an origin search before sending the position command.
In this example, positioning is performed on the Servo Drive registered as axis
1 using the ABSOLUTE MOVEMENT Bit or RELATIVE MOVEMENT Bit in the
Axis Operating Output Memory Area.
The Axis Operating Output/Input Memory Areas are based on the settings of
the Common Parameter Area, as shown below. The application example in
11-3-1 Initial PCU Settings
shows a sample program that can be used to
make the following settings.
Beginning word of Axis Operating Output Memory Areas: CIO 0000
(Axis 1 Operating Output Memory Area: CIO 0000 to CIO 0024)
Beginning word of Axis Operating Input Memory Areas: CIO 1000
(Axis 1 Operating Input Memory Area: CIO 1000 to CIO 1024)
This sample program uses the following parts of the CPU Unit's I/O memory
in addition to the CIO Area words listed above.
Work Area (WR Area)
W201.00 to W201.03
Program name: Origin Search
Section name: Origin Search
000000
(000000)
1000.06
1000.13
Axis 1 Busy
1000.12
Axis 1 Error
W350.00
000001
(000005)
W350.01
1001.08
1000.06
Axis 1 No Origin
TIM
0002
#100
[OP1]
Origin Search Watchdog Timer
[OP2]
000002
(000009)
T0002
1000.06
Axis 1 No Origin
W350.02
000003
(000012)
0.06
1000.06
1000.13
Axis 1 Busy
1000.15
1000.12
Axis 1 Error
W350.02
Axis 1 Origin Search Timeout
W350.01
W350.01
000004
(000020)
W350.00
1.01
1.15
0.15
1522.00
1000.13
Axis 1 Busy
1000.12
Axis 1 Error
0.06
Axis 1 ORIGIN SEARCH
0.06
Axis 1 ORIGIN SEARCH
Origin Search
execution
condition
Axis 1 No
Origin
Searching for
Axis 1 Origin
Axis 1
Distribution
Completed
Execute Axis 1 Origin
Search
Origin Search
Watchdog
Timer
Axis 1 Origin Search
Timeout
Axis 1 ORIGIN
SEARCH
Axis 1 No
Origin
Searching for
Axis 1 Origin
Axis 1 STOP
EXECUTION
Execute Axis
1 Origin
Search
Axis 1 SERVO
UNLOCK
Axis 1
EMERGENCY
STOP
Axis 1 DE-
CELERATION
STOP
Axis 1
Communicating
Searching for Axis 1
Origin
Summary of Contents for CJ1W-NC271 - 12-2009
Page 2: ......
Page 4: ...iv ...
Page 6: ...vi ...
Page 22: ...xxii ...
Page 58: ...30 Starting Operation Section 2 2 ...
Page 244: ...216 Axis Operating Input Memory Areas Section 4 8 ...
Page 264: ...236 Transferring Servo Parameters Section 5 3 ...
Page 396: ...368 Linear Interpolation Section 9 7 ...
Page 648: ...620 List of Error Codes Appendix D ...
Page 674: ...646 Additional Functions for the CJ1W NCF71 MA Appendix F ...
Page 684: ...656 Index ...
Page 686: ...658 Revision History ...