All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form, or
by any means, mechanical, electronic, photocopying, recording, or otherwise, without the prior written permission of
OMRON.
No patent liability is assumed with respect to the use of the information contained herein. Moreover, because OMRON is
constantly striving to improve its high-quality products, the information contained in this manual is subject to change without
notice. Every precaution has been taken in the preparation of this manual. Nevertheless, OMRON assumes no responsibility
for errors or omissions. Neither is any liability assumed for damages resulting from the use of the information contained in
this publication.
Page 3
Introduction
Thank you for purchasing an NJ-series CPU Unit.
This manual contains information that is necessary to use the Motion Control Function Module of an
NJ-series CPU Unit. Please read this manual and make sure you understand the functionality and performance of the NJ-series CPU Unit before you attempt to use it in a control system.
Keep this manual in a safe place where it will be available for reference during operation.
Intended Audience
This manual is intended for the following personnel, who must also have knowledge of electrical systems (an electrical engineer or the equivalent).
• Personnel in charge of introducing FA systems.
• Personnel in charge of designing FA systems.
• Personnel in charge of installing and maintaining FA systems.
• Personnel in charge of managing FA systems and facilities.
For programming, this manual is intended for personnel who understand the programming language
specifications in international standard IEC 61131-3 or Japanese standard JIS B3503.
Introduction
Applicable Products
This manual covers the following products.
• NJ-series CPU Units
• NJ501-1300
• NJ501-1400
• NJ501-1500
NJ-series CPU Unit Motion Control User’s Manual (W507)
1
Page 4
Relevant Manuals
Relevant Manuals
There are three manuals that provide basic information on the NJ-series CPU Units: the NJ-series CPU
Unit Hardware User’s Manual, the NJ-series CPU Unit Software User’s Manual (this manual), and the
NJ-series Instructions Reference Manual.
Most operations are performed from the Sysmac Studio Automation Software. Refer to the Sysmac Studio Version 1 Operation Manual (Cat. No. W504) for information on the Sysmac Studio.
Other manuals are necessary for specific system configurations and applications.
Read all of the manuals that are relevant to your system configuration and application to make the most
of the NJ-series CPU Unit.
Basic information
NJ-series User’s Manuals
Introduction to NJ-series Controllers
Setting devices and hardware
Using motion control
Using EtherCAT
Using EtherNet/IP
Using CJ-series Units
Software settings
Using motion control
Using EtherCAT
Using EtherNet/IP
Programming
Using motion control
Using EtherCAT
Using CJ-series Units
Programming error processing
Testing operation and debugging
Using motion control
Using EtherCAT
Using EtherNet/IP
Troubleshooting and managing
errors in an NJ-series Controller
NJ-series CPU Unit
Hardware User´s Manual
Use the
relevant
manuals for
references
according to
any error that
occurs.
NJ-series CPU Unit
Software User´s Manual
NJ-series Instructions
Reference Manual
NJ-series CPU Unit Motion
Control User´s Manual
NJ-series CPU Unit Built-in
EtherCAT Port User´s Manual
NJ-series Motion Control
Instructions Reference Manual
NJ-series CPU Unit Built-in
EtherNet/IP Port User´s Manual
NJ-series Troubleshooting Manual
CJ-series Special Unit Operation
Manuals for NJ-series CPU Unit
Maintenance
Using EtherCAT
Using EtherNet/IP
Using CJ-series Units
2
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 5
Manual Configuration
NJ-series CPU Unit Hardware User’s Manual (Cat. No. W500)
SectionDescription
Section 1
Introduction
Section 2
System Configuration
Section 3
Configuration Units
Section 4
Installation and Wiring
Section 5
Troubleshooting
Section 6
Inspection and Maintenance
Appendices
This section provides an introduction to the NJ-series Controllers and their features,
and gives the NJ-series Controller specifications.
This section describes the system configuration used for NJ-series Controllers.
This section describes the parts and functions of the configuration devices in the NJseries Controller configuration, including the CPU Unit and Configuration Units.
This section describes where and how to install the CPU Unit and Configuration Units
and how to wire them.
This section describes the event codes, error confirmation methods, and corrections
for errors that can occur.
This section describes the contents of periodic inspections, the service life of the Battery and Power Supply Units, and replacement methods for the Battery and Power
Supply Units.
The appendices provide the specifications of the Basic I/O Units, Unit dimensions,
load short-circuit protection detection, line disconnection detection, and measures for
EMC Directives.
Manual Configuration
NJ-series CPU Unit Software User’s Manual (Cat. No. W501)
SectionDescription
Section 1
Introduction
Section 2
CPU Unit Operation
Section 3
I/O Ports, Slave Configuration, and
Unit Configuration
Section 4
Controller Setup
Section 5
Designing Tasks
Section 6
Programming
Section 7
Simulation, Transferring Projects to
the Physical CPU Unit, and Operation
Section 8
CPU Unit Status
Section 9
CPU Unit Functions
Section 10
Communications Setup
Section 11
Example of Actual Application Procedures
Section 12
Troubleshooting
Appendices
This section provides an introduction to the NJ-series Controllers and their features,
and gives the NJ-series Controller specifications.
This section describes the variables and control systems of the CPU Unit and CPU
Unit status.
This section describes how to use I/O ports, how to create the slave configuration
and unit configuration and how to assign functions.
This section describes the initial settings of the function modules.
This section describes the task system and types of tasks.
This section describes programming, including the programming languages and the
variables and instructions that are used in programming.
This section describes simulation of Controller operation and how to use the results
of simulation.
This section describes CPU Unit status.
This section describes the functionality provided by the CPU Unit.
This section describes how to go online with the CPU Unit and how to connect to
other devices.
This section describes the procedures that are used to actually operate an NJ-series
Controller.
This section describes the event codes, error confirmation methods, and corrections
for errors that can occur.
The appendices provide the CPU Unit specifications, task execution times, systemdefined variable lists, data attribute lists, CJ-series Unit memory information, CJseries Unit memory allocation methods, and data type conversion information.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3
Page 6
Manual Configuration
NJ-series CPU Unit Motion Control User’s Manual (Cat. No. W507)
(This Manual)
SectionDescription
Section 1
Introduction to the Motion Control
Function Module
Section 2
Motion Control Configuration and
Principles
Section 3
Configuring Axes and Axes Groups
Section 4
Checking Wiring from the Sysmac
Studio
Section 5
Motion Control Parameters
Section 6
Motion Control Programming
Section 7
Manual Operation
Section 8
Homing
Section 9
Motion Control Functions
Section 10
Sample Programming
Section 11
Troubleshooting
Appendices
This section describes the features, system configuration, and application flow for the
Motion Control Function Module.
This section outlines the internal structure of the CPU Unit and describes the configuration and principles of the MC Function Module.
This section describes the concept of axes and axes groups, the settings for axes
that are required for the MC Test Run operations to function on the Sysmac Studio,
and the instructions for creating and configuring axes and axes groups using the Sysmac Studio.
This section describes the MC Test Run operations of the Sysmac Studio. You can
use the MC Test Run operations to monitor sensor signals, check Servomotor wiring,
and more, all without any programming.
This section provides information on the axis parameters and axes group parameters
that are used for motion control.
This section provides the specifications of a motion control program and the operating procedures that are required up through actual program development.
This section describes manual operation when the MC Function Module is used
together with an OMRON G5-series Servo Drive.
This section describes homing.
This section describes the motion control functions that are used when connected to
OMRON G5-series Servo Drives with built-in EtherCAT communications.
This section describes basic application methods for homing, error monitoring, and
other functions, and provides programming samples for absolute positioning, cam
operation, and other axis operations.
This section describes the items to check when problems occur in the MC Function
Module. It includes error diagnosis and countermeasures for error indications, and
error diagnosis and countermeasures for operating conditions.
The appendices describe settings and connection methods for OMRON G5-series
Servo Drive objects.
This section provides a table of the instructions that are described in this manual.
This section describes instruction specifications in detail.
The appendices provide a table of error codes and other supplemental information to
use instructions.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 7
Manual Configuration
NJ-series CPU Unit Built-in EtherCAT Port User’s Manual
(Cat. No. W505)
SectionDescription
Section 1
Introduction
Section 2
Part Names and Slave Settings
Section 3
EtherCAT Communications
Section 4
EtherCAT Network Wiring
Section 5
Setting Up EtherCAT Communications with the Sysmac Studio
Section 6
Process Data Communications and
SDO Communications
Section 7
System-defined Variables That Are
Related to the Built-in EtherCAT Port
Section 8
Example of Operations for EtherCAT
Communications
Section 9
Troubleshooting
Appendices
This section provides an overview of EtherCAT communications, describes the system configuration and specifications, and provides operating procedures.
This section provides the part names and describes the slave settings and Sysmac
device functions.
This section describes the different types of EtherCAT communications, EtherCAT
settings, and state transitions.
This section describes how to connect and wire an EtherCAT network.
This section describes how to set the network configuration information and how to
check EtherCAT communications from the Sysmac Studio.
This section describes the timing of communications, response times, and special
instructions for process data communications and SDO communications. It also provides sample programming.
This section describes the system-defined variables that are related to the built-in
EtherCAT port.
This section provides a series of example operations for when an NJ-series CPU Unit
is connected to slaves.
This section describes the event codes, error confirmation methods, and corrections
for errors that can occur for EtherCAT communications. It also describes how to
replace slaves.
The appendices describe the relation of EtherCAT communications to overall CPU
Unit status, packet monitoring functions, and multi-vendor application.
NJ-series Motion Control Instructions Reference Manual
(Cat. No. W508)
SectionDescription
Section 1
Introduction to Motion Control
Instructions
Section 2
Variables and Instructions
Section 3
Axis Command Instructions
Section 4
Axes Group Instructions
Section 5
Common Command Instructions
AppendicesThe appendices describe the error codes that are generated by the instructions.
This section gives an introduction to motion control instructions supported by NJseries CPU Units.
This section describes the variables and instructions for the Motion Control Function
Module.
This section describes the instructions that are used to perform single-axis control for
the MC Function Module.
This section describes the instructions to perform multi-axes coordinated control for
the MC Function Module.
This section describes the instructions that are used for both axes and axes groups.
NJ-series Troubleshooting Manual (Cat. No. W503)
SectionDescription
Section 1
Overview of Errors
Section 2
Error Troubleshooting Methods
Section 3
Error Tables
This section describes the errors that can occur on an NJ-series Controller, the operation that occurs for errors, and methods to confirm errors.
This section describes how to handle errors.
This section lists all of the error events that can occur on NJ-series Controllers.
NJ-series CPU Unit Motion Control User’s Manual (W507)
5
Page 8
Manual Configuration
Sysmac Studio Version 1 Operation Manual (Cat. No. W504)
SectionDescription
Section 1
Introduction
Section 2
Installation and Uninstallation
Section 3
System Design
Section 4
Programming
Section 5
Online Connections to a Controller
Section 6
Debugging
Section 7
Other Functions
Section 8
Reusing Programming
Section 9
Support Software Provided with the
Sysmac Studio
Section 10
Troubleshooting
Appendices
This section provides an overview and lists the specifications of the Sysmac Studio
and describes its features and components.
This section describes how to install and uninstall the Sysmac Studio.
This section describes the basic concepts for designing an NJ-series System with the
Sysmac Studio and the basic operating procedures.
This section describes how to create programs with the Sysmac Studio.
This section describes how to go online with a Controller.
This section describes how to debug the programs online on the Controller or debug
it offline with the Simulator.
This section describes Sysmac Studio functions other than system design functions.
This section describes how to reuse the programs that you create with the Sysmac
Studio.
This section describes the Support Software that is provided with the Sysmac Studio.
This section describes the error messages that are displayed when you check a program on the Sysmac Studio and how to correct those errors.
The appendices describe the following:
Driver Installation for Direct USB Cable Connection
Specifying One of Multiple Ethernet Interface Cards
Online Help
Simulation Instructions
6
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 9
Manual Structure
Page Structure
The following page structure is used in this manual.
Manual Structure
Level 2 heading
Level 3 heading
A step in a procedure
Indicates a procedure.
Special information
Icons indicate
precautions, additional
information, or reference
information.
4 Installation and Wiring
4-3Mounting Units
4-3-1 Connecting Controller Components
The Units that make up an NJ-series Controller can be connected simply by pressing the Units together
and locking the sliders by moving them toward the back of the Units. The End Cover is connected in the
same way to the Unit on the far right side of the Controller.
1 Join the Units so that the connectors fit exactly.
2 The yellow sliders at the top and bottom of each Unit lock the Units together. Move the sliders
toward the back of the Units as shown below until they click into place.
Precautions for Correct UsePrecautions for Correct Use
The sliders on the tops and bottoms of the Power Supply Unit, CPU Unit, I/O Units, Special I/O
Units, and CPU Bus Units must be completely locked (until they click into place) after connecting
the adjacent Unit connectors.
Hook
Connector
Move the sliders toward the back
until they lock into place.
Hook holes
Release
Lock
Slider
Level 1 heading
Level 2 heading
Level 3 heading
Gives the current
headings.
stinU gnitnuoM 3-4
4
stnenopmoC rellortnoC gnitcennoC 1-3-4
Page tab
Gives the number
of the main section.
Manual name
NJ-series CPU Unit Hardware User’s Manual (W500)
This illustration is provided only as a sample. It may not literally appear in this manual.
Special Information
Special information in this manual is classified as follows:
Precautions for Safe Use
Precautions on what to do and what not to do to ensure safe usage of the product.
Precautions for Correct Use
Precautions on what to do and what not to do to ensure proper operation and performance.
Additional Information
Additional information to read as required.
This information is provided to increase understanding or make operation easier.
Note References are provided to more detailed or related information.
NJ-series CPU Unit Motion Control User’s Manual (W507)
4-9
7
Page 10
Manual Structure
Precaution on Terminology
In this manual, “download” refers to transferring data from the Sysmac Studio to the physical Controller
and “upload” refers to transferring data from the physical Controller to the Sysmac Studio.
For the Sysmac Studio, synchronization is used to both upload and download data. Here, “synchronize”
means to automatically compare the data for the Sysmac Studio on the computer with the data in the
physical Controller and transfer the data in the direction that is specified by the user.
8
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 11
Sections in this Manual
Sections in this Manual
1
2
3
4
5
Introduction to the
Motion Control
Function Module
Motion Control
Configuration and
Principles
Configuring Axes
and Axes Groups
Checking Wiring from
the Sysmac Studio
Motion Control Parameters
10
11
A
I
Sample Programming
Troubleshooting
Appendices
Index
1
2
3
4I
10
11
A
5
6
7
6
7
8
9
8
Motion Control Programming
9
Manual Operation
Homing
Motion Control Functions
NJ-series CPU Unit Motion Control User’s Manual (W507)
9
Page 12
Sections in this Manual
10
NJ-series CPU Unit Motion Control User’s Manual (W507)
NJ-series CPU Unit Motion Control User’s Manual (W507)
15
Page 18
CONTENTS
16
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 19
Read and Understand this Manual
Read and Understand this Manual
Please read and understand this manual before using the product. Please consult your OMRON representative
if you have any questions or comments.
Warranty and Limitations of Liability
WARRANTY
OMRON's exclusive warranty is that the products are free from defects in materials and workmanship for a
period of one year (or other period if specified) from date of sale by OMRON.
OMRON MAKES NO WARRANTY OR REPRESENTATION, EXPRESS OR IMPLIED, REGARDING NONINFRINGEMENT, MERCHANTABILITY, OR FITNESS FOR PARTICULAR PURPOSE OF THE
PRODUCTS. ANY BUYER OR USER ACKNOWLEDGES THAT THE BUYER OR USER ALONE HAS
DETERMINED THAT THE PRODUCTS WILL SUITABLY MEET THE REQUIREMENTS OF THEIR
INTENDED USE. OMRON DISCLAIMS ALL OTHER WARRANTIES, EXPRESS OR IMPLIED.
LIMITATIONS OF LIABILITY
OMRON SHALL NOT BE RESPONSIBLE FOR SPECIAL, INDIRECT, OR CONSEQUENTIAL DAMAGES,
LOSS OF PROFITS OR COMMERCIAL LOSS IN ANY WAY CONNECTED WITH THE PRODUCTS,
WHETHER SUCH CLAIM IS BASED ON CONTRACT, WARRANTY, NEGLIGENCE, OR STRICT
LIABILITY.
In no event shall the responsibility of OMRON for any act exceed the individual price of the product on which
liability is asserted.
IN NO EVENT SHALL OMRON BE RESPONSIBLE FOR WARRANTY, REPAIR, OR OTHER CLAIMS
REGARDING THE PRODUCTS UNLESS OMRON'S ANALYSIS CONFIRMS THAT THE PRODUCTS
WERE PROPERLY HANDLED, STORED, INSTALLED, AND MAINTAINED AND NOT SUBJECT TO
CONTAMINATION, ABUSE, MISUSE, OR INAPPROPRIATE MODIFICATION OR REPAIR.
NJ-series CPU Unit Motion Control User’s Manual (W507)
17
Page 20
Read and Understand this Manual
Application Considerations
SUITABILITY FOR USE
OMRON shall not be responsible for conformity with any standards, codes, or regulations that apply to the
combination of products in the customer's application or use of the products.
At the customer's request, OMRON will provide applicable third party certification documents identifying
ratings and limitations of use that apply to the products. This information by itself is not sufficient for a
complete determination of the suitability of the products in combination with the end product, machine,
system, or other application or use.
The following are some examples of applications for which particular attention must be given. This is not
intended to be an exhaustive list of all possible uses of the products, nor is it intended to imply that the uses
listed may be suitable for the products:
• Outdoor use, uses involving potential chemical contamination or electrical interference, or conditions or
uses not described in this manual.
• Nuclear energy control systems, combustion systems, railroad systems, aviation systems, medical
equipment, amusement machines, vehicles, safety equipment, and installations subject to separate
industry or government regulations.
• Systems, machines, and equipment that could present a risk to life or property.
Please know and observe all prohibitions of use applicable to the products.
NEVER USE THE PRODUCTS FOR AN APPLICATION INVOLVING SERIOUS RISK TO LIFE OR
PROPERTY WITHOUT ENSURING THAT THE SYSTEM AS A WHOLE HAS BEEN DESIGNED TO
ADDRESS THE RISKS, AND THAT THE OMRON PRODUCTS ARE PROPERLY RATED AND
INSTALLED FOR THE INTENDED USE WITHIN THE OVERALL EQUIPMENT OR SYSTEM.
PROGRAMMABLE PRODUCTS
OMRON shall not be responsible for the user's programming of a programmable product, or any
consequence thereof.
18
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 21
Read and Understand this Manual
Disclaimers
CHANGE IN SPECIFICATIONS
Product specifications and accessories may be changed at any time based on improvements and other
reasons.
It is our practice to change model numbers when published ratings or features are changed, or when
significant construction changes are made. However, some specifications of the products may be changed
without any notice. When in doubt, special model numbers may be assigned to fix or establish key
specifications for your application on your request. Please consult with your OMRON representative at any
time to confirm actual specifications of purchased products.
DIMENSIONS AND WEIGHTS
Dimensions and weights are nominal and are not to be used for manufacturing purposes, even when
tolerances are shown.
PERFORMANCE DATA
Performance data given in this manual is provided as a guide for the user in determining suitability and does
not constitute a warranty. It may represent the result of OMRON's test conditions, and the users must
correlate it to actual application requirements. Actual performance is subject to the OMRON Warranty and
Limitations of Liability.
ERRORS AND OMISSIONS
The information in this manual has been carefully checked and is believed to be accurate; however, no
responsibility is assumed for clerical, typographical, or proofreading errors, or omissions.
NJ-series CPU Unit Motion Control User’s Manual (W507)
19
Page 22
Read and Understand this Manual
20
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 23
Safety Precautions
Definition of Precautionary Information
Refer to the following manuals for safety precautions.
• NJ-series CPU Unit Hardware User’s Manual (Cat. No. W500)
• NJ-series CPU Unit Software User’s Manual (Cat. No. W501)
Safety Precautions
NJ-series CPU Unit Motion Control User’s Manual (W507)
21
Page 24
Precautions for Safe Use
Precautions for Safe Use
Refer to the following manuals for precautions for safe use.
• NJ-series CPU Unit Hardware User’s Manual (Cat. No. W500)
• NJ-series CPU Unit Software User’s Manual (Cat. No. W501)
22
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 25
Precautions for Correct Use
Refer to the following manuals for precautions for correct use.
• NJ-series CPU Unit Hardware User’s Manual (Cat. No. W500)
• NJ-series CPU Unit Software User’s Manual (Cat. No. W501)
Precautions for Correct Use
NJ-series CPU Unit Motion Control User’s Manual (W507)
23
Page 26
Regulations and Standards
Regulations and Standards
Conformance to EC Directives
Applicable Directives
• EMC Directives
• Low Voltage Directive
Concepts
z EMC Directive
OMRON devices that comply with EC Directives also conform to the related EMC standards so that
they can be more easily built into other devices or the overall machine. The actual products have
been checked for conformity to EMC standards.*
Whether the products conform to the standards in the system used by the customer, however, must
be checked by the customer. EMC-related performance of the OMRON devices that comply with EC
Directives will vary depending on the configuration, wiring, and other conditions of the equipment or
control panel on which the OMRON devices are installed. The customer must, therefore, perform the
final check to confirm that devices and the overall machine conform to EMC standards.
* Applicable EMC (Electromagnetic Compatibility) standards are as follows:
EMS (Electromagnetic Susceptibility): EN 61131-2 and EN 61000-6-2
EMI (Electromagnetic Interference): EN 61131-2 and EN 61000-6-4 (Radiated emission: 10-m regulations)
z Low Voltage Directive
Always ensure that devices operating at voltages of 50 to 1,000 VAC and 75 to 1,500 VDC meet the
required safety standards. The applicable directive is EN 61131-2.
z Conformance to EC Directives
The NJ-series Controllers comply with EC Directives. To ensure that the machine or device in which
the NJ-series Controller is used complies with EC Directives, the Controller must be installed as follows:
• The NJ-series Controller must be installed within a control panel.
• You must use reinforced insulation or double insulation for the DC power supplies connected to
DC Power Supply Units and I/O Units.
• NJ-series Controllers that comply with EC Directives also conform to the Common Emission Standard (EN 61000-6-4). Radiated emission characteristics (10-m regulations) may vary depending
on the configuration of the control panel used, other devices connected to the control panel, wiring, and other conditions.
You must therefore confirm that the overall machine or equipment complies with EC Directives.
24
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 27
Conformance to Shipbuilding Standards
The NJ-series Controllers comply with the following shipbuilding standards. Applicability to the shipbuilding standards is based on certain usage conditions. It may not be possible to use the product in
some locations. Contact your OMRON representative before attempting to use a Controller on a
ship.
Usage Conditions for NK and LR Shipbuilding Standards
• The NJ-series Controller must be installed within a control panel.
• Gaps in the door to the control panel must be completely filled or covered with gaskets or other
material.
• The following noise filter must be connected to the power supply line.
Noise Filter
ManufacturerModel
Cosel Co., Ltd.TAH-06-683
Regulations and Standards
Trademarks
• Sysmac and SYSMAC are trademarks or registered trademarks of OMRON Corporation in Japan
and other countries for OMRON factory automation products.
• Windows, Windows 98, Windows XP, Windows Vista, and Windows 7 are registered trademarks of
Microsoft Corporation in the USA and other countries.
•EtherCAT is a registered trademark of Beckhoff Automation GmbH for their patented technology.
• The SD logo is a trademark of SD-3C, LLC.
Other company names and product names in this document are the trademarks or registered trademarks of their respective companies.
Software Licenses and Copyrights
This product incorporates certain third party software. The license and copyright information associated with this software is available at http://www.fa.omron.co.jp/nj_info_e/.
NJ-series CPU Unit Motion Control User’s Manual (W507)
25
Page 28
Unit Versions
Unit Versions
Unit Versions
A “unit version” has been introduced to manage CPU Units in the NJ Series according to differences in
functionality accompanying Unit upgrades.
Notation of Unit Versions on Products
The unit version is given on the ID information label of the products for which unit versions are managed, as shown below.
Example for NJ-series NJ501-@@@@ CPU Unit:
ID information label
Unit model
NJ501 -1500Ver.1.@@
PORT1 MAC ADDRESS: @@@@@@@@@@@@
PORT2 MAC ADDRESS: @@@@@@@@@@@@
Lot No. DDMYY@xxxx
Unit version
Lot number and serial numberMAC address
The following information is provided on the ID information label.
ItemDescription
Unit modelGives the model of the Unit.
Unit versionGives the unit version of the Unit.
Lot number and
serial number
MAC addressGives the MAC address of the built-in port on the Unit.
Gives the lot number and serial number of the Unit.
DDMYY: Lot number, @: For use by OMRON, xxxx: Serial number
“M” gives the month (1 to 9: January to September, X: October, Y: November, Z: December)
26
Confirming Unit Versions with Sysmac Studio
You can use the Unit Production Information on the Sysmac Studio to check the unit version of the CPU
Unit, CJ-series Special I/O Units, CJ-series CPU Bus Units, and EtherCAT slaves. The unit versions of
CJ-series Basic I/O Units cannot be checked from the Sysmac Studio.
z CPU Unit and CJ-series Units
1 Double-click CPU/Expansion Racks under Configurations and Setup in the Multiview
Explorer. Or, right-click CPU/Expansion Racks under Configurations and Setup and select
Edit from the menu.
The Unit Editor is displayed for the Controller Configurations and Setup layer.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 29
Unit Versions
2 Right-click any open space in the Unit Editor and select Production Information.
The Production Information Dialog Box is displayed.
Simple DisplayDetailed Display
In this example, “Ver.1.0” is displayed next to the unit model.
The following items are displayed.
CPU UnitCJ-series Units
Unit model
Unit version
Lot number
Unit model
Unit version
Lot number
Rack number, slot number, and unit number
z EtherCAT Slaves
1 Double-click EtherCAT under Configurations and Setup in the Multiview Explorer. Or, right-
click EtherCAT under Configurations and Setup and select Edit from the menu.
The EtherCAT Configuration Tab Page is displayed for the Controller Configurations and Setup
layer.
2 Right-click the master in the EtherCAT Configurations Editing Pane and select Display Produc-
tion Information.
The Production Information Dialog Box is displayed.
The following items are displayed.
Node address
Type information*
Serial number
* If the model number cannot be determined (such as when there is no ESI file), the vendor ID, product
code, and revision number are displayed.
NJ-series CPU Unit Motion Control User’s Manual (W507)
27
Page 30
Unit Versions
Unit Version Notation
In this manual, unit versions are specified as shown in the following table.
Product nameplateNotation in this manualRemarks
“Ver.1.0” or later to the right of
the lot number
Unit version 1.0 or laterUnless unit versions are specified, the information in this manual
applies to all unit versions.
28
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 31
Related Manuals
The following manuals are related to the NJ-series Controllers. Use these manuals for reference.
NJ-series Motion Control
Instructions Reference
Manual
CJ-series Special Unit
Manuals for NJ-series
CPU Unit
W500NJ501-@@@@Learning the basic specifi-
cations of the NJ-series
CPU Units, including introductory information,
designing, installation, and
maintenance. Mainly hardware information is provided.
W501NJ501-@@@@Learning how to program
and set up an NJ-series
CPU Unit. Mainly software
information is provided.
W507NJ501-@@@@Learning about motion
control settings and programming concepts.
W502NJ501-@@@@Learning about the specifi-
W508NJ501-@@@@Learning about the specifi-
W490
W498
W499
W491
Z310
W492
W494
W497
CJ1W-@@@@Learning how to use CJ-
cations of the instruction
set that is provided by
OMRON.
cations of the motion control instructions that are
provided by OMRON.
series Units with an NJseries CPU Unit.
An introduction to the entire NJ-series system is
provided along with the following information on
a Controller built with an NJ501 CPU Unit.
• Features and system configuration
• Introduction
• Part names and functions
• General specifications
• Installation and wiring
• Maintenance and inspection
Use this manual together with the NJ-series CPU Unit Software User’s Manual (Cat. No.
W501).
The following information is provided on a Controller built with an NJ501 CPU Unit.
• CPU Unit operation
• CPU Unit features
• Initial settings
• Programming based on IEC 61131-3 language specifications
Use this manual together with the NJ-series CPU Unit Hardware User’s Manual (Cat. No.
W500).
The settings and operation of the CPU Unit and
programming concepts for motion control are
described. Use this manual together with the
NJ-series CPU Unit Hardware User’s Manual
(Cat. No. W500) and NJ-series CPU Unit Soft-ware User’s Manual (Cat. No. W501).
The instructions in the instruction set (IEC
61131-3 specifications) are described. When
programming, use this manual together with the
NJ-series CPU Unit Hardware User’s Manual
(Cat. No. W500) and NJ-series CPU Unit Software User’s Manual (Cat. No. W501).
The motion control instructions are described.
When programming, use this manual together
with the NJ-series CPU Unit Hardware User’s Manual (Cat. No. W500), NJ-series CPU Unit
Software User’s Manual (Cat. No. W501) and
NJ-series CPU Unit Motion Control User’s Manual (Cat. No. W507).
The methods and precautions for using CJseries Units with an NJ501 CPU Unit are
described, including access methods and programming interfaces. Manuals are available for
the following Units.
Analog I/O Units, Insulated-type Analog I/O
Units, Temperature Control Units, ID Sensor
Units, High-speed Counter Units, Serial Communications Units, and DeviceNet Units.
Use these manuals together with the NJ-series CPU Unit Hardware User’s Manual (Cat. No.
W500) and NJ-series CPU Unit Software User’s Manual (Cat. No. W501).
Related Manuals
NJ-series CPU Unit Motion Control User’s Manual (W507)
Learning about the operating procedures and functions of the Sysmac Studio.
networks (data links, routing tables, Communications Unit settings, etc.).
data for NS-series Programmable Terminals.
tocols for general-purpose
devices connected to CJseries Serial Communications Units.
Information on the built-in EtherCAT port is provided. This manual provides an introduction and
provides information on the configuration, features, and setup.
Use this manual together with the NJ-series CPU Unit Hardware User’s Manual (Cat. No.
W500) and NJ-series CPU Unit Software User’s Manual (Cat. No. W501).
Information on the built-in EtherNet/IP port is
provided. Information is provided on the basic
setup, tag data links, and other features.
Use this manual together with the NJ-series CPU Unit Hardware User’s Manual (Cat. No.
W500) and NJ-series CPU Unit Software User’s Manual (Cat. No. W501).
Concepts on managing errors that may be
detected in an NJ-series Controller and information on individual errors are described.
Use this manual together with the NJ-series CPU Unit Hardware User’s Manual (Cat. No.
W500) and NJ-series CPU Unit Software User’s Manual (Cat. No. W501).
Describes the operating procedures of the Sysmac Studio.
Describes operating procedures for the CX-Integrator.
Describes operating procedures for the CXDesigner.
Describes operating procedures for the CX-Protocol.
30
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 33
Revision History
A manual revision code appears as a suffix to the catalog number on the front and back covers of the
manual.
Revision History
Cat. No.
Revision codeDateRevised content
01July 2011Original production
W507-E1-01
Revision code
NJ-series CPU Unit Motion Control User’s Manual (W507)
31
Page 34
Revision History
32
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 35
Introduction to the Motion Control
Function Module
This section describes the features, system configuration, and application flow for the
Motion Control Function Module.
NJ-series CPU Unit Motion Control User’s Manual (W507)
1-1
Page 36
1 Introduction to the Motion Control Function Module
1-1Features
The Motion Control Function Module (sometimes abbreviated to “MC Function Module”) is a software
function module that is built into the CPU Unit. The MC Function Module can perform motion control for
up to 64 axes through the EtherCAT port that is built into the CPU Unit. Cyclic communications are performed with Servo Drives that are connected to the EtherCAT port to enable high-speed, high-precision
machine control.
Motion Control Instructions Based on PLCopen
The motion control instructions of the MC Function Module are based on motion control function blocks
that are standardized by PLCopen. These instructions allow you to program single-axis PTP positioning, interpolation control, synchronized control (e.g., of electronic cams), velocity control, and torque
control. You can set the velocity, acceleration rate, deceleration rate, and jerk each time a motion control instruction is executed to flexibly control operation according to the application.
Additional Information
• PLCopen
PLCopen is an association that promotes IEC 61131-3. It has its headquarters in Europe and a
world-wide membership. PLCopen standardizes function blocks for motion control to define a
program interface for the languages specified in IEC 61131-3 (JIS B 3503).
•Jerk
Jerk is the rate of change in the acceleration rate or deceleration rate. If you specify the jerk, the
velocity graph will form an S-curve for acceleration and deceleration.
Data Transmission Using EtherCAT Communications
The MC Function Module can be combined with OMRON G5-series Servo Drives with built-in EtherCAT
communications to enable exchange of all control information with high-speed data communications.
The various control commands are transmitted via data communications. That means that the Servomotor's operational performance is maximized without being limited by interface specifications, such as
the response frequency of the encoder feedback pulses. You can use the Servo Drive's various control
parameters and monitor data on a host controller to unify management of system information.
Additional Information
1-2
What Is EtherCAT?
EtherCAT is an open high-speed industrial network system that conforms to Ethernet (IEEE
802.3). Each node achieves a short cycle time by transmitting Ethernet frames at high speed. A
mechanism that allows sharing clock information enables high-precision synchronized control
with low communications jitter.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 37
1 Introduction to the Motion Control Function Module
1-2System Configuration
The MC Function Module receives sensor signal status from devices and control panels. It receives
commands from the motion control instructions that are executed in the user program. It uses both of
these to perform motion control with the Servo Drives and Encoder Input Terminals.
1-2 System Configuration
z Motion Control Configuration
The EtherCAT network configuration and Sysmac Studio are used for the MC Function Module.
• EtherCAT Network Configuration
The MC Function Module performs control for Servo Drives and Encoder Input Terminals through
the EtherCAT master port that is built into the CPU Unit. The EtherCAT network configuration is
used to perform precise motion control in a fixed period with very little deviation.
• Sysmac Studio
The Sysmac Studio is connected to the peripheral USB port on the CPU Unit with a commercially
available USB cable. You can also connect it to the built-in EtherNet/IP port on the CPU Unit with
Ethernet cable.
Sysmac Studio
Peripheral USB port
EtherCAT
G5-series Servo Drives with Built-in
EtherCAT Communications
EtherCAT Network
Configuration
Encoder Input Terminal
LAN
USB
Or
EtherNet/IP
NJ-series Controller
Power Supply Unit
Built-in EtherNet/IP port
Built-in EtherCAT port
Positive limit input
Negative limit input
Immediate stop input
Home proximity input
Home input
External latch input, etc.
CPU Unit
1
NJ-series CPU Unit Motion Control User’s Manual (W507)
1-3
Page 38
1 Introduction to the Motion Control Function Module
1-3Application Procedure
This section provides the basic procedure to perform motion control with the MC Function Module.
Basic Flow of Operation
START
Transferring
Checking Wiring
Checking Operation
Create a project.Setup
Create the EtherCAT Network Configuration.
Add axes.
Assign the axes.
Set the axis parameters.
Set the Controller Setup.
Transfer the project to the Controller.
Open the MC Test Run Tab Page.
Monitor input signals to check the wiring.
Perform jogging.
Sysmac Studio Version 1 Operation Manual
(Cat. No. W504)
NJ-series CPU Unit Software User’s Manual
*
(Cat. No. W501)
Section 3 Configuring Axes and Axes Groups
NJ-series CPU Unit Software User’s Manual
(Cat. No. W501)
Section 4 Checking Wiring from the Sysmac
Studio
Continues to on next page.
* The EtherCAT Network Configuration can be set online if you are connected to the physical network.
The EtherCAT Network Configuration can be selected offline if the hardware is not available yet.
1-4
A
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 39
A
1 Introduction to the Motion Control Function Module
1-3 Application Procedure
Programming
Manual operation
Homing
Programming
Debugging
Operation
Write a program to perform jogging.
Jog the axes with the user program.
Define the homes of the Servomotor axes to
control.
Program the motion controls.
Error?
No
Operate the Controller and the machine.
Yes
Read the error code.
Remove the cause of the error and clear the error.
Section 6 Motion Control Programming
Section 7 Manual Operation
Section 8 Homing
Section 6 Motion Control Programming
Section 10 Sample Programming
Section 11 Troubleshooting
Section 9 Motion Control
Functions
1
Maintenance
Perform periodic maintenance.
END
NJ-series CPU Unit Motion Control User’s Manual (W507)
1-5
Page 40
1 Introduction to the Motion Control Function Module
1-4Specifications
This section gives the specifications of the MC Function Module.
1-4-1General Specifications
General specifications conform to the general specifications of the CPU Unit.
Refer to the NJ-series CPU Unit Hardware User's Manual (Cat. No. W500) for details.
1-4-2Performance Specifications
Item
Applicable Servo DrivesOMRON G5-series Servo Drives with Built-in EtherCAT Communica-
Applicable Encoder Input Terminals
Control methodControl commands using EtherCAT communications
Control modesPosition control (Cyclic Synchronous Position Control Mode)
Number of controlled axes
Number of axes groups32 axes groups max.
Unit conversions Unit of displayPulses, millimeters, micrometers, nanometers, degrees, or inches
Positions that can be administeredCommand position and actual position
Position command values
Velocity command valuesNegative or positive long reals (LREAL) or 0 (command units/s)
Acceleration command values and deceleration command values
The acceleration/deceleration curve is automatically
adjusted for an axis motion or axes group motion. You can
select a trapezoidal curve or you can set the jerk for an Scurve.
You can change the acceleration or deceleration rate even
during acceleration or deceleration.
to confirm when positioning is completed.
ate stop input signal or limit input signal is valid.
You can change the input variables for a motion control
instruction during execution and execute the instruction
again to change the target values during operation.
You can specify when to start execution and how to connect
the velocities between operations when another motion control instruction is executed during operation.
You can specify the Transition Mode for multi-execution of
instructions for axes group operation.
You can detect when a range is exceeded during axis motion
and when the target position is outside the range when a
motion control instruction is executed. You can also set
warning values.
the actual current value is monitored for each axis and an
error is created to stop motion if a set value is exceeded.
You can set warning values for each axis and each axes
group.
Absolute Encoder to eliminate the need to perform homing at
startup.
The compensation method and setting range depend on the
specifications of the Servo Drive.
Home signal, home proximity signal, positive limit signal,
negative limit signal, immediate stop signal, and interrupt
input signal
1-4 Specifications
1
1-4-3 Function Specifications
NJ-series CPU Unit Motion Control User’s Manual (W507)
1-9
Page 44
1 Introduction to the Motion Control Function Module
1-10
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 45
Motion Control Configuration and
Principles
This section outlines the internal structure of the CPU Unit and describes the configuration and principles of the MC Function Module.
2-1 Internal Configuration of the CPU Unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-2
NJ-series CPU Unit Motion Control User’s Manual (W507)
2-1
Page 46
2 Motion Control Configuration and Principles
2-1Internal Configuration of the CPU
Unit
This section provides an overview of the internal mechanisms of the NJ-series CPU Unit. The CPU Unit
has the following software configuration. The Motion Control Function Module is a software module that
performs motion control.
Motion Control Function
Module
PLC Function Module
* Refer to the NJ-series CPU Unit Hardware User's Manual (Cat. No. W500) for details.
The PLC Function Module runs on top of the OS. The other Function Modules run on top of the PLC
Function Module. A description of each Function Module is given in the following table.
Function Module nameAbbreviationDescription
PLC Function ModulePLCThis module manages overall scheduling, executes
Motion Control Function ModuleMCThis module performs motion control according to
EtherCAT Master Function ModuleECATThis module communicates with the EtherCAT
EtherCAT Master Function
Module
OS
the user program, sends commands to the Motion
Control Function Module, and provides interfaces to
USB and the SD Memory Card.
the commands from motion control instructions that
are executed in the user program. It sends data to
the EtherCAT Master Function Module.
slaves as the EtherCAT master.
Other Function
Modules
*
2-2
Note Refer to the NJ-series CPU Unit Hardware User's Manual (Cat. No. W500) for details on other Function Mod-
ules.
This manual provides the specifications and operating procedures for the Motion Control Function Module (sometimes abbreviated to “MC Function Module”). Refer to the other NJ-series user’s manuals as
required when using the MC Function Module in an application.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 47
2 Motion Control Configuration and Principles
2-2Motion Control Configuration
A control system built with Servo Drives generally controls motor operation with a semi-closed loop.
The semi-closed loop uses an encoder attached to the motor to detect the amount of rotation that has
been performed by the motor in response to the command value. This is provided as feedback of the
machine’s travel distance. The following error between the command value and actual motor rotation is
calculated and control is performed to bring the following error to zero.
In a machine configuration that uses the MC Function Module, no feedback information is provided for
the commands from the user program in the CPU Unit. A feedback system is built into the Servo Drive.
NJ-series CPU Unit
User programMC Function
Motion
control
instruction
Module
Command
interpretation
Data processing
EtherCAT
Communications
Master Module
Communications
processing
EtherCAT
communications
Servo Drive
Communica-
tions
processing
Command
interpretation
Status
Position
control
Velocity
control
Torque
control
2-2 Motion Control Configuration
2
M
E
A feedback system is not configured.
A feedback system is configured.
• When motion control instructions are executed in the user program, the MC Function Module interprets the resulting commands.
• The MC Function Module then performs motion control processing at a fixed period based on the
results of the command interpretation. It generates command values to send to the Servo Drive. The
following command values are generated: target position, target velocity, and target torque.
• The command values are sent by using PDO communications during each process data communications cycle of EtherCAT communications.
• The Servo Drive performs position loop control, velocity loop control, and torque loop control based
on the command values received during each process data communications cycle of EtherCAT communications.
• The encoder’s current value and the Servo Drive status are sent to the CPU Unit during each process
data communications cycle of EtherCAT communications.
Additional Information
• Motion control processing and process data communications in EtherCAT communications are
performed during the same time period.
• The MC Function Module controls the Servo Drive, which contains the position control loop,
velocity control loop, and torque control loop.
NJ-series CPU Unit Motion Control User’s Manual (W507)
2-3
Page 48
2 Motion Control Configuration and Principles
2-3Motion Control Principles
This section provides information on the CPU Unit tasks and how they relate to motion control.
2-3-1CPU Unit Tasks
Tasks are attributes of programs that determine the execution conditions and sequence of the programs. The NJ-series CPU Units support the following tasks.
Typ e of t askTask name
Tasks that execute programs at a fixed periodPrimary periodic task
Periodic tasks (execution priority: 16, 17, and 18)
Refer to the NJ-series CPU Unit Software User’s Manual (Cat. No. W501) for details on programs,
tasks, and setting methods.
Types of Tasks and Task Priority
The NJ-series CPU Unit can execute the user program with a single task or multiple tasks. Tasks have
an execution priority. Tasks with the highest execution priority are executed first. If the execution conditions are met for another task with a higher execution priority while a task is under execution, the task
with the higher execution priority is given priority in execution. The following table lists the tasks in which
you can use motion control instructions and the task priorities for the NJ-series CPU Unit.
Type of task
Primary
periodic task
Periodic tasks 0 or 1
* The CPU Unit has some periodic tasks with an execution priority of 17 or 18. However, you cannot use motion
control instructions in these tasks. These tasks also do not perform I/O refreshing.
Number of
tasks
14 (fixed)This task executes I/O refreshing, programs, and motion con-
PriorityOperation
trol in the specified task period. This task has the highest execution priority of all tasks and can be executed quickly and
precisely. Therefore, this task is best suited for situations when
synchronized control or highly responsive control is required.
Use the primary periodic task to execute all control with a single task.
16
*
These tasks execute programs and I/O refreshing in the specified task period. The execution period for this task is longer
than the execution period of the primary periodic task. Therefore, periodic tasks are used to execute programs. For example, synchronized control and control requiring a fast response
time are placed in the primary periodic task. Overall device
control is placed in a periodic task.
2-4
Precautions for Correct UsePrecautions for Correct Use
• Motion control instructions can be used in the primary periodic task and in a priority-16 peri-
odic task.
• If motion control instructions are used in any other tasks, an error will occur when the user program is built on the Sysmac Studio.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 49
2 Motion Control Configuration and Principles
Basic Operation of Tasks
z Overall Task Operation
The primary periodic task and periodic tasks operate based on the task period of the primary periodic task (also known as the primary period). The primary periodic task includes operations such as
system common processing and motion control in addition to I/O refreshing and user program execution. Processing of motion control instructions in the programs is executed during the next motion
control (MC) period after the END instruction is executed in the task.
Primary periodPrimary period
Primary
periodic task
Priority-16
periodic task
IO:I/O refreshing
UPG:User program execution
MC:Motion control
IOUPGMCIOUPGMC
A dotted line
represents a transition
to another task.
IOUPGUPG
Task period (primary period × 2)
A double line means that
all processing for that
task has been completed.
A dashed-dotted line means that
processing for that task has been
interrupted.
2-3 Motion Control Principles
2
2-3-1 CPU Unit Tasks
z Operation of the Primary Periodic Task
Task period (= primary period)
Task execution time
I/O refresh
Refresh
executed.
Output data processing
ProcessingProcessing contents
Output data processing• Output refresh data is created for Output Units that execute I/O refreshing.
Refresh execution• This process exchanges data with I/O.
Input data processing• Input refresh data is loaded from Input Units that execute I/O refreshing.
System common processing 1• Variable refresh processing (if there are accessing tasks) is performed.
Control processing
User program
execution
Input data processing
System common processing 1
• If forced refreshing is set, the forced refreshing values are reflected in the
output refresh data.
• If forced refreshing is set, the forced refreshing values are reflected in the
input refresh data that was read.
• Motion input processing is performed.
• Data tracing processing (sampling and trigger checking) is performed.
Motion control
System common processing 2
NJ-series CPU Unit Motion Control User’s Manual (W507)
2-5
Page 50
2 Motion Control Configuration and Principles
ProcessingProcessing contents
User program execution• Programs assigned to tasks are executed in the order that they are
assigned.
Motion control• The motion control commands from the motion control instructions in the
programs are executed.
• Motion output processing is performed.
System common processing 2• Variable refresh processing (if there are refreshing tasks) is performed.
• Variable access processing is performed.
z Operation of a Periodic Task with an Execution Priority of 16
You can refresh I/O in the priority-16 periodic task.
Task period
Task execution time
Task processing time
**
I/O refresh
Refresh
Output data processing
* The CPU Unit will temporarily interrupt the execution of a task in order to execute a task with a higher execution
priority.
Control
processing
executed.
Input data processing
System common
processing 1
User program
execution
Task processing time
Control
processing
User program
execution
System common
processing 2
Task Period
The primary period, which is the task period for the primary periodic task, is the standard period for execution. The primary period is automatically used as the motion control period. (It is also the same as the
process data communications cycle for EtherCAT communications.) Periodic task execution is synchronized with the primary period. Set the task period of a periodic task as an integer multiple of the primary
period. For example, if the primary period is 1 ms, then you can set the task period of a priority-16 periodic task to 4 ms. In that case, the start of the period for the primary periodic task and the periodic task
will match once every four primary periods. The following table lists the possible combinations of primary periodic task and periodic task periods.
Primary periodValid task periods for periodic tasks
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 51
2 Motion Control Configuration and Principles
2-3-2Example of Task Operations for Motion Control
Motion control instructions can be used in the primary periodic task or in a priority-16 periodic task. This
section provides examples of task operations.
Using Motion Control Instructions in the Primary Periodic Task
If high-speed motion control is required, place the motion control instructions (FB) in the primary periodic task.
Slave A
IN
Primary periodPrimary period
Primary
periodic task
1
Loading Data
The input data from the EtherCAT slaves (slave A) is loaded during the I/O refresh (IO).
2
Instruction Execution
The motion control instructions (FB) are executed based on the data that was loaded during
user program execution (UPG).
The output variables of the motion control instructions are refreshed at this point.
UPG
IOMCUPG
FB
Execution of motion control instructions
Servo
Execution command
IOMC
FB
2-3 Motion Control Principles
2
2-3-2 Example of Task Operations for Motion Control
3
Command Generation
Motion processing according to the motion control instructions (FB) that were executed is performed during motion control (MC) immediately after user program execution in the primary
periodic task. During this processing, execution commands for the Servo Drives are generated.
4
Sending Commands
The execution commands that were generated are sent to the Servo Drive during the I/O refresh
(IO) in the next period.
Additional Information
All instructions from inputs to execution command outputs to the Servo Drive are processed
quickly in this task. We recommend placing all motion control instructions in the primary periodic
task.
NJ-series CPU Unit Motion Control User’s Manual (W507)
2-7
Page 52
2 Motion Control Configuration and Principles
Using Motion Control Instructions in a Priority-16 Periodic Task
If high speed motion control is not required and/or your user program is too large, place motion control
instructions in a priority-16 periodic task.
z Timing of Processing
Motion control processing (MC) for the motion control instructions (FB) that are executed in the
same task period as the priority-16 periodic task are performed at the same time. Therefore, processing for multiple axes can be simultaneously executed or stopped.
Primary
periodic task
Priority-16
periodic task
Primary
periodic task
Priority-16
periodic task
Slave A
IN
Primary period
UPG
IOMC
Execution of motion control instructions
Slave A
IN
IOMC
UPG
IOMC
UPG
FB
Task period (primary period × 3)
IOMC
UPG
Primary period
UPG
UPG
IOMC
UPG
IOMC
UPG
FB
UPG
IOMC
UPG
IOMC
Servo
Execution command
UPG
IOMC
Servo
Execution command
UPG
IOMC
Execution of motion control instructions
Task period (primary period × 3)
1
Loading Data
The input data from the EtherCAT slaves (slave A) is loaded during the I/O refresh (IO).
2
Instruction Execution
The motion control instructions (FB) are executed based on the data that was loaded during
user program execution (UPG) in the priority-16 periodic task.
The output variables of the motion control instructions are refreshed at this point.
3
Command Generation
Motion control instructions (FB) are executed in the task period of the priority-16 periodic task
according to the motion control instructions (FB) that were executed. Motion processing is performed during motion control processing (MC) in the next primary periodic task after the periodic task. During this processing, execution commands for the Servo Drives are generated.
4
Sending Commands
The execution commands that were generated are sent to the Servo Drive during the I/O refresh
(IO) in the next period.
2-8
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 53
2 Motion Control Configuration and Principles
z Axis Variable Update Timing
Axis Variables are system-defined variables for some of the axis parameters and for the monitor
information, such as the actual position and error information for the axes controlled by the MC
Function Module.
If you access an Axis Variable during the priority-16 periodic task, the values of the variable that
were read at the start of the periodic task are used.
Also, the values of an Axis Variable are not written when a motion control instruction (FB) is executed. They are written in motion control processing (MC) at the start of the next periodic task.
I/O
OUT
Primary period
Primary
periodic task
Priority-16
periodic task
UPG
IOMC
Values of
Axis
Variable
are read
*1
UPG
IOMC
UPG
Execution of motion control instructions
Task period (primary period × 3)
UPG
FB
UPG
IOMC
UPG
IOMC
*3
*2
*1 The values of an Axis Variable are read at the start of user program execution for the periodic task.
*2 The values of an Axis Variable are not written when a motion control instruction (FB) is executed in the periodic
task.
*3 The values are written during this motion control processing (MC).
Servo
Execution
command
UPG
IOMC
2-3 Motion Control Principles
2
2-3-2 Example of Task Operations for Motion Control
Precautions for Correct UsePrecautions for Correct Use
• When motion control instructions are placed in a periodic task, the response time of the Servo
Drive will increase if the task period of the periodic task is lengthened.
• Make sure that all axes can be stopped safely for emergency stops, including emergency
stops commanded from external devices.
• The execution timing of motion control instructions in a priority-16 periodic task is not the same
as the execution timing for I/O control. Design the user program to allow for this.
Additional Information
For information on Axis Variables, refer to 3-1-3 Introduction to Axis Variables.
NJ-series CPU Unit Motion Control User’s Manual (W507)
2-9
Page 54
2 Motion Control Configuration and Principles
Using Motion Control Instructions in Two Different Types of Tasks
If you have processes that require high-speed motion control and processes that do not require highspeed motion control for the same axis, you can place the motion control instructions (FB) both in the
primary periodic task and in a priority-16 periodic task.
If motion control instructions (FB) are executed in both tasks within the period of the priority-16 periodic
task, the MC Function Module will perform motion processing for instructions in the primary periodic
task first.
For example, the MC_MoveAbsolute instruction is executed in the priority-16 periodic task. Then, the
MC_MoveRelative is executed for the same axis in the primary periodic task. The operation for this is
shown below.
• The MC Function Module will execute MC_MoveRelative first. MC_MoveAbsolute is executed with
multi-execution of instructions.
Servo
Primary period
Execution command for MC_MoveRelative
Primary
periodic task
Priority-16
periodic task
The values of output variables for a motion control instruction and the values of system-defined variables for motion control will change during the I/O refresh of the task that executed the instruction.
Therefore, you may notice different behavior depending on the task if you use motion control instructions for the same axis in different tasks. Make sure that you thoroughly understand the processes of
each task before you start to develop your user program.
UPG
IOMC
UPG
FB1
Task period (primary period × 3)
UPG
IOMC
FB2FB2FB2FB2
FB2: MC_MoveRelative
FB1: MC_MoveAbsolute
UPG
IOMC
UPG
IOMC
The instruction is buffered for
multi-execution of instructions.
UPG
IOMC
Precautions for Correct UsePrecautions for Correct Use
• If you include motion control instructions for the same axis in both the primary periodic task
and the priority-16 periodic task, pay close attention to the following when you develop your
user program: the execution order of the motion control instructions, the timing of updates for
system-defined variables for motion control, and the output timing of command values.
• If you use system-defined variables for motion control for the same axis in multiple tasks, pay
close attention to the differences in timing for updating system-defined variables for motion
control when you develop your user program.
2-10
Additional Information
For information on multi-execution of instructions, refer to 9-5-7 Multi-execution of Motion Control
Instructions (Buffer Mode).
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 55
2 Motion Control Configuration and Principles
2-4EtherCAT Communications and
Motion Control
The MC Function Module controls Servo Drive and encoder input slaves through the PDO communications of the EtherCAT Master Function Module in the CPU Unit. This section describes EtherCAT communications and other items related to the MC Function Module.
2-4-1CAN Application Protocol over EtherCAT (CoE)
The MC Function Module exchanges data with the slaves on EtherCAT using the CAN application protocol over EtherCAT (CoE). With CoE, the parameters and control information held by the slaves are
specified according to data specifications of the object dictionary (OD). To communicate the data
between the Controller (communications master) and slaves, two methods are used: process data
objects (PDOs), which periodically exchange data in realtime, and service data objects (SDOs), which
exchange data when required.
2-4 EtherCAT Communications and Motion
Control
2
2-4-1 CAN Application Protocol over EtherCAT (CoE)
The MC Function Module uses PDO communications for commands to refresh I/O data, such as data
for Servomotor position control, on a fixed control period. It uses SDO communications for commands
to read and write data at specified times, such as for parameter transfers.
Controller
(communications master)
PDO communications
SDO communications
EtherCAT
communications lines
Executed periodically.
Output data
Input data
Write data
Read data
Executed for requests.
Slaves
NJ-series CPU Unit Motion Control User’s Manual (W507)
2-11
Page 56
2 Motion Control Configuration and Principles
2-4-2Relationship between EtherCAT Master Function Module and MC
Function Module
The NJ-series CPU Unit can perform sequence control and motion control through connections to
EtherCAT slaves.
z Sequence Control
• I/O ports for configuration slaves are automatically created when you create the EtherCAT Config-
uration in EtherCAT Edit Tab Page.
• Perform sequence control through instructions other than motion control instructions.
z Motion Control
• I/O ports for configuration slaves are automatically created when you create the EtherCAT Config-
uration in EtherCAT Edit Tab Page.
• Create Axis Variables in Motion Control Setup View and assign the EtherCAT slaves for which
motion control is performed.
• Perform motion control through motion control instructions.
There are two types of EtherCAT slaves that can be assigned to Axis Variables: Servo Drive slaves and
encoder input terminal slaves.
Sequence
control
Motion control
User program in PLC
Function Module
Instructions
other than
motion control
instructions
User-created
function block
Motion control
instructions
Motion control
instructions
Executed
Executed
Executed
Ex-
ecuted
Ex-
ecuted
Axis Variables
CPU Unit
Variables
MC Function Module
Profile processing
Synchronization
processing
Other processing
Task period
Task period
EtherCAT
Master
Function
Module
I/O ports
EtherCAT
EtherCAT
CJ-series Units
Basic I/O
Units
Special Units
EtherCAT
slaves
Servo Drive or
encoder input terminal
EtherCAT slaves
Additional Information
• Commands are not sent directly through PDO communications to an EtherCAT slave that is
assigned to an Axis Variable for instructions other than motion control instructions. However,
the status of such an EtherCAT slave can be accessed indirectly through the Axis Variables.
• You can use SDO communications to read and write the objects of EtherCAT slaves that are
assigned to axes variables. However, do not use SDO communications to write objects that
are mapped to PDO communications. If you do, the operation of the slaves will depend on
slave specifications. For OMRON slaves, SDO communications will result in errors.
• If Servo Drive and encoder input terminal EtherCAT slaves are not assigned to axes variables,
you must execute sequence control for them in the same way as for general-purpose EtherCAT slaves.
2-12
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 57
2 Motion Control Configuration and Principles
2-4-3Relationship between Process Data Communications Cycle and
Motion Control Period
The PLC Function Module sends motion control commands to the MC Function Module when motion
control instructions are executed in the user program. The MC Function Module then performs motion
control processing based on those commands and sends the results of processing as commands to the
EtherCAT’s Servo Drive.
This type of data exchange is updated as shown in the following processing period.
Primary period = Motion control period = Process data communications cycle
for EtherCAT communications
CPU Unit
Basic I/O Units,
Special I/O Units,
and CPU Bus Units
Execution of user
program in PLC
Function Module
Sequence control period
(primary periodic task period or
periodic task period)
Slaves
2-4 EtherCAT Communications and Motion
Control
2
2-4-3 Relationship between Process Data Communications Cycle and Motion Control Period
NJ-series CPU Unit Motion Control User’s Manual (W507)
2-13
Page 58
2 Motion Control Configuration and Principles
2-14
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 59
Configuring Axes and Axes
Groups
This section describes the concept of axes and axes groups, the settings for axes that
are required for the MC test run function to operate on the Sysmac Studio, and the
instructions for creating and configuring axes and axes groups using the Sysmac Studio.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-1
Page 60
3 Configuring Axes and Axes Groups
3-1Axes
This section describes the axes that are used in a MC Function Module.
3-1-1Introduction to Axes
In a motion control system, the targets of motion control are called axes. An axis can be an actual
Servo Drive or encoder connected using EtherCAT or it can be a virtual Servo Drive or encoder within
the MC Function Module.
The MC Function Module supports the axis types that are given in the following table.
Axis typeDescription
Servo axis
Virtual servo axisThese are virtual axes that exist only inside the MC Function Module. They
Encoder axis
Virtual encoder axisThese axes are used virtually for encoder operation. A virtual encoder axis
*1
These are the axes used by the EtherCAT slave Servo Drives
assigned to actual Servo Drives. One Servomotor is used as one axis.
are not used by actual Servo Drives. For example, they are used as master
axes for synchronizing control.
An encoder axis uses an EtherCAT slave encoder input terminal
Encoder axes are assigned to actual encoder input terminals. If one
encoder input terminal contains two encoder inputs, the individual encoder
inputs will act as one axis.
is used temporarily in place of an encoder axis when there is no physical
encoder.
*3
. They are
*2
.
*1 The applicable Servo Drives are the OMRON G5-series Servo Drives with Built-in EtherCAT Communications.
*2 The applicable Encoder Input Terminals are the OMRON GX-series GX-EC0211/EC0241 Encoder I/O Termi-
nals.
*3 Virtual encoder axes are used in combination with motion control instructions that update the actual position of
the virtual encoder axis. Counting cannot be used with versions of the MC Function Module that do not support
these instructions.
The following elements are related to the axes of the MC Function Module.
These elements exist for each axis. The NJ501-1300 has axis parameters for 16 axes, the NJ501-1400
has axis parameters for 32 axes, and the NJ501-1500 has axis parameters for 64 axes.
Configuration elementDescriptionPage
Axis parametersThe axis parameters set the maximum velocity, jogging, homing,
and other items for the axes operations controlled by the MC Function Module. Use the Sysmac Studio to set the axis parameters.
Axis VariablesAxis Variables are system-defined variables for the actual position,
error information, and other monitor information for axes controlled
by the MC Function Module. Axis Variables are created when you
add an axis from the Multiview Explorer of the Sysmac Studio. The
names of the Axis Variables (called the Axis Variable names) are set
here.
Specifying axes in the
user program
In the user program, motion control is implemented with motion control instructions. Motion control instructions that perform single-axis
control are used to create axis commands. To control an axis with
axis commands, specify the Axis Variable name of the systemdefined variable or the Axis Variable name that was set with the Sysmac Studio for the Axis in-out variable of the instruction.
3-3
3-5
3-7
3-2
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 61
3-1-2Introduction to Axis Parameters
z Axis Parameters
ClassificationParameter name
Axis Basic
Settings
Unit Conversion
Settings
Operation Settings Maximum Velocity
Other
Operation Settings
Limit SettingsSoftware Limits
Position Count
Settings
Servo Drive
Settings
Axis Number
Axis Use
Axis Type
Node Address (input devices and output devices)
Unit of Display
Command Pulse Count Per Motor Rotation
Work Travel Distance Per Motor Rotation
Maximum Jog Velocity
Maximum Acceleration
Maximum Deceleration
Acceleration/Deceleration Over
Operation Selection at Reversing
Velocity Warning Value
Acceleration Warning Value
Deceleration Warning Value
Positive Torque Warning Value
Negative Torque Warning Value
Actual Velocity Filter Time Constant
In-position Range
In-position Check Time
Zero Position Range
Immediate Stop Input Stop Method
Limit Input Stop Method
Drive Error Reset Monitoring Time
Maximum Positive Torque Limit
Maximum Negative Torque Limit
Positive Software Limit
Negative Software Limit
Following Error Over Value
Following Error Warning Value
Count Mode
Modulo Maximum Position Setting Value
Modulo Minimum Position Setting Value
Encoder Type
Modulo Maximum Position Setting Value
Modulo Minimum Position Setting Value
3 Configuring Axes and Axes Groups
3-1 Axes
3
3-1-2 Introduction to Axis Parameters
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-3
Page 62
3 Configuring Axes and Axes Groups
ClassificationParameter name
Homing SettingsHoming Method
Home Input Signal
Homing Start Direction
Home Input Detection Direction
Operation Selection at Positive Limit Input
Operation Selection at Negative Limit Input
Homing Velocity
Homing Approach Velocity
Homing Acceleration
Homing Deceleration
Homing Jerk
Home Input Mask Distance
Home Offset
Homing Holding Time
Homing Compensation Value
Homing Compensation Velocity
Refer to 5-2 Axis Parameters for details on axis parameters.
z Settings Required to Use Axes
The following settings must be made to use the axes that are created with the Sysmac Studio.
ClassificationParameter nameSettingPage
Axis Basic
Settings
Axis NumberAxis numbers are automatically set in the order
that the axes are created.
Axis UseSelect Used axis.
Axis TypeSelect the type of axis to control.
Node Address (input
devices and output
devices)
Specify the node address of the EtherCAT slave
device that is assigned to the axis. The Node
Address parameter cannot be selected if the Axis
Type parameter is set to use a virtual axis.
5-5
z Required Settings to Perform a Servo Drive Test Run from the Sysmac Studio
Make the following settings to operate an EtherCAT-connected Servo Drive using the MC test run
function of the Sysmac Studio.
ClassificationParameter nameSettingPage
Axis Basic Settings
Axis NumberAxis numbers are set in order from the lowest
number.
Axis UseSelect Used axis.
Axis TypeSelect Servo axis.
Node Address (input
devices and output
devices)
Specify the node address of the EtherCAT slave
device that is assigned to the axis. The Node
Address parameter cannot be selected if the Axis
Type parameter is set to use a virtual axis.
5-5
3-4
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 63
3 Configuring Axes and Axes Groups
ClassificationParameter nameSettingPage
Unit Conversion
Settings
Position Count
Settings
Limit SettingsSoftware LimitsSet this parameter according to the device speci-
* For example, if the encoder resolution is 10,000 pulses/rotation, set 10,000.
Precautions for Correct UsePrecautions for Correct Use
Unit of DisplaySelect the display unit (mm, degrees, etc.).5-8
Command Pulse Count
Per Motor Rotation
Work Travel Distance
Per Motor Rotation
Count ModeSet this parameter according to the machine
Set the number of command pulses per motor
rotation according to the encoder resolution.
Set the workpiece travel distance per motor rotation according to the machine specifications.
specifications.
fications.
*
5-13
5-13
3-1 Axes
• Select the appropriate values based on the machine’s operating conditions for parameters
such as the maximum velocity, maximum acceleration/deceleration, or stop settings when the
motor is actually operated.
• OMRON G5-series Servo Drives can be set to specific node addresses by using the rotary
switches on the front panels. If the rotary switches are set to 00, the node address will be
determined by the settings made in the EtherCAT Editor of the Sysmac Studio. If the rotary
switches are set to 00 for all connected Servo Drives, errors will not occur even if the Servo
Drive’s connection position is changed. Set the node addresses on the rotary switches to
assign specific Servo Drives for each machine control.
3-1-3Introduction to Axis Variables
Axis Variables are system-defined variables for some of the axis parameters and for the monitor information, such as the actual position and error information, for the axes controlled by the MC Function
Module. When you create axes with the Sysmac Studio, Axis Variables are registered in the variable
table in the order that the axes are created. Axis variables are structures with a data type of
_sAXIS_REF.
z Axis Variables
Each Axis Variable in the MC Function Module has two variable names: The Axis Variable name in
the system-defined variables and the Axis Variable name that is assigned when the axis is added on
the Sysmac Studio. The Axis Variable names in the system-defined variables are _MC_AX[0] to
_MC_AX[63].
When you add axes on the Sysmac Studio, the MC_Axis000 to MC_Axis063 are set by default for
_MC_AX[0] to _MC_AX[63]. The numbers are assigned in the order that the axes are added. You
can change each of these Axis Variables as required from the Sysmac Studio. You can use either
the Axis Variables for the system-defined variables or the Axis Variables that are added on the Sysmac Studio to specify the Axis Variables in the user program.
Axis Variable name in the system-
defined variables (AT specification
in global variable table)*
_MC_AX[0]MC_Axis000Axis 0
_MC_AX[1]MC_Axis001Axis 1
.
.
.
_MC_AX[63]MC_Axis063Axis 63
Default Axis Variable name when
axis is added on the Sysmac Studio
.
.
.
Axis number example
.
.
.
3
3-1-3 Introduction to Axis Variables
* An error will occur if you change the names in the AT column in the global variable table on the Sysmac Studio.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-5
Page 64
3 Configuring Axes and Axes Groups
z Examples of Axis Variable Levels and Changing Axis Variable Names
_MC_AX[0]Axis Variable
_MC_AX[0].StatusLevel that indicates the axis status
_MC_AX[0].Status.ReadyVariable that indicates that the axis is ready for operation
_MC_AX[0].Status.DisabledVariable that indicates when the axis is disabled
.
.
.
_MC_AX[0].DetailsLevel that indicates the axis control status
_MC_AX[0].Details.IdleVariable that indicates when the axis is idle
_MC_AX[0].Details.InPosWaitingVariable that indicates in-position waiting
.
.
.
_MC_AX[0].CmdLevel that indicates the axis command values
_MC_AX[0].Cmd.PosVariable that indicates the command current position
_MC_AX[0].Cmd.VelVariable that indicates the command current velocity
_MC_AX[0].Cmd.AccDecVariable that indicates the command current acceleration/decelera-
.
.
.
_MC_AX[0].ActLevel that indicates the axis current values
_MC_AX[0].Act.PosVariable that indicates the actual current position
_MC_AX[0].Act.VelVariable that indicates the actual current velocity
_MC_AX[0].Act.TrqVariable that indicates the actual current torque
.
.
.
_MC_AX[0].CfgLevel that indicates the axis basic settings
_MC_AX[0].Cfg.AxNoVariable that indicates the axis number
_MC_AX[0].Cfg.AxEnableVariable that indicates when the axis is enabled
_MC_AX[0].Cfg.AxTypeVariable that indicates the axis type
.
.
.
_MC_AX[0].Scale.UnitsVariable that indicates the display unit
_MC_AX[1]Axis Variable
.
.
.
tion rate in the axis monitor
3-6
Example: If MC_Axis000 is changed to MyAxis1, then either MyAxis1.Act.Pos or
_MC_AX[0].Act.Pos can be used as the variable that indicates the actual current position.
Refer to Axis Variables on page 6-19 for details on Axis Variables.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 65
3 Configuring Axes and Axes Groups
3-1-4Specifying an Axis in the User Program
In the user program, an Axis Variable name is specified for the in-out variable Axis in motion control
instructions. In the following example, the Axis Variable name for the axis that was added for the system-defined Axis Variable name of _MC_AX[0] has been changed to MyAxis1 in the Sysmac Studio.
In-out variable Axis
Specify an Axis
Variable name.
MyAxis1
ServoOn
MC_Power_instance
MC_Power
AxisAxis
EnableStatus
Busy
Error
ErrorID
MyAxis1
MyAxis1OnStatus
MyAxis1OnBusy
MyAxis1OnError
MyAxis1OnErrorID
You can also use the _MC_AX[0] system-defined variable in place of MyAxis1.
Refer to 6-2 Motion Control Instructions for details on motion control instructions.
Refer to the instruction descriptions in the NJ-series Motion Control Instructions Reference Manual
(Cat. No. W508) for details on motion control instructions.
3-1 Axes
3
3-1-4 Specifying an Axis in the User Program
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-7
Page 66
3 Configuring Axes and Axes Groups
3-2Axis Setting Procedure
This section gives the procedures to set servo axes that are newly created with the Sysmac Studio.
3-2-1Axis Configuration Procedure
START
Create a project.
Create the EtherCAT Network Configuration.
Add axes.
Assign the axes.
Set the axis parameters.
Go online and synchronize the data.
Transfer the project to the Controller.
END
3-2-2Setting Procedure
This section describes how to set an axis.
Starting the Sysmac Studio
1
Start the Sysmac Studio and click the New Project Button.
2
Set the project properties and click the Create Button.
3-8
A new project is displayed.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 67
3 Configuring Axes and Axes Groups
3-2 Axis Setting Procedure
Creating the EtherCAT Network Configuration
There are two methods to create an EtherCAT Network Configuration: online and offline.
z Online Method
1
Double-click EtherCAT in the Multiview Explorer.
The EtherCAT Edit Tab Page is displayed.
2
Select Online from the Controller Menu. The Sysmac Studio goes online with the Controller.
3
Right-click the Master Icon in the EtherCAT Tab Page and select Compare and Merge with
Actual Network Configuration from the menu.
3
3-2-2 Setting Procedure
When obtaining the information is completed, the physical slave configuration of the EtherCAT
slaves is displayed. Right-click the displayed physical configuration and select Apply actual
network configuration.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-9
Page 68
3 Configuring Axes and Axes Groups
z Offline Method
1
Double-click EtherCAT in the Multiview Explorer.
The EtherCAT Edit Tab Page is displayed.
2
Right-click the slave to connect and select Insert from the menu.
3-10
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 69
The slave is inserted on the display.
3 Configuring Axes and Axes Groups
3-2 Axis Setting Procedure
3
3-2-2 Setting Procedure
3
Insert the remaining slaves.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-11
Page 70
3 Configuring Axes and Axes Groups
Adding Axes
1
Right-click Axis Settings in the Multiview Explorer and select Axis Settings from the Add
Menu.
An axis is added to the Multiview Explorer. The default name for the new axis is MC_Axis000.
z Copying an Axis
You can also add an axis by copying the axis settings for an existing axis.
3-12
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 71
Assigning an Axis
1
Right-click an axis in the Multiview Explorer and select Edit from the menu.
The Axis Basic Settings are displayed in the Axis Parameter Settings Tab Page.
3 Configuring Axes and Axes Groups
3-2 Axis Setting Procedure
3
3-2-2 Setting Procedure
2
Select Servoaxis in the Axis type Box.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-13
Page 72
3 Configuring Axes and Axes Groups
3
Select the Servo Drive to use in the Input Device Box.
This setting allows you to use the EtherCAT slave Servo Drive as an axis.
Setting Axis Parameters
1
Click each of the icons in the Axis Parameter Settings Tab Page.
The settings for each icon are displayed on the Axis Parameter Settings Tab Page.
3-14
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 73
3 Configuring Axes and Axes Groups
Right-click Axis Settings in the Multiview Explorer and select Axis Setting Table to enable set-
ting the axes parameters for all axes at the same time.
3-2 Axis Setting Procedure
3
3-2-2 Setting Procedure
Precautions for Correct UsePrecautions for Correct Use
When making operation settings such as the display unit, electronic gear (unit conversion formula), maximum velocity, or maximum acceleration/deceleration, be sure to use appropriate values for the operating conditions of the device.
Additional Information
Changing Axis Variable Names in the User Program
Perform the following two procedures to change Axis Variable names that are already used.
• Change the Axis Variable name in the variable table in the variable declarations.
• Change the Axis Variable name in the user program.
Even if you change the Axis Variable names in the variable table, the Axis Variable names in the
user program do not change. An error will occur if you use a variable name that is not declared in
the variable table, in the user program. Always change the names in both places.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-15
Page 74
3 Configuring Axes and Axes Groups
Downloading to the CPU Unit
Use the Synchronization menu command of the Sysmac Studio to download the project to the CPU
Unit.
1
Select Online from the Controller Menu. The Sysmac Studio goes online with the Controller.
2
Select Synchronization from the Controller Menu and then click the Transfer to Controller
Button.
Additional Information
Introduction to Servo Drive Settings
The MC Function Module connects to OMRON G5-series Servo Drives with built-in EtherCAT
communications.
Compatible Models
The applicable model numbers are R88D-KN@@@-ECT.
The R88D-KN@@@-ECT-R Servo Drives support only Position Control Mode (Cyclic Syn-
chronous Position Control Mode). Therefore, any functions that use Velocity Control Mode
(Cyclic Synchronous Velocity Control Mode) or Torque Control Mode (Cyclic Synchronous
Torque Control Mode) cannot be used.
Servo Drive Settings
The MC Function Module uses some of the input signals and functions of the Servo Drives.
Servo Drive signal wiring and object setting are required to use the MC Function Module
properly. Refer to A-1 Connecting the Servo Drive for specific settings.
3-16
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 75
3-3Axes Groups
This section describes the axes groups of the MC Function Module.
3 Configuring Axes and Axes Groups
3-3-1Introduction to Axes Groups
Use axes groups to perform complex operations on multiple axes, such as linear or circular interpolation. An axes group consists of multiple axes. Use the Sysmac Studio to set Axes Group Variables to
enable execution of axes group motion control instructions or to enable access of the status of the axes
group. The MC Function Module can handle up to 32 groups. The specifications for axes groups are
shown in the following table.
ItemSpecification
Number of axes groups32 groups max.
Number of composition axes4 axes max. per axes group
The following elements are related to the axes groups of the MC Function Module.
Configuration elementDescriptionPage
Axes group parametersThe axes group parameters set the maximum interpolation veloc-
ity, maximum interpolation acceleration/deceleration, and other
items for the axes groups controlled by the MC Function Module.
Use the Sysmac Studio to set the axes group parameters.
Axes Group VariableAxes Group Variables are system-defined variables that include a
portion of the axes group parameters as well as the command
interpolation velocity, error information, and other monitor information for the axes groups controlled by the MC Function Module.
Axes Group Variables are created when you add an axes group
from the Multiview Explorer of the Sysmac Studio. The names of
the Axes Group Variables (called the Axes Group Variable names)
are set here.
Specifying axes groups
in the user program
In the user program, motion control is implemented with motion
control instructions. Motion control instructions that perform multiaxis coordinated control are used to create axes group commands.
To control an axes group with axes group commands, specify the
axes group variable name of the system-defined variable or the
axes group variable name that was set with the Sysmac Studio for
the AxesGroup in-out variable of the instruction.
3-3 Axes Groups
3
3-3-1 Introduction to Axes Groups
3-18
3-19
3-21
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-17
Page 76
3 Configuring Axes and Axes Groups
3-3-2Introduction to Axes Group Parameters
z Axes Group Parameters
ClassificationParameter name
Axes Group Basic Settings
Axes Group Operation
Settings
Axes Group Number
Axes Group Use
Composition
Composition Axes
Maximum Interpolation Velocity
Maximum Interpolation Acceleration
Maximum Interpolation Deceleration
Interpolation Acceleration/Deceleration Over
Interpolation Velocity Warning Value
Interpolation Acceleration Warning Value
Interpolation Deceleration Warning Value
Axes Group Stop Method
Correction Allowance Ratio
Refer to 5-3 Axes Group Parameters for details on axes group parameters.
z Settings Required to Use an Axes Group
The following settings must be made to use the axes groups that are created with the Sysmac Studio.
ClassificationParameter nameSettingPage
Axes Group
Basic Settings
Precautions for Correct UsePrecautions for Correct Use
Set appropriate values for the maximum interpolation velocity, stop method, and other items
based on the operating conditions.
Axes Group
Number
Axes Group UseSelect Use.
CompositionSelect the axis composition to control.
Composition AxesThis parameter sets the axes to assign to the axes
Axes group numbers are automatically set in the
order that the axes groups are created.
group.
5-21
3-18
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 77
3 Configuring Axes and Axes Groups
3-3-3Introduction to Axes Group Variables
Axes Group Variables are system-defined variables for the setting information and the monitoring information, such as the actual position and error information, for the axes groups controlled by the MC
Function Module. When you create axes groups with the Sysmac Studio, Axes Group Variables are registered in the variable table in the order that the axes groups are created. Axes Group Variables are
structures with a data type of _sGROUP_REF.
z Axes Group Variable Names
Each Axes Group Variable in the MC Function Module has two variable names: The Axes Group
Variable name in the system-defined variables and the Axes Group Variable that is assigned when
the axes group is added on the Sysmac Studio. The Axes Group Variable names in the systemdefined variables are _MC_GRP[0] to _MC_GRP[31].
When you add axes groups on the Sysmac Studio, MC_Group000 to MC_Group031 are set by
default for _MC_GRP[0] to _MC_GRP[31]. The numbers are assigned in the order that the axes are
added. You can change each of these Axes Group Variable names as required from the Sysmac
Studio.
You can use either the Axes Group Variable names for the system-defined variables or the Axes
Group Variable names that are set on the Sysmac Studio to specify the Axes Group Variables in the
user program.
Axes Group Variable name in the
system-defined variables (AT speci-
fication in global variable table)*
_MC_GRP[0]MC_Group000Axes group 0
_MC_GRP[1]MC_Group001Axes group 1
.
.
.
_MC_GRP[31]MC_Group031Axes group 31
Default Axes Group Variable name when
axes group is added on Sysmac Studio
.
.
.
Axes group number
example
.
.
.
3-3 Axes Groups
3
3-3-3 Introduction to Axes Group Variables
* An error will occur if you change the names in the AT column in the global variable table on the Sysmac Studio.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-19
Page 78
3 Configuring Axes and Axes Groups
z Examples of Axes Group Variable Levels and Changing Axes Group Variable
Names
_MC_GRP[0]Axes Group Variables
_MC_GRP[0].StatusLevel that indicates the axes group status
.
.
.
_MC_GRP[0].CmdLevel that indicates the axes group command values
_MC_GRP[0].Cmd.VelVariable that indicates the command interpolation velocity
_MC_GRP[0].Cmd.AccDecVariable that indicates the command interpolation accelera-
.
.
.
_MC_GRP[0].CfgLevel that indicates the axes group basic settings
_MC_GRP[0].Cfg.GrNoVariable that indicates the axes group number
_MC_GRP[0].Cfg.GrEnableVariable that indicates when the axes group is enabled
_MC_GRP[0].KinematicsLevel that indicates the kinematics transformation settings
_MC_GRP[0].Kinematics.GrTypeVariable that indicates the axis composition
_MC_GRP[0].Kinematics.Axis[0]Variable that indicates the axis A0 composition axis
.
.
.
_MC_GRP[0].Kinematics.Axis[3]Variable that indicates the axis A3 composition axis
_MC_GRP[1]Axes Group Variable
.
.
.
tion/deceleration rate
Example: If MC_Group000 is changed to MyGroup1, then either MyGroup1.Cmd.Vel or
_MC_GRP[0].Cmd.Vel can be used as the variable that indicates the command inter-
polation velocity.
Refer to Axes Group Variables on page 6-25 for details on Axes Group Variables.
3-20
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 79
3 Configuring Axes and Axes Groups
3-3-4Specifying an Axes Group in the User Program
In the user program, an axes group variable name is specified for the in-out variable AxesGroup in
motion control instructions. In the following example, the Axes Group Variable name for the axes group
that was added for the system-defined Axes Group Variable name of _MC_GRP[0] has been changed
to MyGroup1 in the Sysmac Studio.
In-out variable AxesGroup
Specify an Axes
Group Variable
name.
MovLStart
MyGroup1
MC_MoveLinear_instance
MC_MoveLinear
AxesGroupAxesGroup
Execute
Position
Velocity
Acceleration
Deceleration
Jerk
CoordSystem
BufferMode
TransitionMode
MoveMode
CommandAborted
Done
Busy
Active
Error
ErrorID
MyGroup1
MyGroup1OnDone
MyGroup1OnBusy
MyGroup1OnActive
MyGroup1OnCA
MyGroup1OnError
MyGroup1OnErrorID
3-3 Axes Groups
3
3-3-4 Specifying an Axes Group in the User Program
You can also use the _MC_GRP[0] system-defined variable in place of MyGroup1.
Refer to 6-2 Motion Control Instructions for details on motion control instructions.
Refer to the instruction descriptions in the NJ-series Motion Control Instructions Reference Manual
(Cat. No. W508) for details on motion control instructions.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-21
Page 80
3 Configuring Axes and Axes Groups
3-4Setting Procedures for Axes Groups
This section gives the procedures to use the Sysmac Studio to set up an axes group. No configuration
is required if you are not going to use any axes group command instructions, such as linear interpolation or circular interpolation.
3-4-1Setting Procedure for an Axes Group
START
Start the Sysmac Studio.
Add an axes group.
Set the axes group parameters.
Go online and synchronize the data.
Transfer the project to the Controller.
END
3-4-2Setting Procedure
This section gives the procedures to use the Sysmac Studio to set up an axes group in a project that
already contains the axes.
Starting the Sysmac Studio
1
Start the Sysmac Studio and open the project.
3-22
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 81
3 Configuring Axes and Axes Groups
Adding an Axes Group
1
Right-click Axes Group Settings in the Multiview Explorer and select Axes Group Settings
from the Add Menu.
An axes group is added to the Multiview Explorer. The default name for the new axes group is
MC_Group000.
3-4 Setting Procedures for Axes Groups
3
3-4-2 Setting Procedure
z Copying an Axes Group
You can also create an axes group by copying an axes group from a project.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-23
Page 82
3 Configuring Axes and Axes Groups
Setting Axes Group Parameters
1
Right-click an axes group in the Multiview Explorer and select Edit from the menu.
The Axes Group Basic Settings are displayed in the Axes Group Parameter Settings Tab Page.
3-24
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 83
3 Configuring Axes and Axes Groups
2
Select Used axes group in the Axes group use Box.
3
Select the composition of the axes group in the Composition Box. A 2-axis composition is
selected in the following example.
3-4 Setting Procedures for Axes Groups
3
3-4-2 Setting Procedure
4
Assign the axis to use in the Logical axes Box.
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-25
Page 84
3 Configuring Axes and Axes Groups
5
Click the bottom icon. The Axes Group Operation Settings Tab Page is displayed.
Set appropriate values for the settings based on the operating conditions of the device.
Additional Information
Changing Axes Group Variable Names in the User Program
Perform the following two procedures to change Axes Group Variable names that are already
used.
• Change the Axes Group Variable name in the variable table in the variable declarations.
• Change the Axes Group Variable name in the user program.
Even if you change the Axes Group Variable names in the variable table, the Axes Group Variable names in the user program do not change. An error will occur if you use a variable name
that is not declared in the variable table, in the user program. Always change the names in both
places.
3-26
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 85
3 Configuring Axes and Axes Groups
Downloading to the CPU Unit
Use the Synchronization menu command of the Sysmac Studio to download the project to the CPU
Unit.
1
Select Online from the Controller Menu. The Sysmac Studio goes online with the Controller.
2
Select Synchronization from the Controller Menu and then click the Transfer to Controller
Button.
3-4 Setting Procedures for Axes Groups
3
3-4-2 Setting Procedure
NJ-series CPU Unit Motion Control User’s Manual (W507)
3-27
Page 86
3 Configuring Axes and Axes Groups
3-28
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 87
Checking Wiring from the Sysmac
Studio
This section describes the MC Test Run operations of the Sysmac Studio. You can use
the MC Test Run to monitor sensor signals, check Servomotor wiring, and more, all
without any programming.
NJ-series CPU Unit Motion Control User’s Manual (W507)
4-1
Page 88
4 Checking Wiring from the Sysmac Studio
4-1Functions of the Sysmac Studio
This section describes how to use the MC test run function to check wiring and basic settings. You can
use the MC test run function in the Sysmac Studio to check wiring without any programming.
4-1-1MC Test Run Function
The MC test run operation supports the following functions.
Category
Axis operationDeceleration
FunctionDescriptionSetting/monitor item
stop
Servo
ON/OFF
Resetting
errors
JoggingJogging is performed in the positive or negative
Absolute positioning
Relative positioning
HomingHoming is performed using the homing parame-
A deceleration stop is performed during the MC
Test Run.
The Servo is turned ON and OFF.---
The errors in the MC Function Module are
reset.
direction.
Absolute positioning is performed.
Relative positioning is performed.Travel Distance
ter settings.
*
---
---
Target Velocity
Acceleration/Deceleration
Target Position
Target Velocity
Acceleration/Deceleration
Jerk
Target Velocity
Acceleration/Deceleration
Jerk
Homing Parameters
4-2
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 89
4 Checking Wiring from the Sysmac Studio
Category
MonitoringError listThe errors in the MC Function Module are mon-
FunctionDescriptionSetting/monitor item
itored.
Axis statusThe status of the axes is monitored.Axis Ready-to-execute
Actual position monitor
Actual velocity
monitor
Servo Drive
status
Input signalsThe status of the input signals are monitored.Positive Limit Input
The actual position is monitored.Command and Actual Cur-
The actual velocity is monitored.Command and Actual Cur-
The status of the Servo Drive is monitored.Servo ON/OFF
MC Common Errors
Axis Errors
Axes Group Errors
Standstill
Discrete Motion
Continuous Motion
Homing
Stopping
Home Defined
In Home Position
rent Positions
rent Velocities
Servo Ready
Main Power
Negative Limit Input
Immediate Stop Input
Home Proximity Input
Home Input
External Latch Inputs 1 to 2
4-1 Functions of the Sysmac Studio
4
4-1-1 MC Test Run Function
* When the Count Mode of the axis is set to Rotary Mode, positioning is performed toward the target position in the
positive direction. For details, refer to the MC_MoveAbsolute (Absolute Positioning) instruction in the NJ-seriesMotion Control Instructions Reference Manual (Cat. No. W508).
Note This MC Test Run is used for an OMRON G5-series Servo Drive with built-in EtherCAT communications. Do
not use it with servo drives from any other manufacturer.
NJ-series CPU Unit Motion Control User’s Manual (W507)
4-3
Page 90
4 Checking Wiring from the Sysmac Studio
4-1-2Application Procedure
Before you perform an MC Test Run, check the following two items.
• Are the Sysmac Studio and Controller connected and are they online?
• Is the MC Test Run Mode currently in use from any other copy of the Sysmac Studio?
After you have confirmed these two items, perform the following operations as instructed.
START
Setup
Starting the MC
test run function
Checking wiring
Checking motor
operation
Checking electronic
gear settings
Confirming homing
Create the EtherCAT slave configuration, add axes,
assign the axes, and set the axis parameters.
Start the MC test run function.
Confirm sensor wiring.
Use jogging to check the direction of the motor.
Perform relative positioning to check the travel distance.
Perform homing to check the homing operation.
Section 3 Configuring Axes and
Axes Groups
Section 4 Checking Wiring
from the Sysmac Studio
Precautions for Correct UsePrecautions for Correct Use
• When one of the following operations is performed for a command from the Sysmac Studio,
the Servomotor will operate at the set velocity: Servo ON, jogging, relative positioning, absolute positioning, or homing. Always confirm that it is safe for the Servomotor to operate before
executing any of these operations.
• When operating the Controller from the Sysmac Studio, always install external emergency circuits so that the Servomotor can be stopped safely whenever necessary. The Sysmac Studio
may not be able to send commands under some circumstances, e.g., if an error occurs in the
computer.
• Set the EtherCAT communications and establish communications before you attempt to perform operation from the Sysmac Studio.
4-4
Additional Information
You can perform the following operations to end the MC test run function at any time.
• Select MC Test Run
−
Stop from the Controller Menu of the Sysmac Studio.
• Right-click the axis in the Multiview Explorer of the Sysmac Studio and select Stop MC Test
Run from the menu.
• Close the MC Test Run Tab Page on the Sysmac Studio.
• Exit the Sysmac Studio.
Refer to the Sysmac Studio Version 1 Operation Manual (Cat. No. W504) for specific procedures.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 91
4 Checking Wiring from the Sysmac Studio
4-1-3Axis Parameter Setting Example
Set the following axis parameters before you execute the MC Test Run Mode in the Sysmac Studio.
The following setting example is for a one-axis device.
Servomotor
Encoder resolution: 20 bits/rotation
Encoder Output Pulse Count per Motor Rotation
20 bits = 1,048,576
10 mm
Ball screw
Ball screw pitch: 10 mm
1 rotation
Parameter nameSetting
Axis Variable Name
Axis Number
Axis1
*2
1
*1
Axis UseUsed axis
Axis TypeServo axis
Node Address (input device)
*3
1
Unit of Displayµm
Command Pulse Count Per Motor Rotation
Work Travel Distance Per Motor Rotation
Maximum Velocity
Maximum Jog Velocity
Maximum Acceleration
Maximum Deceleration
1,048,576
10,000
500,000
50,000
5,000,000
5,000,000
*4
*4
*5
*6
*7
*7
Software LimitsImmediate stop for command position
Positive Software Limit
Negative Software Limit
500,000
0
*8
*8
Count ModeLinear Mode
4-1 Functions of the Sysmac Studio
4
4-1-3 Axis Parameter Setting Example
*1 If there is more than one axis, a different variable name is set for each axis.
*2 If there is more than one axis, a different value is set for each axis.
*3 Set the same node address as for the Servo Drive.
If there is more than one axis, a different value is set for each axis.
*4 The position command unit will be 1 µm.
*5 The maximum velocity will be 3,000 r/min = 30 m/min = 0.5 m/s = 500,000 µm/s.
*6 The maximum jog velocity will be 10% of the maximum velocity, i.e., 0.05 m/s = 50,000 µm/s.
*7 The maximum acceleration and the maximum deceleration will be 5 m/s
The acceleration time to the maximum velocity (3,000 r/min) will be 0.1 s.
*8 Set a value that is within the movable range of the device.
The positive software limit is set to 50 cm = 500,000 µm.
NJ-series CPU Unit Motion Control User’s Manual (W507)
2
.
4-5
Page 92
4 Checking Wiring from the Sysmac Studio
4-1-4Starting the MC Test Run Function
The MC Test Run Mode is started from the Sysmac Studio.
1
Start the Sysmac Studio and open a project in which the axis settings are completed.
2
Select Online from the Controller Menu. The Sysmac Studio goes online with the Controller.
3
Select MC Test Run − Start from the Controller Menu.
When the following caution dialog box appears, read the message carefully. After you confirm
safety, click the OK Button.
The MC Test Run Tab Page is displayed.
4-6
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 93
4 Checking Wiring from the Sysmac Studio
4-2Monitoring Sensor Signals
You can use the input signal display to check sensor signal wiring.
1
Select the axis to check on the MC Test Run Tab Page.
2
Check to see if the signals turn ON and OFF properly on the monitor screen by turning ON and
OFF the sensor connected to each input signal.
4-2 Monitoring Sensor Signals
4
NJ-series CPU Unit Motion Control User’s Manual (W507)
4-7
Page 94
4 Checking Wiring from the Sysmac Studio
4-3Checking Motor Operation
Use the functions of the MC Test Run to check motor operation.
4-3-1Turning ON the Servo
You can use the Servo ON Button to turn the Servo ON and OFF.
1
Select the axis for which to turn ON the Servo.
2
Click the Servo ON Button to turn ON the Servo.
3
Click the Servo OFF Button to turn OFF the Servo.
Precautions for Correct UsePrecautions for Correct Use
• When one of the following operations is performed for a command from the Sysmac Studio,
the Servomotor will operate at the set velocity: Servo ON, jogging, relative positioning, absolute positioning, or homing. Always confirm that it is safe for the Servomotor to operate before
executing any of these operations.
• When you operate the Controller from the Sysmac Studio, always install external emergency
circuits so that the Servomotor can be stopped safely whenever necessary. The Sysmac Studio may not be able to send commands under some circumstances, e.g., if an error occurs in
the computer.
• Set the EtherCAT communications and establish communications before you attempt to perform operation from the Sysmac Studio.
4-3-2Jogging
1
Select the axis to jog on the Jogging Tab Page of the MC Test Run Tab Page.
2
Click the Servo ON Button to turn ON the Servo.
4-8
3
Enter the target velocity, acceleration rate, and deceleration rate, and then press the Apply Button.
4
Click the or Button.
The motor will operate in either the positive or negative direction while one of these buttons is
clicked. Check to see if the motor operates in the set direction.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 95
4-3-3Homing
1
Set the homing parameters in the Homing Settings on the Axis Parameter Settings Tab Page.
2
Click the Homing Tab on the MC Test Run Tab Page.
4 Checking Wiring from the Sysmac Studio
The following dialog box is displayed.
3
Select the axis to home.
4-3 Checking Motor Operation
4
4-3-3 Homing
4
Click the Servo ON Button to turn ON the Servo.
5
Click the Apply homing parameters Button.
6
Click the Button.
Check to see if the homing operation agrees with the settings.
Additional Information
• When you click the Homing Settings Button, the Homing Settings are displayed on the Axis
Parameter Settings Tab Page. Set the homing parameters.
• If the homing parameters were set in advance, click the Apply homing parameters Button to
apply those settings.
NJ-series CPU Unit Motion Control User’s Manual (W507)
4-9
Page 96
4 Checking Wiring from the Sysmac Studio
4-3-4Absolute Positioning
1
Click the Absolute positioning Tab on the MC Test Run Tab Page.
The following dialog box will appear.
2
Select the axis to perform absolute positioning.
3
Click the Servo ON Button to turn ON the Servo.
4
Enter the target position, target velocity, acceleration rate, deceleration rate, and jerk, and then
click the Apply Button.
5
Click the Button. Absolute positioning will start.
Check to see if positioning agrees with the settings.
4-10
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 97
4-3-5Relative Positioning
1
Click the Relative positioning Tab on the MC Test Run Tab Page.
The following dialog box will appear.
4 Checking Wiring from the Sysmac Studio
4-3 Checking Motor Operation
2
Select the axis to perform relative positioning.
3
Click the Servo ON Button to turn ON the Servo.
4
Enter the target travel distance, target velocity, acceleration rate, deceleration rate, and jerk, and
then click the Apply Button.
5
Click the Button. Relative positioning will start.
Check to see if the travel distance agrees with the settings.
4
4-3-5 Relative Positioning
NJ-series CPU Unit Motion Control User’s Manual (W507)
4-11
Page 98
4 Checking Wiring from the Sysmac Studio
4-12
NJ-series CPU Unit Motion Control User’s Manual (W507)
Page 99
Motion Control Parameters
This section explains about axis parameters and axes group parameters used for
motion control.
NJ-series CPU Unit Motion Control User’s Manual (W507)
5-1
Page 100
5 Motion Control Parameters
5-1Introduction
You can use motion control instructions to perform single-axis operations and multi-axis operations on
axes groups with the NJ-series CPU Unit’s MC Function Module. Axis and axes group parameters are
used to set these operations. Axis parameters must be set, but axes group parameters are not required
if you do not use multi-axis operations for axes groups.
These parameters are called motion control parameter settings (MC parameter settings).
Sysmac Studio
Transferred
ID211
0123 4567
9
8
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
COM
DC24
V
7mA
AD042
10 1112 13 14 15
MACH
No
x10
x10
CPU Unit
RUN
ERC
ERH
B1 A1
8
7
9
6
0
.
5
1
4
2
3
1
8
7
9
6
0
5
1
4
2
3
0
Transferred
Non-volatile memory
MC common parameter settings
*1
Axis parameter settings
Axes group parameter settings
• After the setting
are downloaded
• When power is
turned ON
Main memory
MC common parameter settings
*1
Axis parameter settings
Axes group parameter settings
Temporary
changes to some
parameters
Accessing some
parameters as
User program
MC_Write instruction
Data movement or
other instructions
variables
*1 There are no MC Common Parameter Settings for the current version of the MC Function Module.
*2 Use the Synchronization menu command of the Sysmac Studio to upload and download the project.
z Data Flow for Setting MC Parameters
• Download your MC Parameter Settings to the CPU Unit using the Sysmac Studio to save those
settings in the CPU Unit's non-volatile memory.
• Saved settings are applied to the main memory after you download them or when the power is
turned ON.
• If there are no problems with the saved settings, the MC Function Module executes control based
on the settings in the main memory.
• The settings of some of the parameters can be accessed as system-defined variables for motion
control.
• You can upload and download MC parameter settings regardless of the CPU Unit’s mode or the
status of the MC Function Module.
• When you start the download process, all axes in motion will stop immediately and the Servo will
turn OFF.
5-2
z Overwriting Parameters with the MC_Write (Write MC Setting) Instruction
• You can use the MC_Write (Write MC Setting) motion control instruction to change the settings of
some parameters in the main memory while the user program is running.
• If the specified setting value is outside the allowed range, the output variable Error from the
instruction changes to TRUE and the parameter setting is not changed.
• Parameter settings become valid in either of the following two situations.
• The axis or axes group is stopped and you execute an instruction for an axis command or
axes group command.
• You set the Buffer Mode Selection for the instruction to Aborting and execute more than one
instruction.
NJ-series CPU Unit Motion Control User’s Manual (W507)
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.