LCPU_UserManual-BuiltInIO-Functions_SH-080892

LCPU_UserManual-BuiltInIO-Functions_SH-080892
SAFETY PRECAUTIONS
(Read these precautions before using this product.)
Before using this product, please read this manual and the relevant manuals carefully and pay full attention
to safety to handle the product correctly.
In this manual, the safety precautions are classified into two levels:"
WARNING" and "
CAUTION".
WARNING
Indicates that incorrect handling may cause hazardous conditions,
resulting in death or severe injury.
CAUTION
Indicates that incorrect handling may cause hazardous conditions,
resulting in minor or moderate injury or property damage.
Under some circumstances, failure to observe the precautions given under "
CAUTION" may lead to
serious consequences.
Observe the precautions of both levels because they are important for personal and system safety.
Make sure that the end users read this manual and then keep the manual in a safe place for future
reference.
[Design Precautions]
WARNING
● Configure safety circuits external to the programmable controller to ensure that the entire system
operates safely even when a fault occurs in the external power supply or the programmable
controller. Failure to do so may result in an accident due to an incorrect output or malfunction.
(1) Emergency stop circuits, protection circuits, and protective interlock circuits for conflicting
operations (such as forward/reverse rotations or upper/lower limit positioning) must be
configured external to the programmable controller.
(2) Machine OPR (Original Point Return) of the positioning function is controlled by two kinds of
data: an OPR direction and an OPR speed. Deceleration starts when the near-point watchdog
signal turns on. If an incorrect OPR direction is set, motion control may continue without
deceleration. To prevent machine damage caused by this, configure an interlock circuit external
to the programmable controller.
(3) When the CPU module detects an error during control by the positioning function, the motion
slows down and stops.
1
[Design Precautions]
WARNING
●
●
●
●
●
●
2
(4) When the programmable controller detects an abnormal condition, it stops the operation and all
outputs are:
• Turned off if the overcurrent or overvoltage protection of the power supply module is activated.
• Held or turned off according to the parameter setting if the self-diagnostic function of the CPU
module detects an error such as a watchdog timer error.
Also, all outputs may be turned on if an error occurs in a part, such as an I/O control part,
where the CPU module cannot detect any error. To ensure safety operation in such a case,
provide a safety mechanism or a fail-safe circuit external to the programmable controller. For a
fail-safe circuit example, refer to "General Safety Requirements" in the MELSEC-L CPU
Module User's Manual (Hardware Design, Maintenance and Inspection).
(5) Outputs may remain on or off due to a failure of a component such as a transistor in an output
circuit. Configure an external circuit for monitoring output signals that could cause a serious
accident.
In an output circuit, when a load current exceeding the rated current or an overcurrent caused by a
load short-circuit flows for a long time, it may cause smoke and fire. To prevent this, configure an
external safety circuit, such as a fuse.
Configure a circuit so that the programmable controller is turned on first and then the external power
supply. If the external power supply is turned on first, an accident may occur due to an incorrect
output or malfunction.
Configure a circuit so that the external power supply is turned off first and then the programmable
controller. If the programmable controller is turned off first, an accident may occur due to an incorrect
output or malfunction.
For the operating status of each station after a communication failure, refer to relevant manuals for
each network. Incorrect output or malfunction due to a communication failure may result in an
accident.
When changing data from a peripheral device connected to the CPU module during operation,
configure an interlock circuit in the program to ensure that the entire system will always operate
safely. For other controls to a running programmable controller (such as program modification or
operating status change), read relevant manuals carefully and ensure the safety before the
operation. Especially, in the case of a control from an external device to a remote programmable
controller, immediate action cannot be taken for a problem on the programmable controller due to a
communication failure. To prevent this, configure an interlock circuit in the program, and determine
corrective actions to be taken between the external device and CPU module in case of a
communication failure.
An absolute position restoration by the positioning function may turn off the servo-on signal (servo
off) for approximately 20ms, and the motor may run unexpectedly. If this causes a problem, provide
an electromagnetic brake to lock the motor during absolute position restoration.
[Design Precautions]
CAUTION
● Do not install the control lines or communication cables together with the main circuit lines or power
cables. Keep a distance of 100mm or more between them. Failure to do so may result in malfunction
due to noise.
● During control of an inductive load such as a lamp, heater, or solenoid valve, a large current
(approximately ten times greater than normal) may flow when the output is turned from off to on.
Therefore, use a module that has a sufficient current rating.
● Time from when the CPU module is powered on or is reset to when it enters in RUN status depends
on the system configuration, parameter settings, and program size.
Design the program so that the entire system will always operate safely, regardless of the time.
[Installation Precautions]
WARNING
● Shut off the external power supply for the system in all phases before mounting or removing a
module. Failure to do so may result in electric shock or cause the module to fail or malfunction.
[Installation Precautions]
CAUTION
● Use the programmable controller in an environment that meets the general specifications in the
MELSEC-L CPU Module User's Manual (Hardware Design, Maintenance and Inspection). Failure to
do so may result in electric shock, fire, malfunction, or damage to or deterioration of the product.
● To interconnect modules, engage the respective connectors and securely lock the module joint
levers. Incorrect interconnection may cause malfunction, failure, or drop of the module.
● Do not directly touch any conductive parts and electronic components of the module. Doing so can
cause malfunction or failure of the module.
● Securely connect an extension cable to the connectors of a branch module and an extension
module. After connections, check that the cable is inserted completely. Poor contact may cause
malfunction.
[Wiring Precautions]
WARNING
● Shut off the external power supply for the system in all phases before wiring. Failure to do so may
result in electric shock or cause the module to fail or malfunction.
● After installation and wiring, attach the included terminal cover to the module before turning it on for
operation. Failure to do so may result in electric shock.
3
[Wiring Precautions]
CAUTION
● Ground the FG and LG terminals to the protective ground conductor dedicated to the programmable
controller. Failure to do so may result in electric shock or malfunction.
● Use applicable solderless terminals and tighten them within the specified torque range.
If any spade solderless terminal is used, it may be disconnected when a terminal block screw comes
loose, resulting in failure.
● Check the rated voltage and terminal layout before wiring to the module, and connect the cables
correctly. Connecting a power supply with a different voltage rating or incorrect wiring may cause a
fire or failure.
● Connectors for external devices must be crimped or pressed with the tool specified by the
manufacturer, or must be correctly soldered. Incomplete connections may cause short circuit, fire, or
malfunction.
● Securely connect the connector to the module.
● Do not install the control lines or communication cables together with the main circuit lines or power
cables. Failure to do so may result in malfunction due to noise.
● Place the cables in a duct or clamp them. If not, dangling cable may swing or inadvertently be pulled,
resulting in damage to the module or cables or malfunction due to poor contact.
● Check the interface type and correctly connect the cable.
Incorrect wiring (connecting the cable to an incorrect interface) may cause failure of the module and
external device.
● Tighten the terminal block screw within the specified torque range. Undertightening can cause short
circuit, fire, or malfunction. Overtightening can damage the screw and/or module, resulting in drop,
short circuit, or malfunction.
● When disconnecting the cable from the module, do not pull the cable by the cable part. For the cable
with connector, hold the connector part of the cable. For the cable connected to the terminal block,
loosen the terminal screw. Pulling the cable connected to the module may result in malfunction or
damage to the module or cable.
● Prevent foreign matter such as dust or wire chips from entering the module. Such foreign matter can
cause a fire, failure, or malfunction.
● A protective film is attached to the top of the module to prevent foreign matter, such as wire chips,
from entering the module during wiring. Do not remove the film during wiring. Remove it for heat
dissipation before system operation.
● To use the high-speed counter function, ground the shield cable on the encoder side (relay box).
Always ground the FG and LG terminals to the protective ground conductor.
Failure to do so may cause malfunction.
● Mitsubishi programmable controllers must be installed in control panels. Connect the main power
supply to the power supply module in the control panel through a relay terminal block.
Wiring and replacement of a power supply module must be performed by qualified maintenance
personnel with knowledge of protection against electric shock.
For wiring methods, refer to the MELSEC-L CPU Module User's Manual (Hardware Design,
Maintenance and Inspection).
4
[Startup and Maintenance Precautions]
WARNING
● Do not touch any terminal while power is on. Doing so will cause electric shock or malfunction.
● Correctly connect the battery connector. Do not charge, disassemble, heat, short-circuit, solder, or
throw the battery into the fire. Also, do not expose it to liquid or strong shock.
Doing so will cause the battery to produce heat, explode, ignite, or leak, resulting in injury and fire.
● Shut off the external power supply for the system in all phases before cleaning the module or
retightening the terminal block screw. Failure to do so may result in electric shock.
[Startup and Maintenance Precautions]
CAUTION
● Before performing online operations (especially, program modification, forced output, and operating
status change) for the running CPU module from the peripheral device connected, read relevant
manuals carefully and ensure the safety. Improper operation may damage machines or cause
accidents.
● Do not disassemble or modify the modules. Doing so may cause failure, malfunction, injury, or a fire.
● Use any radio communication device such as a cellular phone or PHS (Personal Handy-phone
System) more than 25cm away in all directions from the programmable controller. Failure to do so
may cause malfunction.
● Shut off the external power supply for the system in all phases before mounting or removing a
module. Failure to do so may cause the module to fail or malfunction.
● Tighten the terminal block screw within the specified torque range. Undertightening can cause drop
of the component or wire, short circuit, or malfunction. Overtightening can damage the screw and/or
module, resulting in drop, short circuit, or malfunction.
● After the first use of the product (module, display unit, and terminal block), the number of
connections/disconnections is limited to 50 times (in accordance with IEC 61131-2). Exceeding the
limit may cause malfunction.
● After the first use of the SD memory card, the number of insertions/removals is limited to 500 times.
Exceeding the limit may cause malfunction.
● Do not drop or apply shock to the battery to be installed in the module. Doing so may damage the
battery, causing the battery fluid to leak inside the battery. If the battery is dropped or any shock is
applied to it, dispose of it without using.
● Before handling the module, touch a conducting object such as a grounded metal to discharge the
static electricity from the human body. Failure to do so may cause the module to fail or malfunction.
● Before testing the operation by the positioning function, set a low speed value for the speed limit
parameter so that the operation can be stopped immediately upon occurrence of a hazardous
condition.
5
[Disposal Precautions]
CAUTION
● When disposing of this product, treat it as industrial waste. When disposing of batteries, separate
them from other wastes according to the local regulations. (For details on battery regulations in EU
member states, refer to the MELSEC-L CPU Module User's Manual (Hardware Design, Maintenance
and Inspection).)
[Transportation Precautions]
CAUTION
● When transporting lithium batteries, follow the transportation regulations. (For details on the
regulated models, refer to the MELSEC-L CPU Module User's Manual (Hardware Design,
Maintenance and Inspection).)
6
CONDITIONS OF USE FOR THE PRODUCT
(1) Mitsubishi programmable controller ("the PRODUCT") shall be used in conditions;
i) where any problem, fault or failure occurring in the PRODUCT, if any, shall not lead to any major
or serious accident; and
ii) where the backup and fail-safe function are systematically or automatically provided outside of
the PRODUCT for the case of any problem, fault or failure occurring in the PRODUCT.
(2) The PRODUCT has been designed and manufactured for the purpose of being used in general
industries.
MITSUBISHI SHALL HAVE NO RESPONSIBILITY OR LIABILITY(INCLUDING, BUT NOT LIMITED
TO ANY AND ALL RESPONSIBILITYOR LIABILITY BASED ON CONTRACT, WARRANTY, TORT,
PRODUCTLIABILITY) FOR ANY INJURY OR DEATH TO PERSONS OR LOSS OR DAMAGE TO
PROPERTY CAUSED BY the PRODUCT THAT AREOPERATED OR USED IN APPLICATION
NOT INTENDED OR EXCLUDED BY INSTRUCTIONS, PRECAUTIONS, OR WARNING
CONTAINED IN MITSUBISHI'S USER, INSTRUCTION AND/OR SAFETY MANUALS,
TECHNICAL BULLETINS AND GUIDELINES FOR the PRODUCT.
("Prohibited Application")
Prohibited Applications include, but not limited to, the use of the PRODUCT in;
• Nuclear Power Plants and any other power plants operated by Power companies, and/or any
other cases in which the public could be affected if any problem or fault occurs in the PRODUCT.
• Railway companies or Public service purposes, and/or any other cases in which establishment of
a special quality assurance system is required by the Purchaser or End User.
• Aircraft or Aerospace, Medical applications, Train equipment, transport equipment such as
Elevator and Escalator, Incineration and Fuel devices, Vehicles, Manned transportation,
Equipment for Recreation and Amusement, and Safety devices, handling of Nuclear or
Hazardous Materials or Chemicals, Mining and Drilling, and/or other applications where there is a
significant risk of injury to the public or property.
Notwithstanding the above, restrictions Mitsubishi may in its sole discretion, authorize use of the
PRODUCT in one or more of the Prohibited Applications, provided that the usage of the PRODUCT
is limited only for the specific applications agreed to by Mitsubishi and provided further that no
special quality assurance or fail-safe, redundant or other safety features which exceed the general
specifications of the PRODUCTs are required. For details, please contact the Mitsubishi
representative in your region.
7
INTRODUCTION
Thank you for purchasing the Mitsubishi MELSEC-L series programmable controllers.
This manual describes the functions of the external I/O interface of the LCPU and programming.
Before using this product, please read this manual and the relevant manuals carefully and develop familiarity with the
functions and performance of the MELSEC-L series programmable controller to handle the product correctly.
When applying the program examples introduced in this manual to the actual system, ensure the applicability and
confirm that it will not cause system control problems.
Please make sure that the end users read this manual.
Relevant CPU modules: L02CPU, L26CPU-BT, L02CPU-P, and L26CPU-PBT
Remark
● This manual describes only built-in I/O functions for the CPU module.
For the functions except for built-in I/O functions of the CPU module, refer to the following.
MELSEC-L CPU Module User's Manual (Function Explanation, Program Fundamentals)
MELSEC-L CPU Module User's Manual (Built-In Ethernet Function)
MELSEC-L CPU Module User's Manual (Data Logging Function)
● Unless otherwise specified, this manual describes examples of assigning from X0 to XF for input numbers and from Y0 to
Y7 for output numbers in each function. For I/O number assignment, refer to the following.
MELSEC-L CPU Module User's Manual (Function Explanation, Program Fundamentals)
● Unless otherwise specified, Chapter 7 POSITIONING FUNCTION in this manual is described as using examples of the
setting, special relay, special register, dedicated instruction, error code and warning code supported for Axis #1.
● Unless otherwise specified, Chapter 8 HIGH-SPEED COUNTER FUNCTION in this manual is described as using
examples of the setting, special relay, special register, dedicated instruction, error code and warning code supported for
CH1.
8
RELEVANT MANUALS
(1) CPU module user's manual
Manual name
Description
<manual number (model code)>
MELSEC-L CPU Module User's Manual (Hardware Design, Maintenance and
Inspection)
<SH-080890ENG, 13JZ36>
Specifications of the CPU modules, power supply modules, display unit,
branch module, extension module, SD memory cards, and batteries,
information on how to establish a system, maintenance and inspection,
and troubleshooting
MELSEC-L CPU Module User's Manual (Function Explanation, Program
Fundamentals)
<SH-080889ENG, 13JZ35>
Functions and devices of the CPU module, and programming
MELSEC-L CPU Module User's Manual (Built-In Ethernet Function)
<SH-080891ENG, 13JZ37>
The built-in Ethernet function of the CPU module
MELSEC-L CPU Module User's Manual (Data Logging Function)
<SH-080893ENG, 13JZ39>
The data logging function of the CPU module
(2) Programming manual
Manual name
Description
<manual number (model code)>
MELSEC-Q/L Programming Manual (Common Instruction)
<SH-080809ENG, 13JW10>
Detailed description and usage of instructions used in programs
(3) Operating manual
Manual name
Description
<manual number (model code)>
GX Works2 Version1 Operating Manual (Common)
<SH-080779ENG, 13JU63>
System configuration, parameter settings, and online operations
(common to Simple project and Structured project) of GX Works2
<SH-080373ENG, 13JU41>
Operating methods of GX Developer, such as programming, printing,
monitoring, and debugging
GX Developer Version 8 Operating Manual
(4) I/O module and intelligent function module manual
Manual name
<manual number (model code)>
MELSEC-L I/O Module User's Manual
<SH-080888ENG, 13JZ34>
Description
Specifications and troubleshooting of the I/O module
9
CONTENTS
CONTENTS
SAFETY PRECAUTIONS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
CONDITIONS OF USE FOR THE PRODUCT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
INTRODUCTION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
RELEVANT MANUALS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
MANUAL PAGE ORGANIZATION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
TERMS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
CHAPTER 1 OVERVIEW
18
CHAPTER 2 EXTERNAL I/O SPECIFICATIONS
20
CHAPTER 3 GENERAL-PURPOSE INPUT FUNCTION
28
CHAPTER 4 GENERAL-PURPOSE OUTPUT FUNCTION
30
CHAPTER 5 INTERRUPT INPUT FUNCTION
32
CHAPTER 6 PULSE CATCH FUNCTION
36
CHAPTER 7 POSITIONING FUNCTION
39
7.1
Overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
7.1.1
7.2
7.3
Procedure for performing the positioning function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
Connection to External Devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
7.2.1
I/O signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
7.2.2
Wiring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
Parameter Setting. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
7.3.1
Positioning parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
7.4
Specifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
7.5
Checking Current Position and Operation Status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
7.6
7.7
OPR Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
7.6.1
Machine OPR. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70
7.6.2
Fast OPR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
7.6.3
Forced off of Axis 1 OPR request (SM1842) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
7.6.4
Precautions on Axis 1 OPR request (SM1842) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
Positioning Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93
7.7.1
Start of positioning control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
7.7.2
Position control. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
7.7.3
Speed/position switching control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100
7.7.4
Current value change. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102
7.7.5
Speed control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
7.8
Multiple Axes Simultaneous Start Control. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104
7.9
JOG Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
7.10
Subfunction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110
7.10.1 OPR retry function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111
7.10.2 Speed limit function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115
7.10.3 Speed change function. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116
10
7.10.4 Software stroke limit function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121
7.10.5 Hardware stroke limit function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
7.10.6 Target position change function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
7.10.7 Acceleration/deceleration processing function. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129
7.10.8 Stop processing function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131
7.11
Absolute Position Restoration Function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134
7.12
Dedicated Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139
7.12.1 Details of dedicated instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
7.12.2 Precautions on dedicated instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163
7.13
Programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165
7.14
Errors and Warnings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175
7.15
Monitoring with a Programming Tool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.1
Overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
8.1.1
8.2
8.3
Procedure for performing the high-speed counter function . . . . . . . . . . . . . . . . . . . . . . . . . 184
Connection to External Devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
8.2.1
I/O signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
8.2.2
Wiring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
Parameter Setting. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194
8.3.1
8.4
181
Common settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 196
Normal Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201
8.4.1
Preset. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206
8.4.2
Coincidence output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209
8.4.3
Coincidence detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
8.4.4
Counter function selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
8.5
Frequency Measurement Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
8.6
Rotation Speed Measurement Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
8.7
Pulse Measurement Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
8.8
PWM Output Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
8.9
Specifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
8.10
Dedicated Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
8.10.1 Details of dedicated instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 246
8.10.2 Precautions on dedicated instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261
8.11
Programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262
8.12
Errors and Warnings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
8.13
When the LCPU Stops Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
8.14
Monitoring with a Programming Tool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 272
APPENDICES
273
Appendix 1 Processing Time of Each Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273
Appendix 2 Connection Examples with Servo Amplifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
Appendix 2.1 Connection examples with servo amplifiers manufactured by
Mitsubishi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
11
Appendix 2.2 Connection examples with stepping motors manufactured by
ORIENTAL MOTOR CO.,LTD. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
Appendix 2.3 Connection examples with servo amplifiers manufactured by
Panasonic Corporation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279
Appendix 2.4 Connection examples with servo amplifiers manufactured by
SANYODENKI CO.,LTD. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
Appendix 2.5 Connection examples with servo amplifiers manufactured by
YASKAWA Electric Corporation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282
INDEX
284
INSTRUCTION INDEX
287
REVISIONS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
WARRANTY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
12
MANUAL PAGE ORGANIZATION
In this manual, pages are organized and the symbols are used as shown below.
The following page illustration is for explanation purpose only, and is different from the actual pages.
"" is used for
screen names and items.
The chapter of
the current page is shown.
shows operating
procedures.
shows mouse
operations.*1
[ ] is used for items
in the menu bar and
the project window.
The section of
the current page is shown.
Ex. shows setting or
operating examples.
shows reference
manuals.
shows notes that
requires attention.
shows
reference pages.
shows useful
information.
*1
The mouse operation example is provided below. (For GX Works2)
Menu bar
Ex.
[Online]
[Write to PLC...]
Select [Online] on the menu bar,
and then select [Write to PLC...].
A window selected in the view selection area is displayed.
Ex.
[Parameter]
Project window
[PLC Parameter]
Select [Project] from the view selection
area to open the Project window.
In the Project window, expand [Parameter] and
select [PLC Parameter].
View selection area
13
Pages describing instructions are organized as shown below.
The following page illustration is for explanation purpose only, and is different from the actual pages.
Instruction name
Execution condition of the instruction
Structure of the instruction
in the ladder mode
shows the devices
applicable to the instruction
Descriptions of
setting data and data type
Descriptions of
control data (if any)
Detailed descriptions
of the instruction
Conditions for the error and
error codes
For the errors not described in
this manual, refer to the following.
MELSEC-Q/L Programming
Manual (Common Instruction)
Simple program example(s)
and descriptions of the devices used
14
Setting side
User : Device value is set by the user.
System: Device value is set by
the CPU module.
• Instructions can be executed under the following conditions.
Execution condition
Any time
Symbol
No symbol
During on
On the rising edge
During off
On the falling edge
• The following devices can be used.
Internal device
Setting
(system, user)
data
Applicable
device*1
Bit
Word
X, Y, M, L,
S, M, F, B,
SB, FX,
T, ST, C,
D, W, SD,
SW, FD,
@
FY*2
File
register
Link direct
device J \
Bit
R, ZR
Word
⎯
Intelligent
Index
function module
register
device U \G
U \G
Constant
Zn
Z
*3
K,H,E,$
Others*3
P, I, J, U, D,
X, DY, N,
BL, TR,
BL\S,V
*1
For details on each device, refer to the following.
*2
*3
MELSEC-L CPU Module User's Manual (Function Explanation, Program Fundamentals)
FX and FY can be used for bit data only, and FD for word data only.
In the "Constant" and "Other" columns, a device(s) that can be set for each instruction is shown.
• The following data types can be used.
Data type
Description
Bit
Bit data or the start number of bit data
BIN 16-bit
16-bit binary data or the start number of word device
BIN 32-bit
32-bit binary data or the start number of double-word device
BCD 4-digit
Four-digit binary-coded decimal data
BCD 8-digi
Eight-digit binary-coded decimal data
Real number
Floating-point data
Character string
Character string data
Device name
Device name data
15
TERMS
Unless otherwise specified, this manual uses the following terms.
Term
Description
CPU module
The abbreviation for the MELSEC-L series CPU module
Power supply module
The abbreviation for the MELSEC-L series power supply module
Branch module
The abbreviation for the MELSEC-L series branch module
Extension module
The abbreviation for the MELSEC-L series extension module
END cover
A cover to be attached to the right side of the rightmost MELSEC-L series module
Display unit
A liquid crystal display to be attached to the CPU module
Extension cable
The abbreviation for the MELSEC-L series extension cable
LCPU
Another term for the MELSEC-L series CPU module
Programming tool
A generic term for GX Works2 and GX Developer
GX Works2
GX Developer
The product name of the software package for the MELSEC programmable controllers
Encoder
One of the pulse generators that converts input data into binary data (on and off)
Near-point watchdog
A switch used in positioning systems, placed in front of the starting point of a workpiece. When this switch
turns on, the feed speed is switched to creep speed. Therefore, the deceleration time is required while this
switch is on.
Servo on
A signal that indicates the normal status of a servo amplifier. A servo amplifier is operable only when it is
normal and this signal is on.
Servo motor
A motor that rotates according to a command. This motor is highly responsive, therefore frequent and rapid
start and stop are available with high precision. DC and AC type motors are available as well as high power
motors. Feedback control is available with the included pulse generator that detects the number of rotations.
Stepping motor
A motor that rotates by the predetermined angle for every pulse. The number of rotations is proportional to
the number of pulses. A small power motor is applied, and it rotates accurately without feedbacks. Do not
overload the motor, otherwise it will be out of step.
Zero signal
PG0 of a pulse generator (encoder), that is detected once in one rotation.
Drive unit (servo amplifier)
A unit used to amplify the power and control the motor in the operation by the positioning function since the
signals, such as pulses, that are output from the CPU module are low voltage and small current. The unit,
also called a servo amplifier, is provided with a servomotor and step motor.
Pulse generator
A device that generates pulses. For example, by attaching this device on a motor axis, pulses can be
generated by the rotation of the axis.
Warning
Different from an error, a warning is a minor error that does not terminate or stop the operation even if it is
detected.
PWM
The abbreviation for pulse-width modulation, a method of changing a ratio of on width to off width of a pulse
wave
16
Memo
17
CHAPTER 1
OVERVIEW
The LCPU is equipped with the following built-in I/O functions.
The built-in I/O functions allow constructing a small-scale system using the LCPU module alone because dedicated
modules for these functions are not required. Therefore, the system cost can be reduced.
• General-purpose input function
• General-purpose output function
• Interrupt input function
• Pulse catch function
• Positioning function
• High-speed counter function
General-purpose input function, interrupt input function, and
pulse catch function
General-purpose
output function
Positioning function
High-speed counter
function
18
CHAPTER 1 OVERVIEW
1
(1) Number of points used for each function
X0 to XF and Y0 to Y7 are sorted for each function.
Function
General-purpose
input function
General-purpose
output function
Interrupt input
function
Pulse catch function
Input
Output
0 to 16 points (input signal)
0 to 16 points
⎯
0 to 8 points (output signal)
⎯
0 to 8 points
0 to 16 points (input signal)
0 to 16 points
⎯
0 to 16 points (input signal)
0 to 16 points
⎯
0 to 2CH
High-speed counter
function*1
• Input signal: 0 to 5 points (points/channel)
(depending on settings)
• Output Signal: 0 to 2 points (points/channel)
(depending on settings)
0 to 2 axes
Input: 0 to 6 points (points/axis) (depending
Positioning
on settings)
function*1
Output: 2 to 3 points (points/axis) (depending
on settings)
*1
Number of points
Available range
• When using only one
channel:
0 to 5 points
• When using two channels
• When using only one
channel:
0 to 2 points
• When using two channels
simultaneously:
simultaneously:
0 to 10 points
0 to 4 points
• When using only one axis:
0 to 6 points
• When using two axes
simultaneously: 0 to 12 points
• When using only one axis:
2 to 3 points
• When using two axes
simultaneously: 4 to 6 points
Assignment of some signals used for the high-speed counter function and positioning function (such as A phase, B
phase, and near-point watchdog) are fixed. When using these functions, no signal can be assigned in place of the
signals.
19
CHAPTER 2
EXTERNAL I/O SPECIFICATIONS
This chapter describes internal circuits, pin numbers and corresponding signal names, and specifications of external
I/O interface.
For connectors used for external wiring, refer to
MELSEC-L CPU Module User's Manual (Hardware Design,
Maintenance and Inspection).
(1) Input specifications
Item
Specification
High-speed input (IN0-IN5)
Signal name
24V input
Differential input
24V input
24VDC (+20%/-15%, ripple ratio
Rated input voltage
19.0V or higher/5.0mA or higher
OFF voltage/OFF current
8V or lower/1.5mA or lower
Input resistance
within 5%)
Differential line driver level
6.0mA (TYP.) (At 24VDC)
ON voltage/ON current
24VDC (+20%/-15%, ripple ratio
EIA Standard RS-422-A
within 5%)
Rated input current
Response time
Standard input (IN6-INF)
4.1mA (TYP.) (At 24VDC)
(AM26L31 (Manufactured by
19.0V or higher/3.5mA or higher
Texas Instruments Incorporated)
8V or lower/1.0mA or lower
or equivalent)
3.8kΩ
5.6kΩ
On
10µs or less
100µs or less
Off
10µs or less
100µs or less
Withstand voltage
510VAC for 1 minute between input terminal and internal power supply (altitude: 0 to 2000m)
10MΩ or higher between input terminals and internal power supply (500VDC insulation resistance
Insulation rasistance
tester)
Wiring method for common
Independant common
-
10 points/common
The following shows a temperature derating curve for the input signal.
(16 points, 45
(16 points, 55
)
Input voltage:
24VDC
Input voltage:
26.4VDC
Simultaneous on points (point)
16
14
12
10
Input voltage: 28.8VDC
(8 points, 55
8
6
4
2
0
0
10
20
30
40
Ambient temperature (
20
)
50
)
55
60
)
CHAPTER 2 EXTERNAL I/O SPECIFICATIONS
(2) Output specifications
Item
Signal name
Specification
2
Output (OUT0-OUT7)
Rated load voltage
5 to 24VDC
Rated load current
0.1A/point
Maximum voltage drop at ON
0.2V (TYP.)
Leakage current at OFF
0.1mA or lower
Response
On
1µs or less (rated load, resistive load)
time
Off
1µs or less (rated load, resistive load)
Withstand voltage
Insulation rasistance
Wiring method for common
510VAC for 1 minute between input terminal and internal power supply (altitude: 0 to 2000m)
10MΩ or higher between input terminals and internal power supply (500VDC insulation resistance tester)
L02CPU, L26CPU-BT: 8 points/common (sink type)
L02CPU-P, L26CPU-PBT: 8 points/common (source type)
(3) Signal assignment of the connector for external devices
B20
B19
B18
B17
B16
B15
B14
B13
B12
B11
B10
B09
B08
B07
B06
B05
B04
B03
B02
B01
A20
A19
A18
A17
A16
A15
A14
A13
A12
A11
A10
A09
A08
A07
A06
A05
A04
A03
A02
A01
Viewed from the front of the module
21
(4) Internal circuits
(a) L02CPU, L26CPU-BT
Signal name*2
Classification
External wiring
Pin number
Internal circuit
24VDC
B20
High-speed 24V
input (IN0-24V)
A20
3.6k
1/2W
*1
B19
A19
680
1/10W
B18
A18
B17
A17
220
3.6k
1/2W
B16
A16
680
1/10W
B15
A15
B14
A14
220
24VDC
3.6k
1/2W
Input
*1
B13
A13
680
1/10W
B12
A12
B11
A11
B10
A10
220
1k
1/10W
A09
5.6k
1/3W
B07
Load
Load
A08
A07
B06
A06
B05
A05
B04
A04
B03
A03
B02
A02
B01
A01
High-speed 24V
input (IN1-24V)
High-speed 24V
input (IN3-24V)
High-speed
differential
input (N1-DIFF)
High-speed
input common
(IN1-COM)
High-speed
differential
input (IN3-DIFF)
High-speed
input common
(IN3-COM)
High-speed 24V
input (IN4-24V)
High-speed 24V
input (IN5-24V)
Standard input common
(INCOM)
5.6k
1/3W
B08
High-speed 24V
input (IN2-24V)
High-speed
High-speed
differential
differential
input (IN4-DIFF) input (IN5-DIFF)
High-speed
High-speed
input common
input common
(IN5-COM)
(IN4-COM)
24VDC
B09
A line
High-speed
High-speed
differential
differential
input (IN0-DIFF) input (IN2-DIFF)
High-speed
High-speed
input common
input common
(IN2-COM)
(IN0-COM)
24VDC
*1
B line
5.6k
1/3W
5.6k
1/3W
1k
1/10W
1k
1/10W
1k
1/10W
1k
1/10W
5.6k
1/3W
Standard input
(IN6)
Standard input
(IN7)
Standard input
(IN8)
Standard input
(IN9)
Standard input
(INA)
Standard input
(INB)
Standard input
(INC)
Standard input
(IND)
Standard input
(INE)
Standard input
(INF)
Output (OUT0)
Output (OUT1)
Output (OUT2)
Output (OUT3)
Output (OUT4)
Output (OUT5)
Output (OUT6)
Output (OUT7)
Insulating
element
Insulating
element
Load
Output
Insulating
element
Load
Fuse
5 to 24VDC
*1
*2
Output common (OUTCOM)
High-speed inputs can be connected based on the 24V input mode or differential input mode.
For signal names when using the positioning function or high-speed counter function, refer to the following.
• Positioning function:
Page 48, Section 7.2.1
• High-speed counter function:
22
Insulating
element
Page 185, Section 8.2.1
CHAPTER 2 EXTERNAL I/O SPECIFICATIONS
(b) L02CPU-P, L26CPU-PBT
Signal name*2
Classification
External wiring
Pin number
Internal circuit
24VDC
B20
A20
3.6k
1/2W
*1
B19
A19
680
1/10W
220
A17
High-speed
24V input
(IN1-24V)
High-speed
24V input
(IN3-24V)
High-speed
differential input
(IN1-DIFF)
High-speed
differential input
(IN3-DIFF)
B16
A16
220
B15
A15
High-speed
input common
(IN1-COM)
High-speed
input common
(IN3-COM)
B14
A14
High-speed
24V input
(IN4-24V)
High-speed
24V input
(IN5-24V)
High-speed
differential input
(IN4-DIFF)
High-speed
differential input
(IN5-DIFF)
High-speed
input common
(IN4-COM)
High-speed
input common
(IN5-COM)
B13
A13
680
1/10W
B12
A12
B11
A11
B10
A10
220
24VDC
Standard input common
(INCOM)
1k
1/10W
5.6k
1/3W
B09
A09
5.6k
1/3W
B08
B07
A08
A07
B06
A06
B05
A05
B04
A04
B03
A03
B02
A02
B01
A01
5.6k
1/3W
5.6k
1/3W
Load
1k
1/10W
1k
1/10W
1k
1/10W
1k
1/10W
5.6k
1/3W
Load
Output
High-speed
differential input
(IN2-DIFF)
B17
3.6k
1/2W
Load
High-speed
differential input
(IN0-DIFF)
High-speed
input common
(IN2-COM)
24VDC
Load
High-speed
24V input
(IN2-24V)
High-speed
input common
(IN0-COM)
680
1/10W
*1
High-speed
24V input
(IN0-24V)
A18
3.6k
1/2W
Input
A line
B18
24VDC
*1
B line
Fuse
Insulating
element
Insulating
element
Insulating
element
Insulating
element
Standard input
(IN6)
Standard input
(IN7)
Standard input
(IN8)
Standard input
(IN9)
Standard input
(INA)
Standard input
(INB)
Standard input
(INC)
Standard input
(IND)
Standard input
(INE)
Standard input
(INF)
Output
(OUT0)
Output
(OUT1)
Output
(OUT2)
Output
(OUT3)
Output
(OUT4)
Output
(OUT5)
Output
(OUT6)
Output
(OUT7)
Output common
(OUT24V)
5 to 24VDC
*1
*2
High-speed inputs can be connected based on the 24V input mode or differential input mode.
For signal names when using the positioning function or high-speed counter function, refer to the following.
• Positioning function:
Page 48, Section 7.2.1
• High-speed counter function:
Page 185, Section 8.2.1
23
2
(5) I/O connector pin numbers and corresponding I/O signals
Pin
Cate-
number
gory
Type
Correspondence
Corresponding
Pin
Cate-
for line driver
I/O signal
number
gory
B20
Compatibility
Corresponding
with line driver
I/O signal
A20
Highspeed
B19
X0
B18
A19
Highspeed
X2
Highspeed
X3
Highspeed
X5
A18
A17
B17
Highspeed
B16
X1
B15
A16
A15
B14
B13
Type
A14
Input
Highspeed
X4
B12
A13
Input
A12
B11
Input common
A11
Input common
B10
Standard
⎯
X6
A10
Standard
⎯
X7
B09
Standard
⎯
X8
A09
Standard
⎯
X9
B08
Standard
⎯
XA
A08
Standard
⎯
XB
B07
Standard
⎯
XC
A07
Standard
⎯
XD
B06
Standard
⎯
XE
A06
Standard
⎯
XF
B05
Highspeed
⎯
Y0
A05
Highspeed
⎯
Y1
B04
Highspeed
⎯
Y2
A04
Highspeed
⎯
Y3
Highspeed
⎯
Y4
A03
Highspeed
⎯
Y5
Highspeed
⎯
Y6
A02
Highspeed
⎯
Y7
B03
Output
B02
Output common*1
B01
*1
24
A01
Output
Output common*1
B01 and A01 are used as negative common on the L02CPU and L26CPU-BT, while they are used as positive common
on the L02CPU-P and L26CPU-PBT.
CHAPTER 2 EXTERNAL I/O SPECIFICATIONS
(6) Input signal assignment
: Selectable, ×: No combination
2
Function
External
General-
input signal
purpose
input
Interrupt
Pulse
input
catch
High-speed counter
Positioning
X0(High-speed)
*1
Counter CH1 A Phase*1
×*3
X1(High-speed)
*1
Counter CH1 B Phase*1
×*3
X2(High-speed)
*1
Counter CH2 A Phase*1
×*3
X3(High-speed)
*1
Counter CH2 B Phase*1
×*3
X4(High-speed)
Counter CH1 Z Phase*2
Axis #1 Zero Signal*2
X5(High-speed)
Counter CH2 Z Phase*2
Axis #2 Zero Signal*2
X6(Standard)
Counter CH1 Function Input*2
Axis #1 External Command Signal*2
X7(Standard)
Counter CH2 Function Input*2
Axis #2 External Command Signal*2
X8(Standard)
Counter CH1 Latch Counter*2
Axis #1 Drive Module READY Signal*2
X9(Standard)
Counter CH2 Latch Counter*2
Axis #2 Drive Module READY Signal*2
XA(Standard)
×*3
Axis #1 Near-point Dog Signal*2
XB(Standard)
×*3
Axis #2 Near-point Dog Signal*2
XC(Standard)
×*3
Axis #1 Upper Limit Signal*2
XD(Standard)
×*3
Axis #2 Upper Limit Signal*2
XE(Standard)
×*3
Axis #1 Lower Limit Signal*2
XF(Standard)
×*3
Axis #2 Lower Limit Signal*2
*1
*2
*3
When using CH1 for the high-speed counter function, X0 and X1 cannot be used as interrupt inputs. Also, when using
CH2 for the high-speed counter function, X2 and X3 cannot be used as interrupt inputs.
Other functions such as the general-purpose input can be used.
When this signal is not required, the input signal can be used for other functions such as the general-purpose input.
When the high-speed counter function or positioning function is selected, this signal is not used for that function. This
signal can be used for another function such as the general-purpose input function.
25
(7) Output signal assignment
: Selectable, ×: No combination
Function
External
output signal
*1
*2
*3
General-
High-speed Counter
Positioning
Y0
CH1 Coincidence Output No.1*1
×*3
Y1
CH2 Coincidence Output No.1*1
×*3
Y2
CH1 Coincidence Output No.2*2
Axis #1 Deviation Counter Clear*1
Y3
CH2 Coincidence Output No.2*2
Axis #2 Deviation Counter Clear*1
Y4
×*3
Axis #1 CW/PULSE/A Phase Output*1
Y5
×*3
Axis #2 CW/PULSE/A Phase Output*1
Y6
×*3
Axis #1 CCW/SIGN/B Phase Output*1
Y7
×*3
Axis #2 CCW/SIGN/B Phase Output*1
purpose output
This signal must be used depending on parameter settings.
When this signal is not used, the output signal can be used for the general-purpose output function.
When this signal is not used, the output signal can be used for the general-purpose output function.
When the high-speed counter function or positioning function is selected, this signal is not used for that function. This
signal can be used for the general-purpose output function.
(8) Simplified chart of I/O signals
The following shows a simplified chart of I/O signals for the high-speed counter function and positioning function.
High-speed Counter
Positioning
CH1
CH2
Axis#1
Axis#2
X0
X2
X4
X5
X6
X1
X3
X8
X7
X9
X4
X5
XA
XB
X6
X7
XC
XD
X8
X9
XE
XF
Y0
Y1
Y2
Y3
Y2
Y3
Y4
Y5
Y6
Y7
(9) External input signals (X0 to XF) when using the functions
The on/off statuses of the external input signals (X0 to XF) are reflected to the input devices (X0 to XF) in the
program when using any built-in I/O functions (except the pulse catch function). When using the pulse catch
function, an input device is turned on for one scan by detecting the rising edge of the external input signal
(
Page 36, CHAPTER 6).
When selecting positioning function or high-speed counter function, an input signal that is not used due to settings
of the functions operates as the general-purpose input.
Remark
The IN0 to IN F LEDs indicate statuses of the external input signals (X0 to XF). However, the indicating status is not affected
by turning on or off the input devices (X0 to XF) in the program.
26
CHAPTER 2 EXTERNAL I/O SPECIFICATIONS
(10)External output signals (Y0 to Y7) when using the functions
The external output signals (Y0 to Y7) reflect the output statuses of the functions selected from the generalpurpose output, positioning, and high-speed counter function. Therefore, the output statuses are not affected by
turning on or off the output devices (Y0 to Y7) in the program when using the output signals for the positioning or
high-speed counter function.
In addition, the output devices (Y0 to Y7) do not reflect statuses of the output signals used for the positioning or
the high-speed counter function.
Remark
The OUT 0 to OUT 7 LEDs indicate statuses of the external output signals. So the output statuses of the output devices (Y0
to Y7) are indicated when the output signals are used for the general-purpose output. Actual output statuses of the
positioning or the high-speed counter function are indicated when the output signals are used for the functions. (The
indicating status is not affected by turning on or off the output devices in the program.)
(11)Monitoring by the programming tool
To check the I/O settings, open the "I/O Monitor" dialog box of the programming tool.
[Tool]
[Built-in I/O Module Tool]
For details, refer to the following.
GX Works2 Version1 Operating Manual (Common).
27
2
CHAPTER 3
GENERAL-PURPOSE INPUT
FUNCTION
This function uses the built-in external input signals (16 points) as general-purpose inputs to read the on/off status of
external devices such as switches and sensors.
The on/off status of the external input signals are refreshed to the input device (X0 to XF) and used in programs.
(1) Parameter setting
Set the input signal and input response time value.
Project window
[Parameter]
[PLC Parameter]
"Built-in I/O Function Setting" tab
Select a response time.
Select "General-purpose input".
(2) External input signal types
The following two types are available.
• High-speed input: X0 to X5 (6 points)
• Standard input: X6 to XF (10 points)
(3) Read timing for external input signals
The on/off statuses of the external input signals are reflected to input devices (X0 to XF) by performing the refresh
at execution of END instructions. Therefore, a delay for one scan (maximum) occurs from when an external input
signal changes until when the input device turns on.
(4) Direct input
When using the external input signals for the direct input devices (DX0 to DXF), the external input statuses are
read at execution of sequence instructions using the direct input devices.
28
CHAPTER 3 GENERAL-PURPOSE INPUT FUNCTION
(5) Partial refresh
The LCPU can read the current external input status by executing partial refresh using the RFS instruction to the
input device (X0 to XF). For the RFS instruction, refer to the following.
MELSEC-Q/L Programming Manual (Common Instruction)
(6) Performance specifications
3
The following is the performance specifications of the general-purpose output function.
Item
Description
Points
Standard input
10
Input voltage/current
24VDC, 4.1mA (TYP.)
Minimum input response time
100µs
Input response time setting
0.1ms/1ms/5ms/10ms/20ms/70ms
Points
6
DC input
High-speed input
Input voltage/current
input
Minimum input response time
Input response time
*1
Differential
setting*1
24VDC 6.0mA (TYP.)
EIA Standard RS-422-A Differential line driver level
AM26L31 (manufactured by Texas Instruments
Incorporated) or equivalent
10µs
0.01ms/0.1ms/0.2ms/0.4ms/0.6ms/1ms
The shorter the input response time is, the more the module is susceptible to noise. When setting the input response
time, check that the module will not be affected by noise. For details of measures against noise, refer to the following.
MELSEC-L CPU Module User's Manual (Hardware Design, Maintenance and Inspection)
29
CHAPTER 4
GENERAL-PURPOSE OUTPUT
FUNCTION
This function uses the built-in external output signals (8 points) as general-purpose outputs for external devices such
as lamps.
By turning on/off the output device (Y0 to Y7) in programs, the LCPU can output the signals externally.
(1) Parameter setting
Set the output signal and error time output mode.
Project window
[Parameter]
[PLC Parameter]
"Built-in I/O Function Setting" tab
Select an error time output mode.
Select "General Output".
(2) External output timing
On/off statuses of the output devices are reflected to external outputs (Y0 to YF) by performing the refresh at
execution of the END instructions. Therefore, a delay for one scan (maximum) occurs from when an external
device turns on/off in programs until when the external output is reflected.
(3) Direct output
When using the output devices (Y0 to Y7) for the direct output devices (DY0 to DY7), on/off statuses of the
devices are reflected to external outputs by instructions such as the SET instructions to the devices.
(4) Partial refresh
The output device status (only specified range) is reflected to the external output by executing partial refresh
using the RFS instruction to the output device (Y0 to Y7). (
Instruction)).
30
MELSEC-Q/L Programming Manual (Common
CHAPTER 4 GENERAL-PURPOSE OUTPUT FUNCTION
(5) Error time output mode
Select Hold or Clear for output statuses of the output devices (Y0 to Y7) when an error to stop the program
occurs. (This is not setting for output of the output modules and the intelligent function modules. For details on
setting of the error time output mode for modules, refer to the following.
MELSEC-L CPU Module User's Manual (Function Explanation, Program Fundamentals)
(6) Performance specifications
The following is the performance specifications of the general-purpose output function.
L02CPU, L26CPU-BT
Output type
L02CPU-P, L26CPU-PBT
Sink type
Points
Source type
8
Output voltage/current
Response time
4
Description
Item
5 to 24VDC, 0.1A
On
1µs or less (rated load, resistive load)
Off
1µs or less (rated load, resistive load)
31
CHAPTER 5
INTERRUPT INPUT FUNCTION
This function executes an interrupt program when triggered by the input signal (X0 to XF).
(1) Parameter setting
Set the input signal, input response time value, and interrupt processing condition.
Project window
[Parameter]
[PLC Parameter]
Select a response time.
Select "Interrupt input".
32
"Built-in I/O Function Setting" tab
Select an interrupt
processing condition.
CHAPTER 5 INTERRUPT INPUT FUNCTION
(2) Interrupt pointer assignment and interrupt priority
The following shows interrupt pointers corresponding to input signals (X0 to XF)
*1
I/O signals
Interrupt pointer
Priority*1
X0
I0
5
X1
I1
6
X2
I2
7
X3
I3
8
X4
I4
9
X5
I5
10
X6
I6
11
X7
I7
12
X8
I8
13
X9
I9
14
XA
I10
15
XB
I11
16
XC
I12
17
XD
I13
18
XE
I14
19
XF
I15
20
5
The priority 1 to 4 are used for interrupt pointers I28 to I31 (interrupt by build-in timers)
Interrupt pointer numbers can be changed.(
Page 34, (2) (a))
33
(a) Changing the interrupt pointer numbers
1.
Click the
button in the "PLC System" tab.
Project window
2.
3.
[Parameter]
[PLC Parameter]
[PLC System]
Set the interrupt pointer start No., interrupt pointer count, start I/O No., and start SI No.
Click the
button to exit.
Ex. When assigning the interrupt inputs X0 and X1 to the interrupt pointers I50 and later.
• Precautions
When the range of interrupt input that is specified in the "Intelligent Function Module Interrupt Pointer
Setting" and the interrupt input is not selected for the built-in I/O function in the range, "PARAMETER
ERROR" (error cord: 3000) occurs.
The following shows a correct example and an incorrect example of assigning the interrupt inputs to the
interrupt pointers I50 and later as shown above.
• Correct example
As shown below, the interrupt inputs are set within the range specified in "Intelligent Function Module
Interrupt Pointer Setting", so the error will not occur.
Input signal function selection: X0 and X1 are set to the interrupt inputs.
• Incorrect example
As shown below, input signal X2 and X3 are set to the interrupt inputs, but no interrupt input are set
within the range specified in "Intelligent Function Module Interrupt Pointer Setting", so the error will
occur.
Input signal function selection: X2 and X3 are set to the interrupt inputs.
34
CHAPTER 5 INTERRUPT INPUT FUNCTION
(3) Interrupt processing condition
The following shows three types of conditions to execute the interrupt programs by the interrupt inputs.
Interrupt processing
Description
condition
Rising edge
Executes the program at the rising edge of the interrupt input signal.
Falling edge
Executes the program at the falling edge of the interrupt input signal.
Executes the program at both the rising edge and the falling edge of the interrupt input
Rising edge + Falling edge
signal.
When "Rising edge + Falling edge" is set for the interrupt processing function, only the first interrupt factor is
stored but the second one and later are ignored.
When the second rising edge (falling edge) of the signal is detected after the falling edge (rising edge) during
execution of the interrupt program due to the first one, the second one cannot execute the interrupt program. To
avoid this, keep an enough interval between on and off of the interrupt input.
Also, when the signals that the on width and off width are short are detected frequently, the main routine program
is interrupted frequently. Keep an enough on width and off width so that execution of the main routine program
may not be interrupted.
(4) Interrupt enable/disable
Use the EI instruction to enable the interrupt. Also, use the DI instruction to disable interrupt and IMASK
instruction to mask the interrupt program. (
MELSEC-Q/L Programming Manual (Common Instruction))
(5) Performance specifications
The following is the performance specifications of the interrupt input function.
Item
Description
Points
Standard input
10
Input voltage/current
24VDC, 4.1mA (TYP.)
Minimum input response time
100µs
Input response time setting
0.1ms/1ms/5ms/10ms/20ms/70ms
Points
6
DC input
High-speed
Input voltage/current
input
Differential
input
Minimum input response time
Input response time setting
24VDC, 6.0mA (TYP.)
EIA Standard RS-422-A Differential line driver level
AM26L31 (manufactured by Texas Instruments
Incorporated) or equivalent
10µs
0.01ms/0.1ms/0.2ms/0.4ms/0.6ms/1ms
35
5
CHAPTER 6
PULSE CATCH FUNCTION
This function can catch pulse signals that the general-purpose input function cannot catch because the on time is
shorter than the scan time.
(1) Parameter setting
Set the input signal and input response time value.
Project window
[Parameter]
[PLC Parameter]
"Built-in I/O Function Setting" tab
Select a response time.
Select "Pulse Catch".
(2) Basic operation of the pulse catch function
An input device is turned on for one scan after detecting a pulse signal and turned off by the END instruction.
(a) Operation when using an input signal (X0) as the pulse catch function
An input device is turned on for one scan after detecting a rising edge of an external input signal (X0).
0 step
END
0 step
0 step
END
Program
1) Input signal ON
External input signal
X0
OFF
Input device
X0
OFF
2) ON for 1 scan
36
CHAPTER 6 PULSE CATCH FUNCTION
(b) Operation when detecting more than one pulse in one scan
Second pulse and later are ignored. Input pulse signals at intervals of one scan or more.
0 step
END
0 step
0 step
END
Program
1) Input signal ON
These pulses are ignored.
External input signal
OFF
X0
Input device
X0
OFF
2) ON for 1 scan
When counting second and third pulse input is required, use the interrupt input function.
However, if third pulse is detected before the end of the execution of the interrupt program, the pulse cannot be counted.
1): Interrupt program execution
2): Interrupt program execution in the next scan
3): If a pulse is input after completion of the interrupt program by
1), the interrupt program is executed at time after the next.
1 scan
External
input signal
X0
OFF
1)
2)
3)
Interrupt program
(c) Operation when detecting same pulses in two scans or more.
The input device is turned on for scans by the amount of detected pulses. Input pulse signals at intervals of one
scan or more.
0 step
END
0 step
END
0 step
END
0 step
Program
1) Input signal ON
3) Input signal ON
External input signal
OFF
X0
Input device
X0
OFF
2) ON for 1 scan
4) ON for 1 scan
ON for 2 scans
37
6
(d) Operation when detecting a pulse that has on width of two scans or more.
The input device is turned on for one scan.
0 step
END
0 step
0 step
END
Program
External input signal
OFF
X0
Input device
X0
1) Input signal ON
OFF
2) ON for 1 scan
(3) Detectable pulse width
Pulse width that meets the following condition can be detected.
On or off width of the pulse input > Input response time
When the condition is not met, the pulse cannot be detected correctly. Set the input response time to meet it.
(4) Precautions
Avoid the following actions for the input device (X0 to XF) that is set to the pulse catch function.
Otherwise, the input device cannot be turned on correctly for one scan after detecting a pulse.
• Using the direct devices DX
• Executing the instruction such as the RFS, COM, CCOM (P), and MTR that perform the input refresh at the
execution
(5) Performance specifications
The following is the performance specifications of the pulse catch function.
Item
Description
Points
Standard input
10
Input voltage/current
24VDC, 4.1mA (TYP.)
Minimum input response time
100µs
Input response time setting
0.1ms/1ms/5ms/10ms/20ms/70ms
Points
6
DC input
High-speed input
Input voltage/current
input
Minimum input response time
Input response time setting
38
Differential
24VDC, 6.0mA (TYP.)
EIA Standard RS-422-A Differential line driver level
AM26L31(manufactured by Texas Instruments
Incorporated) or equivalent
10µs
0.01ms/0.1ms/0.2ms/0.4ms/0.6ms/1ms
CHAPTER 7 POSITIONING FUNCTION
CHAPTER 7
7.1
POSITIONING FUNCTION
1
Overview
(1) Definition
This function is used to move a table, machining target, tool, or other moving body (workpiece) at a specified
speed with the purpose of stopping it accurately at a target position.
(2) Features
The positioning function is controlled by dedicated instructions.
Mechanical system
Programming tool
LCPU
Hardware stroke
Hardware stroke
lower limit switch
upper limit switch
Near-point
watchdog Workpiece
Drive unit
Motor power
cable
Servo motor
7
Encoder cable
Hardware stroke
Hardware stroke
lower limit switch
upper limit switch
Near-point
watchdog Workpiece
Drive unit
Motor power
cable
Servo motor
Encoder cable
7.1 Overview
(a) 2-axis control
Two drive units (two motors) can be connected and two coordinates can be controlled independently or
simultaneously.
(b) OPR (Original point return)
Six types of OPR methods are available. A near-point dog (OP sensor), etc., can be used to establish the OP
(position that becomes the starting point of each control) and "address" of this position. (Machine OPR) OPR
can also be performed automatically within the range defined by the upper and lower limit switch. (OPR retry
function)
(c) Target position and speed
• The workpiece can be moved to the target position based on a specified address or movement amount.
(Position control)
• The workpiece can be moved until a stop instruction is executed. (Speed control)
• The current position can be changed to a specified value. (Current value change function)
• The target position can be changed while the workpiece is moving. (Target position change function)
• The speed can be changed while the workpiece is moving. (Speed change function)
(d) Limitation of the moving range of the workpiece
Desired positions can be set as the logical upper limit and lower limit of the moving range of the workpiece,
without using switches. (Software stroke limit function)
Also, upper and lower limit switches can be used to limit the moving range. (Hardware stroke limit function)
39
(e) JOG operation
The workpiece can be moved to a desired position according to the pulses that are output continuously while a
JOG operation instruction is executed. (JOG operation function)
(f) Absolute position detection
A servomotor with absolute position detector can be used to restore the current position after a power failure,
etc. (Absolute position restoration function)
40
CHAPTER 7 POSITIONING FUNCTION
1
(3) Function list
The following table lists and describes functions available for the positioning function.
Item
Description
Machine OPR
OPR control
Fast OPR
Position control
(1-axis linear control)
Speed/position
Positioning
control
switching control
Current value
change function
Speed control
Multiple axes simultaneous start control
JOG operation function
OPR retry
function
A function to mechanically establish the reference point (OP) for
positioning control using a near-point dog, stopper, etc.
A function to execute positioning control to the OP address stored by
machine OPR or standby address that has been set
A function to execute positioning control to a specified position according
to the address or movement amount set by positioning data
A function to start under speed control and then switch to position control
(positioning control based on specified movement amount) via an external
command signal
A function to change the address (current feed value)
A function to implement positioning control via operation at a specified
speed
A function to start two axes simultaneously at the pulse output level
A function to output pulses only while a JOG start instruction(IPJOG1) is
executed to move the workpiece to a desired position
A function to perform machine OPR automatically by detecting an off
edge of the limit signal and moving to a position where machine OPR is
possible, even when the OP is not located in the OPR direction
A function to limit the speed to within the setting range of speed limit when
Speed limit function
the operating speed exceeds the positioning parameter "Speed Limit
Value"
function
A function to change the speed during operation
Page 70, Section
7.6.1
Page 90, Section
7.6.2
Page 99, Section
7.7.2
Page 100, Section
7.7.3
Page 102, Section
7.7.4
Page 103, Section
7.7.5
Page 104, Section
7.8
Page 106, Section
7.9
Page 111, Section
7.10.1
Page 115, Section
7.10.2
Page 116, Section
7.10.3
A function to not start operation when a start instruction is given to move
Software
stroke
Subfunction
limit function
to the target position which is outside the range set by the upper stroke
limit and lower stroke limit
The limit function also stops operation when the current position (current
Page 121, Section
7.10.4
feed value) deviates from the setting range.
Hardware
stroke
limit function
A function to decelerate the axis to a stop using a limit switch connected
to the external device connector
Target position
A function to change the address or movement amount during positioning
change function
control
Acceleration/
deceleration
processing function
Stop processing
function
A function to adjust the acceleration/deceleration processing as part of
control
A function to control the stopping method to be applied when a stop
cause occurs during operation
Page 124, Section
7.10.5
Page 125, Section
7.10.6
Page 129, Section
7.10.7
Page 131, Section
7.10.8
A function to restore the current position (current feed value) using a
servomotor with absolute position detector, without executing machine
Absolute position restoration function
OPR, in the event of a momentary power failure, emergency stop, etc.
(Connectable servo amplifiers are limited to those products in the general-
7
Page 134, Section
7.11
purpose AC servo MEL SERVO series (pulse-train type) supporting
absolute position detection systems.)
41
7.1 Overview
Speed change
Reference
(4) Mechanism of a positioning control system
Positioning control is implemented based on pulses output from the LCPU. In a positioning system, software and
external devices are used to perform the roles shown below.
Parameter setting
Start instruction for the positioning control
such as a JOG operation
Positioning operation monitoring
Signals such as a limit signal and
a positioning control switching signal are output.
External signal
Programming tool
LCPU
Error detection
The drive unit ready signal and
zero signal are output to LCPU.
Pulses are output to the drive unit
by using a programming tool and external command signal.
Drive unit
Motor drive command with pulse commands from the CPU module
Motor
The actual work is performed by the commands
from the drive unit.
Workpiece
42
CHAPTER 7 POSITIONING FUNCTION
1
(5) Operation inside the drive unit
After receiving a pulse input from the LCPU, the following operations occur in the drive unit.
LCPU
Drive unit
Servomotor
Forward run pulse train
Program
Reverse run pulse train
Deviation
counter
Servo
amplifier
D/A
converter
Operation
such as data
read and write
M
Interface
Positioning
function
PLG
Feedback pulse
Pulse generator
Programming tool
7
(a) Starting
When pulses are output from the LCPU, the input pulses are retained in the deviation counter of the drive unit.
The integration value of this pulse (droop pulse) is converted to a DC analog voltage by the D/A converter to
give a speed command for the servomotor (M). The servomotor starts rotating by the speed command from the
drive unit.
(b) During operation
in proportion to the speed. The generated feedback pulses are fed back to the drive unit and the deviation
counter droop pulse are decremented accordingly. The servomotor continues to rotate with the deviation
counter maintaining a certain amount of droop pulses.
(c) Stopping
When the command pulse output from the LCPU stops, the deviation counter droop pulse decrease and the
speed drops. The servomotor stops once the droop pulses become 0.
The rotation speed of the servomotor is proportional to the command pulse frequency, while the rotation angle of
the servomotor is proportional to the number of output command pulses. Therefore, the workpiece can be fed to a
position proportional to the number of pulses in the pulse train by specifying the movement amount per pulse
beforehand. Note that the pulse frequency defines the rotation speed of the servomotor (feed speed).
43
7.1 Overview
As the servomotor rotates, the pulse generator (PLG) supplied with the servomotor generates feedback pulses
(6) Principles of position control and speed control
(a) Position control
The total No. of pulses needed to move a specified distance can be obtained by the formula below.
Total number of pulses
required to move designated distance
*1
Designated distance
=
Movement amount of
machine (load) side
when motor rotates once
Number of pulses required for
motor to rotate once *1
Encoder resolution.
Give the calculated total No. of pulses to the drive unit from the LCPU, and the workpiece will be controlled to
move the specified distance. Note that the movement amount of the machine when one pulse is output to the
drive unit is called "movement amount per pulse." This value corresponds to the minimum movement of the
workpiece and determines the accuracy of electrical positioning control.
(b) Speed control
The speed is controlled by the "pulse frequency" output to the drive unit from the LCPU.
Pulse frequency (pulse/s)
This trapezoid area is equal
to the total number of pulses.
Moving time
t
● The value of "movement amount per pulse" is determined by the machine.
● The LCPU controls the position and speed based on the "total No. of pulses" and "pulse frequency," respectively.
44
CHAPTER 7 POSITIONING FUNCTION
1
(7) Pulses output from the LCPU
• Pulse trains are sparse when the servomotor is accelerating, and become denser as the servomotor
approaches the stable speed that has been set.
• At the stable speed, constant pulse trains are output.
• When the pulses output from the LCPU become sparse, the servomotor decelerates until pulses are no
longer output. There is a slight delay from the LCPU command pulses to the time the servomotor
decelerates and stops. This difference is necessary to ensure sufficient stopping accuracy and is referred to
as the "stop setting time".
V
Servomotor speed
Pulse droop amount
Pulse distribution
t
Deceleration
Acceleration
Stop setting time
7
Pulse train
Sparse
Dense
Sparse
7.1 Overview
45
(8) Movement amount and speed of a worm gear system
This section explains methods of calculations required for positioning control by using worm gear system. The
worm gear consists of a balls lined up in an engagement part, just like a ball bearing. The ball screw has no
backlash and can rotate with a small force.
Internal thread
External thread
The calculations are performed based on the system described below.
V
Workpiece
Worm gear
Pulse generator (PLG)
R
Servomotor
Table
L
P0
P
A : Movement amount per pulse (mm/pulse)
Vs : Command pulse frequency (pulse/s)
n : Pulse generator resolution (pulse/rev)
L : Worm gear lead (mm/rev)
R : Deceleration ratio
V : Movable section speed (mm/s)
N : Motor speed (r/min)
K : Position loop gain (1/s)
: Deviation counter droop pulse amount
P0 : OP (pulse)
P : Address (pulse)
(a) Movement amount per pulse
Calculated from the worm gear lead, deceleration ratio and pulse generator resolution.
L
(mm/pulse)
R n
A=
The movement amount is calculated by (Number of output pulses) x (Movement amount per pulse)
(b) Command pulse frequency
Calculated from the movable section speed and movement amount per pulse.
Vs =
V
(pulse/s)
A
(c) Deviation counter droop pulse amount
Calculated from the command pulse frequency and position loop gain*1.
=
*1
46
Vs
(pulse)
K
Ratio of the command pulse frequency to the number of deviation counter droop pulses. A desired position loop gain can
be set adjusting the drive unit. To improve the stopping accuracy, increase the gain. Note, however, that an excessively
high gain may cause overshooting (beyond the target position) to make the operation unstable. An excessively low gain
increases the stopping error, although the movement becomes smoother at stopping.
CHAPTER 7 POSITIONING FUNCTION
7.1.1
Procedure for performing the positioning function
1
The following shows the procedure.
Start
Connect an external device.
Set parameters by a programming
tool.
Create programs.
Connection to an
external device
( Page 48, Section 7.2 )
Positioning parameters
( Page 55, Section 7.3.1 )
OPR parameters
( Page 62, Section 7.6 )
Positioning data
( Page 93, Section 7.7 )
Dedicated instructions
( Page 139, Section 7.12 )
Programming
( Page 165, Section 7.13 )
Execute the programs.
7
End
7.1 Overview
7.1.1 Procedure for performing the positioning function
47
7.2
Connection to External Devices
7.2.1
I/O signals
The following shows the simplified diagrams of the internal circuits of LCPU external device connection interface.
" " in the signal name indicates either 1 (Axis 1) or 2 (Axis 2). For I/O signal settings, refer to
Page 53, Section
7.3.
(1) Input
Pin number
External wiring
Internal circuit
Axis 1
Axis 2
B20
A20
Signal name
24VDC
3.6k
1/2W
*1
B19
A19
680
1/10W
B18
220
A18
(Not used for the positioning function)
24VDC
B17
A17
3.6k
1/2W
*1
B16
A16
680
1/10W
B15
A15
B14
A14
220
24VDC
+24V
(PG0
3.6k
1/2W
*1
B13
Zero signal (PG0 )
A13
680
1/10W
24VDC
B12
A12
B11
A11
B10
A10
1k
1/10W
A09
B07
B06
*1
48
A08
A07
A06
COM
-COM)
Input common
5.6k
1/3W
B08
Differential
(PG0 -DIFF)
(PG0
5.6k
1/3W
B09
220
-24V)
5.6k
1/3W
5.6k
1/3W
5.6k
1/3W
1k
1/10W
External command signal (CHG )
Drive unit ready signal (READY )
1k
1/10W
Near-point watchdog signal (DOG )
1k
1/10W
Upper limit signal (FLS )
1k
1/10W
Lower limit signal (RLS )
High-speed inputs can be connected based on the 24V input mode or differential input mode.
CHAPTER 7 POSITIONING FUNCTION
1
(2) Output
(a) L02CPU, L26CPU-BT
Pin number
Internal circuit
Signal name
Axis 1
Axis 2
B05
A05
Insulating
element
(Not used for the positioning function)
B04
A04
Insulating
element
Deviation counter clear signal (CLEAR )
B03
A03
Insulating
element
B02
A02
B01
A01
-
Insulating
element
CW/PULSE/A phase output (PULSE F )
CCW/SIGN/B phase output (PULSE R )
Output common
7
(b) L02CPU-P, L26CPU-PBT
Pin number
Internal circuit
Axis 1
Axis 2
B05
A05
A04
B03
A03
B02
A02
B01
A01
Insulating
element
Insulating
element
Insulating
element
(Not used for the positioning function)
7.2 Connection to External Devices
7.2.1 I/O signals
B04
Insulating
element
Signal name
Deviation counter clear signal (CLEAR )
CW/PULSE/A phase output (PULSE F )
CCW/SIGN/B phase output (PULSE R )
Output common
49
(3) Details of I/O signals
The following table lists and describes the I/O signals of the connector for external devices.
Category
Signal name
Description
• The zero signal from the pulse generator etc. is used to input the OP signal for
Zero Signal
(PG0 )
performing the machine OPR.
• This signal is also used to indicate the completion of the machine OPR that uses a
stopper method for the machine OPR method.
• This signal is detected at the leading edge.
Input Common
External Command Signal
(CHG )
Common line for the external command signals, drive unit ready signal, near-point dog
signal, upper limit signal and lower limit signal
Used to input control switching signals in speed/position switching control.
• This signal turns on when the drive unit is normal and able to accept pulses.
• The LCPU checks this signal and if the drive unit is not ready, it turns on the Axis 1 OPR
request (SM1842).
• This signal turns off when the drive unit malfunctions, such as when the drive unit
Drive Unit Ready
Signal(READY )
control power generates an error.
• Turning off this signal during positioning control stops the axis. The axis will no longer
move even when the signal is turned on again.
Input
• When this signal turns off, the Axis 1 OPR completion (SM1843) also turns off.
• If this signal is not selected for the input signal function selection, the signal is regarded
as being on.
Near-point DOG Signal
(DOG )
• This signal is used to detect the near-point dog during machine OPR. The near-point
dog signal is detected at the leading edge.
• This signal is input from the limit switch installed at the upper limit position of the stroke.
• When this signal turns off, positioning stops.
Upper Limit Signal
(FLS )
• This signal defines the upper limit which is used to find the near-point dog when the
OPR retry function is enabled.
• If this signal is not selected for the input signal function selection, the signal is regarded
as being on.
• This signal is input from the limit switch installed at the lower limit position of the stroke.
• When this signal turns off, positioning stops.
Lower Limit Signal
(RLS )
• This signal defines the lower limit which is used to find the near-point dog when the
OPR retry function is enabled.
• If this signal is not selected for the input signal function selection, the signal is regarded
as being on.
Deviation Counter Clear Signal
(CLEAR )
This signal is output during machine OPR. (Count 2 is excluded.)
For the drive unit, use a model capable of resetting the internal deviation counter droop
pulse amount when the LCPU turns this signal on.
CW/PULSE/A Phase Output
Output
(PULSE F )
CCW/SIGN/B Phase Output
These signals are output as positioning pulses with pulse code to the drive unit.
(PULSE R )
Output Common
50
Common line for the deviation counter clear signal, CW/PULSE/phase A outputs and
CCW/SIGN/phase B outputs.
CHAPTER 7 POSITIONING FUNCTION
1
(4) On/off status of input signals
(a) On/off status of input signals
On/off status of input signals is determined according to external wiring.
Signal name
Signal on/off status as viewed from
External wiring
(Photocoupler OFF)
LCPU
24VDC
INn - 24V
OFF
INn - COM
(n = 0 to 5)
High-speed input
IN0 to IN5
(Photocoupler ON)
24VDC
INn - 24V
ON
7
INn - COM
(n = 0 to 5)
(Photocoupler OFF)
INn
24VDC
OFF
7.2 Connection to External Devices
7.2.1 I/O signals
IN - COM
(n = 6 to F)
Standard input
IN6 to INF
(Photocoupler ON)
INn
24VDC
ON
IN - COM
(n = 6 to F)
In the context of the LCPU's positioning function, the statuses shown above are defined as representing the
"negative logic".
(b) Internal circuit
With the LCPU, the "input signal OFF" status is defined as the off status of the corresponding internal circuit
(photocoupler).
• Voltage not applied: Photocoupler OFF
• Voltage applied: Photocoupler ON
51
7.2.2
Wiring
For connectors used for external wiring, refer to
MELSEC-L CPU Module User's Manual (Hardware Design,
Maintenance and Inspection). For examples of connection with servo amplifiers, refer to
52
Page 275, Appendix 2.
CHAPTER 7 POSITIONING FUNCTION
7.3
Parameter Setting
Set parameters for each axis.
1.
Click the
Project window
2.
button in the "Built-in I/O Function Setting" tab.
[Parameter]
[PLC Parameter]
"Built-in I/O Function Setting" tab
Select the "Use positioning function (Axis #1)" checkbox on the top left on the "Positioning Axis
#1 Detailed Setting" screen.
3.
Configure required settings.
4.
Click the
button to exit.
Select the "Use positioning
function (Axis #1)" checkbox.
7
Item
Positioning Parameter
Description
These parameters define data that must be set upon system start-up according to the drive
OPR Parameter
These parameters define data used in OPR control.
Positioning Data
A group of data required in a single positioning operation.
Page 55,
Section 7.3.1
Page 62,
Section 7.6
Page 93,
Section 7.7
53
7.3 Parameter Setting
unit, motor and system configuration used.
Reference
When the setting is complete, the necessary external signals are assigned automatically. The drive unit ready signal
and limit signals should be set as necessary. Set the input response time for input signals. The Error time output mode
is fixed to "Clear."
Select an option from the pull-down menu as necessary.
54
According to the settings, external signals are assigned.
CHAPTER 7 POSITIONING FUNCTION
7.3.1
Positioning parameter
Positioning parameters are common to all controls. Set these parameters for each axis.
Setting item
Setting range
Default
CW/CCW Mode
PULSE/SIGN Mode
Pulse Output Mode
CW/CCW Mode
A Phase/B Phase Mode (Multiple of 1)
A Phase/B Phase Mode (Multiple of 4)
Current Value Increment with Forward Run
Rotation Direction Setting
Pulse Output
Current Value Increment with Forward
Current Value Increment with Forward Run
Run Pulse Output
Pulse Output
S/W Stroke Upper Limit (pulse)
2147483647
-2147483648 to 2147483647
S/W Stroke Lower Limit (pulse)
-2147483648
Speed Limit Value (pulse/s)
1 to 200000
10000
Bias Speed at Start (pulse/s)
0 to 200000
0
Trapezoid Acceleration/Deceleration
Acceleration/Deceleration System Selection
Trapezoid Acceleration/Deceleration
S-curve Acceleration/Deceleration
7
Executable controls and corresponding positioning parameters are shown below.
: Must be set,
: Set as necessary, ⎯: Need not be set
Positioning control
Positioning parameter
OPR control
Position
Speed
control
control
Current
JOG
switching
value
operation
control
change
Speed/position
7.3 Parameter Setting
7.3.1 Positioning parameter
Pulse Output Mode
Rotation Direction Setting
S/W Stroke Upper Limit (pulse)
⎯
S/W Stroke Lower Limit (pulse)
⎯
Speed Limit Value (pulse/s)
⎯
Bias Speed at Start (pulse/s)
⎯
Acceleration/Deceleration
⎯
System Selection
(1) Pulse output mode
Set the pulse output mode applicable to the drive unit used.
(a) CW/CCW mode
Forward run feed pulses (CW) are output when the motor is rotating forward. Reverse run feed pulses (CCW)
are output when the motor is rotating in reverse.
OFF
CW
ON
OFF
CCW
ON
Forward run
Reverse run
55
(b) PULSE/SIGN mode
Forward/reverse control is based on on/off of the direction sign (SIGN).
• The direction sign turns on when the motor is rotating forward.
• The direction sign turns off when the motor is rotating in reverse.
PULSE
OFF
ON
SIGN
OFF
ON
Forward run
Reverse run
Move in + direction
Move in - direction
For CCW, pulses are output 100µs after the direction sign turns off.
1 pulse
OFF
PULSE
ON
SIGN
OFF
100 s
ON
(c) A phase/B phase mode (multiple of 1), A phase/B phase mode (multiple of 4)
Forward/reverse control is based on the difference between phase A (Aφ) and phase B (Bφ).
• Phase B lags phase A by 90° when the motor is rotating forward.
• Phase A lags phase B by 90° when the motor is rotating in reverse.
• When "A Phase/B Phase Mode (Multiple of 1)" is set
Reverse run
Forward run
Command 1 pulse output
Command 1 pulse output
Phase A
(A )
OFF
OFF
ON
ON
Phase B
(B )
OFF
OFF
ON
ON
Phase B runs slower
than phase A by 90 .
Phase A runs slower
than phase B by 90 .
Ex. When one command pulse output corresponds to 1 pulse/s, there are four leading/trailing edges per
second.
• When "A Phase/B Phase Mode (Multiple of 4)" is set
Phase A
(A )
Phase B
(B )
Forward run
Reverse run
Command 1 pulse output
Command 1 pulse output
OFF
OFF
ON
ON
OFF
OFF
ON
ON
Phase B runs slower
than phase A by 90 .
Phase A runs slower
than phase B by 90 .
Ex. When one command pulse output corresponds to 1 pulse/s, there is one leading/trailing edge per second.
56
CHAPTER 7 POSITIONING FUNCTION
(2) Rotation direction setting
Set how the current position would increase/decrease in each rotation direction of the motor. Check the settings
by JOG operation. (
1.
Page 106, Section 7.9)
Set "Current Value Increment with Forward Run Pulse Output" for the rotation direction setting
and perform forward JOG operation.
2.
If the workpiece moves in the address decreasing direction defined by the system, set "Current
Value Increment with Forward Run Pulse Output" for the rotation direction setting to change the
rotation direction.
(If the workpiece moves in the address increasing direction defined by the system, the current
setting need not be changed.)
3.
Perform forward JOG operation again and if the workpiece (W) moves in the address increasing
direction, the setting is complete.
Address
decrement
direction
LCPU
Motor
2
Workpiece
Address
increment
direction
1
Forward run pulse
M
W
OP
7
3
(3) S/W stroke upper Limit, S/W stroke lower limit
Set the upper/lower limits of the moving range of the workpiece.
• Set the software stroke limits according to the condition specified below:
Software lower stroke limit < Software upper stroke limit
• To disable the software stroke limits, set the same value for both the upper limit and lower limit. (Desired
values can be set as long as they are within the setting range.)
Software stroke limit
lower limit
Software stroke limit
upper limit
Workpiece moveable range
Limit switch
for emergency stop
Limit switch
for emergency stop
OP
Remark
In general, the OP is set at the lower limit or upper limit of the software stroke.
57
7.3 Parameter Setting
7.3.1 Positioning parameter
If Rotation Direction Setting was changed from "Current Value Increment with Forward Run Pulse Output" to "Current Value
Increment with Forward Run Pulse Output," perform JOG operation to check if the upper limit switch and lower limit switch
operate correctly. If any operation problem was found, review the wirings.
(4) Speed Limit Value
Set the maximum speed for OPR control, positioning control and JOG operation. If any of the following settings
exceeds the speed limit, the speed is limited to the specified limit.
• OPR speed
• Command speed
• JOG speed
• New speed value
• Bias speed at start
The speed limit is determined by the two conditions specified below:
• Motor speed
• Moving speed of the workpiece
(5) Bias speed at start
Set the minimum speed for OPR control, positioning control and JOG operation. When a stepping motor etc. is
used, set this speed to ensure smooth starting of the motor. (Stepping motors do not start smoothly if the motor
speed at start is low.) For the bias speed at start, set a value not exceeding the speed limit.
(6) Acceleration/deceleration system selection
Set "Trapezoid Acceleration/Deceleration" or "S-curve Acceleration/Deceleration" for acceleration/deceleration
processing.
If S-curve Acceleration/Deceleration is set when a stepping motor is used, the motor does not operate normally.
Trapezoid Acceleration/Deceleration
V
The acceleration and
deceleration follow a
straight line.
t
58
S-curve Acceleration/Deceleration
V
The acceleration and
deceleration follow a
Sine curve.
t
CHAPTER 7 POSITIONING FUNCTION
7.4
Specifications
(1) Performance specifications
The following is the performance specifications of the positioning function.
Description
Item
L02CPU, L26CPU-BT
Number of controlled axes
2
Control unit
pulse
Operation pattern
PTP*1 control
Available
Path control
Not usable
Number of positioning data
10 data/axis
*1
Positioning control
method
PTP
ABS/INC
control
Speed/position switching
INC
control
PTP*1 control
Positioning
L02CPU-P, L26CPU-PBT
Positioning range
-2147483648 to 2147483647 pulses
Speed/position switching
control
0 to 2147483647 pulses
control
Speed command
Acceleration/deceleration system selection
Automatic trapezoid acceleration/deceleration and S-curve
acceleration/deceleration
Acceleration/deceleration time
0 to 32767 ms
OPR method
6 types
Trapezoid acceleration/deceleration (single-axis start): 30 µs/axis
Starting time (1-axis linear control)
Sink type
Source type
Command pulse
Pulse output mode
4 modes
output
Maximum output pulse
200k pulses/s
Maximum connection distance with drive unit
2m
DC input
Differential input
24VDC, 6.0 mA (TYP.)
EIA RS-422-A differential line driver level
(AM26LS31 (by Texas Instruments Japan Limited.) or equivalent)
Speed/position switching signal
External input
Near-point dog signal
24VDC, 4.1 mA (TYP.)
Upper and lower limit signal
Drive unit ready signal
Zero signal: 10µs
Input response time
Speed/position switching control, near-point dog signal: 100µs
Upper and lower limit signal, drive unit ready signal: 2ms
Deviation counter clear signal
External output
Response time
*1
Sink type (5 to 24VDC, 0.1A)
Source type (5 to 24VDC,
0.1A)
ON
1 µs or less (rated load, resistive load)
OFF
1 µs or less (rated load, resistive load)
Abbreviation for "Point to Point". This is a type of position control.
59
7.4 Specifications
S-curve acceleration/deceleration (single-axis start): 35 µs/axis
Pulse output type
Zero signal
7
0 to 200k pulses/s
(2) Special relay and special register
The following table lists the special relay (SM) and special register (SD) related to the positioning function.
in
the name indicates either 1 (Axis 1) or 2 (Axis 2). For details of the special relay and special register other than
the Axis 1 axis operation status (SD1844) (
Page 61, Section 7.5), refer to "
MELSEC-L CPU Module
User's Manual (Hardware Design, Maintenance and Inspection)".
Special register
Special relay number
Axis 1
Axis 2
SM1840
SM1860
SM1841
SM1861
SM1842
SM1862
SM1843
SM1863
SM1844
SM1864
SM1845
SM1865
SM1846
SM1866
SM1847
SM1867
SM1848
SM1868
SM1850
SM1870
SM1851
SM1871
Name
Axis
Axis
busy
positioning
completion
Axis
Axis 2
SD1860
SD1841
SD1861
SD1842
SD1862
completed
SD1843
SD1863
speed 0
SD1844
SD1864
Axis
Axis
Axis
Axis 1
SD1840
OPR request
Axis
Axis
number
error
SD1845
SD1865
warning
SD1846
SD1866
start in busy status
SD1847
SD1867
start instruction
SD1848
SD1868
error reset
SD1849
SD1869
OPR request off
SD1850
SD1870
Axis
Axis
Name
Axis
current feed value
Axis
Axis
current speed
axis operation status
Axis
Axis
Axis
Axis
external I/O signals
movement amount after
near-point dog ON
Axis
Axis
error code
warning code
data No. of
positioning being
executed
SM1852
60
SM1872
Axis
speed/position
switching
⎯
⎯
CHAPTER 7 POSITIONING FUNCTION
7.5
Checking Current Position and Operation Status
The current position and operation status of the moving workpiece can be monitored in the special register.
(1) Checking a current position
Values indicating the current position are stored in the Axis 1 current feed value (SD1840, SD1841). The address
established by machine OPR is used as the reference.
(2) Checking an operation status
The Axis 1 axis operation status (SD1844) indicates the operation status of the axis.
Stored
value
Operation status
Description
This is the status after the following operations:
• (Successful) completion of operation
• Power-on
0
Standing by
• When the CPU module is reset
• Error reset
7
• After JOG operation
• End of absolute position restoration
The axis has stopped successfully according to the Axis stop instruction
1
Stopped
2
In JOG operation
JOG operation is in progress.
3
In OPR
Machine OPR is in progress.
4
In position control
5
In speed-position control (speed)
(position)
7
Decelerating (axis stop ON)
8
Decelerating (JOG start OFF)
9
In high-speed OPR
10
In speed control
11
Analyzing
−1
Error occurring
Position control is in progress.
Speed control of speed/position switching control is in progress.
Position control of speed/position switching control is in progress.
The axis is decelerating according to the Axis stop instruction (IPSTOP1).
The axis is decelerating after the execution command for JOG start
instruction turned off.
Fast OPR is in progress.
Speed control is in progress.
Absolute position restoration is in progress.
An error is present.
61
7.5 Checking Current Position and Operation Status
6
In speed-position control
(IPSTOP1).
7.6
OPR Control
Two controls (machine OPR and fast OPR) are defined as OPR controls in line with the flow of OPR operation of the
LCPU.
OPR control
Overview
Reference
This is control to establish the reference position (= OP) to be used when positioning control is
started. This control is executed when requested by the LCPU at power-on, etc. The OP is
Machine OPR
Page 70,
established by using a near-point dog, zero signal, etc. Set machine OPR for the original
Section
position return type of the OPR start instruction (IPOPR1(P)) and execute the instruction to
7.6.1
start the operation.
Fast OPR is used to return the axis, which has stopped at a position other than the OP after
positioning control, to the OP. After the machine OPR establishes the OP position, the
Fast OPR
workpiece is moved to the OP address or standby address by the fast OPR without using a
Page 90,
near-point dog, zero signal, etc. Set fast OPR (OP address) or fast OPR (standby address) for
the original position return type of the OPR start instruction (IPOPR1(P)) and execute the
Section
7.6.2
instruction to start the operation.
To implement OPR control, the "OPR parameters" must be set on the "Positioning Function Parameter Setting" screen.
The OPR parameters that have been set apply commonly to each axis. Setting details are explained below.
Setting item
Setting range
Default
Near-Point Dog Method
Stopper 1
Stopper 2
Stopper 3
OPR Method
Near-Point Dog Method
Count 1
Count 2
No Method
Forward RUN
OPR Direction
Reverse RUN
OP Address (pulse)
-2147483648 to 2147483647
0
1 to 200000
1
0 to 32767
1000
OPR Speed (pulse/s)
Creep Speed (pulse/s)
OPR Acceleration/Deceleration Time (ms)
OPR Deceleration Stop Time (ms)
Setting of Movement Amount after Near-point Dog
ON (pulse)
Forward RUN
0 to 2147483647
OPR Dwell Time (ms)
0
0 to 65535
Note that the explanations in this section assume use of Axis 1. For the special relay, special register, dedicated
instructions, and error codes for Axis 2, refer to the following.
• Special relay and special register:
• Dedicated instructions:
• Error codes:
62
Page 60, Section 7.4 (2)
Page 139, Section 7.12
Page 179, Section 7.14 (2)
CHAPTER 7 POSITIONING FUNCTION
(1) OPR method
Set the method of machine OPR. (This setting does not affect the fast OPR.) Operations under each method are
explained below. For the details of each method and applicable precautions, refer to (
Page 70, Section
7.6.1).
Near-point dog method
V
OPR speed
1) Start of machine OPR.
2)
Creep speed
Bias speed at start
2) The axis starts to decelerate upon detection of turning on of the near-point dog.
↓
4)
3)
1)
↓
t
3) The axis decelerates to the creep speed and moves at the creep speed thereafter.
↓
ON
Near-point
watchdog signal OFF
4) Pulse output from the LCPU stops when the first zero signal is issued after the
First zero after
the near-point
watchdog signal
OFF
Zero signal
near-point dog has turned off, and machine OPR is complete.
Stopper 1
V
1) Start of machine OPR.
OPR speed
2)
↓
Creep speed
2) The axis starts to decelerate upon detection of turning on of the near-point dog.
↓
Bias speed at start
3)
4)
5)
t
Range where motor
rotation is forcibly
stopped by stopper
1)
3) The axis decelerates to the creep speed and moves at the creep speed thereafter.
↓
4) The axis contacts the stopper at the creep speed and stops.
↓
ON
Near-point
watchdog signal OFF
5) Upon elapse of the OPR dwell time after the near-point dog has turned on, pulse
Dwell time counting
Dwell time out
7.6 OPR Control
output from the LCPU stops and machine OPR is complete.
Stopper 2
V
1) Start of machine OPR.
OPR speed
Creep speed
2)
Stopped by
stopper
Bias speed at start
3)
t
5)
Zero signal
ON
↓
2) The axis starts to decelerate upon detection of turning on of the near-point dog.
↓
3) The axis decelerates to the creep speed and moves at the creep speed thereafter.
4)
1)
Near-point
watchdog signal OFF
7
↓
4) The axis contacts the stopper at the creep speed and stops.
↓
5) When the zero signal is detected, pulse output from the LCPU stops and machine
OPR is complete.
63
Stopper 3
V
1) Start of machine OPR.
Stopped by
stopper
Creep speed
2)
2) The axis contacts the stopper at the creep speed and stops.
↓
Bias speed at start
1)
↓
t
3) When the zero signal is detected, pulse output from the LCPU stops and
machine OPR is complete.
3)
Zero signal
Count 1
V
OPR speed
Setting for the movementamount
after near-point watchdog signal ON
2)
Bias speed at start
↓
2) The axis starts to decelerate upon detection of turning on of the near-point dog.
Creep speed
3)
↓
4)
t
Movement amount after nearpoint watchdog signal ON
1)
1) Start of machine OPR.
The near-point watchdog
signal should be turned
off with enough distance
provided from OP position.
First zero after movement
amount has been traveled
after near-point watchdog
signal OFF
ON
Near-point
watchdog signal OFF
Zero signal
3) The axis decelerates to the creep speed and moves at the creep speed
thereafter.
↓
4) Pulse output from the LCPU stops at the first zero signal after the near-point
dog has turned on and the axis has moved the distance set by "Movement amount
after near-point dog ON", and the machine OPR is complete.
Count 2
1) Start of machine OPR.
V
Setting for the movement
amount after near-point
watchdog signal ON
OPR speed
2)
Creep speed
Bias speed at start
4)
t
Movement amount after
near-point watchdog
signal ON
ON
Near-point
OFF
watchdog signal
64
2) The axis starts to decelerate upon detection of turning on of the near-point dog.
↓
3) The axis decelerates to the creep speed and moves at the creep speed
3)
1)
↓
thereafter.
↓
4) Pulse output from the LCPU stops after the axis has moved the distance set by
"Movement amount after near-point dog ON" (the axis starts to decelerate from
the creep speed over the OPR deceleration stop time), and the machine OPR is
complete.
CHAPTER 7 POSITIONING FUNCTION
(a) OPR methods and OPR parameters
Different I/O signals are required depending on each OPR method. The relationships are shown below.
For the settings required for the fast OPR, refer to
Page 90, Section 7.6.2.
: Must be set, ⎯: Need not be set
OPR Method
OPR Parameter
Nearpoint Dog
Stopper 1
Stopper 2
Stopper 3
⎯
⎯
⎯
⎯
⎯
Count 1
Count 2
Method
OPR Direction
OP Address
OPR Speed
Creep Speed
OPR Acceleration/Deceleration
Time
OPR Deceleration Stop Time
Setting of Movement Amount
⎯
after near-point Dog ON
*1
OPR Dwell Time
*1
*1
7
*1
This setting becomes effective when OPR is retried.
(2) OPR direction
Set the direction in which to start machine OPR. (This setting does not affect fast OPR.)
Forward RUN: The axis operates in the direction of increasing address (arrow 2)).
7.6 OPR Control
Reverse RUN: The axis operates in the direction of decreasing address (arrow 1)).
Normally the OP is set near the lower limit switch or upper limit switch. Accordingly, set the OPR direction as
shown below.
When the OP is set at the lower limit side,
the OPR direction is in the direction of
arrow 1). Set "Reverse run direction".
Lower limit
Upper limit
1)
OP
Address
increment direction
Address
decrement direction
Lower limit
Upper limit
Address
decrement direction
2)
OP
Address
increment direction
When the OP is set at the upper limit side,
the OPR direction is in direction of
arrow 2). Set "Forward run direction".
65
(3) OP address
Set the position that becomes the reference point of position control (ABS). Upon completion of machine OPR,
the address of the stop position (Axis 1 current feed value (SD1840, SD1841) changes to the OP address that
has been set.
(4) OPR speed
Set the speed of OPR control. The following condition must be met:
Bias speed at start
66
Creep speed
OPR speed
Speed limit
CHAPTER 7 POSITIONING FUNCTION
(5) Creep speed
Set the low speed at which the axis moves immediately before stopping after decelerating from the OPR speed
following the turning on of the near-point dog. The following condition must be met: (This setting does not affect
fast OPR.)
Bias speed at start
Creep speed
OPR speed
Speed limit
V
OPR speed
Machine OPR start
Creep speed
Bias speed at start
t
ON
Near-point
watchdog signal
OFF
Zero signal
7
The creep speed affects the detection error in an OPR method using a zero signal, or degree of impact of collision in the
OPR Method using a stopper method.
Set the time required to reach the OPR speed from the bias speed at start, or creep speed from the OPR speed.
When the OPR Method is set to other than "Stopper 3":
V
When the OPR Method is set to "Stopper 3":
OPR speed
V
Creep speed
Creep speed
Bias speed at start
Bias speed at start
t
t
OPR ACC/DEC time
OPR ACC/DEC time
67
7.6 OPR Control
(6) OPR acceleration/deceleration time
(7) OPR deceleration stop time
Set the time required for the following conditions.
• For "Count 2"
This time is from when the axis decelerates the speed from the creep speed to when it stops at the bias
speed at start.
• For all OPR method
This time is from when a stop cause occurs during OPR control to when the axis stops at the bias speed at
start from the OPR speed.
• For the fast OPR
This time is from when the axis decelerates the speed from the OPR speed to when it stops at the
bias speed at start. (
Page 90, Section 7.6.2)
When a stop cause occurs during OPR control:
When the OPR Method is set to "Count 2":
V
(This applies commonly to all OPR methods.)
OPR speed
V
OPR speed
Creep speed
Bias speed at start
Bias speed at start
Axis stop
factor
occurrence
Creep speed
t
t
OPR DEC/STOP time
OPR DEC/STOP time
(8) Setting of Movement Amount after near-point Dog ON
• Set the movement amount from the position at which the near-point dog turns on until a zero signal is input
when the OPR Method is set to "Count 1."
• Set the movement amount from the position at which the near-point dog turns on to the OP when the OPR
Method is set to "Count 2."
For "Setting of Movement Amount after near-point Dog ON" set a value equal to or greater than the deceleration
distance from the OPR speed to creep speed. (This setting does not affect fast OPR.)
Ex. Calculation of "Movement amount after near-point dog ON" when "OPR speed" is set to 10 kpulses/s, "Creep
speed" to 2 kpulses/s, and "OPR acceleration/deceleration time" to 320 ms
[Machine OPR control operation]
[Deceleration distance] =
1
2
Vz
t+t'
1000
OPR speed : Vz=10kpulses/s
=
Vz (t+t')
2000
=
10 103 (320+80)
2000
Creep speed: Vc=2kpulses/s
= 2000
80ms: t'
OPR ACC/DEC time : t=320ms
Near-point
OFF
watchdog signal
68
ON
Set 2000 pulses or more in "Setting
of Movement Amount after
near-point Dog ON".
CHAPTER 7 POSITIONING FUNCTION
(9) OPR dwell time
Set this parameter in the conditions specified below. (This setting does not affect the fast OPR.)
(a) When the OPR Method is set to "Stopper 1":
Set the time required for machine OPR to complete after the near-point dog turns on. For the OPR dwell time,
set a value equal to or greater than the moving time after the near-point dog turns on until the axis stops at the
stopper.
(b) When the OPR retry function is enabled:
Set the stopping time after the axis decelerates to a stop. (
Page 111, Section 7.10.1)
7
7.6 OPR Control
69
7.6.1
Machine OPR
The machine OPR establishes the machine OP using the OPR start instruction (IPOPR1(P)). (
Page 148, Section
7.12.1 (4)) Once the machine OPR is complete, the mechanically established position becomes the "OP" which
defines the starting point of positioning control. (No address information stored in the LCPU or servo amplifier is used.)
How the OP is established by machine OPR varies depending on the "OPR method." Select one of the six methods
that best suits your system.
(1) OPR method and I/O signal
Different I/O signals are used under each OPR method. A correspondence table of OPR methods and I/O signals
is shown below.
: Wire as necessary, ⎯: Wiring not required
: Wiring required,
OPR method
I/O signal
Near-point
dog method
Stopper 1
Stopper 2
Stopper 3
Count 1
⎯*1
Zero Signal
⎯*1
⎯*1
Near-point Dog Signal
⎯
⎯
⎯
⎯
No
method
⎯*1
⎯*1
Deviation Counter Clear Signal
External Command Signal*1
Count 2
⎯
⎯*1
⎯*1
⎯
⎯
CW/PULSE/A Phase Output
⎯*1
CCW/SIGN /B Phase Output
⎯*1
Drive Unit Ready Signal*1
⎯
Upper Limit Signall
*1*2
Lower Limit Signal*1*2
*1
*2
When this signal is not required, it can be used for other functions such as the general-purpose input and generalpurpose output.
These signals are required when the OPR retry function or hardware stroke limit function is used.
(2) Subfunction
The OPR retry function can be used when the upper and lower limit signals are input.
(
70
Page 111, Section 7.10.1)
CHAPTER 7 POSITIONING FUNCTION
Important
• OPR direction
(1)The direction of the OP must always be the same when viewed from any arbitrary position in the moving area of the workpiece (= the
OP must be positioned near the upper limit or lower limit of the machine).
(2)Set the OPR direction correctly so that the workpiece moves toward the OP.
If the above two conditions are not met, the OPR retry function may actuate inadvertently.
The following situations may also result:
• The near-point dog is already off at the start of machine OPR.
• Machine OPR starts in the opposite direction of near-point dog.
In this case, no near-point dog is detected after machine OPR is started. As a result, the axis may continue to operate at the OPR
speed until reaching the limit switch and damage the machine system. If this is the possibility, use the OPR retry function
(
Page 111, Section 7.10.1) or perform JOG operation (
Page 106, Section 7.9) to move the
workpiece until just before the near-point dog as viewed from the OPR direction.
• Deceleration stop time
If any of the following stop causes occurs during OPR operation, the axis decelerates to a stop over the "OPR deceleration stop time,"
not "OPR acceleration/deceleration time":
• The program is stopped.
• The drive unit ready signal is turned off.
• A hardware stroke limit is reached. (If the OPR retry function is enabled, the axis decelerates to a
7
stop and then starts moving in the opposite direction.)
• The Axis stop instruction (IPSTOP1) is issued.
When decelerating from the OPR speed, for example, the data to be used as the deceleration time varies between "deceleration due to
near-point dog ON" and "deceleration by Axis stop instruction (IPSTOP1) execution command ON." Since the motor load changes
according to the deceleration time, set this time properly by giving full consideration to the impact on the machine.
7.6 OPR Control
7.6.1 Machine OPR
71
(3) Operations of Near-point dog method and precautions
Under the near-point dog method, machine OPR completes when a zero signal is input after the near-point dog
has turned off. The following operations take place.
Operation step
Description of operation
1)
speed at start to the OPR speed in the OPR direction over the OPR acceleration/deceleration time and moves at the
Machine OPR starts upon execution of the OPR start instruction (IPOPR1(P)). The axis accelerates from the bias
OPR speed.
2)
3)
4)
The axis starts to decelerate upon detection of turning on of the near-point dog. The axis decelerates to the creep
speed and moves at the creep speed thereafter.
When the first zero signal (signal for outputting one pulse per motor rotation) is issued after the near-point dog has
turned off, the LCPU stops outputting pulses and outputs a deviation counter clear signal to the drive unit.
Upon completion of output of the deviation counter clear signal (output for 10 ms), the Axis 1 OPR completion
(SM1843) turns on and Axis 1 OPR request (SM1842) turns off.
V
t
2)
1)
Near-point
watchdog
OFF
ON
3)
Zero signal
Set the near-point watchdog OFF position as close
to the center of zero signal length as possible.
If the near-point watchdog turns off in the zero
signal state, the OPR stop position may change by
one servomotor rotation.
One motor rotation
Movement amount after near-point
watchdog ON *1
3)
Deviation counter clear signal
Output time 10ms
ON
OPR start instruction
execution command OFF
ON
Axis 1 OPR request
(SM1842)
OFF
ON
4)
Axis 1 OPR complete
OFF
(SM1843)
Axis 1 operation status
(SD1844)
Axis 1 movement amount after
near-point watchdog ON
(SD1848, SD1849)
Axis 1 current feed value
(SD1840, SD1841)
72
Standby (0)
Unfixed
Unfixed
Standby (0)
Returning to OP (3)
0
(Updated according to the movement)
(Updated according to the movement)
*1 value
OP address
CHAPTER 7 POSITIONING FUNCTION
(a) Required pulse generator
Use a pulse generator with zero signal. If a pulse generator without zero signal is used, generate a zero signal
using an external signal.
(b) Near-point dog length
The near-point dog length should be equal to or longer than the distance moved by the axis as it decelerates
from the OPR speed to creep speed. If the length is short, the near-point dog turns off while the axis is still
decelerating from the OPR speed to creep speed. When the zero signal turns on in this condition, the axis
stops immediately to complete machine OPR. As a result, the OP position deviates and the motor load also
increases because the axis stops suddenly at the creep speed or higher.
V
When the near-point watchdog
length is increased sufficiently
t
Near-point
watchdog
ON OFF
Zero signal
For the method to calculate the distance from the near-point dog ON position to OP, refer to
Page 68,
7
Section 7.6 (8).
7.6 OPR Control
7.6.1 Machine OPR
73
(c) Advantages of using limit switches
The following functions can be used when the upper and lower limit signals are selected:
• OPR retry function
When machine OPR is started in a position indicated as interval A (where the near-point dog is turned off
and no near-point dog is found in the OPR direction) in the figure below , the axis continues to operate at
the OPR speed until reaching the limit switch of the machine system because it cannot detect the nearpoint dog.
When the limit signal in the OPR direction turns off, the OPR retry function actuates. As a result, the axis
decelerates to a stop and then move in the opposite direction to complete machine OPR successfully.
(
Page 111, Section 7.10.1). This eliminates the need to perform JOG operation, etc., to return to the
position before the near-point dog turns on.
• Hardware stroke limit function
When the limit signal in the direction opposite the OPR direction turns off, the axis decelerates to a stop
due to the hardware stroke limit function (
Page 124, Section 7.10.5). This prevents damage to the
machine system.
Limit switch
When started from here
Near-point watchdog
ON
Interval A
OFF
Zero signal
Retry operation
When started from here
Moving in the opposite direction
74
OFF
CHAPTER 7 POSITIONING FUNCTION
(d) Machine OPR from a position where the near-point dog is turned on
When machine OPR is started at a position indicated as interval B (where the near-point dog is turned on) in
the figure below, the OPR retry function does not operate. The axis moves at the creep speed to complete
machine OPR.
V
Creep speed
t
Interval B
Near-point
watchdog
ON
OFF
Zero signal
7
7.6 OPR Control
7.6.1 Machine OPR
75
(4) Operations of Stopper 1 and precautions
Under this method, machine OPR completes upon elapse of the OPR dwell time after the detection of near-point
dog ON. The following operations take place.
Operation step
Description of operation
Machine OPR starts upon execution of the OPR start instruction (IPOPR1(P)). The axis accelerates from the bias
1)
speed at start to the OPR speed in the OPR direction over the "OPR acceleration/deceleration time" and moves at the
OPR speed.
2)
3)
4)
5)
The axis starts to decelerate upon detection of turning on of the near-point dog. The axis decelerates to the creep
speed and moves at the creep speed thereafter.
The axis contacts the stopper at the creep speed and stops.
Upon elapse of the OPR dwell time after the near-point dog has turned on, the LCPU stops outputting pulses and
outputs a deviation counter clear signal to the drive unit.
Upon completion of output of the deviation counter clear signal (output for 10 ms), the Axis 1 OPR completion
(SM1843) turns on and Axis 1 OPR request (SM1842) turns off.
V
Stopper
3)
t
2)
1)
Near-point watchdog
OFF
ON
Dwell time
counting start
Dwell time elapsed
Movement amount after near-point watchdog ON *1
4)
Output time
10ms
Deviation counter clear signal
OPR start instruction
execution command
ON
OFF
ON
OFF
Axis 1 OPR request
(SM1842)
Axis 1 OPR complete
(SM1843)
Axis 1 operation status
(SD1844)
Axis 1 movement amount after
near-point watchdog ON
(SD1848, SD1849)
Axis 1 current feed value
(SD1840, SD1841)
76
ON
5)
OFF
Standby (0)
Unfixed
Unfixed
Returning to OP (3)
0
Standby (0)
(Updated according to the movement)
(Updated according to the movement)
*1 value
OP address
CHAPTER 7 POSITIONING FUNCTION
(a) Motor torque limit
Be sure to limit the motor torque after the creep speed is reached. If the torque is not limited, the motor may be
damaged when the stopper is contacted. For limitation of torque, refer to the manual for the drive unit.
(b) Setting of OPR dwell time
For "OPR dwell time," set a value equal to or greater than the moving time from the near-point dog ON position
until the stopper is contacted. If the OPR dwell time is short, machine OPR completes before the stopper is
contacted and the OP position deviates. If the OPR dwell time is shorter than the OPR acceleration/
deceleration time, the motor stops suddenly at the higher speed than the creep speed. As a result, load for
motor is increased.
V
Suddenly stopped during
deceleration to the creep speed
Stopper
t
Near-point watchdog
ON
OFF
7
OPR dwell time
(c) Near-point dog and starting position
• When machine OPR is started in a position indicated as interval A (where the near-point dog is turned on)
in the figure below, the axis moves at the creep speed to complete machine OPR.
V
7.6 OPR Control
7.6.1 Machine OPR
Stopper
Creep speed
t
Interval A
Near-point
watchdog
OFF
ON
• When starting position is in interval B (between the near-point dog OFF position and stopper
• ) in the figure below, no near-point dog is detected and thus the axis may collide with the stopper at the
OPR speed. Make sure the near-point dog is longer than the distance to the stopper.
V
Collision at OPR speed
Stopper
t
Interval B
Near-point
watchdog
ON
OFF
77
(d) OPR retry function
The OPR retry function cannot be used.
78
CHAPTER 7 POSITIONING FUNCTION
(5) Operations of Stopper 2 and precautions
Under this method, machine OPR completes upon input of a zero signal via an external switch, etc., following
stopper contact. The following operations take place.
Operation step
Description of operation
Machine OPR starts upon execution of the OPR start instruction (IPOPR1(P)). The axis accelerates from the bias
1)
speed at start to the OPR speed in the OPR direction over the "OPR acceleration/deceleration time" and moves at
the OPR speed.
2)
3)
4)
5)
The axis starts to decelerate upon detection of turning on of the near-point dog. The axis decelerates to the creep
speed and moves at the creep speed thereafter.
The axis contacts the stopper at the creep speed and stops.
When a zero signal (output upon detection of stopper contact) is issued after the axis has stopped, the LCPU stops
outputting pulses and outputs a deviation counter clear signal to the drive unit.
Upon completion of output of the deviation counter clear signal (output for 10 ms), the Axis 1 OPR completion
(SM1843) turns on and Axis 1 OPR request (SM1842) turns off.
V
7
Stopper
3)
t
2)
1)
7.6 OPR Control
7.6.1 Machine OPR
Near-point watchdog
OFF
ON
4)
Zero signal
Movement amount after near-point watchdog ON *1
4)
Deviation counter clear signal
Output time
10ms
ON
OPR start instruction
execution command
OFF
ON
OFF
Axis 1 OPR request
(SM1842)
Axis 1 OPR complete
(SM1843)
ON
5)
OFF
Axis 1 operation status
(SD1844)
Standby (0)
Axis 1 movement amount after
near-point watchdog ON
(SD1848, SD1849)
Unfixed
Axis 1 current feed value
(SD1840, SD1841)
Unfixed
Returning to OP (3)
0
Standby (0)
(Updated according to the movement)
(Updated according to the movement)
*1 value
OP address
79
(a) Motor torque limit
Limit the motor torque after the creep speed is reached. If the torque is not limited, the motor may be damaged
when the stopper is contacted. For limitation of torque, refer to the manual for the drive unit.
(b) Near-point dog and starting position
• When machine OPR is started in a position indicated as interval B (where the near-point dog is turned on)
in the figure below, the axis moves at the creep speed to complete machine OPR.
V
Stopper
Creep speed
t
Interval A
Near-point
watchdog
OFF
ON
• When starting position is in interval B (between the near-point dog OFF position and stopper
• ) in the figure below, no near-point dog is detected and thus the axis may collide with the stopper at the
OPR speed. Make sure the near-point dog is longer than the distance to the stopper.
V
Collision at OPR speed
Stopper
t
Interval B
Near-point
watchdog
ON
OFF
(c) OPR retry function
The OPR retry function cannot be used.
80
CHAPTER 7 POSITIONING FUNCTION
(d) Zero signal input
• Input a zero signal after the stopper has been contacted. If a zero signal is input before the stopper is
contacted, machine OPR completes at that point. As a result, the OP position deviates and if a zero signal
is input while the axis is decelerating to the creep speed, the motor load also increases because the axis
stops suddenly at the creep speed or higher.
V
Suddenly stopped during
deceleration to the creep speed
Stopper
t
Near-point watchdog
ON
OFF
Zero signal
• Do not input a zero signal before machine OPR is started. If a zero signal is already input externally when
machine OPR is started, a "Zero signal ON" error (Axis 1 error code: 1200) occurs and machine OPR is
7
not performed.
7.6 OPR Control
7.6.1 Machine OPR
81
(6) Operations of Stopper 3 and precautions
Under this method, machine OPR completes upon input of a zero signal via an external switch etc. following
stopper contact. This method is effective when no near-point dog is installed. Note, however, that it takes a longer
time to complete machine OPR because the axis operates at the creep speed, not at the OPR speed. The
following operations take place.
Operation step
Description of operation
Machine OPR starts upon execution of the OPR start instruction (IPOPR1(P)). The axis accelerates from the bias
1)
speed at start to the creep speed in the OPR direction over the "OPR acceleration/deceleration time" and moves at
the creep speed.
2)
3)
4)
The axis contacts the stopper at the creep speed and stops.
When a zero signal (output upon detection of stopper contact) is issued after the axis has stopped, the LCPU stops
outputting pulses and outputs a deviation counter clear signal to the drive unit.
Upon completion of output of the deviation counter clear signal (output for 10 ms), the Axis 1 OPR completion
(SM1843) turns on and Axis 1 OPR request (SM1842) turns off.
V
Stopper
2)
t
1)
3)
Zero signal
3)
Deviation counter clear signal
OPR start instruction
execution command
Output time 10ms
ON
OFF
ON
OFF
Axis 1 OPR request
(SM1842)
Axis 1 OPR complete
(SM1843)
ON
4)
OFF
Axis 1 operation status
(SD1844)
Standby (0)
Axis 1 current feed value
(SD1840, SD1841)
Unfixed
Returning to OP (3)
(Updated according to the movement)
Standby (0)
OP address
(a) Motor torque limit
Limit the motor torque after the creep speed is reached. If the torque is not limited, the motor may be damaged
when the stopper is contacted. For limitation of torque, refer to the manual for the drive unit used.
(b) OPR retry function
The OPR retry function cannot be used.
(c) Zero signal input
• Input a zero signal after the stopper has been contacted. If a zero signal is input before the stopper is
contacted, machine OPR completes at that point and the OP position deviates.
• Do not input a zero signal before machine OPR is started. If a zero signal is already input externally when
machine OPR is started, a "Zero signal ON" error (Axis 1 error code: 1200) occurs and machine OPR is
not performed.
82
CHAPTER 7 POSITIONING FUNCTION
(7) Operations of Count 1 and precautions
Under this method, machine OPR completes when the first zero signal is input after the axis has moved the
distance set by "Movement amount after near-point dog ON" from the near-point dog ON point. The following
operations take place.
Operation step
Description of operation
Machine OPR starts upon execution of the OPR start instruction (IPOPR1(P)). The axis accelerates from the bias
1)
speed at start to the OPR speed in the OPR direction over the "OPR acceleration/deceleration time" and moves at
the OPR speed.
2)
The axis starts to decelerate upon detection of turning on of the near-point dog. The axis decelerates to the creep
speed and moves at the creep speed thereafter.
When the first zero signal (signal for outputting one pulse per motor rotation) is issued after the axis has moved the
3)
distance set by "Movement amount after near-point dog ON," the LCPU stops outputting pulses and outputs a
deviation counter clear signal to the drive unit.
4)
Upon completion of output of the deviation counter clear signal (output for 10 ms), the Axis 1 OPR completion
(SM1843) turns on and Axis 1 OPR request (SM1842) turns off.
Setting the movement amount after the near-point watchdog ON
V
7
t
2)
1)
OFF
ON
3)
Zero signal
One motor rotation
Set the near-point watchdog OFF position as close
to the center of zero signal length as possible.
If the near-point watchdog turns off in the zero
signal state, the OPR stop position may change by
one servomotor rotation.
Movement amount after near-point
watchdog ON *1
3)
Deviation counter clear signal
ON
OPR start instruction
execution command OFF
ON
OFF
Axis 1 OPR request
(SM1842)
ON
Axis 1 OPR complete OFF
(SM1843)
Standby (0)
Axis 1 operation status
(SD1844)
Axis 1 movement amount after
near-point watchdog ON
(SD1848, SD1849)
Axis 1 current feed value
(SD1840, SD1841)
Output time 10ms
Unfixed
Unfixed
Standby (0)
Returning to OP (3)
0
4)
(Updated according to the movement)
(Updated according to the movement)
*1 value
OP address
83
7.6 OPR Control
7.6.1 Machine OPR
Near-point watchdog
(a) Required pulse generator
A pulse generator with zero signal is required. If a pulse generator without zero signal is used, generate a zero
signal using an external signal.
(b) Movement amount after near-point dog ON
The "Movement amount after near-point dog ON" should be equal to or greater than the distance moved by the
axis as it decelerates from the OPR speed to creep speed (
Page 68, Section 7.6 (8)). If a zero signal is
input after the axis has moved the distance set by "Movement amount after near-point dog ON" while still
decelerating from the OPR speed to creep speed, the axis stops immediately at that point to complete machine
OPR. As a result, the OP position deviates and the motor load also increases because the axis stops suddenly
at the creep speed or higher.
V
Setting the movement amount after
the near-point watchdog ON
Suddenly stopped during deceleration
to the creep speed
t
Near-point watchdog
ON
Zero signal
84
OFF
CHAPTER 7 POSITIONING FUNCTION
(c) Advantages of using limit switches
The following functions can be used when the upper and lower limit signals are selected:
• OPR retry function
When machine OPR is started in a position indicated as interval A (where the near-point dog is turned off
and no near-point dog is found in the OPR direction) in the figure below , the axis continues to operate at
the OPR speed until reaching the limit switch of the machine system because it cannot detect the nearpoint watchdog.
When the limit signal in the OPR direction turns off, the OPR retry function actuates. As a result, the axis
decelerates to a stop and then move in the opposite direction to complete machine OPR successfully.
(
Page 111, Section 7.10.1). This eliminates the need to perform JOG operation, etc., to return to the
position before the near-point dog turned on.
• Hardware stroke limit function
When the limit signal in the direction opposite the OPR direction turns off, the axis decelerates to a stop
due to the hardware stroke limit function (
Page 124, Section 7.10.5). This prevents damage to the
machine system.
7
Interval B
Limit switch
When started from here
Interval A
Near-point watchdog
ON
OFF
OFF
7.6 OPR Control
7.6.1 Machine OPR
Zero signal
Retry operation
When started from here
Moving in the opposite direction
(d) Machine OPR from near-point dog ON
When machine OPR is started in a position indicated as interval B (where the near-point dog is turned on) in
the figure below, the axis starts moving at the OPR speed in the direction opposite the OPR direction due to the
OPR retry function to perform machine OPR (
Page 114, Section 7.10.1 (4)).
85
(8) Operations of Count 2 and precautions
Under this method, the position achieved by moving the distance set by "Movement amount after near-point dog
ON" from the near-point dog ON point is set as the OP. This method is effective when a stepping motor is used or
otherwise a zero signal cannot be issued. Note that the stop position varies more than when the count 1 method
is used. The following operations take place.
Operation step
Description of operation
Machine OPR starts upon execution of the OPR start instruction (IPOPR1(P)). The axis accelerates from the bias
1)
speed at start to the OPR speed in the OPR direction over the OPR acceleration/deceleration time and moves at the
OPR speed.
2)
The axis starts to decelerate upon detection of turning on of the near-point dog. The axis decelerates to the creep
speed and moves at the creep speed thereafter.
After the axis has moved the distance set by "Movement amount after near-point dog ON," the LCPU stops outputting
3)
pulses (the axis starts decelerating from the creep speed over the OPR deceleration stop time). The Axis 1 OPR
completion (SM1843) turns on, while the Axis1 OPR request (SM1842) turns off.
Setting the movement amount after
the near-point watchdog ON
V
3)
t
1)
2)
Near-point watchdog
OFF
ON
Movement amount after near-point
watchdog ON *1
OPR start instruction
execution command
ON
OFF
ON
OFF
Axis 1 OPR request
(SM1842)
Axis 1 OPR complete
(SM1843)
Axis 1 operation status
(SD1844)
ON
3)
OFF
Standby (0)
Axis 1 movement amount after
near-point watchdog ON
(SD1848, SD1849)
Unfixed
Axis 1 current feed value
(SD1840, SD1841)
Unfixed
Returning to OP (3)
0
Standby (0)
(Updated according to the movement)
(Updated according to the movement)
*1 value
OP address
(a) Wiring of deviation counter clear signal
Deviation counter clear signals are not output in the count 2 method. Use a general-purpose output signal and
output it to the servo amplifier.
86
CHAPTER 7 POSITIONING FUNCTION
(b) Movement amount after near-point dog ON
The "Movement amount after near-point dog ON" should be equal to or greater than the distance moved by the
axis as it decelerates from the OPR speed to creep speed (
Page 68, Section 7.6 (8)). If the axis has
moved the distance set by "Movement amount after near-point dog ON" while still decelerating from the OPR
speed to creep speed, the axis stops immediately at that point to complete machine OPR. As a result, the OP
position deviates and the motor load also increases because the axis stops suddenly at the creep speed or
higher.
Setting the movement amount after
the near-point watchdog ON
Suddenly stopped during deceleration
to the creep speed
V
t
Near-point watchdog
ON
OFF
7
7.6 OPR Control
7.6.1 Machine OPR
87
(c) Advantages of using limit switches
The following functions can be used when the upper and lower limit signals are selected:
• OPR retry function
When machine OPR is started in a position indicated as interval A (where the near-point dog is turned off
and no near-point dog is found in the OPR direction) in the figure below , the axis continues to operate at
the OPR speed until reaching the limit switch of the machine system because it cannot detect the nearpoint watchdog.
When the limit signal in the OPR direction turns off, the OPR retry function actuates. As a result, the axis
decelerates to a stop and then move in the opposite direction to complete machine OPR successfully
(
Page 111, Section 7.10.1). This eliminates the need to perform JOG operation, etc., to return to the
position before the near-point dog turned on.
• Hardware stroke limit function
When the limit signal in the direction opposite the OPR direction turns off, the axis decelerates to a stop
due to the hardware stroke limit function (
Page 124, Section 7.10.5). This prevents damage to the
machine system.
Interval B
Limit switch
When started from here
Near-point watchdog
Interval A
ON
OFF
OFF
Retry operation
When started from here
Moving in the opposite direction
(d) Machine OPR from a position where the near-point dog is turned on
When starting position is in interval B (where the near-point dog is turned on) in the figure above, the axis starts
moving at the OPR speed in the direction opposite the OPR direction due to the OPR retry function to perform
machine OPR (
88
Page 114, Section 7.10.1 (4)).
CHAPTER 7 POSITIONING FUNCTION
(9) Setting of no method
"No method" is provided as an OPR method for those systems that do not use machine OPR. The I/O signals
used for OPR can be used with other functions. If "No method" is set, an attempt to start machine OPR with the
OPR start instruction (IPOPR1(P)) generates "OPERATION ERROR" (error code: 4116).
7
7.6 OPR Control
7.6.1 Machine OPR
89
7.6.2
Fast OPR
The fast OPR is a function to perform positioning to the "OP address" established by machine OPR or other position
(standby address).
Address
Description
OP address
This address is used to perform positioning using the OP established by machine OPR as the starting point.
This address is used to perform positioning using a position other than the OP established by machine OPR
as the starting point. In certain situations such as when a near-point dog cannot be installed near the standby
Standby address
address and thus the standby address is not the same as the OP in machine system design, fast OPR can be
implemented to the standby address to return the workpiece to the starting point (≠ OP).
High-speed positioning control is started with the OPR start instruction (IPOPR1(P)) and implemented without using a
near-point dog or zero signal (
Page 148, Section 7.12.1 (4)).
(1) Fast OPR operation
This operation uses the following OPR parameters, except for the OP address and standby address set for the
OPR start instruction (IPOPR1(P).
Setting item
Data type
OPR Speed
OPR Acceleration/
Deceleration Time
OPR Parameter
OPR Deceleration Stop
Time
V
OPR speed
OP or standby
address
Fast OPR
t
OPR ACC/DEC time
OPR DEC/STOP time
ON
OPR start instruction
execution command
OFF
ON
Axis 1 start instruction in
execution (SM1848)
Axis 1 BUSY (SM1840)
OFF
Axis 1 positioning complete
(SM1841)
Axis 1 OPR request (SM1842)
OFF
Axis 1 OPR complete (SM1843)
OFF
Axis 1 operation status (SD1844)
Axis 1 movement amount after
near-point watchdog ON
(SD1848, SD1849)
90
OFF
ON
ON
ON
OFF
Standby (0)
Fast OPR (9)
Standby (0)
Not changed
CHAPTER 7 POSITIONING FUNCTION
(2) Precautions
• Establish the OP via machine OPR before starting fast OPR. Otherwise, the "Machine OPR not performed"
error (Axis 1 error code: 1201) occurs and operation does not start.
• If the system uses speed control, speed/position switching control and current value change, the Axis 1
current feed value (SD1840, SD1841) is different from the coordinate calculated with reference to the
machine OP and thus fast OPR to the machine OP or standby address cannot be performed.
7
7.6 OPR Control
7.6.2 Fast OPR
91
7.6.3
Forced off of Axis 1 OPR request (SM1842)
When the LCPU requests machine OPR upon power on, etc., the Axis 1 OPR request (SM1842) turns on. If the
system does not require machine OPR, the Axis 1 OPR request (SM1842) can be forcibly turned off by turning on the
Axis 1 OPR request off (SM1851). The Axis 1 OPR request off (SM1851) should be turned off again after confirming
that the Axis 1 OPR request (SM1842) has turned off.
7.6.4
Precautions on Axis 1 OPR request (SM1842)
In the following condition, the Axis 1 OPR request (SM1842) needs to be turned on to perform the machine OPR.
• At power on
• At reset
• When the operating status is switched from STOP to RUN
• When the drive unit ready signal is turned off
• At the start of machine OPR control
While the Axis 1 OPR request (SM1842) is on, address information stored in the LCPU cannot be guaranteed. When
the machine OPR is performed and successfully completed, the Axis 1 OPR request (SM1842) turns off and the Axis 1
OPR completion (SM1843) turns on.
92
CHAPTER 7 POSITIONING FUNCTION
7.7
Positioning Control
The positioning control method is set by the positioning data "Control System". 10 positioning data can be set for each
axis with the programming tool. To start positioning control using positioning data set with the programming tool, use
the Table start instruction (IPPSTRT1(P)) (
Page 140, Section 7.12.1 (1)). To start positioning control using 10 or
more positioning data, set them as the setting data of the Positioning start instruction (IPDSTRT1(P)) (
Page 142,
Section 7.12.1 (2)).
10
9
Positioning data No.
1
3
2
Positioning data No.
Control System
1
3
2
Control System
Acceleration/Deceleration
Time
Axis 1
10
9
Acceleration/Deceleration
Time
Deceleration Stop Time
Axis 2
Deceleration Stop Time
Dwell Time
Dwell Time
Command Speed
Command Speed
Positioning Address/
Movement Amount
Positioning Address/
Movement Amount
Setting item
Setting range
7
Default
Control system not available
Positioning Control (INC)
Speed-position Control (Forward RUN)
Control System
Speed-position Control (Reverse RUN)
Control system not available (blank)
Current Value Changing
Speed Control (Forward RUN)
Speed Control (Reverse RUN)
Acceleration/Deceleration Time (ms)
0 to 32767
Deceleration Stop Time (ms)
Dwell Time (ms)
1000
0 to 65535
Command Speed (pulse/s)
0 to 200000
-2147483648 to 2147483647
Positioning Address/Movement Amount (pulse)
0
(0 to 2147483647 if the control method is
speed/position switching control)
Setting details are explained below.
Note that the explanations in this section assume use of Axis 1. For the special relay, special register, dedicated
instructions, error codes, and warning codes for Axis 2, refer to the following.
• Special relay and special register:
• Dedicated instructions:
• Error codes:
• Warning codes:
Page 60, Section 7.4 (2)
Page 139, Section 7.12
Page 175, Section 7.14 (1)
Page 179, Section 7.14 (2)
93
7.7 Positioning Control
Positioning Control (ABS)
(1) Control system
Set the positioning control system.
Control system
Overview
Control system not available
Reference
⎯
Set this option if positioning control is not performed.
Positioning Control (ABS)
Positioning control is implemented from the position at which the axis is currently
Positioning Control (INC)
stopped, to the specified position.
Speed-position Control (Forward
RUN)
Speed-position Control (Reverse
RUN)
Page 99,
Section 7.7.2
Speed control is implemented first and when the external command signal is turned
on, position control (positioning control based on specified movement amount) is
implemented successively.
Current Value Changing
The Axis 1 current feed value (SD1840, SD1841) is changed to the set address.
Speed Control (Forward RUN)
After acceleration, operation continues until the execution command for Axis stop
Speed Control (Reverse RUN)
instruction (IPSTOP1) turns on.
Page 100,
Section 7.7.3
Page 102,
Section 7.7.4
Page 103,
Section 7.7.5
Combinations of "control system" and other required positioning data are shown below.
: Must be set,
: Set as necessary, ⎯: Need not be set
Control system
Positioning data
Position
control
Speed control
Speed/position
Current value
switching control
change
Acceleration/Deceleration Time
⎯
Deceleration Stop Time
⎯
Dwell Time
⎯
Command Speed
Positioning Address/Movement
Amount
94
⎯
CHAPTER 7 POSITIONING FUNCTION
(2) Acceleration/deceleration time, deceleration stop time, dwell time, and
command speed
• Set the time required for the axis to reach the command speed from the bias speed at start.
• Deceleration stop time: Set the time required for the axis to reach the bias speed at start from the command
speed and then stop upon completion of position control or occurrence of a stop cause.
• Dwell time: Set the time required for Axis 1 positioning completion (SM1841) to turn on after completion of
positioning control.
• Command speed: Set the speed at which to implement positioning control. If the set command speed
exceeds the speed limit, positioning control is implemented at the speed limit. If the set command speed is
less than the bias speed at start, positioning control is implemented at the bias speed at start.
V
Command speed
7
Bias speed at start
t
Dwell time
ACC/DEC time
DEC/STOP time
ON
7.7 Positioning Control
Axis 1 positioning complete (SM1841) OFF
95
(3) Positioning address/movement amount
Set the address or movement amount to be used as the target value for positioning control. The setting range of
values varies depending on the "control method."
(a) Position control (ABS), current value change
Set the address from the OP.
Stop position
(positioning start address)
-1000
1000
Movement amount: 2000
3000
Movement amount: 2000
(b) Position control (INC)
Set the movement amount with sign.
• When the movement amount is positive: Move in the positive direction (address increasing direction)
• When the movement amount is negative: Move in the negative direction (address decreasing direction)
Stop position
(positioning start address)
(Movement amount)
-30000
Moving in negative
direction
(Movement amount)
30000
Moving in positive
direction
(c) Speed/position switching control (forward/reverse)
Set the movement amount after switching from speed control to position control.
The setting range is 0 to 2147483647 (pulses).
V
Movement amount
setting
Speed control
Position control
t
Speed/position switching
command
(d) Speed control (forward and reverse RUN)
The set value is ignored.
96
CHAPTER 7 POSITIONING FUNCTION
7.7.1
Start of positioning control
Positioning control can be started using positioning data set with the programming tool or by setting positioning data in
a program. The I/O signals used under each control method are shown below.
: Wiring required,
: Wire as necessary, ⎯: Wiring not required
Control system
I/O signal
Speed/position
Position control
Speed control
Zero Signal*1
⎯
⎯
⎯
Near-point Dog Signal*1
⎯
⎯
⎯
Deviation Counter Clear Signal*1
⎯
⎯
⎯
External Command Signal
⎯*1
switching control
*1
⎯
CW/PULSE/A Phase output
CCW/SIGN/B Phase output
Drive Unit Ready Signal*1
Upper Limit Signal*1*2
7
Lower Limit Signal*1*2
*1
*2
When this signal is not required, it can be used for other functions such as the general-purpose input and generalpurpose output.
These signals are required when the hardware stroke limit and OPR retry functions are used.
(1) Starting with positioning data set by the programming tool
Positioning data (up to 10 sets of data for each axis) can be set easily using the programming tool. Note that once
level using the Two axes simultaneous start instruction (IPSIMUL(P)).
(a) Setting
Set positioning data (10 sets of data for each axis) using the programming tool and write the data to the LCPU.
(b) Starting
Start positioning with the Table start instruction (IPPSTRT1(P)) by specifying a positioning data No.
(
Page 140, Section 7.12.1 (1)). Only one set of positioning data can be executed with each instruction. To
start two axes simultaneously, use the Two axes simultaneous start instruction (IPSIMUL(P)).
(2) Starting by setting positioning data with a device
Start positioning with the Positioning start instruction (IPDSTRT1(P)) by specifying the device in which positioning
data is stored. Positioning data can be changed every time positioning is started. Use this mode when there are
many positioning points and 10 sets of positioning data are not enough, or when positioning addresses and
command speeds are calculated by a program, among others.
(a) Setting
Set positioning data to a device by a program.
(b) Starting
Positioning is started when the set device is specified as setting data and the Positioning start instruction
(IPDSTRT1(P)) is executed in the program (
Page 142, Section 7.12.1 (2)). Two axes cannot be started
simultaneously.
97
7.7 Positioning Control
7.7.1 Start of positioning control
set, positioning data cannot be changed in a program. Two axes can be started simultaneously at the pulse output
(3) Subfunction
• The command speed can be changed using the Speed change instruction (IPSPCHG1(P))
(
Page 116, Section 7.10.3).
• The software stroke limit function can be used when the software upper/lower stroke limits are set
(
Page 121, Section 7.10.4).
• The hardware stroke limit function can be used when upper/lower limit signals are input
(
Page 124, Section 7.10.5).
• The target position can be changed using the Target position change instruction (IPTPCHG1(P))
(
98
Page 125, Section 7.10.6).
CHAPTER 7 POSITIONING FUNCTION
7.7.2
Position control
Positioning control is implemented for the specified axis from the current position to specified position.
(1) Positioning control by ABS (absolute) method
Positioning is performed by specifying a position with reference to the OP. The moving direction is determined by
the current position.
Ex. Operation when the starting point address is 2000 and "Positioning address/movement amount" is set to
11000:
Positioning address
(End address)
Start address
0
2000
11000
Positioning control (movement amount 9000)
7
(2) Positioning control by INC (incremental) method
Positioning is performed by the set movement amount from the current position being the starting point. The
moving direction is determined by the sign of "Positioning address/movement amount."
Ex. Operation when the starting point address is 2000 and "Positioning address/movement amount" is set to
-11000:
End address
0
7.7 Positioning Control
7.7.2 Position control
-9000
Start address
2000
Positioning control (movement amount -11000)
(3) Precautions
If the value of "Positioning address/movement amount" exceeds the upper limit of the software stroke, a
"Software stroke limit+" error (Axis 1 error code: 1103) occurs. If the value is smaller than the lower limit of the
software stroke, a "Software stroke limit-" error (Axis 1 error code: 1104) occurs. In these cases, position control
does not start.
99
7.7.3
Speed/position switching control
After the start instruction has been executed, position control is started via speed control first. When the external
command signal turns on, speed control switches to position control and positioning control is implemented by the
movement amount set by "Positioning address/movement amount." Speed/position switching control is implemented in
forward and reverse directions. To switch from speed control to position control, the Axis 1 Speed/position switching
enable (SM1852) must be turned on beforehand.
(1) Speed/position switching control operations
(a) Operation timings
V
Command speed
Position
control
Speed
control
Bias speed at start
Dwell time
Start instruction
execution command
Axis 1 BUSY (SM1840)
Axis 1 positioning complete
(SM1841)
External command signal
Axis 1 speed/position
switching enable
(SM1852)
t
ON
OFF
ON
OFF
ON
OFF
ON
OFF
ON
OFF
Axis 1 current feed value
(SD1840, SD1841)
0
(Will be updated)
(b) Axis 1 current feed value (SD1840, SD1841)
This value is cleared to 0 at the start of speed control. It is not refreshed during speed control, and refreshed
only after switching to position control.
100
CHAPTER 7 POSITIONING FUNCTION
(2) Precautions
(a) Selection of external command signal
An attempt to start speed/position switching control without selecting an external command signal generates a
"Speed/position switching control start not possible" error (Axis 1 error code: 1505).
(b) External command signal on timing and operation
• If speed/position switching control is started while the external command signal is still on, position control
is implemented first. (The Axis 1 current feed value (SD1840, SD1841) is cleared to 0 and then refreshed
accordingly thereafter.)
• If the external command signal is turned on before the command speed is reached, position control is
implemented at the speed effective at that point.
(c) External command signal and positioning data
If the following condition is met, deceleration starts at the moment an external command signal is input:
Positioning address/Movement amount < Deceleration distance from command speed
In this case, the axis moves only by the movement amount set by "Positioning address/movement amount,"
before decelerating to the bias speed at start, and then stops immediately.
7
(d) Speed 0
When the bias speed at start is set to 0 and the command speed is also set to 0 under the speed control,
operation does not start. At this time, the special relays and registers assume the following statuses. To
continue with the operation, set a value other than 0 for the new speed value and then turn off the Axis 1 speed
0 (SM1844) using a speed change request with the Speed change instruction (IPSPCHG1(P)).
• Axis status: Stop
• Axis 1 axis operation status (SD1844): 5 (In speed-position control (speed))
• Axis 1 busy (SM1840): On
If the bias speed at start is other than 0, changing the command speed to 0 generates an "Out of speed range"
warning (Axis 1 warning code: 1020) and the axis operates at the bias speed at start.
(e) Software stroke limit
Do not implement speed/position switching control beyond the range of software stroke limits. If the value of
"Positioning address/movement amount" exceeds the range of software stroke limits during speed control, a
"Software stroke limit+" error (Axis 1 error code: 1103) or "Software stroke limit-" error (Axis 1 error code: 1104)
occurs the moment it switches to position control, and the axis decelerates to a stop.
(f) Set value of "Positioning address/movement amount"
Do not set a negative value for "Positioning address/movement amount." A "Movement amount setting out of
range under speed/position switching control" error (Axis 1 error code: 1504) occurs.
(g) Stop position
To suppress fluctuation of the stop position after switching to position control, turn the external command signal
on in a stable speed area.
101
7.7 Positioning Control
7.7.3 Speed/position switching control
• Axis 1 speed 0 (SM1844): On
7.7.4
Current value change
The Axis 1 current feed value (SD1840, SD1841) of a stationary axis is changed to a specified address.
(1) Timing of current value change
When the execution command for start instruction turns on, the specified address is stored in the Axis 1 current
feed value (SD1840, SD1841).
ON
Start instruction
execution command OFF
Axis 1 current feed value
(SD1840, SD1841)
****
Value set for "Positioning address/movement amount"
(2) Precautions
If the new current value exceeds the upper limit of the software stroke, "Software stroke limit +" (Axis 1 error code:
1103) occurs. If the value is smaller than the lower limit of the software stroke, "Software stroke limit -" (Axis 1
error code: 1104) occurs. In these cases, the current value is not changed.
102
CHAPTER 7 POSITIONING FUNCTION
7.7.5
Speed control
After accelerating to the command speed, the axis continues to operate at the command speed until the Axis stop
instruction (IPSTOP1) is executed. Speed control is implemented in forward and reverse directions. Operation timings
are shown in the figure below.
(1) Speed control operation
(a) Operation timings
V
Command speed
Bias speed at start
t
ON
Start instruction execution OFF
command
Axis 1 BUSY (SM1840)
OFF
Axis stop instruction
execution command
OFF
7
ON
ON
Axis 1 current feed value
(SD1840, SD1841)
0
(b) Axis 1 positioning completion (SM1841) and Axis 1 current feed value (SD1840,
SD1841)
The Axis 1 positioning completion (SM1841) does not turn on during speed control. Also note that the Axis 1
current feed value (SD1840, SD1841) is fixed to 0 during speed control.
(2) Precautions
(a) Speed 0
When the bias speed at start is set to 0 and the command speed is also set to 0 under the speed control, the
special relays and register assume the following statuses. To continue with the operation, set a value other
than 0 for the new speed value and then turn off the Axis 1 speed 0 (SM1844) using a speed change request
with the Speed change instruction (IPSPCHG1(P)).
• Axis 1 speed 0 (SM1844): On
• Axis status: Stop
• Axis 1 axis operation status (SD1844): 10 (In speed control)
• Axis 1 busy (SM1840): On
If the bias speed at start is other than 0, changing the command speed to 0 generates an "Out of speed range"
warning (Axis 1 warning code: 1020) and the axis operates at the bias speed at start.
103
7.7 Positioning Control
7.7.5 Speed control
Axis 1 positioning complete OFF
(SM1841)
7.8
Multiple Axes Simultaneous Start Control
Two axes can be started simultaneously using the Two axes simultaneous start instruction (IPSIMUL(P))
(
Page 145, Section 7.12.1 (3)).
(1) Operation details
Two axes can be started simultaneously. The stop timing varies depending on the data of each axis.
V
Axis 1
t
Axis 2
t
ON
Simultaneous 2-axes
start instruction execution OFF
command
104
CHAPTER 7 POSITIONING FUNCTION
1
If you want the two axes to generate a linear composite locus, simulated interpolation control can be performed. In this case,
take note of the following points:
• Calculate the speed according to the ratio of movement amounts of two axes.
• Use identical acceleration and deceleration time and deceleration stop time for the two axes.
Ex. "Positioning address/movement amount" ratio Axis 1: Axis 2 = 2:1
Command speed ratio Axis 1:Axis 2 = 2:1
Movement amount in Axis 2 direction
Generated path
Movement amount
in axis 1 direction
V
7
Axis 1
t
Axis 2
t
Simultaneous 2-axes start
instruction execution command OFF
ACC/DEC time
DEC/STOP time
(2) Precautions
• Errors are handled for each axis. If Axis 1 data is abnormal but Axis 2 data is normal, for example, only Axis
2 is started.
• If either axis or both axes is/are operating when the Two axes simultaneous start instruction (IPSIMUL(P)) is
executed, the two axes do not start simultaneously. The operating axis or axes continue(s) with the current
positioning operation.
• To stop each axis, execute the Axis stop instruction (IPSTOP1) for the axis.
105
7.8 Multiple Axes Simultaneous Start Control
ON
7.9
JOG Operation
JOG operation is used for moving the axis only by a desired movement amount without using positioning data. Use this
operation when checking the connection of the positioning control system, or to move the workpiece to inside the
range of software stroke limits after operation has stopped by the software stroke limit function. JOG operation is
started with the JOG start instruction by setting the JOG speed, JOG ACC time, JOG DEC time and direction
(
Page 151, Section 7.12.1 (5)).
Note that the explanations in this section assume use of Axis 1. For the special relay, special register, dedicated
instructions, error codes, and warning codes for Axis 2, refer to the following.
• Special relay and special register:
• Dedicated instructions:
• Error codes:
Page 60, Section 7.4 (2)
Page 139, Section 7.12
Page 175, Section 7.14 (1)
• Warning codes:
Page 179, Section 7.14 (2)
(1) Flow of operation
Operation step
Description of operation
JOG operation is started with the JOG start instruction (IPJOG1). When the execution command for JOG start
1)
instruction turns on, the axis starts to accelerate in the set direction over the JOG ACC time. The Axis 1 busy
(SM1840) turns on.
2)
3)
4)
Once the accelerating workpiece reaches the JOG speed, the axis continues to move by maintaining the JOG speed.
When the execution command for JOG start instruction turns off, the axis starts to decelerate from the JOG speed
over the JOG DEC time.
The axis stops when the speed drops to 0. The Axis 1 busy (SM1840) turns off.
V
Forward JOG
t
1)
2)
3)
4)
Reverse JOG
ON
JOG start instruction
execution command OFF
JOG direction
ON
OFF
ON
Axis 1 BUSY
(SM1840)
106
OFF
CHAPTER 7 POSITIONING FUNCTION
1
(2) Precautions
(a) JOG speed adjustment
It is dangerous to set a high JOG speed from the beginning. To ensure safety, set a small value first and
gradually increase it while checking the operation to adjust to an optimal speed for control.
(b) Axis stop instruction command during JOG operation
When the execution command for Axis stop instruction (IPSTOP1) turns on during JOG operation, the axis
decelerates to a stop. If the execution command for JOG start instruction turns on while the execution
command for Axis stop instruction (IPSTOP1) is on, a "Stop instruction ON at start" error (Axis 1 error code:
1102) occurs and JOG does not start.
V
A error occurs and the JOG operation is not performed.
t
7
ON
JOG start instruction
OFF
execution command
Axis stop instruction
OFF
execution command
OFF
JOG direction
OFF
ON
7.9 JOG Operation
Axis 1 BUSY
(SM1840)
ON
To start JOG operation, follow the steps below.
1.
2.
3.
4.
Turn off the execution command for JOG start instruction.
Reset the axis error.
Turn off the execution command for Axis stop instruction (IPSTOP1).
Turn on the execution command for JOG start instruction again.
107
If the execution command for Axis stop instruction (IPSTOP1) is turned on while the execution command for
the JOG start instruction (IPJOG1) is on and then the execution command for Axis stop instruction (IPSTOP1)
is turned off, JOG operation cannot be performed. To start JOG operation, turn on the execution command for
JOG start instruction again.
V
JOG does not start even
if Axis stop instruction
execution command is
turned off.
t
ON
JOG start instruction
OFF
execution command
ON
Axis stop instruction
OFF
execution command
Axis 1 BUSY
(SM1840)
ON
OFF
(c) Multiple instruction executions
If the execution command for JOG start instruction is turned off and then turned on again while the axis is
decelerating, JOG operation cannot be performed.
V
JOG start instruction
is ignored.
t
ON
JOG start instruction OFF
execution command
ON
Axis 1 BUSY
(SM1840)
OFF
(d) Limitation of JOG speed
If the JOG speed exceeds the set speed limit, the axis operates at the speed limit and an "Out of speed range"
warning (Axis 1 warning code: 1020) occurs. If the JOG speed is less than the bias speed at start, the same
warning occurs and the bias speed at start is applied.
108
CHAPTER 7 POSITIONING FUNCTION
(e) JOG speed 0
If the bias speed at start is 0 and JOG operation is started by setting 0 for the JOG speed, the special relays
1
and registers assume the following statuses. If the new speed value is set to other than 0 and the speed is
changed accordingly using the Speed change instruction (IPSPCHG1(P)), the Axis 1 speed 0 (SM1844) turns
off and JOG operation continues.
• Axis 1 speed 0 (SM1844): On
• Axis status: Stop
• Axis 1 axis operation status (SD1844): 2 (In JOG control)
• Axis 1 busy (SM1840): On
If the bias speed at start is other than 0, changing the JOG speed to 0 generates an "Out of speed range"
warning (Axis 1 warning code: 1020) and the axis operates at the bias speed at start.
(f) Speed change
The speed cannot be changed while the axis is decelerating.
(g) Forward/reverse switching
To switch between forward and reverse directions, confirm that the Axis 1 busy (SM1840) is off and then turn
on the execution command for JOG start instruction. While the Axis 1 busy (SM1840) is on, establishment of
the execution command for JOG start instruction is ignored.
7
(3) Subfunction
• The software stroke limit function can be used when the software upper/lower stroke limits are set
(
Page 121, Section 7.10.4).
• The hardware stroke limit function can be used when upper/lower limit signals are input
(
Page 124, Section 7.10.5).
Important
To perform JOG operation near the perimeter of the moving range, use the hardware stroke limit function (
Page 124,
Section 7.10.5).
If the hardware stroke limit function is not used, the workpiece may go out of the moving range and cause an accident.
109
7.9 JOG Operation
• The JOG speed can be changed using the Speed change instruction (IPSPCHG1(P)).
7.10
Subfunction
"Subfunctions" govern control limitation, addition of function, etc., when OPR control, positioning control and JOG
operation are performed. These subfunctions are implemented by setting parameters or in programs.
Subfunction
Overview
Reference
A function to perform machine OPR automatically by detecting an off edge of the
OPR retry function
limit signal and moving to a position where machine OPR is possible, even when
Page 111, Section 7.10.1
the OP is not located in the OPR direction.
Speed limit function
Speed change function
A function to limit the speed to within the setting range of speed limit values when
the operating speed exceeds the positioning parameter "Speed limit".
A function to change the speed during operation.
Page 115, Section 7.10.2
Page 116, Section 7.10.3
A function to not start operation when a start instruction is given to move to the
Software stroke limit
target position which is outside the range set by the upper stroke limit and lower
function
stroke limit. The limit function also stops operation when the current feed value
Page 121, Section 7.10.4
deviates from the setting range.
Hardware stroke limit
function
A function to decelerate the axis to a stop using a limit switch connected to the
external device connector.
Target position change
function
Page 124, Section 7.10.5
A function to change the target value during positioning control.
Page 125, Section 7.10.6
A function to adjust the acceleration/deceleration processing as part of control.
Page 129, Section 7.10.7
Acceleration/
deceleration
processing function
Stop processing
function
A function to control the stopping method to be applied when a stop cause occurs
during operation.
Page 131, Section 7.10.8
Note that the explanations in this section assume use of Axis 1. For the special relay, special register, dedicated
instructions, error codes, and warning codes for Axis 2, refer to the following.
• Special relay and special register:
• Dedicated instructions:
• Error codes:
• Warning codes:
Page 60, Section 7.4 (2)
Page 139, Section 7.12
Page 175, Section 7.14 (1)
Page 179, Section 7.14 (2)
(1) Subfunction and external input signal
When the OPR retry function and hardware stroke limit function are used, upper and lower limit signals are
required.
110
CHAPTER 7 POSITIONING FUNCTION
7.10.1
OPR retry function
1
The workpiece may not move toward the OP depending on the position (for example, when it has already exceeded
the OP during position control). In this case, normally machine OPR is started again after moving the workpiece to just
before the near-point dog after JOG operation, etc. If the OPR retry function is used, however, machine OPR can be
performed regardless of where the workpiece is. To operate the OPR retry function, select the limit signal in the OPR
direction (upper limit signal or lower limit signal) using the built-in I/O function setting.
(1) OPR methods in which this function is enabled
This function is always enabled when the following OPR methods are used:
• Near-point dog method
• Count 1
• Count 2
7
7.10 Subfunction
7.10.1 OPR retry function
111
(2) Flow of operation
The following shows OPR retry function When the workpiece is outside the range of upper or lower limit switches.
Operation step
Description of operation
Machine OPR starts upon execution of the OPR start instruction (IPOPR1(P)). The axis starts moving in the OPR
1)
direction.
2)
The axis decelerates upon detection of turning off of the limit signal.
After stopping upon detection of turning off of the limit signal, it moves in the direction opposite the OPR direction at
3)
the OPR speed. "OPR dwell time" is enabled, if set.
4)
The axis decelerates upon turning off of the near-point dog.
After stopping upon turning off of the near-point dog, the axis performs machine OPR in the OPR direction. The OPR
5)
dwell time is enabled, if set.
Machine OPR is complete.
• Near-point dog method: Machine OPR completes upon detection of the first zero signal after the near-point dog has
turned off.
• Count 1: Machine OPR completes upon detection of the first zero signal after reaching a position corresponding to
6)
"Movement amount after near-point dog ON."
• Count 2: Machine OPR completes upon reaching a position corresponding to "Movement amount after near-point
dog ON." (Before machine OPR is complete, the axis decelerates from the creep speed over the OPR deceleration
stop time.)
2)
In the case
of count 2
5)
6)
1)
6)
3)
4)
OFF
Near-point
watchdog
Zero signal
112
OFF
Limit switch
CHAPTER 7 POSITIONING FUNCTION
1
(3) When the workpiece is outside the range of upper or lower limit switches
(a) When the OP direction is the same as the OPR direction
Machine OPR is not performed. A "Hardware stroke limit +" error (Axis 1 error code: 1100) or "Hardware stroke
limit -" error (Axis 1 error code: 1101) occurs.
Ex. When "OPR direction" is set to "Forward RUN":
A error occurs and the machine OPR is not performed.
Machine OPR start position
OP
OPR direction
Lower limit switch
Upper limit switch
Near-point watchdog
Zero signal
7
Moving range
(b) When the OP direction is opposite to "OPR direction":
The axis decelerates to a stop upon turning off of the near-point dog and then performs machine OPR in the
direction set as "OPR direction."
Ex. When "OPR direction" is set to "Forward RUN":
7.10 Subfunction
7.10.1 OPR retry function
Machine OPR start
OP
OPR direction
Lower limit switch
Upper limit switch
Near-point watchdog
Zero signal
Moving range
113
(4) Near-point dog and starting position of machine OPR
If machine OPR is performed at a position where the near-point dog is turned on, the following operations take
place under each OPR method:
• Near-point dog method: Machine OPR starts at the creep speed.
• Count 1 or count 2: Machine OPR is performed according to the OPR retry function.
Ex. Count 1
Decelerates by near-point watchdog ON.
Movement amount after
near-point watchdog ON
Origin
OPR direction
Start point
With near-point
watchdog ON
Zero signal
Decelerates and stops
by near-point watchdog
OFF.
Near-point watchdog
ON
OFF
(5) Precautions
• If a limit signal is not selected by the built-in I/O function setting, the OPR retry function does not operate and
the mechanical system may also be damaged as the axis continues to operate to the limit of the machine
system.
• If the near-point dog method is used, make sure the area in which the limit switch turns off does not overlap
with the area in which the near-point dog turns on. An attempt to start machine OPR in an overlapped area
generates "Retry error" (Axis 1 error code: 1202) and the axis stops. If the two areas are overlapped during
OPR retry, "Retry error" (Axis 1 error code: 1202) may occur regardless of the OPR method (near-point dog
method, Count 1 or Count 2) and the axis may stop.
• Make sure the limit signal in the direction opposite the OPR direction does not turn off during machine OPR.
A "Hardware stroke limit +" error (Axis 1 error code: 1100) or "Hardware stroke limit -" error (Axis 1 error
code: 1101) occurs and the axis stops.
• Do not start machine OPR in an area where the limit signal in the direction opposite the OPR direction is off.
A "Hardware stroke limit +" error (Axis 1 error code: 1100) or "Hardware stroke limit -" error (Axis 1 error
code: 1101) occurs and machine OPR does not start.
114
CHAPTER 7 POSITIONING FUNCTION
7.10.2
Speed limit function
1
If the operating speed exceeds the speed limit, this function limits the speed to within the setting range of speed limits.
To use this function, set the positioning parameter "Speed limit."
(1) Relationship of speed limit function and control
Control
Operation when the speed limit is exceeded
Machine OPR
OPR control
Fast OPR
Position control
Positioning control
Speed control
Speed/position switching control
Current value change
JOG operation
No operation occurs. (The OPR speed cannot be set higher than the
speed limit using the programming tool.)
An "Out of speed range" warning (Axis 1 warning code: 1020) occurs
and the command speed is limited to the speed limit.
⎯
An "Out of speed range" warning (Axis 1 warning code: 1020) occurs
and the JOG speed is limited to the speed limit.
7
7.10 Subfunction
7.10.2 Speed limit function
115
7.10.3
Speed change function
The speed change function changes the operating speed to a newly specified speed at a desired timing. This function
is implemented with the Speed change instruction (IPSPCHG1(P)) by setting the new speed value, ACC/DEC time at
speed change and DEC/STOP time at speed change (
Page 158, Section 7.12.1 (8)).
(1) Controls that permit speed change and timings of change
The speed can be changed during the controls denoted by "Speed change possible" in the table below, at the
specified timings. If speed change is not possible, a "Speed change not possible" warning (Axis 1 warning code:
1022) occurs and the instruction is ignored, or the instruction is simply ignored without any warning.
Control
OPR
Machine OPR
control
Fast OPR
During
During
During speed
During
constant-
change by the Speed
During
acceleration
speed
change instruction
deceleration
operation
(IPSPCHG1(P))
Warning
Warning
⎯
Warning
Ignored.
Warning
change
Warning
Warning
Ignored.
Speed change possible
⎯
Ignored.
Speed change possible
⎯
Ignored.
Warning
Warning
Ignored.
Speed change possible
Ignored.
Ignored.
deceleration by the
Axis stop
instruction
(IPSTOP1)
Speed
Position control
possible
Speed control
Speed change
possible
Positioning
control
Speed control of
speed/position
Speed change
possible
switching control
Position control of
possible
Speed
change
possible
Speed
speed/position
Warning
switching control
JOG operation
Speed
change
change
possible
Speed change
possible
Speed
change
possible
(2) Description of operation
Speed change under speed control
V
Command speed
Decelerating (accelerating) by ACC/DEC time at speed change
New speed
value
New speed
value
New speed
value
Decelerates by DEC/STOP
time at speed change
Bias speed at
start
t
ON
Speed change instruction
OFF
execution command
116
CHAPTER 7 POSITIONING FUNCTION
1
(3) Precautions
(a) Limitation of new speed value
If the new speed value exceeds the speed limit, the axis operates at the speed limit and an "Out of speed
range" warning (Axis 1 warning code: 1020) occurs. If the new speed value is less than the bias speed at start,
the same warning occurs and the bias speed at start is applied.
(b) Operation during processing
Even when the workpiece is moving at the command speed or JOG speed, speed change is not accepted if
calculations are in progress following the establishment of the execution command for Speed change
instruction (IPSPCHG1(P)).
Ex. Timings at which speed change is permitted during position control
V
Command is acceptable here.
Request
New speed
7
* The area does not change in this figure.
(The movement amount does not change.)
Operation
Previous
speed
Previous
speed
t
7.10 Subfunction
7.10.3 Speed change function
Remark
Change to a new speed occurs after completion of pulse output at the current speed.
ON
Operation time
Pulse waveform
Pulse output is
not completed.
ON
Speed change instruction
OFF
execution command
117
(c) Speed change during position control
If the target position is reached during the processing for speed change in the case of a speed change during
position control or position control of speed/position switching control, a "Speed change not possible" warning
(Axis 1 warning code: 1022) occurs and the speed is not changed.
(d) Target position change and speed change
If the Target position change instruction (IPTPCHG1(P)) is accepted simultaneously as the execution
command for Speed change instruction (IPSPCHG1(P)) is established, a "Speed change not possible" warning
(Axis 1 warning code: 1022) generates and the Speed change instruction (IPSPCHG1(P)) is cancelled.
(For example, if the execution command for Target position change instruction (IPTPCHG1(P)) is established
during acceleration, the operation switches to a constant speed and the target position change is accepted. If
the execution command for Speed change instruction (IPSPCHG1(P)) is established at this timing, it means
that the execution commands for both instructions are established simultaneously. ) (
Page 125, Section
7.10.6)
(e) Speed change and deceleration stop time
When the speed is changed during position control or position control of speed/position switching control in the
following condition, positioning completes before the stop speed reaches the bias speed at start.
• The deceleration stop time is longer than the remaining movement amount at the end of speed change
and thus the constant-speed part of operation cannot be performed after the speed has changed.
V
Movement before speed change (dotted line)
New target
speed Movement after speed change (solid line)
Operation
processing
ACC/DEC time at
speed change
ON
Speed change instruction
OFF
execution command
118
Positioning completed before reaching
the bias speed at start
DEC/STOP time at
speed change
Bias speed
at start
t
CHAPTER 7 POSITIONING FUNCTION
(f) Speed change to 0
1
• When Bias speed at start is 0
If the bias speed at start is set to 0 and new speed value is changed to 0, the axis stops.
However, the Axis 1 busy (SM1840) does not turn off. Even when the axis is stopped, the Axis 1 axis
operation status (SD1844) does not change.
V
New speed value
Bias speed
at start
Speed 0
t
ON
Speed change instruction
OFF
execution command
ON
Start instruction execution
OFF
command
Axis 1 BUSY
(SM1840)
7
ON
OFF
1000
0
New speed value
ON
Axis 1 speed 0
(SM1844)
OFF
(Not changed)
• When bias speed at start is other than 0
When the speed is changed to 0, an "Out of speed range" warning (Axis 1 warning code: 1020) occurs and
the axis operates at the bias speed at start.
• Occurrence of error
If the speed is changed and "Outside the acceleration/deceleration time setting" error (Axis 1 error code:
1502) or "Deceleration stop time out of range" error (Axis 1 error code: 1503) occurs under operation at
speed 0, the axis stops and the Axis 1 axis operation status (SD1844) changes to Error occurring (-1).
119
7.10 Subfunction
7.10.3 Speed change function
Axis 1 operation status
(SD1844)
(g) Speed change and "setting out of range" error
If an "Outside the acceleration/deceleration time setting" error (Axis 1 error code: 1502) or "Deceleration stop
time out of range" error (Axis 1 error code: 1503) occurs at the start of speed change, the Axis 1 axis operation
status (SD1844) change changes to Error occurring (-1). When each control is active, the following operations
are performed according to the control.
• In position control (including it of speed/position switching control)
Position control continues until the end and the axis decelerates to a stop over the deceleration stop time
effective before the speed change.
• In speed control
The axis decelerates to a stop over the deceleration stop time effective before the speed change.
• In JOG operation
The axis decelerates to a stop over the JOG deceleration time effective before the speed change or DEC/
STOP time at speed change (if the last speed change was successful).
The DEC/STOP time at speed change represents the "time until the axis stops at the new speed value" and not the "time
until the axis stops at the current speed."
120
CHAPTER 7 POSITIONING FUNCTION
7.10.4
Software stroke limit function
1
This function prevents execution of a moving command to a position outside the upper/lower limit of the moving range
of the workpiece. The range is set using the address established by machine OPR.
RLS
Movable range of work
Software stroke limit (lower limit)
FLS
Limit switch for
emergency stop
Software stroke limit (upper limit)
7
7.10 Subfunction
7.10.4 Software stroke limit function
121
(1) Range check
A software stroke limit range check is executed at the start of operation and also during operation.
(a) Range check at start of operation
The following are checked at start of operation
• Whether operation starts from outside the range of software stroke limits
• Whether operation starts to outside the range of software stroke limits
The software stroke limit range check is processed as follows depending on the applicable control.
In the table, "Error" indicates "Software stroke limit +" (Axis 1 error code: 1103) or "Software stroke limit -" (Axis
1 error code: 1104).
Control
Operation after range check
Machine OPR
Check is not performed.
• If the Axis 1 current feed value (SD1840, SD1841) is outside the range of
OP address
software stroke limits, an error occurs and operation does not start.
• If the OP address is outside the range of software stroke limits, an error
occurs and operation does not start.
Fast OPR
• If the Axis 1 current feed value (SD1840, SD1841) is outside the range of
Standby address
software stroke limits, an error occurs and operation does not start.
• If the standby address is outside the range of software stroke limits, an
error occurs and operation does not start.
• If the Axis 1 current feed value (SD1840, SD1841) is outside the range of
software stroke limits, an error occurs and operation does not start.
Position control
• If the value of "Positioning address/movement amount" is outside the
range of software stroke limits, an error occurs and operation does not
start.
Speed control
Speed/position switching control
Positioning control
Check is not performed.
(in speed control)
• If the Axis 1 current feed value (SD1840, SD1841) is outside the range of
Speed/position switching control
(in position control)*1
software stroke limits, an error occurs and operation does not start.
• If the value of "Positioning address/movement amount" is outside the
range of software stroke limits, an error occurs and operation does not
start.
Current value change
If the new current value is outside the range of software stroke limits, an error
occurs and the current value is not changed.
When the Axis 1 current feed value (SD1840, SD1841) is outside the range
of software stroke limits and:
JOG operation
• If operation is started in the direction of going out of the range of software
stroke limits, an error occurs and operation does not start.
• If operation is started in the direction of going into the range of software
stroke limits, an error does not occur and operation starts.
Absolute position restoration
*1
122
Check is not performed.
If speed/position switching control is started while the external command signal is still on, operation starts under position
control.
CHAPTER 7 POSITIONING FUNCTION
(b) Range check during operation
1
The software stroke limit range check is processed as follows depending on the applicable control.
In the table, "Error" indicates "Software stroke limit +" (Axis 1 error code: 1103) or "Software stroke limit -" (Axis
1 error code: 1104).
Control
Operation after range check
Machine OPR
OPR control
Fast OPR
Check is not performed.
If the Axis 1 current feed value (SD1840,SD1841) may exceed the software
Position control
stroke limit by changing the target position, the change is not executed and
the original positioning operation is continued. An error occurs after the
positioning is completed.
Speed control
Speed/position switching control
Check is not performed.
(in speed control)
• If the Axis 1 current feed value (SD1840, SD1841) is outside the range of
software stroke limits upon switching to position control, an error occurs
Positioning control
and the axis decelerates to a stop.
• If the value of "Positioning address/movement amount" is outside the
range of software stroke limits upon switching to position control, an error
Speed/position switching control
(in position control)
occurs and the axis decelerates to a stop.
• If the target position is changed and the Axis 1 current feed value (SD1840,
7
SD1841) exceeds the software stroke limit as a result, the target position
change is ignored and the control continues based on the original value of
"Positioning address/movement amount." An error occurs after the
positioning is completed.
Current value change
⎯
An error occurs at the moment the Axis 1 current feed value (SD1840,
SD1841) exceeds the software stroke limit, and the axis decelerates to a
stop.
Absolute position restoration
Check is not performed.
(2) Precautions
• So that the software stroke limit function operates normally, execute machine OPR beforehand.
• Setting the upper and lower software stroke limits prevents a software overrun. To make doubly sure, also
provide emergency stop limit switches near the outer perimeter of the range.
Remark
With the Two axes simultaneous start instruction (IPSIMUL(P)), the current values of the two axes to be started
simultaneously are checked against the stoke limits. If either axis generates an error, only the other axis is started.
123
7.10 Subfunction
7.10.4 Software stroke limit function
JOG operation
7.10.5
Hardware stroke limit function
The hardware stroke limit function stops the control (after deceleration) by detecting an input from the upper and lower
limit switches that are installed at the upper and lower limit of the physical moving range. Equipment damage can be
prevented by this function. Normally a hardware stroke limit is set on the inside of the stroke limit or stroke end on the
drive unit side, to stop the control before this stroke limit or stroke end is reached. For the limit signal, select either the
upper limit signal or lower limit signal using the built-in I/O function setting.
(1) System overview
Lower limit
Upper limit
Controllable range
Mechanical
stopper
Mechanical
stopper
Moving direction
Start
Decelerates and stops
upon detection of the lower
limit switch
Start
Moving direction
Decelerates and stops
upon detection of the upper
limit switch
LCPU
Stroke limit
of the drive
unit
Lower limit switch
Upper limit switch
Stroke limit
of the drive
unit
Drive unit
(2) Precautions
While the axis is stopped outside the controllable range (outside the upper or lower limit switch) or after detection
of a limit switch, OPR control and positioning control cannot be started. Start each control after moving the
workpiece to inside the controllable range via JOG operation.
124
CHAPTER 7 POSITIONING FUNCTION
7.10.6
Target position change function
1
The target position change function changes the target position set by "Positioning address/movement amount" during
position control (including it of speed/position switching control), to a new target position at a desired timing. This
function is implemented with the Target position change instruction (IPTPCHG1(P)) (
Page 161, Section 7.12.1
(9)). The following shows the target position of each control method.
• Position control (ABS): Address with reference to the OP address
• Position control (INC): Movement amount from the starting address
• Position control of speed/position switching control: Movement amount from the address at which speed
control switched to position control
7
7.10 Subfunction
7.10.6 Target position change function
125
(1) Control details
• If the position of the workpiece upon establishment of the execution command for Target position change
instruction (IPTPCHG1(P)) is located before the position at which to start decelerating to the new target
value over the deceleration stop time, positioning is performed to the new target position.
V
Target position change instruction execution command
t
New target position
(When decreased)
Original target
position
New target position
(When increased)
• If the position of the workpiece upon establishment of the execution command for Target position change
instruction (IPTPCHG1(P)) exceeds the position at which to start decelerating to the new target value over
the deceleration stop time, the axis decelerates to a stop and then positions itself to the new target position.
V
Original deceleration start position
for new target position
Target position change instruction
execution command
New target
position
t
Previous target position
• If the workpiece is decelerating when the execution command for Target position change instruction
(IPTPCHG1(P)) is established, the axis decelerates to a stop and then positions itself to the new target
position.
V
Target position change instruction
execution command
New target position
(When decreased)
New target position
(When increased)
t
Stops at the previous target
position.
126
CHAPTER 7 POSITIONING FUNCTION
1
(2) Precautions
(a) Instruction execution during acceleration/deceleration
If the axis was accelerating/decelerating to the command speed when the execution command for Target
position change instruction (IPTPCHG1(P)) was established, the workpiece is allowed to reach the command
speed, after which positioning to the new target position is performed. If the axis starts decelerating to a stop
before reaching the command speed, positioning to the new target position is performed after the axis has
decelerated to a stop.
V
Target position change instruction execution command
Processing for
change
t
Previous target position
Changed
New target position
7
(b) Software stroke limit
If the new target value exceeds the range of software stroke limits, the target position is not changed and the
positioning control effective before the establishment of the execution command for Target position change
instruction (IPTPCHG1(P)) continues. When the positioning control is complete, a "Software stroke limit +"
error (Axis 1 error code: 1103) or "Software stroke limit -" error (Axis 1 error code: 1104) occurs. (If causes of
1104) error are present, a "Software stroke limit -" error (Axis 1 error code: 1104) occurs.)
(c) Multiple target position changes
The target position can be changed as many times as desired during a single operation.
• During operation under position control (INC), a new target position is always defined by the movement
amount from the current value from which positioning is started.
• During position control of speed/position switching control, a new target position is always defined by the
movement amount from the current value (0) at which speed control switched to position control.
If the target position is changed multiple times while the workpiece is accelerating/decelerating to the command
speed or simply decelerating, only the last target position change is implemented.
(d) Target position change and speed change
If the execution command for Target position change instruction (IPTPCHG1(P)) is established during speed
change, the target position change is executed upon completion of the speed change. Note that if the new
speed value is 0, only the target position is changed and the workpiece does not move. If the speed is set to
other than 0, positioning is performed to the target position.
(e) Positioning control and target position change
The target position cannot be changed during operation other than when position control is active. A "Target
position change not possible" warning (Axis 1 warning code: 1021) occurs.
127
7.10 Subfunction
7.10.6 Target position change function
both "Software stroke limit +" error (Axis 1 error code: 1103) and "Software stroke limit -" (Axis 1 error code:
(f) When Axis 1 speed 0 (SM1844) is on
If the Target position change instruction (IPTPCHG1(P)) is executed when the Axis 1 speed 0 (SM1844) is on,
a "Target position change not possible" warning (Axis 1 warning code: 1021) occurs and the target position is
not changed.
(g) Axis 1 axis operation status (SD1844) and target position change
If the Axis 1 axis operation status (SD1844) is indicating a stopped status (1) or indicating a standby status (0),
the target position is not changed.
(h) Instruction calculation and positioning completion
If positioning based on positioning data completes while the calculation relating to the Target position change
instruction (IPTPCHG1(P)) is still in progress, the target position is not changed. A "Target position change not
possible" warning (Axis 1 warning code: 1021) occurs.
(i) Acceleration and deceleration
Target position change does not involve acceleration or deceleration change. (The slope in the VT diagram
does not change.)
(j) Target position change value during position control of speed/position switching
control
For the target position change value during position control of speed/position switching control, do not set a
negative value. If a negative value is set, a "Movement amount setting out of range under speed/position
switching control" error (Axis 1 error code: 1504) occurs. (The target position change is ignored and position
control continues.)
128
CHAPTER 7 POSITIONING FUNCTION
7.10.7
Acceleration/deceleration processing function
1
The acceleration/deceleration processing function is used to adjust the acceleration/deceleration when OPR control,
positioning control or JOG operation is performed. By adjusting the acceleration/deceleration processing according to
each control, the control can be implemented in a more detailed manner.
(1) Decision of acceleration/deceleration processing method
The acceleration/deceleration method is determined by the setting items specified below.
Function
Operation start speed
Acceleration time
Target speed
OPR control
Bias speed at start*1
OPR acceleration/
deceleration time
OPR speed*2
Acceleration/deceleration
time
Command speed
JOG ACC time
JOG speed
JOG DEC time
New speed value
DEC/STOP time at speed
change
Positioning control
JOG operation
Speed change
function
*1
Bias speed at start
ACC/DEC time at speed
change
Deceleration time
OPR acceleration/
deceleration time*1
Deceleration stop time
Deceleration is to the creep speed. In the Count 2 method, the axis decelerates from the creep speed over the OPR
deceleration stop time prior to the completion of machine OPR (
Page 70, Section 7.6.1). Also during fast OPR, the
axis decelerates from the OPR speed over the OPR deceleration stop time.
*2
In the Stopper 3 method, the creep speed applies (
Page 82, Section 7.6.1 (6)).
7
V
Target speed
7.10 Subfunction
7.10.7 Acceleration/deceleration processing function
When Bias speed at start is
other than 0
When Bias speed at start is 0
Bias speed at start
t
Set acceleration time = Actual acceleration time
Set deceleration time = Actual deceleration time
129
(2) Trapezoid acceleration/deceleration, S-curve acceleration/deceleration
Set an appropriate method by the positioning parameter "Acceleration/deceleration method selection".
(
Page 58, Section 7.3.1 (6))
When S-curve acceleration/deceleration is selected, the motor load can be reduced upon start and during
standstill.
V
Target speed
Bias speed at start
t
Acceleration
time
Deceleration
time
(3) Set acceleration/deceleration time and actual acceleration/deceleration time
Basically the acceleration/deceleration set by the parameter becomes the actual acceleration/deceleration, so the
speed limit does not affect the acceleration/deceleration time. However, the following differences apply depending
on the acceleration/deceleration method selected:
(a) Trapezoid acceleration/deceleration method
Both become equal regardless of whether the bias speed at start is 0 or not 0.
(b) S-curve acceleration/deceleration method
Since the final speed of deceleration becomes 1 pulse/s faster than the bias speed at start, the actual
deceleration time becomes longer than the set deceleration time. In this case, the actual deceleration time can
be shortened by setting the bias speed at start to other than 0.
(4) Precautions
• If the target speed is 1 pulse/s, the set acceleration/deceleration time is ignored.
• If the constant speed is not performed during operation (for example, when the axis starts decelerating to a
stop during acceleration/deceleration) , the axis does not operate at the set acceleration/deceleration time.
130
CHAPTER 7 POSITIONING FUNCTION
7.10.8
Stop processing function
1
The following explains the stop processing that takes place when a stop cause occurs during operation. The
deceleration time after the occurrence of a stop cause varies according to the specific control.
Control details
Positioning control
JOG operation
OPR control
After speed change
Deceleration time
• Positioning using the Table start instruction (IPPSTRT1(P)): Positioning data"Deceleration stop time"
• Positioning using the Positioning start instruction (IPDSTRT1(P)): Setting data "Deceleration stop time"
JOG DEC time set as control data in the JOG start instruction
OPR parameter "OPR deceleration stop time"
DEC/STOP time at speed change, set by the Speed change instruction (IPSPCHG1(P))
(1) Details of stop processing control
• When a stop cause occurs, the axis decelerates to the bias speed at start and then stops.
• If the axis reaches the specified position while decelerating following the occurrence of a stop cause, it stops
immediately.
(2) Stop cause
7
A stop cause occurs at the following conditions.
• Each control ends successfully
• An error occurs
• The Axis stop instruction (IPSTOP1) is executed
• A return operation occurs during target position change
The following shows operations when above conditions occur except "each control ends successfully".
Stop cause
Positioning
control
OPR control
JOG
operation
Target axis
operation status
(SD1844) after
stopping
Software upper stroke limit
Deceleration
Software lower stroke limit
to a stop
Hardware upper stroke limit
⎯
Deceleration to a
stop
Deceleration
Deceleration
Deceleration to a
to a stop
to a stop
stop
Deceleration
Deceleration
Deceleration to a
to a stop
to a stop
stop
Deceleration
Deceleration
Deceleration to a
to a stop
to a stop
stop
The Axis stop instruction (IPSTOP1) is
Deceleration
Deceleration
Deceleration to a
executed.
to a stop
to a stop
stop
⎯
⎯
Hardware lower stroke limit
Program execution is stopped.
Drive unit ready signal is off.
A return operation occurs during target
position change.
(Operating normally)
Deceleration
to a stop
For each axis
Error occurring (-1)
For each axis
(Except when OPR
Error occurring (-1)
retry is performed.)
All axes
Error occurring (-1)
For each axis
Error occurring (-1)
For each axis
Stopped (1)
⎯
⎯
131
7.10 Subfunction
7.10.8 Stop processing function
Axis 1 axis
(3) Stop processing during speed change
If the axis starts decelerating to a stop before the new speed value is reached, the actual deceleration stop time
may not become the same as the set value of "Deceleration stop time."
Ex. When a stop cause occurs in the middle of speed change during speed control
V
Interruption factor
Movement when no interruption occurred during speed change (dotted line)
When an interruption occurred after
reaching the target speed
Same inclination
New speed value
ACC/DEC time
DEC/STOP time
Bias speed
at start
t
Actual deceleration/stop time
Speed change
instruction execution
command
OFF
ON
(4) Stop processing during S-curve acceleration/deceleration
If a stop cause occurs while the axis is accelerating according to "S-curve acceleration/deceleration," the S-curve
needed to decelerate from the current speed is recalculated. The axis moves at a constant speed while the
calculation is in progress.
V
Movement when no interruption
occurred
Interruption factor
Operation time
(Up to 60 s)
t
Since pulses are output during constant-speed operation, the positioning address may be reached during
deceleration. In this case, the axis stops immediately upon reaching the positioning address.
(5) Stopping after simultaneous starting of two axes
The axes started by the Two axes simultaneous start instruction (IPSIMUL(P)) are not stopped simultaneously.
Each axis must be stopped separately. (
132
Page 103, Section 7.7.5)
CHAPTER 7 POSITIONING FUNCTION
1
(6) Pulse output processing upon stop
If the axis stops due to occurrence of a stop cause, pulse output currently in progress after elapse of the set
deceleration stop time after the start of deceleration stop will continue until one pulse is output. The actual
deceleration time may become longer by a maximum of 1s than the deceleration stop time. As indicated by the
calculation formula below, the extended deceleration stop time can be reduced by increasing the value of "Bias
speed at start."
Increase in
DEC/STOP time =
V
1
(S)
Bias speed at start
stop cause
Pulse being output at this point
will be completely output.
7
DEC/STOP time
t
Pulse
waveform
1 pulse
1 pulse
Depends on Bias speed
at start (up to 1s)
Deceleration/stop
completed
Even if the execution command for axis stop instruction is established in the middle of deceleration, the current
deceleration is continued until the axis stops. (
Page 156, Section 7.12.1 (7))
133
7.10 Subfunction
7.10.8 Stop processing function
(7) The Axis stop instruction (IPSTOP1) is executed
7.11
Absolute Position Restoration Function
The absolute position restoration function restores the absolute position of the specified axis using the absolute
position detection system. The Absolute position restoration function (IPABRST1) (
Page 154, Section 7.12.1 (6))
is used to adjust the Axis 1 current feed value (SD1840, SD1841) to the actual motor position. This way, machine OPR
is no longer necessary after the power was cut off due to a momentary power failure, emergency stop, etc., and the
onsite recovery work can be done easily.
(1) Configuration of Absolute position detection system
Battery for storing absolute position data
1)
Power
supply
Servo
amplifier
3)
Connector for control signals
Encoder cable
2)
Input
module
LCPU
Output
module
4) Programmable controller system
Servomotor with absolute encoder
Number
Component
1)
Servo amplifier*1
Description
• Install the battery in the servo amplifier.
• Enable the absolute position detection function of the servo amplifier.
For other details, refer to the instruction manual for the servo amplifier.
2)
Servomotor
3)
Encoder cable
4)
Programmable controller
system
*1
*2
134
• Use a servomotor with absolute position detector.
For other details, refer to the instruction manual for the servomotor.
• Wire the battery power connection lines (BAT/LG signals) to the incremental encoder cable.
For other details, refer to the instruction manual for the cables.
• Absolute position detection data is sent/received using general-purpose I/Os or the I/O unit
(three input points, three output points*2).
Any Mitsubishi general-purpose AC servomotor (pulse-train type) supporting absolute position detection systems.
The orders of three input points and three output points are determined, and the device numbers must be consecutive.
CHAPTER 7 POSITIONING FUNCTION
(2) Communication overview of absolute position detection data
As shown below, the detector consists of phase A/B/Z signals for position control during normal operation, an
encoder for detecting positions within one rotation, and an accumulative revolution counter for detecting the
rotation amount. This absolute position detection system always detects the absolute position of the machine and
stores it in a memory backed up by a battery, regardless of the power condition of the programmable controller
system. Accordingly, once the OP is initially set when the machine is installed*1, machine OPR is no longer
necessary at subsequent power-on operations and recovery also becomes easy in the event of a momentary
power failure or emergency stop. Also, absolute position data is backed up using a super capacitor in the
detector, which means that absolute position data is retained for a specified time even when the cable is
disconnected or breaks.
Servo amplifier
LCPU
Pulse train command
OP
Flash memory
LS0
1X0
Current feed value
(SD1840, SD1841)
Position
control
Speed
control
Current
position
Backed up at
power failure
I/O module
LS
Detected no.
of rotations
Input
Absolute position
restore instruction
(IPABRST1)
1X
Detected
position within
one rotation
7
Output
Battery
Servo motor
Accumulative revolution counter
(1 pulse/rev)
Super capacitor
High-speed serial
communication
Less-than-one revolution counter
(Encoder)
*1
Operation to output a deviation counter clear signal to the servo amplifier at the OP position. This operation must be
performed before absolute position restoration.
When other than Count2 is selected: Perform machine OPR, output a deviation counter clear signal.
When Count2 is selected: Wire a general-purpose output signal to the deviation counter clear signal line of the servo
amplifier ,perform JOG operation to adjust the position, and then turn the signal on.
135
7.11 Absolute Position Restoration Function
Phase A, B, and Z signals
(3) Connection example with a servo amplifier (MR-J3-A) manufactured by
Mitsubishi
For details, refer to the instruction manual for the MR-J3-A specification.
<Servo amplifier>
<Programmable controller system>
MR-J3-A
LCPU
22(ABSB0)
23(ABSB1)
25(ABST)
15(SON)
136
ABS transmission data bit 0
ABS transmission data bit 1
ABS transmission data ready
Servo on
17(ABSM)
ABS transfer mode
18(ABSR)
ABS request
0(X0)
1(X1)
General-purpose output or
16-point output module
2(X2)
0(Y0)
1(Y1)
2(Y2)
General-purpose input or
16-point input module
CHAPTER 7 POSITIONING FUNCTION
(a) Connector pin on servo side
Pin
Signal name
Abbreviation
Servo on
SON
15
ABS transfer mode
ABSM
17
Function/application
number
This signal is on when the servo amplifier is normal.
While this signal is on, the servo amplifier operates in the ABS transfer
mode and the functions of CN1-22, 23 and 25 conform to those shown in
this table.
ABS request flag
ABSR
18
ABS transmission data bit 0
ABSB0
22
ABS transmission data bit 1
ABSB1
23
ABS transmission data ready
ABST
25
This signal turns on when ABS data is requested in the ABS transfer mode.
Lower bit of the two ABS data bits to be transferred to the programmable
controller system from the servo in the ABS transfer mode.
Upper bit of the two ABS data bits to be transferred to the programmable
controller system from the servo in the ABS transfer mode.
This signal turns on when the ABS transmission data is ready in the ABS
transfer mode.
(4) Condition for starting positioning using the absolute position detection system
Use the system within the range where conditions 1 and 2 specified below are satisfied. If this range is exceeded,
the current value cannot be successfully restored by absolute position restoration.
7
(a) Condition 1: Number of output pulses
This is the numbe of pulses that can be output to the servo amplifier when positioning is performed from the OP
using the absolute position detection system. With the absolute position detection system, pulses within the
range calculated by the formula below, around the OP, can be output to the servo amplifier:
{-32678 x (Number of feedback pulses)}
Number of output pulses
{32768 x (Number of feedback pulses)
7.11 Absolute Position Restoration Function
-1}
The number of feedback pulses indicates pulses per servomotor rotation as recognized by the LCPU.
Ex. Number of feedback pulses = 8192: -268435456 (pulses) to 268435455 (pulses)
Number of feedback pulses = 16384: -536870912 (pulses) to 536870911 (pulses)
(b) Condition 2: Positioning address
Set an appropriate address within the settable range of "Positioning address/movement amount."
• Setting range: -2147483648 (pulses) to 2147483647 (pulses)
137
(5) Precautions
• With the absolute position detection system, the following controls cannot be performed:
• Feed control of the turntable, etc., for unlimited length in one direction only
• Control where the movement amount from the OP address exceeds the ranges of conditions 1 and 2
explained in
Page 137, Section 7.11 (4)
• With the Absolute position restoration function (IPABRST1), three consecutive bits starting from the input
signal and output signal set by the arguments are used, respectively. Do not mistakenly use them as I/O
signals for other purposes.
• If you have built an absolute position detection system, perform absolute position restoration at least once
after the power on or reset.
Important
When absolute position restoration is performed, the servo ON signal may turn off (thereby causing the servo to turn off) for
approx. 20 ms and the motor may move as a result. If this movement of motor may present problems, provide an
electromagnetic brake and lock the motor during absolute position restoration.
138
CHAPTER 7 POSITIONING FUNCTION
7.12
Dedicated Instructions
The following table lists and describes dedicated instructions for the positioning function.
Ex. The table start instruction for Axis 1 is IPPSTRT1(P), and for Axis 2 is IPPSTRT2(P).
Instruction
Axis 1
Axis 2
IPPSTRT1(P)
IPPSTRT2 (P)
Description
Start operation based on the desired data number specified from among "Positioning
data" Nos. 1 to 10 set beforehand using the programming tool.
Start positioning with data stored in the device specified by control data and
IPDSTRT1(P)
IPDSTRT2 (P)
subsequent devices, without using "Positioning data" Nos. 1 to 10 set beforehand
using the programming tool.
IPSIMUL(P)
Start positioning using the specified "Positioning data" number for Axis 1, and
positioning using the specified "Positioning data" number for Axis 2, simultaneously.
Reference
Page 140,
Section
7.12.1 (1)
Page 142,
Section
7.12.1 (2)
Page 145,
Section
7.12.1 (3)
Page 148,
IPOPR1(P)
IPOPR2 (P)
Start OPR of the specified axis based on the specified method.
Section
7.12.1 (4)
Page 151,
IPJOG1
IPJOG2
JOG operation of the specified axis is started.
Section
7
7.12.1 (5)
Page 154,
IPABRST1
IPABRST2
Perform absolute position restoration of the specified axis.
Section
7.12.1 (6)
Page 156,
IPSTOP1
IPSTOP2
Stop the operating axis.
Section
Page 158,
IPSPCHG1(P)
IPSPCHG2(P)
Change the speed of the specified axis.
Section
7.12.1 (8)
Page 161,
IPTPCHG1(P)
IPTPCHG2(P)
Change the target position of the specified axis.
Section
7.12.1 (9)
139
7.12 Dedicated Instructions
7.12.1 (7)
7.12.1
Details of dedicated instructions
(1) Table start instructions: IPPSTRT1(P), IPPSTRT2(P)
Command
IPPSTRT1
IPPSTRT1
n
IPPSTRT1P
n
IPPSTRT2
n
IPPSTRT2P
n
Command
IPPSTRT1P
Command
IPPSTRT2
Command
IPPSTRT2P
Internal device
Setting data
Bit
Word
⎯
n
J \
R, ZR
Bit
⎯
Word
Constant
Bit
Word
⎯
⎯
U \G
Z
⎯
K, H
$
Others
⎯
(a) Setting data
140
Setting data
Setting item
Setting range
Data type
n
Positioning data No.
1 to 10
BIN 16bit
⎯
CHAPTER 7 POSITIONING FUNCTION
(b) Function
• These instructions start operation based on the desired data number specified by "n" from among
"Positioning data" No. 1 to 10 set beforehand using the programming tool.
Ex. Timing chart when "Positioning data" No. 1 is executed
[IPPSTRT1 K1]
Starts positioning data No.1.
Axis 1 Positioning data
No.1
No.2
No.3
Control method
ACC/DEC time
DEC/STOP time
Dwell time
Command speed
Positioning address
No.9
No.10
v
Executes positioning data No.1.
t
ON
IPPSTART1 execution
command
OFF
ON
Axis 1 start instruction in OFF
execution (SM1848)
Axis 1 BUSY (SM1840) OFF
Axis 1 positioning complete
(SM1841)
7
ON
1)
2)
ON
OFF
2)
• When positioning control starts successfully, the Axis 1 busy (SM1840) turns on. (1))
• When positioning is complete, the Axis 1 busy (SM1840) turns off and Axis 1 positioning completion
(SM1841) turns on. (2))
• If the Axis stop instruction (IPSTOP1) is executed or an error is detected during positioning, the axis
decelerates to a stop and the Axis 1 positioning completion (SM1841) does not turn on.
The basic number of steps is 2.
(c) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When a value other than 1 to 10 is specified in "n":
(Error code: 4100)
• When an unusable device is specified in "n":
(Error code: 4101)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
(d) Program example
Program that starts "Positioning data" No. 1 for Axis 1 when M0 turns on
141
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
• The Axis 1 positioning completion (SM1841) will turn off the next time the applicable axis is started.
(2) Positioning start instructions: IPDSTRT1(P), IPDSTRT2(P)
Command
IPDSTRT1
IPDSTRT1
S
IPDSTRT1P
S
IPDSTRT2
S
IPDSTRT2P
S
Command
IPDSTRT1P
Command
IPDSTRT2
Command
IPDSTRT2P
Internal device
Setting data
Bit
Word
Bit
⎯
S
J \
R, ZR
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
Z
⎯
K, H
$
⎯
⎯
⎯
Others
⎯
(a) Setting data
Setting data
S
Setting item
Setting range
Data type
Device start number of the device
Within the specified range of
storing control data
devices
Device name
(b) Control data
Device
Item
Setting data
Setting range
Set by
1: Position control (ABS)
2: Position control (INC)
3: Speed/position switching control
(forward RUN)
Control System
S
4: Speed/position switching control
1 to 7
(reverse RUN)
5: Current value change
6: Speed control (forward RUN)
7: Speed control (reverse RUN)
⎯
0 to 32767 (ms)
Deceleration stop time
⎯
0 to 32767 (ms)
Dwell time
⎯
0 to 65535 (ms)*1
Command speed
⎯
0 to 200000 (pulse/s)*2
S
+1
S
+2
S
+3
S
+4
S
+5
S
+6
Positioning address/
+7
movement amount
S
*1
*2
142
Acceleration/
deceleration time
⎯
-2147483648 to 2147483647
(pulses)
In the program, enter the set values as follows:
1 to 32767: Enter as decimals.
32768 to 65535: Convert to hexadecimals and enter the resulting hexadecimals.
If the set value of command speed is outside 0 to 200000, the axis may operate at the speed limit.
User
CHAPTER 7 POSITIONING FUNCTION
(c) Function
• These instructions start positioning with data stored in the device specified by
S
and subsequent devices,
without using "Positioning data" Nos. 1 to 10 set beforehand using the programming tool.
Ex. Timing chart when position control is performed by setting the start device number in D0
[IPDSTRT1 D0]
Using values set for the specified device,
positioning is started.
Device
Control method
D0
D1
ACC/DEC time
D2
DEC/STOP time
Dwell time
D3
D4, D5 Command speed
D6, D7 Positioning address
Positioning data
No.1
Positioning data are not used.
to
No.10
V
7
Positioning execution
t
ON
OFF
Axis 1 start instruction
in execution (SM1848)
OFF
Axis 1 BUSY (SM1840)
OFF
Axis 1 positioning complete
(SM1841)
ON
1)
ON
2)
ON
2)
OFF
• When positioning control starts successfully, the Axis 1 busy (SM1840) turns on. (1))
• When positioning is complete, the Axis 1 busy (SM1840) turns off and Axis 1 positioning completion
(SM1841) turns on. (2)) (During speed control, causes that stop the axis include execution of the Axis stop
instruction (IPSTOP1) and aborted operation due to error detection. Accordingly, the Axis 1 positioning
completion (SM1841) does not turn on.)
• The Axis 1 positioning completion (SM1841) will turn off the next time the applicable axis is started.
• If operation cannot be started because
S
is outside the setting range, etc., the Axis 1 error (SM1845)
turns on.
• If the Axis stop instruction (IPSTOP1) is executed or an error is detected during positioning, the axis
decelerates to a stop and the Axis 1 positioning completion (SM1841) does not turn on.
The basic number of steps is 2.
(d) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When an unusable device is specified in
S
:
(Error code: 4101)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
143
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
IPDSTRT1(P) execution
command
(e) Program example
Program that starts Axis 1 based on the set positioning data below when M0 turns on
Device used
144
Item
Setting item
D0
Control method
Position control (ABS)
D1
Acceleration/deceleration time
1000 (ms)
D2
Deceleration stop time
1000 (ms)
D3
Dwell time
0 (ms)
D4, D5
Command speed
20000 (pulse/s)
D6, D7
Positioning address/movement amount
100000 (pulse)
CHAPTER 7 POSITIONING FUNCTION
(3) Two-axes simultaneous start instruction: IPSIMUL(P)
Command
IPSIMUL
IPSIMUL
n1
n2
IPSIMULP
n1
n2
Command
IPSIMULP
Internal device
Setting data
Bit
Word
J \
R, ZR
Bit
Word
Constant
Bit
Word
U \G
Z
K, H
$
Others
n1
⎯
⎯
⎯
⎯
⎯
⎯
⎯
n2
⎯
⎯
⎯
⎯
⎯
⎯
⎯
7
(a) Setting data
Setting data
Setting item
n1
Axis 1 positioning data No.
n2
Axis 2 positioning data No.
Setting range
Data type
1 to 10
BIN 16-bit
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
145
(b) Function
• This instruction start positioning using the "Positioning data" number for Axis 1 specified by "n1", and
positioning using the "Positioning data" number for Axis 2 specified by "n2", simultaneously.
Ex. Timing chart when positioning data No. 1 for Axis 1 and positioning data No. 10 for Axis 2 are started
simultaneously
V
Positioning execution
for axis 1
t
V
Positioning execution for axis 2
t
ON
IPSIMUL execution command
OFF
ON
Axis 1 start instruction in
execution (SM1848)
OFF
Axis 2 start instruction in
execution (SM1868)
OFF
Axis 1 BUSY (SM1840)
Axis 2 BUSY (SM1860)
Axis 1 positioning complete
(SM1841)
Axis 2 positioning complete
(SM1861)
ON
OFF
1)
ON
1)
ON
2)
2)
OFF
ON
OFF
3)
ON
3)
OFF
• When positioning control starts successfully, both of the Axis
busy signals (SM1840, SM1860) turn on.
(1))
• The Axis
busy (SM1840 or SM1860) turns off and Axis
positioning completion (SM1841 or SM1861)
turns on, starting from the axis whose positioning has completed. (2) (3))
• The Axis
positioning completion (SM1841 or SM1861) will turn off the next time the applicable axis is
started.
• If the Axis stop instruction (IPSTOP ) is executed for each axis or an error is detected during positioning,
the axis decelerates to a stop and the Axis
on.
The basic number of steps is three.
146
positioning completion (SM1841 or SM1861) does not turn
CHAPTER 7 POSITIONING FUNCTION
(c) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When a value other than 1 to 10 is specified in "n1" or "n2":
(Error code: 4100)
• When an unusable device is specified in "n1" or "n2":
(Error code: 4101)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
(d) Program example
Program that simultaneously starts positioning data No. 1 for Axis 1 and positioning data No. 10 for Axis 2
when M0 turns on
7
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
147
(4) Original position return start instructions: IPOPR1(P), IPOPR2(P)
Command
IPOPR1
IPOPR1
S
IPOPR1P
S
IPOPR2
S
IPOPR2P
S
Command
IPOPR1P
Command
IPOPR2
Command
IPOPR2P
Internal device
Setting data
Bit
Word
⎯
S
J \
R, ZR
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
⎯
Z
⎯
K, H
$
⎯
⎯
Others
⎯
(a) Setting data
Setting data
S
Setting item
Setting range
Device start number of the device storing
Within the specified range of
control data
devices
Data type
Device name
(b) Control data
Device
Item
Setting data
Setting range
Set by
1: Machine OPR
S
Original position return type
2: Fast OPR (OP address)
1 to 3
3: Fast OPR (standby address)
S
S
+1
+2
148
Standby address
-2147483648 to
(This address is set only when fast OPR
2147483647 (pulses)
(standby address (3)) is specified for original
position return type)
⎯
(Other than standby
address (3) is ignored)
User
CHAPTER 7 POSITIONING FUNCTION
(c) Function
• These instructions start OPR of the type specified by
S
Ex. Near-point dog method
V
Machine OPR execution
t
ON
IPOPR1(P) execution command
OFF
Near-point watchdog
signal
ON
OFF
Zero signal
Deviation counter
clear signal
10ms
ON
Axis 1 start instruction in
execution (SM1848)
Axis 1 BUSY (SM1840)
Axis 1 positioning
complete (SM1841)
Axis 1 OPR request
(SM1842)
2)
7
OFF
ON
2)
1)
OFF
ON
2)
1)
OFF
ON
2)
OFF
ON
2)
OFF
• When machine OPR starts successfully, the Axis 1 busy (SM1840) and Axis 1 OPR request (SM1842) turn
on. (1))
• When machine OPR is complete, the Axis 1 busy (SM1840) turns off and Axis 1 positioning completion
(SM1841) turns on. Also, the Axis 1 OPR request (SM1842) turns off and Axis 1 OPR completion
(SM1843) turns on. (2))
The Axis 1 OPR completion (SM1843) will turn off the next time the applicable axis is started.
• If operation cannot be started because
S
is outside the setting range, etc., the Axis 1 error (SM1845)
turns on.
• If the Axis stop instruction (IPSTOP1) is executed or an error is detected during machine OPR, the axis
decelerates to a stop and the Axis 1 OPR completion (SM1843) does not turn on.
149
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
Axis 1 OPR complete
(SM1843)
The following operations take place in the case of fast OPR:
V
OP or standby address
Fast OPR
t
ON
IPOPR1(P) execution command
OFF
ON
Axis 1 start instruction in
execution (SM1848)
OFF
Axis 1 BUSY (SM1840)
ON
2)
1)
OFF
ON
2)
Axis 1 positioning complete
(SM1841)
• When fast OPR starts successfully, the Axis 1 busy (SM1840) turns on. (1))
• When fast OPR is complete, the Axis 1 busy (SM1840) turns off and Axis 1 positioning completion
(SM1841) turns on. (2))
• The Axis 1 positioning completion (SM1841) will turn off the next time the applicable axis is started.
• If operation cannot be started because
S
is outside the setting range, etc., the Axis 1 error (SM1845)
turns on.
• If the Axis stop instruction (IPSTOP1) is executed or an error is detected during fast OPR, the axis
decelerates to a stop and the Axis 1 positioning completion (SM1841) does not turn on.
The basic number of steps is 2.
(d) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When an unusable device is specified in
S
:
(Error code: 4101)
• When the OPR Method for the target axis is set to "No method":
(Error code: 4116)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
(e) Program example
Program that starts machine OPR of Axis 1 when M0 turns on
150
Device used
Item
Setting item
D0
Original position return type
Machine OPR
D1, D2
Standby address
0 (Ignored)
CHAPTER 7 POSITIONING FUNCTION
(5) JOG start instructions: IPJOG1, IPJOG2
Command
IPJOG1
IPJOG1
S1
S2
IPJOG2
S1
S2
Command
IPJOG2
Internal device
Setting data
Bit
Word
⎯
S1
J \
R, ZR
Bit
Word
⎯
⎯
S2
⎯
Constant
U \G
Bit
Word
⎯
⎯
⎯
⎯
⎯
⎯
Z
Others
K, H
$
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
7
(a) Setting data
Setting data
S1
Setting item
Setting range
Device start number of the device
Within the specified range of
storing control data
devices
Data type
Device name
Specification of JOG operation direction
0,1
Bit
1: Reverse RUN
(b) Control data
Device
S1
*1
Setting data
Setting range
JOG speed
0 to 200000 (pulse/s)*1
S1 +
1
S1 +
2
JOG ACC time
S1 +
3
JOG DEC time
Set by
User
0 to 32767 (ms)
If the set value of JOG speed is outside 0 to 200000, the axis may operate at the speed limit.
151
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
0: Forward RUN
S2
(c) Function
• These instructions perform JOG operation in the direction specified by
ACC time and JOG DEC time stored in
S1
S2
using the JOG speed, JOG
onwards.
Decelerating by JOG DEC time
Accelerating by JOG ACC time
V
JOG speed
JOG operation
t
ON
IPJOG1 execution command OFF
ON
Axis 1 start instruction in
OFF
execution (SM1848)
Axis 1 BUSY (SM1840) OFF
Axis 1 positioning complete
(SM1841)
1)
ON
2)
ON
2)
OFF
• When JOG operation starts successfully, the Axis 1 busy (SM1840) turns on. (1))
• When JOG operation ends, the Axis 1 busy (SM1840) turns off but the Axis 1 positioning completion
(SM1841) does not turn on. (2))
• If operation cannot be started because
S1
is outside the setting range, etc., the Axis 1 error (SM1845)
turns on.
The basic number of steps is 3.
(d) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When an unusable device is specified in
S1 , S2
:
(Error code: 4101)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
152
CHAPTER 7 POSITIONING FUNCTION
(e) Program example
Program that starts forward JOG when M0 turns on, and reverse JOG when M1 turns on.
Device used
Item
Setting item
D0, D1
JOG speed
10000 (pulse/s)
D2
JOG ACC time
D3
JOG DEC time
1000 (ms)
7
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
153
(6) Absolute position restoration instructions: IPABRST1, IPABRST2
Command
IPABRST1
IPABRST1
S
D
IPABRST2
S
D
Command
IPABRST2
Internal device
Setting data
Bit
Word
J \
R, ZR
Bit
Word
Constant
Bit
Word
U \G
Z
K, H
$
Others
S
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
D
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
(a) Setting data
Setting data
Setting item
S
Start input device number
D
Setting range
Start output device number
Data type
Within the specified range of
devices
Device name
Within the specified range of
devices
(b) Control data
Device
Item
+1
S
+2
Device
Signal loaded from
the servo amplifier
154
+1
D
+2
Set by
ABS transmission data bit 1
0,1
User
Setting range
Set by
⎯
System
ABS transmission data ready
Item
Setting data
Servo on
D
D
Setting range
ABS transmission data bit 0
S
S
Setting data
Signal output to the
servo amplifier
ABS transfer mode
ABS request flag
CHAPTER 7 POSITIONING FUNCTION
(c) Function
• These instructions perform absolute position restoration of the specified axis via communication with the
servo amplifier using the input device and output device specified by
S
and
D
, respectively.
ON
IPABRST1(P) execution
command
OFF
ON
Axis 1 start instruction in
execution (SM1848) OFF
Axis 1 BUSY (SM1840) OFF
2)
ON
Axis 1 positioning complete
(SM1841)
Axis 1 operation status
(SD1844)
ON
1)
2)
OFF
Standby (0)
Analyzing (11)
Axis 1 current feed value
(SD1840, SD1841)
Standby (0)
Value read from servo amplifier
• When absolute position restoration starts successfully, the Axis 1 busy (SM1840) turns on. 1)
• The current position data retained by the servo amplifier is read. The read data is stored in the Axis 1
current feed value (SD1840, SD1841).
• When absolute position restoration is complete, the Axis 1 busy (SM1840) turns off and Axis 1 positioning
7
completion (SM1841) turns on.
• The Axis 1 positioning completion (SM1841) will turn off the next time the applicable axis is started. 2)
• The Axis stop instruction (IPSTOP1) is ignored during absolute position restoration.
• If an error occurs during absolute position restoration, the Axis 1 positioning completion (SM1841) does
not turn on.
(d) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When an unusable device is specified in
S
,
D
:
(Error code: 4101)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
(e) Program example
Program that performs absolute position restoration of Axis 1 when M0 turns on
• X20 to X22: Signal loaded from the servo amplifier
• Y30 to Y32: Signal output to the servo amplifier
155
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
The basic number of steps is 3.
(7) Axis stop instructions: IPSTOP1, IPSTOP2
Command
IPSTOP1
IPSTOP1
Command
IPSTOP2
IPSTOP2
Internal device
Setting data
⎯
156
Bit
Word
⎯
⎯
J \
R, ZR
Bit
Word
⎯
⎯
Constant
Bit
Word
⎯
⎯
U \
⎯
Z
⎯
K, H
$
⎯
⎯
Others
⎯
CHAPTER 7 POSITIONING FUNCTION
(a) Function
• These instructions stop the operation of the specified axis.
Ex. Timing chart when the positioning started by the Table start instruction (IPPSTRT1(P)) is stopped
V
Positioning execution
t
ON
IPPSTRT1(P) execution command
OFF
ON
IPSTOP1 execution command OFF
Axis 1 start instruction in
execution (SM1848)
Turn it on more than 2ms.
This command may not be
detected in the case of 2ms
or less.
ON
OFF
ON
Axis 1 BUSY (SM1840)
OFF
ON
Axis 1 positioning complete
(SM1841)
OFF
7
The positioning complete signal
does not turn on.
• No processing is performed if IPSTOP1 is executed while the Axis 1 axis operation status (SD1844) is
indicating one of the following values:
Standing by (0)
Stopped (1)
Decelerating (axis stop ON) (7)
Decelerating (JOG start OFF) (8)
Analyzing (11)
• If an attempt is made to start positioning while IPSTOP1 is still being executed, a "Stop instruction ON at
start" error (Axis 1 error code: 1102) occurs and positioning does not start.
• When the deceleration stop is complete due to IPSTOP1, the Axis 1 positioning completion (SM1841)
does not turn on.
The basic number of step is 1.
(b) Operation error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
(c) Program example
Program that stops Axis 1 when M0 turns on
157
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
Error occurring (-1)
(8) Speed change instructions: IPSPCHG1(P), IPSPCHG2(P)
Command
IPSPCHG1
IPSPCHG1
S
IPSPCHG1P
S
IPSPCHG2
S
IPSPCHG2P
S
Command
IPSPCHG1P
Command
IPSPCHG2
Command
IPSPCHG2P
Internal device
Setting data
Bit
Word
⎯
S
J \
R, ZR
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
Z
⎯
⎯
K, H
$
⎯
⎯
Others
⎯
(a) Setting data
Setting data
S
Setting item
Setting range
Data type
Device start number of the device
Within the specified range of
storing control data
devices
Device name
(b) Control data
Device
Setting data
S
ACC/DEC time at speed change
*1
158
S
+1
S
+2
S
+3
DEC/STOP time at speed change
New speed value
Setting range
Set by
0 to 32767 (ms)
User
0 to 200000
(pulse/s)*1
If the set new speed value is outside 0 to 200000, the axis may operate at the speed limit.
CHAPTER 7 POSITIONING FUNCTION
(c) Function
• These instructions change the speed using the ACC/DEC at speed change, DEC/STOP time at speed
change and new speed value stored in
onward.
S
Ex. Timing chart when the speed is changed during positioning which was started by the Table start instruction
(IPPSTRT1(P))
Accelerating by ACC/DEC time at speed change
V
Decelerating by DEC/STOP time
at speed change
Accelerating by
"ACC/DEC time"
New speed value
Positioning execution
t
ON
IPPSTRT1(P) execution command
OFF
ON
IPSPCHG1(P) execution command
OFF
Axis 1 BUSY (SM1840)
7
ON
Axis 1 start instruction in
execution (SM1848) OFF
ON
OFF
Axis 1 positioning complete
(SM1841)
ON
OFF
• If IPSPCHG1(P) is executed while the Axis 1 axis operation status (SD1844) is indicating one of the
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
following values, the instruction is ignored:
Standing by (0)
Stopped (1)
Error occurring (-1)
Decelerating (axis stop ON) (7)
Decelerating (JOG start OFF) (8)
Analyzing (11)
The basic number of steps is two.
(d) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When an unusable device is specified in
S
:
(Error code: 4101)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
159
(e) Program example
Program that changes the Axis 1 speed when M0 turns on
Device used
160
Item
Setting item
D0
ACC/DEC time at speed change
2000 (ms)
D1
DEC/STOP time at speed change
1000 (ms)
D2, D3
New speed value
20000 (pulse/s)
CHAPTER 7 POSITIONING FUNCTION
(9) Target position change instructions: IPTPCHG1(P), IPTPCHG2(P)
Command
IPTPCHG1
IPTPCHG1
S
IPTPCHG1P
S
IPTPCHG2
S
IPTPCHG2P
S
Command
IPTPCHG1P
Command
IPTPCHG2
Command
IPTPCHG2P
Internal device
Setting data
Bit
Word
⎯
S
J \
R, ZR
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
Z
K, H
⎯
$
Others
⎯
⎯
7
(a) Setting data
Setting data
Setting item
Setting range
• Target position change value (constant)
data
• Constant: -2147483648 to
2147483647
• Constant: BIN 32 bits
• Device: Within the specified range
• Device: Device name
of devices
(b) Control data
Device
S
S
+1
Setting data
Target position change value
Setting range
-2147483648 to 2147483647
(pulses)
Set by
User
161
7.12 Dedicated Instructions
7.12.1 Details of dedicated instructions
• Device start number of the device storing control
S
Data type
(c) Function
• These instructions change the target position to the new value specified by
S
.
Ex. Timing chart when the address is changed during positioning which was started by the Table start
instruction (IPPSTRT1(P))
V
Positioning execution
t
ON
IPPSTRT1(P) execution command
New target position First target position
OFF
ON
IPTPCHG1(P) execution command OFF
Axis 1 start instruction in
execution (SM1848)
ON
OFF
ON
Axis 1 BUSY (SM1840)
OFF
ON
Axis 1 positioning complete
(SM1841)
OFF
• No processing is performed if IPTPCHG1(P) is executed while the Axis 1 axis operation status (SD1844)
is indicating one of the following values:
Standing by (0)
Stopped (1)
Error occurring (-1)
Decelerating (axis stop ON) (7)
Decelerating (JOG start OFF) (8)
Analyzing (11)
The basic number of steps is 2.
(d) Error
If an operation error occurs, the error flag (SM0) turns on and the corresponding error code is stored in SD0.
• When an unusable device is specified in
S
:
(Error code: 4101)
• When the positioning function for the target axis is not set to "Use":
(Error code: 4116)
(e) Program example
Program that changes the target position of Axis 1 to 2000 when M0 turns on
162
CHAPTER 7 POSITIONING FUNCTION
7.12.2
Precautions on dedicated instructions
(1) Multiple instruction executions
(a) Axis 1 start instruction (SM1848) and execution of instructions
When the Axis 1 start instruction (SM1848) is on, any attempt to perform positioning of the same axis by each
of the following instructions is ignored. (If an instruction to start positioning is executed again after the Axis 1
start instruction (SM1848) has turned off, positioning starts even when the Axis 1 start during operation
(SM1847) is on.)
• IPPSTRT1(P)
• IPDSTRT1(P)
• IPSIMUL(P)
• IPOPR1(P)
• IPJOG1
• IPABRST1
(b) Multiple executions during one scan
If each of the following instructions is used multiple times on the same axis during one scan, normal operation
cannot be guaranteed.
7
• IPJOG1
• IPSTOP1
(2) Program executed only once and execution of instructions
If the following instructions are executed in a program which is executed only once, turning off of execution
commands cannot be detected and thus normal operation is not possible. Use these instructions in a program
• IPJOG1
• IPSTOP1
(3) Axis 1 axis operation status (SD1844) and execution of instructions
If IPSTOP1, IPSPCHG1(P) or IPTPCHG1(P) is executed while the Axis 1 axis operation status (SD1844) is
indicating one of the following values, the instruction is ignored:
• Standing by (0)
• Stopped (1)
• Error occurring (-1)
• Decelerating (axis stop ON) (7)
• Decelerating (JOG start OFF) (8)
• Analyzing (11)
(4) Instructions not requiring execution command
The following instructions are always executed, which means that they are executed even when their execution
command is off. Accordingly, an error occurs, if it is bound to occur when the instruction is executed, even when
the execution command is off:
• IPJOG1
• IPSTOP1
163
7.12 Dedicated Instructions
7.12.2 Precautions on dedicated instructions
where turning off of execution commands can be detected (such as a scan program).
(5) Pulse instructions
IPPSTRT1P, IPSIMULP and other pulse instructions are executed at the leading edge of their execution
command. If these instructions are used in an interrupt program or subroutine, they are not executed until the until
the second or later leading edge of the their execution command.
Ex. Executing IPPSTRT1P in an interrupt program
X0
END
0
I0
X0
X0
IPPSTRT1P
IRET
IPPSTRT1P
I0
IRET
END
0
IPPSTRT1P
I0
IRET
END
0
ON
X0
OFF
IPPSTRT1P is not executed even if
the execution condition is on because
no change was made since the previous
interrupt program execution."
IPPSTRT1P
OFF
Execution of IPPSTRT1P
(6) Precautions on IPSTOP1
(a) IPSTOP1 and positioning control
If an attempt is made to start positioning control while IPSTOP1 is still being executed, a "Stop instruction ON
at start" error (Axis 1 error code: 1102) occurs and positioning does not start.
(b) IPSTOP1 and Axis 1 positioning completion (SM1841)
When the deceleration stop is complete due to IPSTOP1, the Axis 1 positioning completion (SM1841) does not
turn on.
(c) Execution command for IPSTOP1
The execution command for IPSTOP1 must remain on for at least 2 ms. If the execution command does not
remain on for at least 2 ms, it may not be detected.
(7) Speed setting
If the speed set for IPDSTRT1(P), IPJOG1 or IPSPCHG1(P) is outside 0 to 200000, the axis may operate at the
speed limit.
164
CHAPTER 7 POSITIONING FUNCTION
7.13
Programming
This section describes the programs for the positioning function. When applying the program examples introduced in
this section to an actual system, ensure the applicability and confirm that it will not cause system control problems.
7
7.13 Programming
165
(1) Programming procedure
Start
NO
Use positioning data set with
the programming tool?
YES
Data setting programs
Position control (ABS)
Position control (INC)
Speed/position switching control (forward)
Speed/position switching control (reverse)
Current value change
Speed control (forward)
Speed control (reverse)
Page 171, Section 7.13 (3)
Perform original point
return (OPR)?
YES
OPR data setting
Machine OPR
Fast OPR (OP address)
Fast OPR (standby address)
NO
OPR request OFF program
Page 172, Section 7.13 (3) (b)
Page 172, Section 7.13 (3)
OPR start program
Page 173, Section 7.13 (3) (d)
Page 173, Section 7.13 (3) (e)
(When table data are used)
Positioning start programs
Position control (ABS)
Position control (INC)
Speed/position switching control (forward)
Speed/position switching control (reverse)
Current value change
Speed control (forward)
Speed control (reverse)
Table start program
Page 173, Section 7.13 (3) (f)
Page 173, Section 7.13 (3) (g)
JOG operation program
Page 174, Section 7.13 (3) (h)
Speed change program
Page 174, Section 7.13 (3) (i)
Target position change program
Page 174, Section 7.13 (3) (j)
Absolute position restoration program
Page 174, Section 7.13 (3) (k)
Error reset program
Page 174, Section 7.13 (3) (l)
Axis stop program
Page 174, Section 7.13 (3) (m)
End
166
Speed/position switching enable program
(When a speed/position switching control is executed)
(When positioning data are set with programs)
CHAPTER 7 POSITIONING FUNCTION
(2) System configuration and programing condition
The following system configuration is used to introduce program examples.
(a) System configuration
LCPU
Servo amplifier
M
Servomotor
LY42NT1P (Y60 to Y9F)
X50 to X52 (for absolute
position restoration)
Y60 to X62
(for absolute position restoration)
LX42C4 (X20 to X5F)
7
7.13 Programming
167
(b) Programming conditions
Device
X30
X31
Function
Stop command
Axis 1 machine original position return start
selection
X32
Axis 1 fast OPR (OP address) start selection
X33
Axis 1 fast OPR (standby address) start selection
X34
Axis 1 original position return start command
X35
Axis 1 positioning start command (table start)
X36
Current start command
X37
Axis 1 position control (ABS) start selection
X38
Axis 1 position control (INC) start selection
X39
Axis 1 speed control (forward run) start selection
X3A
Axis 1 speed control (reverse run) start selection
X3B
X3C
Axis 1 speed-position switching control (forward run)
start selection
Axis 1 speed-position switching control (reverse run)
start selection
X3D
Axis 1 current value change selection
X3E
Axis 1 positioning start instruction
X40
Axis 1 forward run JOG command
X41
Axis 1 reverse run JOG command
X42
Speed change command
X43
Target position change command
X44
Error reset command
X45
OPR request off command
X46
Absolute position restoration
X47
Axis 1 speed/position switching command
X48
X50
X51
X52
LX42C4 (X20 to X5F)
Axis 1 speed/position switching prohibition
command
Absolute position restoration ABS transmission data
bit 0
Absolute position restoration ABS transmission data
bit 1
Absolute position restoration Transmission data
ready
Y60
Absolute position restoration Servo on
Y61
Absolute position restoration ABS transfer mode
Y62
Absolute position restoration ABS request
LY42NT1P (Y60 to Y9F)
(To the next page)
168
CHAPTER 7 POSITIONING FUNCTION
Device
Function
D0
Table start number
D1
Concurrent start data No. (axis 1)
D2
Concurrent start data No. (axis 2)
D20
D21
JOG speed
D22
JOG ACC time
D23
JOG DEC time
D30
ACC/DEC time at speed change
D31
DEC/STOP time at speed change
D32
D33
D40
D41
New speed value
Target position change value
D100
Control method
D101
Acceleration/deceleration time
D102
Deceleration stop time
D103
D104
Position control (ABS) start data
7
Dwell time
Command speed
D105
D106
Positioning address/movement amount
D107
D110
Control method
Acceleration/deceleration time
Deceleration stop time
D113
D114
Position control (INC) start data
Dwell time
Command speed
D115
D116
Positioning address/movement amount
D117
D120
Control method
D121
Acceleration/deceleration time
D122
Deceleration stop time
D123
D124
Speed/position switching control (forward) start data
Dwell time
Command speed
D125
D126
Positioning address/movement amount
D127
D130
Control method
D131
Acceleration/deceleration time
D132
Deceleration stop time
D133
D134
D135
D136
D137
Speed/position switching control (reverse) start data
Dwell time
Command speed
Positioning address/movement amount
(To the next page)
169
7.13 Programming
D111
D112
Device
Function
D140
Control method
D141
Acceleration/deceleration time
D142
Deceleration stop time
D143
D144
Current value change start data
Command speed
D145
D146
Positioning address/movement amount
D147
D150
Control method
D151
Acceleration/deceleration time
D152
Deceleration stop time
D153
D154
Speed control (forward run) start data
Dwell time
Command speed
D155
D156
Positioning address/movement amount
D157
D160
Control method
D161
Acceleration/deceleration time
D162
Deceleration stop time
D163
D164
Speed control (reverse run) start data
D166
Positioning address/movement amount
D167
D200
Original position return type
D201
Machine OPR start data
D202
D210
D211
D220
M10
Axis 1 OPR start permission/prohibition storage
M20
Forward run JOG command
M21
Reverse run JOG command
M22
JOG operation direction
Z1
Standby address (unused)
Original position return type
Standby address of fast OPR start data
D222
Z0
Standby address (unused)
Original position return type
OP address of fast OPR start data
D212
D221
Dwell time
Command speed
D165
170
Dwell time
OPR parameter index
Positioning data index
SM1840
Axis 1 busy signal
SM1842
Requested
SM1845
Axis 1 error
SM1848
Axis 1 start instruction
SM1850
Axis 1 error reset command
SM1851
Axis 1 OPR request off
SM1868
Axis 2 start instruction
Standby address
CHAPTER 7 POSITIONING FUNCTION
(3) Program example
Positioning programs for Axis 1 are shown below.
(a) Data setting program
• Position control
Control method: Position control (ABS)
ACC/DEC time: 1000ms
DEC/STOP time: 1000ms
Dwell time: 100ms
Command speed: 30000 pulses/s
Positioning address/movement
amount: 250000 pulses
Control method: Position control (INC)
ACC/DEC time: 1000ms
DEC/STOP time: 1000ms
7
Dwell time: 100ms
Command speed: 30000 pulses/s
Positioning address/movement
amount: 250000 pulses
• Speed/position switching control
7.13 Programming
Control method: Speed/position
switching control (forward run)
ACC/DEC time: 1000ms
DEC/STOP time: 1000ms
Dwell time: 100ms
Command speed: 30000 pulses/s
Positioning address/movement
amount: 250000 pulses
Control method: Speed/position
switching control (reverse run)
ACC/DEC time: 1000ms
DEC/STOP time: 1000ms
Dwell time: 100ms
Command speed: 30000 pulses/s
Positioning address/movement
amount: 250000 pulses
171
• Current value change
Control method: Current value change
ACC/DEC time: 0ms
DEC/STOP time: 0ms
Dwell time: 0ms
Command speed: 0 pulses/s
Positioning address/movement
amount: 250000 pulses
• Speed control
Control method: Speed control
(forward run)
ACC/DEC time: 1000ms
DEC/STOP time: 1000ms
Dwell time: 0ms
Command speed: 30000 pulses/s
Positioning address/movement
amount: 0 pulses
Control method: Speed control
(reverse run)
ACC/DEC time: 1000ms
DEC/STOP time: 1000ms
Dwell time: 0ms
Command speed: 30000 pulses/s
Positioning address/movement
amount: 0 pulses
(b) OPR request off program
Axis1 OPR request off: On
Axis1 OPR request off: Off
(c) OPR data setting program
OPR type: Machine OPR
Standby address: Not used
OPR type: Fast OPR
Standby address: Not used
OPR type: Fast OPR
Standby address: 10000 pulses
172
CHAPTER 7 POSITIONING FUNCTION
(d) OPR start program
Selection of OPR type: Machine OPR
Axis 1 OPR enable/disable setting: On
Selection of OPR type: Fast OPR
(OP address)
Axis 1 OPR enable/disable setting: On
Axis 1 OPR enable/disable setting: Off
Selection of OPR type: Fast OPR
(standby address)
Axis 1 OPR enable/disable setting: On
Axis 1 OPR enable/disable setting: Off
Dedicated instruction (IPOPR1)
(e) Speed/position switching enable program
Axis 1 speed/position switching: On
Axis 1 speed/position switching: Off
7
(f) Table start program
Axis 1 data No. of positioning being
executed: 1
Dedicated instruction (IPPSTRT1)
(g) Positioning start program
Selection of positioning control (ABS)
Selection of positioning control (INC)
Selection of speed/position switching
control (forward run)
Selection of speed/position switching
control (reverse run)
Selection of current value change
Selection of speed control
(forward run)
Selection of speed control
(reverse run)
Dedicated instruction (IPDSTRT1)
173
7.13 Programming
Axis 1 data No. of positioning being
executed: 1
Axis 2 data No. of positioning being
executed: 10
Dedicated instruction (IPSIMUL)
(h) JOG operation program
Direction of JOG operation:
Forward run
Forward JOG command
Direction of JOG operation:
Reverse run
Reverse JOG command
JOG speed (forward run):
10000 pulses/s
JOG ACC time: 10000s
JOG DEC time: 10000s
Dedicated instruction (IPJOG1)
(i) Speed change program
ACC/DEC time at speed change:
1000ms
DEC/STOP time at speed change:
1000ms
New speed value: 20000 pulses/s
Dedicated instruction (IPSPCHG1)
(j) Target position change program
Target position change value:
200000 pulses
Dedicated instruction (IPTPCHG1)
(k) Absolute position restoration program
Dedicated instruction (IPABRST1)
(l) Error, warning reset program
Axis 1 error reset: On
Axis 1 error reset: Off
Dedicated instruction (IPSTOP1)
(m) Axis stop program
Dedicated instruction (IPSTOP1)
174
CHAPTER 7 POSITIONING FUNCTION
7.14
Errors and Warnings
This section describes errors and warnings of the positioning function.
(1) Error
When an error occurs, the following operations are performed.
• The I/O ERR. LED turns on.
• The Axis 1 error (SM1845) turns on.
• An error code corresponding to the error is stored to the Axis 1 error code (SD1845) in decimal.
• The Axis 1 axis operation status (SD1844) changes to error occurring (-1).
If an error occurs during operation, the axis decelerates to a stop. (This excludes situations that the range of
software stroke limits is exceeded when the target position is changed.) (
Interface
Special relay
Special registers
Number
SM1845
Axis 2
SM1865
Axis 1
SM1850
Axis 2
SM1870
Axis 1
SD1845
Axis 2
SD1865
Axis 1
SD1844
Axis 2
SD1864
Name
Description
The occurrence condition of positioning function
Axis
error
errors is indicated. This relay turns off when the axis
error reset is turned on.
Axis
error reset
• Reset the axis
error code.
• Turn off the axis
error.
When an error occurs, the corresponding error code
Axis
error code
7
is stored here. This register is reset when the axis
error reset is turned on.
Axis
axis
operation status
When an error occurs, error occurring (-1) is set.
When the axis
error reset is turned on, the value
changes to error standing by (0).
Until the Axis 1 busy (SM1840) turns off, the Axis error (SM1845) does not turn off even when the Axis 1 error reset
(SM1850) is turned on, and accordingly the Axis 1 error code (SD1845) is not reset. Also, the Axis 1 axis operation
status (SD1844) does not change to 0: Standing by.
175
7.14 Errors and Warnings
*1
Axis
Axis 1
Page 127, Section 7.10.6 (2) (b))
The following table lists the Axis
Axis
error codes.
error
code
(decimal)
Axis 1
Axis 2
1100
2100
Name
Hardware stroke
limit+
Description
Operation at error
The hardware stroke limit
At start: Operation starts from a
(upper limit signal) turned
off.
position where the limit signal is on.
• At start: Operation is not
started.
1101
2101
Hardware stroke
limit-
The hardware stroke limit
(lower limit signal) turned
off.
Corrective action
occurrence
• During operation: The
axis decelerates to a
stop.
During operation:
• Revise the OPR speed so that the
limit will not be triggered.
• Use JOG operation to move to a
position where the limit signal turns
on.
A start request was issued
1102
2102
Stop instruction
at start ON
when the Axis stop
instruction (IPSTOP1) was
Stop the execution of the Axis stop
Operation is not started.
operation.
being executed.
• Positioning control was
performed at a position
exceeding the software
upper stroke limit.
• The Axis 1 current feed
1103
2103
Software stroke
limit+
value (SD1840,
SD1841), "Positioning
address/movement
amount," new current
value or target position
change value exceeds
the software upper
stroke limit.
• Positioning control was
performed at a position
below the software
lower stroke limit.
• The Axis 1 current feed
1104
2104
Software stroke
limit-
value (SD1840,
SD1841), "Positioning
address/movement
amount," new current
value or target position
change value exceeds
the software lower
stroke limit.
instruction (IPSTOP1) and then start
At start: Operation is not
started.
At current value change
analysis: The current value
is not changed.
During operation:
• During JOG operation,
the axis decelerates to a
stop when the Axis 1
current feed value
(SD1840, SD1841)
exceeds the range of
software stroke limits.
• During position control
(including position control
of speed/position
switching control), the
axis decelerates to a stop
when the Axis 1 current
feed value (SD1840,
SD1841) or "Positioning
address/movement
amount" exceeds the
range of software stroke
limits.
At start: Use JOG operation to bring
the Axis 1 current feed value (SD1840,
SD1841) to within the range of
software stroke limits.
Current value change: Bring the new
current value to within the range of
software stroke limits.
Target position change value: Bring the
target position change value to within
the range of software stroke limits.
During operation:
• In the case of JOG operation,
perform JOG operation in the
opposite direction to bring the Axis 1
current feed value (SD1840,
SD1841) to within the range of
software stroke limits.
• During position control, bring
"Positioning address/movement
amount" to within the range of
software stroke limits.
• During speed/position switching
control, switch between speed
control and position control within
the range of software stroke limits.
• During operation: The
During
operation
1105
2105
Sequence
Execution
stopped*1
axis decelerates to a
The CPU unit stopped
during operation.
stop.
• During absolute position
restoration: Absolute
Review the program to check for
program errors.
position restoration is not
performed.
*1
This error is not displayed when the LCPU is paused.
(To the next page)
176
CHAPTER 7 POSITIONING FUNCTION
Axis
error
code
(decimal)
Axis 1
Name
Description
Operation at error
occurrence
Axis 2
• At start: Operation is not
1106
Corrective action
2106
Drive unit
ready off
The drive unit ready signal is off
at start or turned off during
operation.
started.
• During operation: The
axis decelerates to a
stop.
Check the power condition of the
drive unit, wiring with the drive unit,
and connection condition of
connectors.
The OPR method is Stopper 2
1200
2200
Zero signal ON
or 3 and a zero signal is input at
Machine OPR control is not
Turn off the zero signal and then
the start of machine OPR
performed.
perform machine OPR control.
Fast OPR control is not
Perform machine OPR control
performed.
before fast OPR control.
control.
1201
2201
Machine OPR
not performed
Fast OPR control was
performed when machine OPR
control was not performed.
• At start of OPR control
by near-point dog
1202
2202
Retry error
method: OPR retry
Correct the limit signal position so
The near-point dog signal is on
operation is not
that it does not overlap with the area
and limit signal is off.
performed
in which the near-point dog signal
• During OPR retry
7
turns on.
operation: The axis
decelerates to a stop.
Communication could not be
1204
2204
ABS transfer
time-out
Absolute position
servo amplifier following the
restoration is not
Absolute position restoration
performed.
instruction (IPABRST1).
Communication could not be
1205
2205
ABS transfer
SUM
performed normally with the
Absolute position
servo amplifier following the
restoration is not
Absolute position restoration
performed.
instruction (IPABRST1).
1500
2500
Speed 0 error
Control
1501
2501
method out of
range
The command speed is "0" at
the start of position control.
The set value of control method
is outside the setting range.
Operation is not started.
Operation is not started.
Review the wirings.
Review the setting data of the
Absolute position restoration
instruction (IPABRST1).
Review the wirings.
Review the setting data of the
Absolute position restoration
instruction (IPABRST1).
Set the command speed to other
than "0."
Set the control method to a value
within the setting range.
At start: Operation is not
started.
During operation:
• During speed control
1502
2502
Acceleration/
The set value of JOG ACC
deceleration
time, acceleration/deceleration
time
time or ACC/DEC time at speed
Out of setting
range
change is outside the setting
range.
(including speed control
of speed/position
Set the JOG ACC time,
switching control) or JOG
acceleration/deceleration time or
operation, the axis
ACC/DEC time at speed change to
decelerates to a stop.
a value within the setting range.
• During position control
(including position
control of speed/position
switching control),
operation continues.
(To the next page)
177
7.14 Errors and Warnings
performed normally with the
Axis
error
code
Name
Description
Operation at error
occurrence
(decimal)
Corrective action
At start: Operation is not
started.
During operation:
• During speed control
(including speed control
Deceleration
1503
2503
stop time out of
range
The set value of JOG DEC time,
deceleration stop time or DEC/
STOP time at speed change is
outside the setting range.
of speed/position
switching control) or JOG
operation:
The axis decelerates to a
stop.
Set the JOG DEC time, deceleration
stop time or DEC/STOP time at
speed change to a value within the
setting range.
• During position control
(including position control
of speed/position
switching control):
Operation continues.
Movement
amount setting
1504
2504
At start: Operation is not
A negative value is set in
started.
out of range
"Positioning address/movement
During operation: When the
Correct the value of "Positioning
under speed/
amount" when speed/position
target position is changed
address/movement amount" or
switching control is selected as
during position control of
target position change value.
the control method.
speed/position switching
position
switching
control
1505
2505
No external command signal is
switching
selected when speed/position
control start
switching control is selected as
not possible
the control method.
Original
1506
2506
control, operation continues.
Speed/position
position return
type setting out
of range
The set value of original position
return type is outside the setting
range.
Operation is not started.
Select an external command signal.
OPR control is not
Set the original position return type
performed.
to a value within the setting range.
If a different error occurs while an error is already present, the error code is not rewritten to reflect the latest error.
178
CHAPTER 7 POSITIONING FUNCTION
(2) Warning
When a warning occurs, the following operations are performed.
• The Axis 1 warning (SM1846) turns on.
• A warning code corresponding to the warning is stored to the Axis 1 warning code (SD1846) in decimal.
Different from errors, occurrence of a warning does not stop the operation of CH1. The SD value is always
updated with the latest warning code.
Interface
Axis
Number
Axis 1
SM1846
Axis 2
Special relay
Special registers
Axis 1
SM1850
SM1870
Axis 1
SD1846
SD1866
Description
The occurrence condition of positioning function
Axis
SM1866
Axis 2
Axis 2
Name
warning
warnings is indicated. This relay turns off when
the axis
Axis
error reset
error reset is turned on.
• Reset the axis
warning code.
• Turn OFF the axis
warning.
When a warning occurs, the corresponding
Axis
warning code
warning code is stored here. This register is reset
when the axis
error reset is turned on.
Remark
7
When a warning occurs, the Axis 1 axis operation status (SD1844) does not change.
The following table lists the Axis
Axis
warning codes.
warning
code
(decimal)
1020
Name
Description
Axis 2
2020
warning
Out of speed
range
The set speed or new speed value
is less than the bias speed at start
or exceeds the speed limit.
The speed is
Change the set speed or new speed
controlled at the bias
value so that it becomes equal to or
speed at start or
greater than the bias speed at start or
speed limit.
equal to or smaller than the speed limit.
• The Target position change
1021
2021
• Do not execute the Target position
instruction (IPTPCHG1(P)) was
change instruction (IPTPCHG1(P))
Target
executed other than when
other than when position control is
position
position control was active.
change not
• The Target position change
possible
Operation continues.
change instruction (IPTPCHG1(P))
executed when the Axis 1 speed
when the Axis 1 speed 0 (SM1844) is
0 (SM1844) was on.
on.
• Do not execute the Speed change
(IPSPCHG1(P)) was executed
instruction (IPSPCHG1(P)) when
when OPR control was active.
Speed
2022
change
Not allowed
active.
• Do not execute the Target position
instruction (IPTPCHG1(P)) was
• The Speed change instruction
1022
Corrective action
occurrence
OPR control is active.
• The Speed change instruction
(IPSPCHG1(P)) was executed
during acceleration/deceleration
when position control (including
position control of speed/
position switching control) was
active.
• Do not execute the Speed change
Operation continues.
instruction (IPSPCHG1(P)) during
acceleration/deceleration when
position control (including position
control of speed/position switching
control) is active.
179
7.14 Errors and Warnings
Axis 1
Operation at
7.15
Monitoring with a Programming Tool
When the positioning function is executed, the operating status can be checked on the "Positioning Monitor" window of
the programming tool.
[Tools]
For details, refer to the
180
[Built-in I/O Module Tool]
GX Works2 Version1 Operating Manual (Common).
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
CHAPTER 8
8.1
HIGH-SPEED COUNTER FUNCTION
Overview
(1) Definition
This function counts the number of high-speed input pulses that cannot be measured by general counter.
(2) Features
The high-speed counter function is controlled by parameters and dedicated instructions.
LCPU
PWM output mode
PWM output ON time
setting
Encoder (pulse generator)
CH2
Encoder
(pulse generator)
CH1
8
PWM output on time setting
8.1 Overview
(a) Pulse inputs from two channels
Pulses can be simultaneously input from two pulse generators.
(b) Five operation modes
According to application, an operation mode can be selected from the following five modes.
• Normal mode: Has the CPU module operate as a general high-speed counter.
• Frequency measurement mode: Calculates frequencies from the number of input pulses.
• Rotation speed measurement mode: Calculates a rotation speed from the number of input pulses.
• Pulse measurement mode: Measures the on or off width of input pulses. Select this mode for measuring
length.
• PWM (pulse width modulation) output mode: Outputs pulses with the on width and cycle setting. Select
this mode when using the CPU module as an oscillator.
(c) Combined use of functions
Functions for preset, count stop, and counter value latch can be used in combination.
(Counter function selection)
(d) Execution of an interrupt program
An interrupt program can be executed when the current counter value and a set value match.
(Coincidence detection interrupt function)
(e) Coincidence output
A coincidence signal can be output when the current counter value and a set value match.
(Coincidence output function)
181
(3) Function list
The following table lists and describes functions available for the high-speed counter function.
Item
Description
Available
operation mode
Reference
Counts pulses within the range of
Linear counter function
-2147483648 to 2147483647 and detects an
Page 203,
overflow or an underflow if the count range is
Section 8.4 (1)
exceeded.
Repeatedly counts pulses within the range of
Ring counter function
Page 203,
the upper limit value to the lower limit value of
Section 8.4 (1)
ring counter.
Preset function
Page 207,
Overwrites CH1 current value (SD1880,
Section 8.4.1
SD1881) of a counter with a set value.
(2)
Compares a set value with CH1 current value
Coincidence output function
Page 209,
(SD1880, SD1881) of a counter and outputs on
Section 8.4.2
or off signal.
Overwrites CH1 current value (SD1880,
Preset at coincidence
output function
Page 211,
SD1881) of a counter with a set value on the
Section 8.4.2
rising edge of Counter value coincidence (No.n)
(1)
signal.
Coincidence detection
interrupt function
Starts an interrupt program when CH1 current
Section 8.4.3
match.
Latches CH1 current value (SD1880, SD1881)
Latch counter function
Page 213,
value (SD1880, SD1881) and a set value
of a counter on the rising edge of Latch counter
Normal mode
input signal.
Latch counter function
Page 218,
Latches CH1 current value (SD1880, SD1881)
Section 8.4.4
of a counter on the rising edge of CH1 selected
(2) (a)
counter function start command (SM1896) or
Function input signal.
Count disable function
Counter function
selection
Sampling counter function
Count disable/preset
function
Latch counter/preset
function
Internal clock function
Page 220,
Section 8.4.4
sampling period.
(2) (c)
Page 222,
Performs the count disable function and the
Section 8.4.4
preset function without switching the function.
(2) (d)
Page 224,
Performs the latch counter function and the
Section 8.4.4
preset function without switching the function.
(2) (e)
Page 197,
Counts clock frequencies generated by the
Section 8.3.1
LCPU.
of phases A and B and automatically calculates
Counts pulses input from the pulse input signals
of phases A and B and automatically calculates
a rotation speed.
182
(2) (a)
Counts pulses input during the specified
frequencies.
Rotation speed measurement function
Section 8.4.4
command (SM1895) is on.
Counts pulses input from the pulse input signals
Frequency measurement function
Page 218,
Stops counting while CH1 count enable
(2) (a)
Frequency
Page 229,
measurement mode
Section 8.5 (5)
Rotation speed
Page 235,
measurement mode
Section 8.6 (5)
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
Item
Pulse measurement function
PWM output function
Description
Measures the on or off width of pulses input to
Function input signal.
Outputs PWM waveforms from Coincidence
output No.1 signal at the maximum of 200kHZ.
Available
operation mode
Reference
Pulse measurement
Page 239,
mode
Section 8.7 (2)
PWM output mode
Page 242,
Section 8.8 (2)
8
8.1 Overview
183
8.1.1
Procedure for performing the high-speed counter function
The following shows the procedure.
Start
Connect an external device.
Connection to an external
device
(
Page 185, Section 8.2 )
Parameter setting
(
Page 194, Section 8.3 )
Normal mode
(
Page 201, Section 8.4 )
Frequency measurement
mode
Rotation speed
measurement mode
(
Page 225, Section 8.5 )
(
Page 231, Section 8.6 )
Pulse measurement mode
(
Page 237, Section 8.7 )
PWM output mode
(
Page 240, Section 8.8 )
Dedicated instructions
(
Page 245, Section 8.10 )
Programming
(
Page 262, Section 8.11 )
Configure common settings such as
operation mode in a programming tool.
Configure settings for the selected
operation mode.
Create programs.
Execute the programs.
End
184
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.2
Connection to External Devices
8.2.1
I/O signals
The following shows the simplified diagrams of the internal circuits of LCPU external device connection interface.
the signal name indicates either 1 (CH1) or 2 (CH2). For I/O signal settings, refer to
in
Page 194, Section 8.3.
(1) Input
Pin number
Internal circuit
CH1
CH2
B20
A20
Signal name
+24V (PULSE A
-24V)
3.6k
1/2W
B19
A19
680
1/10W
Phase A (PULSE A )
220
Differential (PULSE A
-DIFF)
B18
A18
COM (PULSE A
-COM)
B17
A17
+24V (PULSE B
-24V)
8
3.6k
1/2W
B16
A16
B15
A15
B14
A14
Phase B (PULSE B )
220
Differential (PULSE B
-DIFF)
COM (PULSE B
-COM)
+24V (PULSE Z
-24V)
3.6k
1/2W
B13
A13
680
1/10W
B12
A12
B11
A11
B10
A10
1k
1/10W
A09
B07
B06
A08
A07
A06
-DIFF)
-COM)
Input common
5.6k
1/3W
B08
Differential (PULSE Z
COM (PULSE Z
5.6k
1/3W
B09
Phase Z (PULSE Z )
220
5.6k
1/3W
5.6k
1/3W
1k
1/10W
Function input signal (FUNC )
Latch counter input signal (LATCH )
1k
1/10W
1k
1/10W
(Not used for the high-speed counter function)
1k
1/10W
5.6k
1/3W
185
8.2 Connection to External Devices
8.2.1 I/O signals
680
1/10W
(2) Output
(a) L02CPU, L26CPU-BT
Pin number
Internal circuit
CH1
CH2
B05
A05
Insulating
element
B04
A04
Insulating
element
B03
A03
B02
A02
B01
A01
Insulating
element
Signal name
Coincidence output No.1 signal (EQU 1)
Coincidence output No.2 signal (EQU 2)
(Not used for the high-speed counter function)
Insulating
element
Output common
(b) L02CPU-P, L26CPU-PBT
Pin number
Internal circuit
Signal name
CH1
CH2
B05
A05
Insulating
element
Coincidence output No.1 signal (EQU 1)
B04
A04
Insulating
element
Coincidence output No.2 signal (EQU 2)
B03
A03
Insulating
element
B02
A02
B01
A01
186
Insulating
element
(Not used for the high-speed counter function)
Output common
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(3) Details of I/O signals
The following table lists and describes the I/O signals of the connector for external devices.
Category
Signal name
Description
Phase A (PULSE A )
Pulse input signal.Pulses input to these signals are counted according to the operation
Phase B (PULSE B )
mode set for the phases A and B.
Phase Z (PULSE Z )
External signals to perform the preset function are input.
Normal mode:
• While the count disable function is selected, external signals to suspend count are
input.
• While the latch counter function is selected, external signals to perform the latch
function are input.
Input
Function input signal
(In normal mode, set positive or
negative logic.)
• While the count disable/preset function is selected, external signals to stop count or
perform the preset function are input.
• While the latch counter/preset function is selected, external signals to perform the
latch function or the preset function are input.
• While the sampling counter function is selected, external signals to start counting
during sampling period are input.
Pulse measurement mode:
• The on or off width of pulses input to Function input signal can be measured.
Latch counter input signal
(LATCH )
Input common
Coincidence output No.1 signal
(EQU 1)
Coincidence output No.2 signal
(EQU 2)
Output common
8
Common for Function input signal and Latch counter input signal
Normal mode:
• Signals are output when a count value set by Coincidence output point write
instruction (ICCOVWR1(P)) matches CH1 current value (SD1880, SD1881).
PWM output mode:
8.2 Connection to External Devices
8.2.1 I/O signals
Output
This signal is used when the current counter value is latched.
• PWM waveforms are output. (for Coincidence output No.1 signal only)
Common for Coincidence output No.1 signal and Coincidence output No.2 signal
187
8.2.2
Wiring
This section describes wiring of a LCPU with an encoder and a controller. For connectors used for external wiring,
refer to the following.
MELSEC-L CPU Module User's Manual (Hardware Design, Maintenance and Inspection).
(1) Wiring precautions
• Inputting a signal with a different voltage may cause malfunction of the module and failure of the connected
devices.
• In 1-phase input, connect a pulse input cable to A-phase line.
• When inputting high-speed pulses, take the following noise reduction measures.
• Always use a shielded twisted pair cable and ground the FG and LG terminals to the protective ground
conductor dedicated to the programmable controller.
• To prevent noise from power cables and I/O cables, do not install shielded twisted pair cables in parallel
with them and separate the shielded twisted pair cables at least 100mm away from them. Also, wire the
shielded twisted pair cables with the shortest distance.
The following figures show an example of noise reduction measures.
LCPU
Inverter
Terminal
block
Terminal block
Avoid using a solenoid valve and inductive load together in the same metallic pipe.
If a sufficient distance cannot be secured with a high voltage cable in wiring in a duct,
use a CVVS type shield wire or other shield wires for the high voltage cable.
Install these cables at least
100mm away from the I/O
cables of high voltage
equipment such as a
relay and an inverter.
(Apply this wiring in a control
panel as well.)
Relay box
AC motor
Wire the encoder and the relay box with the shortest distance.
If the distance between the LCPU and the encoder is long,
a voltage drop may occur.
Therefore, check that voltages while the encoder is in operation
and in stop are within the rated voltage of the encoder at the
terminal block of the relay box using a measure such as a
synchronoscope.
Cart
Encoder
• Ground the shielded twisted pair cable on the encoder side (relay box). (This example shows wiring using
24V sink type.)
+24V
Current for the encoder
To
To
To the encoder
0V
A
A
B
B
To LCPU
24V
E
E
Connect the shield wire of the encoder and the shield wire of the
shielded twisted pair cable at inside of the relay box.
If the shield wire of the encoder is not grounded inside the encoder,
ground the wire in the relay box as indicated by the dotted line.
(2) Connectable encoders
Check that the output voltages of the following encoders meet the specifications of the high-speed counter
function. (
Page 243, Section 8.9).
• Open collector output type encoder
• Line driver output type encoder
188
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(3) Example of wiring with an encoder
Characters in the parentheses of the terminal part indicate the pin number of CH2.
(a) Example of wiring with an open collector output type encoder (24VDC)
Encoder
LCPU
24V
Phase A
Shielded twisted
pair cable
+24V
B20(A20)
DIFF
OUT
B19(A19)
Shield
COM
E
B18(A18)
Phase B
24V
Shielded twisted
pair cable
+24V
B17(A17)
DIFF
OUT
B16(A16)
Shield
COM
E
B15(A15)
8
24VDC
External
power supply
0V
● Wiring example
LCPU
Phase A
COM
Shielded twisted pair cable
OUT
24V
+24V
Shield
0V
Encoder
E
External power 24VDC
supply
0V
● Improper wiring example
LCPU
Phase A
COM
Shielded twisted pair cable
OUT
24V
Shield
+24V
0V
E
Encoder
Since a current flows through
the shielded twisted pair
cables in the same direction,
canceling effect does not work.
Accordingly, a current is
easily affected by
electromagnetic induction.
External power 24VDC
supply
0V
189
8.2 Connection to External Devices
8.2.2 Wiring
When wiring a LCPU and an encoder, separate power cables and signal cables. The following figures show examples.
(b) Example of wiring with a line driver (equivalent to AM26LS31) encoder
LCPU
Encoder
Phase A
24V
B20(A20)
DIFF
Shielded twisted
pair cable
OUT
B19(A19)
OUT
COM
Shield
B18(A18)
E
Phase B
24V
B17(A17)
DIFF
Shielded twisted
pair cable
OUT
B16(A16)
OUT
COM
Shield
B15(A15)
E
(4) Example of wiring of a controller and external input signals
Characters in the parentheses of the terminal part indicate the pin number of CH2.
(a) Example of wiring with a controller (sink type)
LCPU
Controller
Shielded twisted
pair cable
OUT
+24V
B10(A10)
Shield
Function input
E
B11(A11)
COM
Shielded twisted
pair cable
+24V
B9(A9)
Latch counter input
OUT
Shield
E
+
24VDC
190
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(b) Example of wiring when the controller is a line driver
LCPU
Controller
Phase Z
24V
B14(A14)
DIFF
Shielded twisted
pair cable
OUT
B13(A13)
OUT
COM
B12(A12)
Shield
E
8
8.2 Connection to External Devices
8.2.2 Wiring
191
(5) Example of wiring with an external output device
(a) L02CPU, L26CPU-BT
LCPU
Load
B5(A5)
Load
B4(A4)
+
-
5 to 24VDC
B1(A1)
When connecting an inductive load, connect a diode to the load in parallel to prevent the back EMF from being generated for
output element protection.
Back EMF
Load
192
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(b) L02CPU-P, L26CPU-PBT
LCPU
Load
B5(A5)
Load
B4(A4)
5 to 24VDC
B1(A1)
When connecting an inductive load, connect a diode to the load in parallel to prevent the back EMF from being generated for
output element protection.
8
Back EMF
Load
8.2 Connection to External Devices
8.2.2 Wiring
193
8.3
Parameter Setting
Set parameters for each channel.
1.
Click the
button in the "Built-in I/O Function Setting" tab.
Project window
2.
[Parameter]
[PLC Parameter]
"Built-in I/O Function Setting" tab
Select the "Use high-speed counter function (CH1)" checkbox on the top left on the "High-speed
Counter CH1 Detailed Setting" screen.
3.
Configure required settings.
4.
Click the
button to exit.
Select the "Use high-speed
counter function (CH1)" checkbox.
Available
Item
Description
Default
operation
Reference
mode
Operation Mode Setting
Select an operation mode.
Count Source Selection
Select a count source.
Pulse Input Mode
Counting Speed Setting
Z Phase (Preset) Trigger Setting
Select a pulse input mode.
Select the counting speed of pulses.
Select a trigger condition to perform the
preset function by phase Z input.
Normal mode
A Phase/B Phase
1-Phase Multiple of 1
⎯
(Common
settings)
10kpps
Page 206,
Rising
Section 8.4.1
(1)
Select whether to turn on CH1 external
External Preset (Z Phase) Request
Detection Setting
preset (phase Z) request detection
(SM1886) when the preset function is
Page 206,
ON at detection
performed by phase Z input.
Counter Format
Page 196,
Section 8.3.1
Section 8.4.1
Normal
Select a counter type.
Linear Counter
Select logic for Function input signal.
Positive Logic
mode
(1)
Page 203,
Section 8.4 (1)
Page 216,
Function Input Logic Setting
Section 8.4.4
(1) (a)
Counter Function Selection
Select a counter function.
Count Disabling
Page 216,
Function
Section 8.4.4
(To the next page)
194
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
Available
Item
Description
Default
operation
Reference
mode
Coincidence Output Time Preset
Setting
Coincidence Detection Interrupt
Setting (Counter Value Coincidence
No.1)
Coincidence Detection Interrupt
Setting (Counter Value Coincidence
No.2)
Sampling Time Setting (ms)
Frequency Movement Averaging
Processing Count
Frequency Measurement Unit Time
Setting
Rotation Speed Movement Averaging
Processing Count
Rotation Speed Measurement Unit
Time Setting
Number of Pulses per Rotation
(pulse)
function on the rising edge of CH1 counter
Page 211,
Not preset
Section 8.4.2
value coincidence (No.1) (SM1881).
(1)
Select whether to perform coincidence
detection interrupt using CH1 counter value
coincidence (No.1) (SM1881).
Select whether to perform coincidence
Page 213,
Not used
Normal mode
Section 8.4.3
(1)
detection interrupt using CH1 counter value
coincidence (No.2) (SM1884).
Set sampling period for the sampling
counter function.
Set a moving average processing count
when frequencies are measured.
Select a pulse measurement period to
calculate frequencies.
Set a moving average processing count
when a rotation speed is measured.
Select a pulse measurement period to
calculate a rotation speed.
Set the number of pulses per rotation when
a rotation speed is measured.
Select a period (on width or off width)
during which pulses are measured.
Page 216,
⎯
Section 8.4.4
(1) (b)
⎯
Frequency
measurement
⎯
mode
Page 225,
Section 8.5
⎯
Rotation speed
⎯
measurement
mode
Page 231,
Section 8.6
8
⎯
Pulse
⎯
measurement
mode
Page 237,
Section 8.7
After the settings are configured, used external signals are automatically assigned. Set "Input Response Time" for
input signals other than phases A and B, and set "Error Time Output Mode" for output signals for each channel.
According to the settings, external signals are assigned.
195
8.3 Parameter Setting
Pulse Measurement Target Setting
Select whether to perform the preset
8.3.1
Common settings
This section describes settings common to some operation modes.
(1) Operation mode setting
According to application, select an operation mode from the following five modes. The setting items depend on
the selected operation mode. For required settings and available functions for each operation mode, refer to the
following table.
Operation mode
Normal Mode
Frequency Measurement
Mode
Rotation Speed
Measurement Mode
Pulse Measurement
Mode
PWM Output Mode
Description
Reference
This mode has the CPU module operate as a general high-speed counter.
Page 201, Section 8.4
The frequencies of pulses input to the pulse input signals of phases A and B are
measured.
A rotation speed is calculated from the number of pulses input to the pulse input
signals of phases A and B.
Page 225, Section 8.5
Page 231, Section 8.6
The on or off width of pulses input to Function input signal is measured.
Page 237, Section 8.7
PWM waveforms are output from Coincidence output No.1 signal.
Page 240, Section 8.8
(2) Count source selection
Select a count source from the following.
Count source
Description
Counts pulses input to the pulse input signals of phases A and B of an
A Phase/B Phase
external I/O connector. Select a pulse count method in ÅgPulse Input
Mode".
Available operation mode
Normal mode
Frequency measurement mode
Rotation speed measurement
mode
Internal Clock (0.1µs)
Internal Clock (1µs)
Internal Clock (10µs)
Counts pulses generated at the inside of a LCPU in the specified cycle.
Normal mode
Internal Clock (100µs)
Counts pulses at the timing according to the operation mode set to other
channels.
Other CH Coincidence
Output No.1
• Normal mode: On the rising edge of CH2 counter value coincidence
(No.1) (SM1901) (when the own channel is CH1)
• PWM output mode: On the rising edge of Coincidence output No.1
signal
196
Own channel: Normal mode
Other channels: Normal mode or
PWM output mode
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(a) Internal clock
By setting the internal clock, clock frequencies generated at the inside of the LCPU can be counted as input
pulses. For example, when the internal clock is used together with the coincidence output function, an on delay
timer can be configured.
Ex. Selecting "Internal Clock (100µs)" in Count Source Selection and turning on Coincidence output No.1
signal after the elapse of 180 seconds
CH1 current value (SD1880, SD1881)
1800000
When the count reaches to
1800000 (180s), Coincidence
output No.1 signal turns on.
900000
0
90
8
t(s)
180
Set Coincidence output No.1 point setting to 1800000 and
start counting an internal clock (100 s).
8.3 Parameter Setting
8.3.1 Common settings
A count value and time have the following relationship.
Time (s)
Count value =
Internal clock ( s)
"
Remark
The accuracy of measured time against a count value is as follows.
Count source
Time accuracy
±60ppm and "-6.25ns to + 9.376ns"
Internal clock (0.1µs)
Ex. When pulses are counted from 0 to 10000, time calculated using a count value is:
1ms (= (10000 - 0) × 0.1µs). However, the measured time will be as follows:
(1ms × (1-0.00006) - 6.25ns) to (1ms × (1 + 0.00006) + 9.376ns)
Internal clock (1µs)
Internal clock (10µs)
±60ppm
Internal clock (100µs)
197
(3) Pulse input mode
Select the mode of pulses input to the pulse input signals of phases A and B. The mode can be set when "A
Phase/B Phase" has been selected for Count Source Selection. The following eight pulse input modes are
available. φA and φB express phase A and phase B, respectively.
Pulse input mode
Count timing
A
For counting up
Counts on the rising edge (↑) of φA.
B and CH1
count down
command
(SM1894)
Both φB and CH1 count down command (SM1894) are off.
1-Phase Multiple of 1
For counting
down
A
Counts on the falling edge (↓) of φA.
B or CH1
count down
command
(SM1894)
Either φB or CH1 count down command (SM1894) is on.
A
For counting up
1-Phase Multiple of 1
Counts on the rising edge (↑) of φA.
CH1 count down command (SM1894) is off.
CH1 count
down command
(SM1894)
(A Phase Only)
A
For counting
down
Counts on the falling edge (↓) of φA.
CH1 count down command (SM1894) is on.
CH1 count
down command
(SM1894)
A
For counting up
B and CH1
count down
command
(SM1894)
Counts on the rising edge (↑) and the falling edge (↓) of φA.
Both φB and CH1 count down command (SM1894) are off.
1-Phase Multiple of 2
For counting
down
A
B and CH1
count down
command
(SM1894)
A
For counting up
1-Phase Multiple of 2
CH1
count down
command
(SM1894)
Counts on the rising edge (↑) and the falling edge (↓) of φA.
Either φB or CH1 count down command (SM1894) is on.
Counts on the rising edge (↑) and the falling edge (↓) of φA.
CH1 count down command (SM1894) is off.
(A Phase Only)
For counting
down
A
CH1
count down
command
(SM1894)
Counts on the rising edge (↑) and the falling edge (↓) of φA.
CH1 count down command (SM1894) is on.
(To the next page)
198
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
Pulse input mode
Count timing
For counting up
A
Counts on the rising edge (↑) of φA.
φΒ ισ οφφ.
B
CW/CCW
For counting
A
φA is off.
Counts on the rising edge (↑) of φB.
down
B
For counting up
A
Counts on the rising edge (↑) of φA while φB is off.
B
2-Phase Multiple of 1
For counting
A
down
Counts on the falling edge (↓) of φA while φB is off.
B
For counting up
A
Counts on the rising edge (↑) of φA while φB is off.
Counts on the falling edge (↓) of φA while φB is on.
B
2-Phase Multiple of 2
For counting
A
8
Counts on the rising edge (↑) of φA while φB is on.
Counts on the falling edge (↓) of φA while φB is off.
down
B
Counts on the rising edge (↑) of φA while φB is off.
8.3 Parameter Setting
8.3.1 Common settings
For counting up
A
Counts on the falling edge (↓) of φA while φB is on.
Counts on the rising edge (↑) of φB while φA is on.
B
Counts on the falling edge (↓) of φB while φA is off.
A
Counts on the falling edge (↓) of φA while φB is off.
2-Phase Multiple of 4
Counts on the rising edge (↑) of φA while φB is on.
For counting
Counts on the rising edge (↑) of φB while φA is off.
down
B
Counts on the falling edge (↓) of φB while φA is on.
When a pulse input mode has been set to "1-Phase Multiple of 1 (A Phase Only)" or "1-Phase Multiple of 2 (A Phase Only)",
the input signal of phase B can be used for other functions, such as general-purpose input function other than the interrupt
input function.
199
The overview of external connections regarding pulse input is as follows.
1-phase pulse input
1-phase pulse input (phase A only)
LCPU
Encoder
Pulse input
A
LCPU
Pulse input
Encoder
A
B
B or CH1 subtraction count command
(SM1894)
CW/CCW pulse input
2-phase pulse input
LCPU
LCPU
Encoder
Addition pulse input
Pulse input to phase A
A
A
Encoder
Encoder
Subtraction pulse input
Pulse input to phase B
B
B
(4) Counting speed setting
Select the counting speed of pulses with considering the following conditions.
Counting speed
Available pulse input mode
10kpulse/s
All
50kpulse/s
All
100kpulse/s
All other than "2-Phase Multiple of 1"
1-Phase Multiple of 2
200kpulse/s
1-Phase Multiple of 2 (A Phase Only)
2-Phase Multiple of 4
200
Available count source
A Phase/B Phase
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.4
Normal Mode
This section describes settings that become valid and functions that can be used when "Normal Mode" is selected for
"Operation Mode Setting". The following table shows I/O signals used in this mode.
:Wiring required,
:Wiring required when necessary, ⎯:Wiring not required
Input signal
Count source
Output signal
Phase
Phase
Phase
Function input
Latch counter
A
B
Z
signal
input signal
Coincidence
Coincidence
output No.1
output No.2
signal
signal
1-Phase
Multiple of 1
(A Phase
Only)
⎯*2
1-Phase
Multiple of 2
(A Phase
Only)
1-Phase
A Phase/
B Phase
Multiple of 1
1-Phase
Multiple of 2
CW/CCW
*3
*3
*3
*3
*3
2-Phase
8
Multiple of 1
2-Phase
8.4 Normal Mode
Multiple of 2
2-Phase
Multiple of 4
0.1µs
1µs
Internal
clock
10µs
100µs
⎯*2
⎯*2
Other CH Coincidence
Output No.1*1
*1
*2
*3
Setting the high-speed counter function of other channel to the normal mode or PWM output mode is required.
The input signal can be used for other functions such as the general-purpose input except the interrupt input.
Wiring the input signal is required depending on the selected counter function. When this signal is not required, it can be
used for other functions such as the general-purpose input and general-purpose output.
201
This section describes required settings and functions for each of the following item.
Item
Reference
Preset
Page 206, Section 8.4.1
Coincidence output
Page 209, Section 8.4.2
Coincidence detection
Page 213, Section 8.4.3
Counter function selection
Page 216, Section 8.4.4
First of all, the setting item, "Counter type", which is common for all items, is described.
Note that the explanations in this section assume use of CH1. For the special relay, special register, dedicated
instructions, error codes, and warning codes for CH2, refer to the following.
• Special relay and special register:
• Dedicated instructions:
• Error codes:
• Warning codes:
202
Page 244, Section 8.9 (2)
Page 245, Section 8.10
Page 269, Section 8.12 (1)
Page 270, Section 8.12 (2)
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(1) Counter format
Select the high-speed counter format.
• Linear counter: Counts pulses within the range of -2147483648 to 2147483647.
• Ring counter: Counts pulses within the range between the ring counter upper limit value and the lower limit
value.
(a) Operations of the linear counter
This format can be used with any counter functions available in the normal mode.
3) Overflow
2147483647
CH1 present value (SD1880 and SD1881)
0
-2147483648
1) Underflow
8
ON
CH1 underflow detection flag (SD1882.b1)
OFF
8.4 Normal Mode
ON
CH1 overflow detection flag (SD1882.b2)
OFF
2)
CH1 Preset command (SM1893)
ON
4)
OFF
t
2ms
t
2ms
Number
Description
1)
"detection (1)" is stored in the underflow detection flag (SD1882.b1). Even if an additional pulse is inputted, the CH1 current
When CH1 current value (SD1880, SD1881) becomes smaller than the lower limit (-2147483648) during counting down,
value (SD1880, SD1881) remains at the lower limit (-2147483648).
When performing preset of the current value by turning on the CH1 preset command (SM1893) or other methods, "No
2)
detection (0)" is stored in the underflow detection flag (SD1882.b1). The value is preset to "0" in the above chart. And then,
counting restarts.
When CH1 current value (SD1880, SD1881) becomes larger than the upper limit (2147483647) during counting up,
3)
"detection (1)" is stored in the overflow detection flag (SD1882.b2). Even if an additional pulse is inputted, the CH1 current
value (SD1880, SD1881) remains at the upper limit (2147483647).
4)
When presetting the value by turning on the CH1 preset command (SM1893) or other methods, "No detection (0)" is stored in
the overflow detection flag (SD1882.b1) The value is preset to "0" in the above chart. And then, counting restarts.
• Errors of the linear counter
When the overflow error or underflow error is detected, "Over/underflow error (CH1 error code: 3100)"
occurs.
203
(b) Operations of the ring counter
This format counts pulses repeatedly within the range within the range between the ring counter upper limit
value and the lower limit value. These limit values are set by the ring counter upper/lower limit value write
instruction (ICRNGWR1(P)) (
Page 247, Section 8.10.1 (2)). This format can be used with any counter
functions available in the normal mode. When the ring counter is selected, the overflow error and underflow
error does not occur.
+2147483647
Ring counter upper limit value
CH1 present value
(SD1880 and SD1881)
0
Ring counter lower limit value
1)
2)
-2147483648
Number
1)
2)
204
Description
When CH1 current value (SD1880, SD1881) is counted up from "the upper limit value -1", the lower limit value is stored in the
current value.
When CH1 current value (SD1880, SD1881) is counted down from the lower limit value, "the upper limit value -1" is stored in
the current value.
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
• Count range of the ring counter
The count range differs depending on the CH1 current value (SD1880, SD1881) when preset is performed
or CH1 count enable command (SM1895) is turned on, upper limit value and lower limit value.
Ex. When setting the ring counter lower limit value to -50000 and the ring counter upper limit value to
100000. (Except Range 3)
Count range
Setting condition
Range 1
(
+2147483647
Ring counter
upper limit value
Ring counter
lower limit value
) (
) (
CH1 present value
(SD1880 and SD1881)
Ring counter
upper limit value
)
Subtraction
and
Addition
Ring counter
lower limit value
(
-2147483648
Count range
-50000 to 99999
Range 2
+2147483647
Ring counter
upper limit value
Ring counter
lower limit value
(
)
(
Ring counter
upper limit value
)
)
(
Ring counter
lower limit value
)
CH1 present value
(SD1880 and SD1881)
Subtraction
8
or
Addition
Ring counter
lower limit value
(
)
(
Ring counter
upper limit value
)
)
(
Ring counter
upper limit value
)
CH1 present value
(SD1880 and SD1881)
-2147483648
8.4 Normal Mode
Count range
-2147483648 to 50000
100001 to 2147483647
Range 3
+2147483647
Ring counter
upper limit value=
Ring counter
lower limit value Subtraction
Addition
-2147483648
Count range
-2147483648 to 2147483647
(
Ring counter
lower limit value
The CH1 present value (SD1880 and SD1881) is not included in the setting condition.
• Precautions
• The change of upper limit value and lower limit value of ring counter takes effect when rising edge of
CH1 count enable command (SM1895) is detected. To enable the changed settings of these values
when CH1 count enable command (SM1895) is on, turn off it for 2ms or more and then turn on it.
• When changing the count range by preset, perform it after turning off CH1 count enable command
(SM1895) to prevent incorrect counts.
205
8.4.1
Preset
This function overwrites CH1 current value (SD1880, SD1881) with a value set to Preset value write instruction
(ICPREWR1(P)) (preset value) and counts pulses starting from the set value (
Page 249, Section 8.10.1 (3)). The
following methods are available.
• Preset by phase Z input
• Preset by a program
• Preset by the preset at coincidence output function (
Page 211, Section 8.4.2 (1))
• Preset by the count disable/preset function (
Page 222, Section 8.4.4 (2) (d))
• Preset by the latch counter/preset function (
Page 224, Section 8.4.4 (2) (e))
This section describes preset by phase Z input and preset by a program.
(1) Phase Z settings
(a) Phase Z (preset) trigger setting
Select a trigger condition to perform the preset function by phase Z input from the following.
Rising edge
Phase Z
Rising edge + Falling edge
Phase Z
Falling edge
Phase Z
During on
Phase Z
(b) External preset (phase Z) request detection setting
When performing the preset function by phase Z input, select whether to turn on CH1 external preset (phase Z)
request detection (SM1886). This setting is invalid if Z "Phase (Preset) Trigger Setting" is set to "During ON".
Select either of the following items.
• ON at detection
• Not ON at detection
• Precautions
While CH1 external preset (phase Z) request detection (SM1886) is on, the current value cannot be replaced
with the preset value by any method. In this case, turn off this relay by turning on CH1 external preset (phase
Z) request detection reset command (SM1897).
206
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(2) Description of the methods
(a) Preset by phase Z input
With phase Z input, the current value is replaced with the preset value when the set trigger condition is met.
Ex. Operation when "Z Phase (Preset) Trigger Setting" is set to "Rising" and "External Preset (Z Phase)
Request Detection Setting" is set to "ON at detection"
ON
CH1 count enable command
(SM1895)
OFF
Counter input pulse
ON
OFF
1)
100
0
Preset value setting
t
t
2ms
CH1 preset command
(SM1893)
3)
2ms
ON
OFF
ON
2)
8
2)
3)
Phase Z
OFF
CH1 external preset (phase Z)
request detection (SM1886)
ON
8.4 Normal Mode
8.4.1 Preset
OFF
CH1 external preset (phase Z)
request detection reset command
(SM1897)
ON
4)
OFF
CH1 current value
(SD1880, SD1881)
t
0
Number
1)
1
2
to 65 66 67 68
100 101 102 103 104105 106 107 108109
2ms
110
100 101
Description
When Preset value write instruction (ICPREWR1(P)) is executed, a set value is overwritten to the preset value setting.
The value written to the preset value setting is stored in CH1 current value (SD1880, SD1881) on the rising edge of phase Z.
2)
CH1 external preset (phase Z) request detection (SM1886) turns on. The current value can be replaced with the preset value
independent of the on/off status of CH1 count enable command (SM1895).
3)
While CH1 external preset (phase Z) request detection (SM1886) is on, the current value cannot be replaced.
4)
In this case, turn off this relay by turning on CH1 external preset (phase Z) request detection reset command (SM1897).
• Precautions
Provide a 2ms or more interval between the execution command establishment of the Preset value write
instruction (ICPREWR1(P)) and replacement with the preset value. If not, the value of the preset value
setting before change may be stored in CH1 current value (SD1880, SD1881). When the preset function is
performed by CH1 preset command (SM1893), execution of the relay delays. Therefore, providing a
period is not required.
207
(b) Preset by a program
When not using a phase Z and the counter function selection, perform the preset function by turning on CH1
preset command (SM1893) by a program.
ON
CH1 count enable command (SM1895)
OFF
Counter input pulse
ON
OFF
1)
Preset value setting
0
100
t
2)
2ms
ON
CH1 preset command (SM1893)
OFF
CH1 current value (SD1880, SD1881)
Number
1)
0
1
2
to 65 66 67
100 101 102103 104
100 101102 103
Description
When Preset value write instruction (ICPREWR1(P)) is executed, a set value is overwritten to the preset value setting.
The value written to the preset value setting is stored in CH1 current value (SD1880, SD1881) on the rising edge of CH1 preset
2)
command (SM1893). The current value can be replaced with the preset value independent of the on/off status of CH1 count
enable command (SM1895).
208
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.4.2
Coincidence output
Coincidence output is a function by which a signal can be output when a value set by the coincidence output point
write instruction (ICCOVWR1(P)) matches the CH1 current value (SD1880 or SD1881). (
Page 254, Section
8.10.1 (6)) Two kinds of coincidence outputs (No.1 and No.2) are provided for each channel.
Ex. When the Coincidence output No.1 signal is turned on.
ON
CH1 count enable command
(SM1895)
OFF
ON
4)
CH1 coincidence output
enable command (SM1892)
OFF
Coincidence output No.1
point setting
1)
1000
0
ON
CH1 counter value smaller No.1
OFF
(SM1882)
5)
2)
ON
5)
CH1 counter value coincidence
No.1 (SM1881)
OFF
ON
8)
CH1 counter value greater No.1
OFF
(SM1880)
CH1 current value
(SD1880 and SD1881)
0
1
999
1000
8
1001
5) ON
Coincidence output No.1 signal
CH1 coincidence signal No.1
reset command (SM1890)
ON
OFF
6)
7)
8.4 Normal Mode
8.4.2 Coincidence output
OFF
9)
3)
t
2ms
t
2ms
t
2ms
209
Number
1)
2)
3)
4)
Description
By executing the Coincidence output point write instruction (ICCOVWR1(P)), any value can be written to the coincidence
output No.1 point setting area.
When the following condition is met, CH1 counter value smaller (No.1) (SM1882) turns on.
• CH1 current value (SD1880 or SD1881) < Coincidence output No.1 point setting
When CH1 coincidence signal No.1 reset command (SM1890) is turned on, CH1 counter value coincidence (No.1) (SM1881)
and the Coincidence output No.1 signal turn off.
To enable the output by the Coincidence output No.1 signal, turn on CH1 coincidence output enable command (SM1892).
(Output of both the Coincidence output No.1 and No.2 signals is enabled.)
When the following condition is met, CH1 counter value coincidence (No.1) (SM1881) and the Coincidence output No.1 signal
turn on.
5)
• CH1 current value (SD1880, SD1881) = Coincidence output No.1 point setting
Also, when the following condition is met, CH1 counter value smaller (No.1) (SM1882) turns off.
• CH1 current value (SD1880 or SD1881)
6)
7)
8)
Coincidence output No.1 point setting
If CH1 coincidence signal No.1 reset command (SM1890) is turned on while the values match, CH1 counter value
coincidence (No.1) (SM1881) and the Coincidence output No.1 signal turn off.
If CH1 coincidence signal No.1 reset command (SM1890) is turned off while the values match, CH1 counter value
coincidence (No.1) (SM1881) and the Coincidence output No.1 signal turn on again.
When the following condition is met, CH1 counter value greater (No.1) (SM1880) turns on.
• CH1 current value (SD1880 or SD1881) > Coincidence output No.1 point setting
When CH1 coincidence signal No.1 reset command (SM1890) is turned on, CH1 counter value coincidence (No.1) (SM1881)
9)
and the Coincidence output No.1 signal turn off. If CH1 counter value coincidence (No.1) (SM1881) remains on, it cannot turn
on the next time.
● CH1 counter value coincidence (No.n) (SM1881 or SM1884) can turn on regardless of the status of CH1 coincidence
output enable command (SM1892).
● Due to internal processing of the high counter function, when CH1 counter value coincidence (No.n) is turned on, CH1
counter value greater (No.1) (SM1880) or CH1 counter value smaller (No.1) (SM1882), or CH1 counter value greater
(No.2) (SM1883) or CH1 counter value smaller (No.2) (SM1885) may be on.
• Precautions
• When program scan time is less then 2ms, ensure a 2ms or longer on width for Coincidence signal No.n
reset command (SM1890 or SM1891) by using a method such as a timer.
• Coincidence output occurs on the rising edge of CH1 counter value coincidence (No.n) (SM1881 or
SM1884). Because of this, if it stays on, the next coincidence signal cannot be output. BY turning on CH1
coincidence signal No.n reset command (SM1890 or SM1891), turn off CH1 counter value coincidence
(No.n) (SM1881 or SM1884)
210
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(1) Coincidence output time preset setting
Select whether to set a preset value on the rising edge of CH1 counter value coincidence (No.1) (SM1881).
• Not preset
• Preset
This setting is used for an operation such as sizing. Note, however, that this setting is not available for CH1
counter value coincidence (No.2) (SM1884).
CH1 current value
(SD1880 and SD1881)
1)
1000
5)
0
t
Coincidence output No.1 point setting
1000
Preset value setting
0
8
200
ON
OFF
4)
2)
t
ON
CH1 coincidence signal No.1 reset command
OFF
(SM1890)
Number
1)
2)
2ms
3)
t
2ms
t
2ms
Description
When the following condition is met, CH1 counter value coincidence (No.1) (SM1881) turns on.
CH1 current value (SD1880 or SD1881) = Coincidence output No.1 point setting.
The preset value is set on the rising edge of CH1 counter value coincidence (No.1) (SM1881).
Turn on CH1 coincidence signal No.1 reset command (SM1890) so that CH1 counter value coincidence (No.1) (SM1881) will
3)
be turned on the next time CH1 current value (SD1880 or SD1881) becomes equal to the coincidence output No.1 point
setting.
4)
If the preset value setting has been changed with the Preset value write instruction (ICPREWR1(P)), the new preset value is
set.
Even if CH1 current value (SD1880 or SD1881) becomes equal to the coincidence output No.1 point setting with CH1 counter
5)
value coincidence (No.1) (SM1881) not turned off, the value will not be replaced with the preset value. This happens because
CH1 counter value coincidence (No.1) (SM1881) remains on (does not rise).
211
8.4 Normal Mode
8.4.2 Coincidence output
CH1 counter value coincidence No.1
(SM1881)
(a) Precautions
• While CH1 external preset (phase Z) request detection (SM1886) is on, the current value cannot be
replaced with the preset value. In this case, turn off this relay by turning on CH1 external preset (phase Z)
request detection reset command (SM1897).
• Provide a 2ms or more interval between the execution command establishment of the Preset value write
instruction (ICPREWR1(P)) and replacement with the preset value. If not, a preset value setting before
change may be stored in CH1 current value (SD1880 or SD1881).
212
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.4.3
Coincidence detection
When a match is detected, an interrupt request can be issued to start an interrupt program. There are four points of
interrupt factors (interrupt pointers, I0 to I3).
I Number
Interrupt factor
I0
Coincidence detection of CH1 coincidence output No.1 point setting
I1
Coincidence detection of CH1 coincidence output No.2 point setting
I2
Coincidence detection of CH2 coincidence output No.1 point setting
I3
Coincidence detection of CH2 coincidence output No.2 point setting
Interrupt pointer numbers can be changed. (
CH1 counter value coincidence No.1
(SM1881)
CH1 counter value coincidence No.2
(SM1884)
CH1 coincidence signal No.1 reset command
(SM1890)
CH1 coincidence signal No.2 reset command
(SM1891)
Page 214, Section 8.4.3 (2))
ON
OFF
ON
OFF
Program processing
Interrupt program processing
8
(1) Coincidence detection interrupt setting (counter value coincidence No.n)
Select whether to "use" or "not use" the coincidence detection interrupt function by CH1 counter value output
(a) Interrupt program execution setting by the IMASK instruction
Use of the IMASK instruction allows the interrupt program execution to be enabled or disabled (interrupt mask)
for each interrupt pointer number. For details on the IMASK instruction, refer to the
MELSEC-Q/L
Programming Manual (Common Instruction).
(b) Time taken until the interrupt request
Time taken from a coincidence detection to an interrupt request is approximately 150µs.
(c) Precautions
A coincidence detection interrupt occurs on the rising edge of CH1 counter value coincidence (No.n) (SM1881
or SM1884). Because of this, if it stays on, the next coincidence signal cannot be output. BY turning on CH1
coincidence signal No.n reset command (SM1890 or SM1891), turn off CH1 counter value coincidence (No.n)
(SM1881 or SM1884).
213
8.4 Normal Mode
8.4.3 Coincidence detection
(No.n) (SM1881 or SM1884).
(2) Changing the interrupt pointer numbers
Configure the settings in the "Interrupt Function Module Interrupt Pointer Setting" dialog box.
1.
Click the
button in the "PLC System" tab.
Project window
2.
3.
[Parameter]
[PLC Parameter]
[PLC System] tab
Set the interrupt pointer start No., interrupt pointer count, start I/O No., and start SI No.
Click the
button to exit.
Ex. When assigning coincidence detection interrupt pointers of high-speed counter CH1 to I50 and higher
(a) Precautions
When there is no high-speed counter with the coincidence detection output setting and no input interrupt within
the range specified in the "Intelligent Function Module Interrupt Pointer Setting" of PLC Parameter,
"PARAMETER ERROR" occurs (error code: 3000).
The following are a correct example and an incorrect example of assigning the interrupt pointers of the highspeed counter to I50 and higher as shown above.
• Correct setting example
In this case, there is a high-speed counter (for which coincidence detection interrupt is set) within the
range specified in "Intelligent Function Module Interrupt Pointer Setting." Therefore, no error will occur.
Input signal function selection: setting of high-speed
counter X0 and X1
214
CH1 coincidence detection interrupt setting: set to "Used"
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
• Incorrect setting example
Although CH2 high-speed counter with the coincidence detection interrupt setting is set, both the counter
and input interrupt settings do not exist within the range specified in the Intelligent Function Module
Interrupt Pointer Setting dialog box. Because of this, an error occurs.
Input signal function selection: setting of high-speed
counter X2 and X3
CH2 coincidence detection interrupt setting: set to "Used"
8
8.4 Normal Mode
8.4.3 Coincidence detection
215
8.4.4
Counter function selection
The following counter functions are selectable.
• Latch counter function: Latches the current value of the counter.
• Count disable function: Stops the counting while it is enabled.
• Sampling counter function: Counts the pulses input during the specified sampling time.
• Count disable/preset function: Performs the count disable function and the preset function depending on
changes of the Function input signal without switching the function.
• Latch counter/preset function: Performs the latch counter function and the preset function depending on
changes of the Function input signal without switching the function.
These functions can be performed by either of CH1 selected counter function start command (SM1896) or an input
from the Function input signal (OR), or the Function input signal only.
: Applicable, ⎯: N/A
Method
Function
CH1 selected counter function
start command (SM1896)
Function input signal
Latch counter function
Count disable function
Sampling counter function
Count disable/preset function
⎯
Latch counter/preset function
⎯
(1) Required settings
For use of the counter function selection, the following two settings are required.
(a) Function input logic setting
Select a logic for the Function input signal.
• Positive logic: The Function input signal is on while a voltage is applied.
• Negative logic: The Function input signal is on while no voltage is applied.
This section explains each function based on the case where "Function Input Logic Setting" is set to "Positive
logic (default)."
(b) Sampling time setting
This setting is enabled when "Sampling Counter Function" is selected. Set sampling time for the sampling
counter function in units of 10ms.
• Setting range: 10 to 655350 (ms)
216
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
A time lag occurs before start of the selected function due to any of the following factors:
• Input response time of the Function input signal
• Program scan time (for CH1 selected counter function start command (SM1896))
• Internal control cycle (1ms) of the high-speed function (for CH1 selected counter function start command
(SM1896))
The count error is as follows:
• Count error (maximum) when the Function input signal is used for the function
Input response time setting value (up to 70) (ms)
1000
(s)
*1
Pulse input speed (pulse/s)
• Count error (maximum) in function execution by CH1 selected counter function start command (SM1896)
1 scan time (ms) + 2(ms)
(s)
1000
Pulse input speed (pulse/s) *
1
In the case of the sampling counter function, a sampling time error due a component error (±60 ppm) will also occur.
Therefore, the count error is:60ppm)
2
Sampling time (s)*
=
Sampling time (s)*
2
60(ppm)
1000000
6
1
Pulse input speed (pulse/s)*
Pulse input speed (pulse/s)*
1
100000
*1
Pulse input speed (pulse/s) = pulse input frequency (Hz) × number of multiples (count)
*2
Sampling time setting value (ms)
Sampling time (s) =
1000
8
8.4 Normal Mode
8.4.4 Counter function selection
217
(2) Details on each function
(a) Latch counter function
CH1 current value (SD1880 and SD1881) can be latched by setting in "Counter Function Selection" or by using
the Latch counter input signal.
• Using "Counter Function Selection": Select "Latch Counter Function" or "Latch Counter/Preset Function"
(
Page 224, Section 8.4.4 (2) (e))
• Using the Latch counter input signal
The latch count value can be read out into the specified device by the Latch counter value read instruction
(ICLTHRD1(P)). (
Page 250, Section 8.10.1 (4)) The following explains the operations of both methods.
ON
CH1 count enable command
(SM1895)
2)
OFF
150
130
100
100
CH1 current value
(SD1880 and SD1881)
50
50
0
0
CH1 selected counter function
start command (SM1896)
OFF
or
function input signal
150
(setting for the counter function selection)
or
latch counter input signal
100
Latch count value 1
(setting for the counter function selection)
or
Latch count value 2
(setting for the latch counter input signal)
1) ON
1)
1)
1)
130
100
50
50
0
0
Number
Description
• Using "Counter Function Selection": CH1 current value (SD1880 or SD1881) is stored in the latch count value 1 area on the
rising edge of CH1 selected counter function start command (SM1896) or the Function input signal. The latch count value 1
1)
can be read out into the specified device by the Latch counter value read instruction (ICLTHRD1(P)).
• Using the Latch counter input signal: CH1 current value (SD1880 or SD1881) is stored in the latch count value 2 area on the
rising edge of the Latch counter input signal. The latch count value 2 can be also read out into the specified device by the
Latch counter value read instruction (ICLTHRD1(P)).
2)
The latch counter function can be performed regardless of the status of CH1 count enable command (SM1895).
• Precautions
• When the latch counter function is performed by the Function input signal or the Latch counter input signal,
the actual execution delays by the input response time. Updating latch count value 1 or 2 will cause a
further 1ms delay in the updating cycle.
• While either of CH1 selected counter function start command (SM1896) or the Function input signal is on,
turning on the other does not latch the counter.
218
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(b) Count disable function
Counting can be stopped while CH1 count enable command (SM1895) is on. To use this function, select
"Count Disabling Function" for "Counter Function Selection."
1) ON
6)
8)
CH1 count enable command (SM1895)
OFF
2) ON 3)
CH1 selected counter function
start command (SM1896)
7)
9)
OFF
4) ON
5)
Function input signal
OFF
Pulse actually input
CH1 current value
(SD1880 and SD1881)
8
Count value to be stored
in the current value area
0
Counting
stopped
Counting
stopped
Counting
stopped
Counting stopped
Description
1)
Counting starts when CH1 count enable command (SM1895) turns on.
2)
Counting stops when CH1 selected counter function start command (SM1896) turns on.
3)
Counting restarts when CH1 selected counter function start command (SM1896) turns off.
4)
Counting stops when the Function input signal turns on.
5)
Counting restarts when the Function input signal turns off.
6)
Counting stops when CH1 count enable command (SM1895) is turned off.
7)
8)
9)
8.4 Normal Mode
8.4.4 Counter function selection
Number
Because CH1 count enable command (SM1895) is off, counting stops regardless of CH1 selected counter function start
command.
Even though CH1 count enable command (SM1895) is turned on, counting remains stopped because CH1 selected counter
function start command (SM1896) is on.
Counting restarts when CH1 selected counter function start command (SM1896) turns off.
219
(c) Sampling counter function
The pulses input during the specified sampling time (Sampling Time Setting (
Page 216, Section 8.4.4 (1)
(b))) can be counted. The sampling count value can be read out into the specified device by the Sampling
count value read instruction (ICSMPRD1(P)). (
Page 252, Section 8.10.1 (5))
ON
CH1 count enable command
(SM1895)
5)
OFF
150
CH1 current value
(SD1880 and SD1881)
100
50
0
CH1 selected counter function
start command (SM1896)
or
function input signal
1)
OFF
T
T
T
150
100
Sampling count value
2)
4)
50
0
-50
CH1 sampling flag
(SD1882.b3)
Number
1)
ON 3)
OFF
T: Sampling time
Description
Counting of the input pulses starts from 0 on the rising edge of CH1 selected counter function start command (SM1896) or the
Function input signal.
2)
Counting stops when the specified sampling time has elapsed.
3)
During execution of the sampling counter function, Sampling flag (SD1882, b3) is set to 1 (Operating).
4)
5)
220
Even after termination of the sampling counter function, the sampling count value is retained. The sampling count value can
be read out into the specified device by the Sampling count value read instruction (ICSMPRD1(P)).
The sampling counter function can be performed regardless of the status of CH1 count enable command (SM1895).
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
• Precautions
• While either of CH1 selected counter function start command (SM1896) or the Function input signal is on,
turning on the other does not perform the sampling counter function. If CH1 selected counter function start
command (SM1896) or the Function input signal is turned on during execution of the sampling counter
function, the sampling time measurement will continue. However, the pulses will be counted from 0.
• If "Internal Clock (0.1µs)" is selected for Count Source Selection and 21475 or more is set for Sampling
Time Setting, the sampling count value may exceed the maximum (2147483647). In that case, the
sampling count value is fixed to the maximum (2147483647), and "Sampling count value overflow" (CH1
warning code: 3050) is detected. Even after occurrence of this warning, execution of the sampling counter
function continues until the sampling time has elapsed.
• The immediately preceding operation of the sampling counter function continues even after status change
from STOP to RUN. Therefore, if the sampling time setting is changed by changing the status from STOP
to RUN during execution of the sampling counter function, the change takes effect the next time the
sampling counter function is performed.
8
8.4 Normal Mode
8.4.4 Counter function selection
221
(d) Count disable/preset function
The count disable function and the preset function can be performed depending on changes of the Function
input signal without switching the function.
1)
5)
ON
7)
CH1 count enable command
(SM1895)
OFF
4)
0
Preset value setting
100
t
2) ON
3)
2ms
6)
8)
Function input signal
OFF
Pulse actually input
100
CH1 current value
(SD1880 and SD1881)
Count value to be stored
in the current value area
0
Counting
stopped
Number
Counting
stopped
Counting stopped
Description
1)
Counting starts when CH1 count enable command (SM1895) is turned on.
2)
Counting stops on the rising edge of the Function input signal.
3)
On the falling edge of the Function input signal, the preset value setting is stored in CH1 current value (SD1880, SD1881), and
counting is restarted.
4)
When the Preset value write instruction (ICPREWR1(P)) is executed, a set value is overwritten to the preset value setting.
5)
Counting stops when CH1 count enable command (SM1895) turns off.
6)
Because CH1 count enable command (SM1895) is off, counting stops regardless of the Function input signal.
7)
8)
222
Even though CH1 count enable command (SM1895) is turned on, counting remains stopped because the Function input
signal is on.
On the falling edge of the Function input signal, the preset value setting is stored in CH1 current value (SD1880, SD1881), and
counting is restarted.
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
The explanation in this section is based on the case where the Function Input Logic Setting is set to Positive Logic (default).
The execution timing of the count disable function and the preset function in the case of Negative Logic setting is as shown
below.
Counting stopped
Preset value is set, and counting restarts.
Negative logic setting
• Precautions
• The preset function is not available if CH1 external preset (phase Z) request detection (SM1886) is on.
(Only the count disable function is executable.) In this case, turn off this relay by turning on CH1 external
preset (phase Z) request detection reset command (SM1897).
• Provide a 2ms or more interval between the execution command establishment of the Preset value write
instruction (ICPREWR1(P)) and replacement with the preset value. If not, a preset value setting before
change may be stored in CH1 current value (SD1880 or SD1881).
8
8.4 Normal Mode
8.4.4 Counter function selection
223
(e) Latch counter/preset function
The latch counter function and the preset function can be performed depending on changes of the Function
input signal without switching the function.
1)
CH1 count enable command
(SM1895)
ON
4)
5)
OFF
3)
Preset value setting
0
100
t
2)
2ms
ON
Function input signal
OFF
150
Pulse actually input
100
CH1 current value
(SD1880 and SD1881)
63
50
Count value to be stored in the current value area
7
0
100
63
Latch count value 1
50
0
Number
1)
0
7
Description
Counting starts when CH1 count enable command (SM1895) is turned on.
On the rising edge of the Function input signal, CH1 current value (SD1880 or SD1881) is stored in the latch count value 1
2)
area. Also, the preset value setting is stored in CH1 current value (SD1880, SD1881). The latch count value 1 can be read
out into the specified device by the Latch counter value read instruction (ICLTHRD1(P)).
3)
When the Preset value write instruction (ICPREWR1(P)) is executed, a given value is written as a preset value setting.
4)
Counting stops when CH1 count enable command (SM1895) is turned off.
5)
Counting restarts when CH1 count enable command (SM1895) is turned on.
• Precautions
• The preset function is not available if CH1 external preset (phase Z) request detection (SM1886) is on.
(Only the latch counter function is available.) In this case, turn off this relay by turning on CH1 external
preset (phase Z) request detection reset command (SM1897).
• Provide a 2ms or more interval between the execution command establishment of the Preset value write
instruction (ICPREWR1(P)) and replacement with the preset value. If not, the value of the preset value
setting before change may be stored in CH1 current value (SD1880, SD1881).
224
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.5
Frequency Measurement Mode
This section describes settings and functions that become valid when "Frequency Measurement Mode" is selected for
"Operation Mode Setting". In this mode, the pulses input from phase A and phase B pulse input signals are counted,
and the frequency is automatically calculated from the pulses. The measured frequency value is written to the
specified device using the Frequency measurement instruction (ICFCNT1). (
Page 246, Section 8.10.1 (1)) The
following table shows I/O signals used in this mode.
: Wiring required, ⎯: Wiring not required
Input signal
Count source
Phase Phase Phase
A
B
Output signal
Function input
Latch counter
Z
signal
input signal
⎯*2
⎯*2
⎯*2
Coincidence
Coincidence
output No.1
output No.2
signal
signal
⎯*2
⎯*2
1-Phase
Multiple of 1
(A Phase
Only )
1-Phase
⎯*1
Multiple of 2
(A Phase
Only )
1-Phase
A Phase/
B Phase
Multiple of 1
1-Phase
8
Multiple of 2
CW/CCW
2-Phase
Multiple of 2
2-Phase
Multiple of 4
*1
*2
The input signal can be used for other functions such as the general-purpose input except the interrupt input.
The signals can be used for other functions such as the general-purpose input and output.
Note that the explanations in this section assume use of CH1. For the special relay, special register, and dedicated
instructions for CH2, refer to the following.
• Special relay and special register:
• Dedicated instructions:
Page 244, Section 8.9 (2)
Page 245, Section 8.10
225
8.5 Frequency Measurement Mode
2-Phase
Multiple of 1
(1) Required settings
(a) Frequency movement averaging processing count
The frequency measurement function performs moving average processing to reduce the unevenness among
the measured frequencies. The setting range is 1 to 100 (times). When "1" is set, the processing is not
performed. After frequencies are measured for the number of times set to the frequency movement averaging
processing count, the average is stored as a measured frequency value.
(b) Frequency measurement unit time setting
Select a pulse measurement time to calculate frequencies from 0.01s, 0.1s, and 1s. The frequencies are
calculated using the following formula.
Frequency (Hz) =
Count value per unit time
Frequency measurement unit time setting (S)
When the count per time unit is 0, the frequency becomes 0. When counting down, the frequency becomes a
negative value.
(2) Relationship between frequency measurement unit time and frequency
Frequency is calculated from the count value per time unit. (
Page 226, Section 8.5 (1) (b)) The following
table shows the unit of frequency for each frequency measurement unit time setting when the frequency
movement averaging processing count is set to "1". Select an appropriate unit time according to the time and
frequency to be measured.
Frequency measurement unit time
Unit of frequency
1s
1Hz
0.1s
10Hz
0.01s
100Hz
(3) Frequency error
Frequency error (maximum) can be calculated using the following formula.
Error (maximum) (Hz) = Actual frequency (Hz)
60(ppm)
1000000
+
1
frequency measurement unit time (s)
number of frequency moving averages
Setting larger values for the following items helps reduce error and unevenness among the measured
frequencies.
• Frequency measurement unit time
• Frequency movement averaging processing count
226
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(4) Measurement example
In this example, frequency is measured under the following conditions.
• Actual frequency: 1234Hz
• Frequency measurement unit time: 0.01s
• Frequency movement averaging processing count: 1 (The moving average processing is not performed.)
(a) Count value per time unit
Count value per time unit for the actual frequency is calculated as follows using the formula in
Page 226,
Section 8.5 (1) (b).
1234(Hz) =
Count value per unit time
0.01(s)
Count value per unit time = 12.34
The count value should be an integer. For this reason, the count value in this example is 12 or 13 because the
numbers after the decimal point is accumulated within the module. When this count value is used in the formula
above, the following result can be acquired.
Frequency measurement value (Hz) =
12 or 13
0.01(s)
8
Frequency measurement value (Hz) = 1200(Hz) or 1300(Hz)
(b) Calculating frequency error (maximum)
60(ppm)
1000000
8.5 Frequency Measurement Mode
Error (maximum) (Hz) = 1234(Hz)
1
+
0.01(s)
1
= 0.07404(Hz) + 100(Hz)
= 100.07404(Hz)
227
(c) Reducing unevenness
When the frequency movement averaging processing count setting is changed to "4", frequency error
(maximum) will be as follows.
Error (maximum) (Hz) = 1234(Hz)
60(ppm)
1000000
1
+
0.01(s)
4
= 0.07404(Hz) + 25(Hz)
= 25.07404(Hz)
The measured frequency value in this example is 1225Hz or 1250Hz.
Accumulated count value per time
unit
Measured frequency value obtained
Measured frequency value
by moving average processing
(4 times)
12.34
1200Hz
−
24.68
1200Hz
−
37.02
1300Hz
−
49.36
1200Hz
1225Hz
61.70
1200Hz
1225Hz
74.04
1300Hz
1250Hz
86.38
1200Hz
1225Hz
98.72
1200Hz
1225Hz
111.06
1300Hz
1250Hz
•••
•••
•••
As shown in the table above, the measured frequency value obtained by moving average processing is closer to
the actual frequency value. The following table shows the measurement result for each frequency measurement
unit time setting.
Measured frequency value obtained
Frequency measurement unit time
Measured frequency value
by moving average processing
(4 times)
1s
1234Hz
1234Hz
0.1s
1230 or 1240Hz
1233 or 1235Hz
0.01s
1200 or 1300Hz
1225 or 1250Hz
Even when the pulse input mode is set to "1-Phase Multiple of 2", "1-Phase Multiple of 2 (A Phase Only)", "2-Phase Multiple
of 2", or "2-Phase Multiple of 4", frequency (Hz) is calculated based on the count value per time unit.
Ex. When the pulse input mode is set to "1-Phase Multiple of 2", the measured frequency value is 20kHz. This is because
even when the input frequency of phase A is 10kHz (10000 pulses per second), the pulse count is 20000 pulses per
second (10000 pulse × 2).
228
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(5) Description
The following example describes the frequency measurement operation.
Ex. Operation when the frequency measurement unit time is set to "0.1s" and the frequency movement averaging
processing count is set to "4".
0.1s
0.1s
Frequency
1st storage (a)
2nd storage (b)
3rd storage (c)
0
1)
Frequency measurement
instruction execution command
CH1 frequency in-measurement
flag (SD1882.b4)
OFF
ON
t (s)
3)
8
ON
OFF
8.5 Frequency Measurement Mode
2)
Frequency measurement value
0
(a)
(b)
(c)
0
Frequency measurement value data transition
1st storage (a)
+
Number
+
4
2nd storage (b)
+
+
+
4
+
3rd storage (c)
+
+
4
+
Description
Turning on the execution command for Frequency measurement instruction (ICFCNT1) starts the following operations:
1)
• Measurement of the frequency
• CH1 Frequency measurement flag (SD1882. b4) changes from stopped (0) to operating (1).
While processing the execution command for Frequency measurement instruction(ICFCNT1), a measured frequency value is
2)
written to the device specified by the Frequency measurement instruction(ICFCNT1). As the frequency moving average
processing count is set as 4 times, an average of the 4 counts is written.
Turning off the execution command for Frequency measurement instruction (ICFCNT1) starts the following operations:
• Measurement of the frequency stops.
3)
• CH1 Frequency measurement flag (SD1882. b4) changes from operating (1) to stopped (0).
• The measured frequency value becomes 0. (The frequency is not stored as the setting data of Frequency measurement
instruction (ICFCNT1).)
229
(a) Precautions
To restart frequency measurement after an interruption, execute Frequency measurement instruction
(ICFCNT1) after "stopped (0)" is stored in CH1 Frequency measurement flag (SD1882. b4). If another
execution command of CH1 Frequency measurement instruction (ICFCNT1) is turned on, failing to check
Frequency measurement flag (SD1882. b4), while the measurement is being executed, the command may be
ignored because the current measurement does not stop.
230
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.6
Rotation Speed Measurement Mode
This section describes settings and functions that become valid when "Rotation Speed Measurement Mode" is
selected for "Operation Mode Setting". In this mode, the pulses input phase A and phase B pulse input signals are
counted, and the rotation speed is automatically calculated from the pulses. The measured rotation speed value is
written to the specified device using the Rotation speed measurement instruction (ICRCNT1). (
Page 257,
Section 8.10.1 (8)) The following table shows I/O signals used in this mode.
: Wiring required, ⎯: Wiring not required
Input signal
Count source
Output signal
Phase
Phase
Phase
Function input
Latch counter
A
B
Z
signal
input signal
⎯*2
⎯*2
⎯*2
Coincidence Coincidence
output No.1
output No.2
signal
signal
⎯*2
⎯*2
1-Phase
Multiple of 1
(A Phase
Only )
1-Phase
⎯*1
Multiple of 2
(A Phase
Only )
1-Phase
A Phase/
B Phase
Multiple of 1
1-Phase
8
Multiple of 2
CW/CCW
2-Phase
Multiple of 2
2-Phase
Multiple of 4
*1
*2
The input signal can be used for other functions such as the general-purpose input except the interrupt input.
The signals can be used for other functions such as the general-purpose input and output.
Note that the explanations in this section assume use of CH1. For the special register, and dedicated instructions for
CH2, refer to the following.
• Special register:
Page 244, Section 8.9 (2)
• Dedicated instructions:
Page 245, Section 8.10
231
8.6 Rotation Speed Measurement Mode
2-Phase
Multiple of 1
(1) Required settings
(a) Rotation speed movement averaging processing count
The rotation speed measurement function performs moving average processing to reduce the unevenness
among the measured rotation speed. The setting range is 1 to 100. When "1" is set, the processing is not
performed.
(b) Rotation speed measurement unit time setting
Select a pulse measurement unit time to calculate rotation speeds from 0.01s, 0.1s, and 1s. The rotation
speeds are calculated using the following formula.
Rotation speed (r/min) =
60 count value per unit time
Rotation speed measurement unit time setting (S)
number of pulses per revolution(pulse)
When the count per time unit is 0, the rotation speed becomes 0. When counting down, the rotation speed
becomes a minus value.
(c) Number of pulses per rotation (pulse)
Set the number of pulses per rotation.
• Setting range 1 to 200000 (pulse)
(2) Relationship between rotation speed measurement unit time and rotation
speed
Rotation speed is calculated from the count value per time unit. (
Page 232, Section 8.6 (1) (b)) The
following table shows the unit of pulse speed for each rotation speed measurement unit time setting when the
rotation speed movement averaging processing count is set to "1". Select an appropriate unit time according to
the time and rotation speed to be measured.
Rotation speed measurement unit time
Unit of pulse speed
1s
1pulse/s
0.1s
10pulse/s
0.01s
100pulse/s
(3) Rotation speed error
Rotation speed error (maximum) can be calculated using the following formula.
Error (maximum) (r/min) = Actual rotation speed
(r/min)
60(ppm)
1000000
60
+
rotation speed
measurement unit time (s)
number of rotation speed
moving averages
number of
pulses per revolution
(pulse)
Setting larger values for the following items helps reduce error and unevenness among the measured rotation
speeds.
• Rotation speed measurement unit time
• Rotation speed movement averaging processing count
• Number of pulses per rotation (pulse)
232
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(4) Measurement example
In this example, rotation speed is measured under the following conditions.
• Actual rotation speed: 1234r/min
• Rotation speed measurement unit time: 0.01s
• Rotation speed movement averaging processing count: 1 (The moving average processing is not
performed.)
• Number of pulses per rotation (pulse): 60pulses
(a) Count value per time unit
Count value per time unit for the actual rotation speed is calculated as follows using the formula in
Page
232, Section 8.6 (1) (b).
1234(r/min) =
60
Count value per unit time
0.01(s)
60(pulse)
Count value per unit time = 12.34
The count value should be an integer. For this reason, the count value in this example is 12 or 13 because the
numbers after the decimal point is accumulated within the module. When this count value is used in the formula
above, the following result can be acquired.
Rotation speed measurement value (r/min) =
60
8
(12 or 13)
0.01(s)
60(pulse)
8.6 Rotation Speed Measurement Mode
Rotation speed measurement value (r/min) = 1200(r/min) or 1300(r/min)
(b) Calculating rotation speed error (maximum)
Error (maximum) (r/min) = 1234(r/min)
60(ppm)
1000000
60
+
0.01(s)
1
60(pulse)
= 0.07404(r/min) + 100(r/min)
= 100.07404(r/min)
233
(c) Reducing unevenness
When the rotation speed movement averaging processing count setting is changed to "4", rotation speed error
(maximum) will be as follows.
Error (maximum) (r/min) = 1234(r/min)
60(ppm)
1000000
60
+
0.01(s)
4
60(pulse)
= 0.07404(r/min) + 25(r/min)
= 25.07404(r/min)
The measured rotation speed value in this example is 1225r/min or 1250r/min.
Accumulated count value per time
unit
Measured rotation speed value
Measured rotation speed value
obtained by moving average
processing (4 times)
12.34
1200r/min
−
24.68
1200r/min
−
37.02
1300r/min
−
49.36
1200r/min
1225r/min
61.70
1200r/min
1225r/min
74.04
1300r/min
1250r/min
86.38
1200r/min
1225r/min
98.72
1200r/min
1225r/min
111.06
1300r/min
1250r/min
•••
•••
•••
As shown in the table above, the measured rotation speed value obtained by moving average processing is
closer to the actual rotation speed value. The following table shows the measurement result for each rotation
speed measurement unit time setting.
Rotation speed measurement unit
time
Measured rotation speed value
Measured rotation speed value
obtained by moving average
processing (4 times)
1s
1234r/min
1234r/min
0.1s
1230 to 1240r/min
1233 to 1235r/min
0.01s
1200 to 1300r/min
1225 to 1250r/min
Even when the pulse input mode is set to "1-Phase Multiple of 2", "1-Phase Multiple of 2 (A Phase Only)", "2-Phase Multiple
of 2", or "2-Phase Multiple of 4", rotation speed (r/min) is calculated based on the count value per time unit.
234
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(5) Description
The operation of rotation speed measurement is shown below.
Ex. Operation when the rotation speed measurement unit time is set to "0.1s" and the rotation speed movement
averaging processing count is set to "4".
0.1s
0.1s
Rotation speed
1st storage (a)
2nd storage (b)
3st storage (c)
0
t(s)
ON
1)
Rotation speed measurement
instruction execution condition OFF
3)
8
ON
CH1 rotation speed
in-measurement OFF
flag (SD1882.b5)
Rotation speed measurement value
(a)
(b)
(c)
0
Rotation speed measurement value data transition
1st storage (a)
+
+
4
+
Number
2nd storage (b)
+
+
4
+
3st storage (c)
+
+
4
+
Description
Turning on the execution command for Rotation speed measurement instruction (ICRCNT1) starts the following operations:
1)
• Measurement of the rotation speed
• CH1 Rotation speed in-measurement flag (SD1882.b5) changes from operation stop(0) to operating(1).
While processing the execution command for Rotation speed measurement instruction (ICRCNT1), a measured rotation
2)
speed value is written to the device specified by the Rotation speed measurement instruction (ICRCNT1). As the rotation
speed moving average processing count is set as 4 times, an average of the 4 counts is saved.
Turning off the execution command for Rotation speed measurement instruction (ICRCNT1) starts the following operations:
• Measurement of the rotation speed stops
3)
• CH1 Rotation speed in-measurement flag (SD1882.b5) changes from operating (1) to operation stop (0).
• The measured rotation speed value becomes 0. (The rotation speed is not saved to the setting data of Rotation speed
measurement instruction (ICRCNT1). )
235
8.6 Rotation Speed Measurement Mode
2)
0
(a) Precautions
To restart frequency measurement after an interruption, execute Rotation speed measurement instruction
(ICRCNT1) after "stopped (0)" is stored in CH1 Rotation speed in-measurement flag (SD1882.b5). If another
execution command of Rotation speed measurement instruction (ICRCNT1) is turned on, failing to check CH2
Rotation speed in-measurement flag (SD1882.b5), while the measurement is being executed, the command
may be ignored because the current measurement does not stop.
236
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.7
Pulse Measurement Mode
This section describes settings and functions that become valid when "Pulse Measurement Mode" is selected for
"Operation Mode Setting". In this mode, the on or off width of pulses that are input to Function input signal is
measured. The measured pulse value is written to the specified device using the Measured pulse value read
instruction (ICPLSRD1(P)). (
Page 258, Section 8.10.1 (9)) The following table shows I/O signals used in this
mode.
: Wiring required, ⎯: Wiring not required
Input signal
Operation
mode
Output signal
Phase
Phase
Phase
Function input
Latch counter
A
B
Z
signal
input signal
−*1
−*1
−*2
Coincidence
Coincidence
output No.1
output No.2
signal
signal
−*2
−*2
Pulse
measurement
−*2
mode
*1
*2
The input signal can be used for other functions such as the general-purpose input except the interrupt input.
The signals can be used for other functions such as the general-purpose input and output.
Note that the explanations in this section assume use of CH1. For the special relay, special register, dedicated
instructions, and error codes for CH2, refer to the following.
• Special relay and special register:
• Dedicated instructions:
• Error codes:
Page 244, Section 8.9 (2)
8
Page 245, Section 8.10
Page 269, Section 8.12 (1)
8.7 Pulse Measurement Mode
237
(1) Required settings
(a) Pulse measurement target setting
Select a target of pulse measurement from "Pulse ON Width" and "Pulse OFF Width".
ON width
OFF width
• The range of pulses that can be measured
Pulses can be measured within the range from 2000 to 2147483647 (0.2ms to approx. 214s). If the number
of pulses exceeds the range, "Pulse measurement range overflow error" (CH1 error code:3200) occurs.
To resume the measurement, perform either of the following operation. Note, however, that these operations
do not reset CH1 error code (SD1887), it must be reset by CH1 error reset command (SM1899).
• Input the pulse measurement target again. (Select on for on width and off for off width).
• Turn on CH1 pulse measurement start command (SM1898) after turning off the CH1 pulse measurement
start command (SM1898) and setting Pulse measurement flag to stopped(0).
• Update intervals of the pulse measurement
Update interval of the pulse measurement is 1ms. If pulses are measured twice or more often within 1ms,
only the last measured value is read out to the device by Measured pulse value read instruction
(ICPLSRD1(P)).
• Resolution of measured pulse value
The resolution of the measured pulse value varies by the input response time of Function input signal.
(Measured pulse value is the increments of the resolution.)
Input response time
Resolution(0.1µs)(time)
0.1ms
50(5µs)
1ms
500(50µs)
5ms
5000(500µs)
10ms
5000(500µs)
20ms
10000(1000µs)
70ms
50000(5000µs)
There is a margin of error for ±0.1ms in the measured pulse value, depending on the response time from the standard input
circuit.
238
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(2) Description
The following example describes the pulse measurement operation.
Ex. "Pulse ON Width" is selected for "Pulse Measurement Target Setting"
ON
Pulse measurement start command
(SM1898)
1)
3)
OFF
ON
2)
Function input signal
4)
OFF
Pulse measurement value
0
XXX
0
YYY
ON
Pulse in-measurement flag (SD1882.b6)
OFF
Number
1)
2)
3)
Description
When CH1 Pulse measurement start command turns on, 0 is set as a measured pulse value and then "operating (1)" is stored
in CH1 Pulse measurement flag (SD1882.b6).
After completion of the pulse measurement, the measured pulse value can be read to the specified device using Measured
pulse value read instruction (ICPLSRD1(P)).
8
When CH1 Pulse measurement start command is turned off, "stopped (0)" is stored in CH1 Pulse measurement flag
(SD1882.b6).
When the pulse measurement target is specified before "operating (1)" is stored in CH1 Pulse measurement flag (SD1882.b6),
a measured pulse value will not be updated even if the Function input signal is turned off. Only a value that is specified after
"operating (1)" is stored in CH1 Pulse measurement flag (SD1882.b6) can be measured.
Updating of a measured pulse value can be indirectly detected with Function input status (SD1883.b1).
Ex. With "Pulse ON Width" selected for "Pulse Measurement Target Setting", a measured pulse value is stored into D100.
239
8.7 Pulse Measurement Mode
4)
8.8
PWM Output Mode
This section describes settings and functions that become valid when "PWM Output Mode" is selected for "Operation
Mode Setting". With this mode, PWM waveforms at a maximum of 200kHz can be output from Coincidence output
No.1 signal. (This mode cannot be used for Coincidence output No.2 signal.) Set output waveforms using the PWM
output instruction (ICPWM1). (
Page 259, Section 8.10.1 (10)) The following table shows I/O signals used in this
mode.
: Wiring required, ⎯: Wiring not required
Input signal
Operation
mode
PWM output
mode
*1
*2
Output signal
Phase
Phase
Phase
Function input
Latch counter
A
B
Z
signal
input signal
⎯*1
⎯*1
⎯*2
⎯*2
⎯*2
Coincidence
Coincidence
output No.1
output No.2
signal
signal
⎯*2
The signals can be used for other functions such as the general-purpose input except the interrupt input.
The signals can be used for other functions such as the general-purpose input and output.
Note that the explanations in this section assume use of CH1. For the special register and dedicated instructions for
CH2, refer to the following.
• Special register:
Page 244, Section 8.9 (2)
• Dedicated instructions:
240
Page 245, Section 8.10
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(1) Required settings
(a) Output waveform setting
Store the values of on width and a cycle in the setting data of PWM output instruction (ICPWM1).
Setting item
Setting range
PWM output on width setting value
0 or 10 to 10000000 (0.1µs)
PWM output cycle setting value
50 to 10000000 (0.1µs)
Description
Set the on width of output pulses.
Set a cycle of output pulses.
Set these values so that PWM output on width setting value may be smaller than or equal to PWM output cycle
setting value.
PWM output on
width setting value
PWM output cycle setting value
8
PWM output on width =
*1
PWM output cycle
8.8 PWM Output Mode
Using a duty ratio*1, PWM output on width can be calculated by the following formula.
Duty ratio (%)
100
A duty ratio refers to the ratio between the on width of signals and cycle.
241
(2) Description
The operation of PWM output is shown below.
ON
PWM output instruction
execution command
1)
3)
OFF
PWM output on width setting value
1000
PWM output cycle setting value
2000
ON
Coincidence output
No.1 signal
2)
T1
OFF
T2
ON
CH1 PWM output flag
(SD1882. b7)
OFF
T1: PWM output on width setting value
T2: PWM output cycle setting value
Number
Description
Turning on the PWM output instruction (ICPWM1) execution command starts the following operations.
• The PWM output on width setting value and the PWM output cycle setting value of PWM output instruction (ICPWM1)
1)
become valid. (A value changed during PWM output is invalid.)
• PWM waveforms are output from Coincidence output No.1 signal. (Output is started with the signal off.)
• CH1 PWM output flag (SD1882. b7) turns from "not operating" (0) to "operating" (1).
2)
While the PWM output instruction (ICPWM1) execution command is established, the output of PWM waveforms is continued.
Turning off the PWM output instruction (ICPWM1) execution command starts the following operations.
3)
• The output of PWM waveforms from Coincidence output No.1 signal is stopped.
• CH1 PWM output flag (SD1882. b7) turns from "operating" (1) to "not operating" (0).
● Waveforms output from Coincidence output No.1 signal is susceptible to the output circuit of the LCPU and connected
devices. When setting output waveforms, observe waveforms with a synchroscope.
● Output of PWM waveforms is started with the signal off.
● Output waveforms can be changed while CH1 PWM output flag (SD1882. b7) is "not operating" (0). When PWM output
instruction (ICPWM1) is executed after output waveforms are changed, the waveforms after the change are output.
242
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.9
Specifications
(1) Performance specifications
The following is the performance specifications of the high-speed counter function.
Description
Item
L02CPU, L26CPU-BT
Number of channels
L02CPU-P, L26CPU-PBT
2
1-phase input (1 multiple/2 multiples)
Phase
CW/CCW,
2-phase input (1 multiple/2 multiples/4 multiples)
Count input
DC input
signal
Signal level
Differential
input
(AM26L31(manufactured by Texas Instruments Incorporated) or
equivalent)
Maximum counting speed
200k pulse/s (for 2 multiples of 1 phase and 4 multiples of 2 phases)
Counting range
-2147483648 to 2147483647
Model
Counter
24VDC, 6.0mA (TYP.)
EIA Standard RS-422-A Differential line driver level
UP/DOWN preset counter (with ring counter function)
Minimum count pulse width (Duty
1 phase
5µs
ratio 50%)
2 phases
10µs
Min. phase differential for 2-phase input
5µs
DC input
Phase Z (preset)
Differential
input
External input
24VDC, 6.0mA (TYP.)
(AM26L31(manufactured by Texas Instruments Incorporated) or
equivalent)
Function start
Phase Z: 10µs
Minimum input response time
Function start, latch: 100µs
Output type
Output
Coincidence output No.1/PWM
output
current
Coincidence output No.2
Comparison range
Coincidence
output
Sink type
voltage/
Response time
8.9 Specifications
24VDC, 4.1mA (TYP.)
Latch
External output
8
EIA Standard RS-422-A Differential line driver level
Source type
5 to 24VDC, 0.25A*1
5 to 24VDC, 0.1A
On
1µs or less (rated load, resistive load)
Off
1µs or less (rated load, resistive load)
-2147483648 to 2147483647
Set value < Counted value
Comparison result
Set value = Counted value
Set value > Counted value
PWM output
Pulse width
measurement
*1
Number of output points
2 points/channel
Output frequency range
DC to 200kHz
ON width
1µs
Duty ratio
On width can be set in increments of 0.1µs.
Number of output points
1 point/channel
Measurement item
Pulse width (On width: 200µs or more, Off width: 200µs or more)
Measurement resolution
5µs
Measurement points
1 point/channel
This is applicable for the CPU modules whose first six digits of the serial numbers are "120722" or later. "5 to 24VDC
0.1A" applies to the CPU modules whose first six digits of the serial numbers are "120721" or earlier. For how to check
serial numbers, refer to the following.
MELSEC-L CPU Module User's Manual (Hardware Design, Maintenance and Inspection)
243
(2) Special relay and special register
The following table lists the special relay (SM) and special register (SD) relevant to the high-speed counter
function.
in the name indicates either of 1 (CH1) or 2 (CH2). For details, refer to the following.
MELSEC-L CPU Module User's Manual (Hardware Design, Maintenance and Inspection)
Special register
Special relay number
CH1
CH2
SM1880
SM1900
SM1881
SM1901
Name
CH1
CH2
SD1880
SD1900
counter value coincidence (No.1)
SD1881
SD1901
CH
counter value greater (No.1)
CH
number
SM1882
SM1902
CH
counter value smaller (No.1)
SD1882
SD1902
SM1883
SM1903
CH
counter value greater (No.2)
SD1883
SD1903
SM1884
SM1904
counter value coincidence (No.2)
SD1884
SD1904
SM1885
SM1905
counter value smaller (No.2)
SD1885
SD1905
SD1886
SD1906
CH
CH
CH
external preset (phase Z) request
SM1886
SM1906
SM1887
SM1907
SM1888
SM1908
SM1890
SM1910
CH
coincidence signal No.1 reset command
SM1891
SM1911
CH
coincidence signal No.2 reset command
SM1892
SM1912
SM1893
SM1913
SM1894
SM1914
SM1895
SM1915
SM1896
SM1916
SM1897
SM1917
SM1898
SM1918
SM1899
SM1919
244
detection
CH
CH
CH
error
SD1887
SD1907
warning
SD1888
SD1908
Name
CH
CH
current value
CH
status monitor
external I/O status monitor
CH
CH
CH
operation mode monitor
counter type monitor
selected counter function
CH
CH
error code
warning code
coincidence output enable command
CH
CH
CH
CH
preset command
count down command
count enable command
selected counter function start
command
CH
external preset (phase Z) request
detection reset command
CH
pulse measurement start command
CH
error reset command
−
−
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.10
Dedicated Instructions
The following table lists and describes dedicated instructions for the high-speed counter function.
Ex. The current value read instruction for CH1 is ICCNTRD1(P) and for CH2 is ICCNTRD2(P).
Instruction
Description
CH1
CH2
ICCNTRD1(P)
ICCNTRD2(P)
Stores the current counter value in the special register.
ICRNGWR1(P)
ICRNGWR2(P)
Sets the upper limit value and lower limit value of a ring counter.
ICPREWR1(P)
ICPREWR2(P)
Sets a preset value (a value to replace another).
ICLTHRD1(P)
ICLTHRD2(P)
Stores a latch counter value.
ICSMPRD1(P)
ICSMPRD2(P)
Stores a sampling count value.
ICCOVWR1(P)
ICCOVWR2(P)
ICFCNT1
ICFCNT2
ICRCNT1
ICRCNT2
ICPLSRD2(P)
ICPWM1
ICPWM2
Measures frequency.
Measures rotation speed.
Stores a measured pulse value.
Outputs PWM waveforms.
Page 246, Section
8.10.1 (1)
Page 247, Section
8.10.1 (2)
Page 249, Section
8.10.1 (3)
Page 250, Section
8.10.1 (4)
Page 252, Section
8.10.1 (5)
Page 254, Section
8.10.1 (6)
Page 246, Section
8.10.1 (1)
Page 257, Section
8.10.1 (8)
8
Page 258, Section
8.10.1 (9)
Page 259, Section
8.10.1 (10)
245
8.10 Dedicated Instructions
ICPLSRD1(P)
Sets a coincidence output No.n point.
Reference
8.10.1
Details of dedicated instructions
(1) Current value read instructions: ICCNTRD1(P), ICCNTRD2(P)
Command
ICCNTRD1
ICCNTRD1
Command
ICCNTRD1P
ICCNTRD1P
Command
ICCNTRD2
ICCNTRD2
Command
ICCNTRD2P
ICCNTRD2P
Internal device
Setting
data
Bit
Word
⎯
⎯
⎯
J \
R, ZR
Bit
Word
⎯
⎯
Constant
Bit
Word
⎯
⎯
U \G
⎯
Z
⎯
K, H
$
⎯
⎯
Others
⎯
(a) Setting data
Setting data
Setting item
Setting range
Data type
⎯
⎯
⎯
⎯
(b) Function
Stores the current counter value in the special register.
The number of steps is basically one.
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• Other than "Normal Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
The latest value is stored into CH1 current value (SD1880, SD1881) when M0 turns on.
246
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(2) Ring counter upper/lower limit value write instructions: ICRNGWR1(P),
ICRNGWR2(P)
Command
ICRNGWR1
ICRNGRWR1
S1
S2
ICRNGRWR1P
S1
S2
ICRNGRWR2
S1
S2
ICRNGRWR2P
S1
S2
Command
ICRNGWR1P
Command
ICRNGWR2
Command
ICRNGWR2P
Setting
Internal device
data
Bit
S1
⎯
S2
⎯
Word
J \
R, ZR
Constant
U \G
Z
Word
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
Bit
Word
K, H
$
Others
Bit
Setting
data
Setting item
Setting range
Data type
• Start number of the device where a
ring counter lower limit value
S1
(constant) or a ring counter lower limit
value is stored
• Ring counter upper limit value
(constant) or start number of the
S2
• Constant: a value within -2147483648 to
2147483647 and is ( S1 ,
S1 +1)
≤ ( S2 ,
S2
+1)
• Device: within the range of the specified device
• Constant: BIN 32-bit
• Device: device name
device where a ring counter upper
limit value is stored
(b) Function
This instruction sets the upper limit value and lower limit value of a ring counter.
The number of steps is basically three.
247
8.10 Dedicated Instructions
8.10.1 Details of dedicated instructions
(a) Setting data
8
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• Ring counter lower limit value is greater than ring counter upper limit value
(Error code: 4100)
• The devices specified in
S1
and
S2
are exceeding their range.
(Error code: 4101)
• Other than "Normal Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• Other than "Ring Counter" is selected for "Counter Format" of the specified device.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
100000 is set to a ring counter lower limit value of CH1 and 100000 to a ring counter upper limit value when M0
turns on.
248
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(3) Preset value write instructions: ICPREWR1(P), ICPREWR2(P)
Command
ICPREWR1
ICPREWR1
S
ICPREWR1P
S
ICPREWR2
S
ICPREWR2P
S
Command
ICPREWR1P
Command
ICPREWR2
Command
ICPREWR2P
Internal device
Setting
data
Bit
S
⎯
Word
J \
R, ZR
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
⎯
Z
K, H
$
Others
⎯
⎯
8
(a) Setting data
Setting data
Setting range
• Preset value setting (constant)
• Constant: -2147483648 to 2147483647
• Start number of the device where a
• Device: within the range of the specified
value to replace is stored
device
Data type
• Constant: BIN 32-bit
• Device: device name
(b) Function
This function sets a preset value (a value to replace another).
The number of steps is basically two.
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• The device specified in
S
is exceeding its range.
(Error code: 4101)
• Other than "Normal Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
10000 is set as the preset value of CH1 when M0 turns on.
249
8.10 Dedicated Instructions
8.10.1 Details of dedicated instructions
S
Setting item
(4) Latch counter value read instructions: ICLTHRD1(P), ICLTHRD2(P)
Command
ICLTHRD1
ICLTHRD1
n
D
ICLTHRD1P
n
D
ICLTHRD2
n
D
ICLTHRD2P
n
D
Command
ICLTHRD1P
Command
ICLTHRD2
Command
ICLTHRD2P
Internal device
Setting
data
Bit
n
⎯
D
⎯
Word
J \
R, ZR
Constant
U \G
Bit
Word
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
Bit
Word
Z
K, H
⎯
$
Others
⎯
⎯
⎯
⎯
(a) Setting data
Setting data
n
D
Setting item
Latch count value number
Data type
1, 2
BIN 16-bit
Start number of the device where a latch count value is
Within the range of the specified
stored
device
(b) Function
This instruction stores a latch count value n into
The number of steps is basically three.
250
Setting range
D
and
D
+1.
Device name
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• Other than 1 or 2 is specified to n.
(Error code: 4100)
• The device specified in
D
is exceeding its range.
(Error code: 4101)
• Inapplicable device is specified in
D
.
(Error code: 4101)
• While 1 is specified to n, other than "Latch Counter Function" or "Latch Counter/Preset Function" is
selected for "Counter Function Selection".
(Error code: 4116)
• While 2 is specified to n, other than latch counter input signal is set to external input signals X8 and X9.
(Error code: 4116)
• Other than "Normal Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
The latch count value 1 of CH1 is stored into D100 and D101 when M0 turns on.
8
8.10 Dedicated Instructions
8.10.1 Details of dedicated instructions
251
(5) Sampling count value read instructions: ICSMPRD1(P), ICSMPRD2(P)
Command
ICSMPRD1
ICSMPRD1
D
ICSMPRD1P
D
ICSMPRD2
D
ICSMPRD2P
D
Command
ICSMPRD1P
Command
ICSMPRD2
Command
ICSMPRD2P
Internal device
Setting
data
Bit
D
⎯
Word
J \
R, ZR
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
Z
⎯
K, H
$
⎯
⎯
Others
⎯
(a) Setting data
Setting data
Setting item
Setting range
Start number of the device where a sampling count
D
Within the range of the specified
value setting is stored
device
(b) Function
This instruction stores a sampling count value into
The number of steps is basically two.
252
D
and
D
+1.
Data type
Device name
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• Inapplicable device is specified in
D
.
(Error code: 4101)
• The device specified in
D
is exceeding its range.
(Error code: 4101)
• Other than "Sampling Counter Function" is selected for "Counter Function Selection" of the specified
device.
(Error code: 4116)
• Other than "Normal Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
A sampling count value of CH1 is stored into D100 and D101 when M0 turns on.
8
8.10 Dedicated Instructions
8.10.1 Details of dedicated instructions
253
(6) Coincidence output point write instructions: ICCOVWR1(P), ICCOVWR2(P)
Command
ICCOVWR1
ICCOVWR1
n
S
ICCOVWR1P
n
S
ICCOVWR2
n
S
ICCOVWR2P
n
S
Command
ICCOVWR1P
Command
ICCOVWR2
Command
ICCOVWR2P
Setting
Internal device
data
Bit
n
⎯
S
⎯
Word
J \
R, ZR
Constant
U \G
Z
Word
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
Bit
Word
K, H
$
Others
Bit
(a) Setting data
Setting data
Setting item
Setting range
Data type
n
Coincidence output No.n point number
1, 2
BIN 16-bit
• Coincidence output No.n point setting
(constant)
S
• Start number of the device where
Coincidence output No.n point setting
• Constant: -2147483648 to 2147483647
• Device: within the range of the specified
device
is stored
(b) Function
This function sets a coincidence output No.n point.
The number of steps is basically three.
254
• Constant: BIN 32-bit
• Device: device name
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• Other than 1 or 2 is specified to n.
(Error code: 4100)
• Inapplicable device is specified in
S
.
(Error code: 4101)
• The device specified in
S
is exceeding its range.
(Error code: 4101)
• Other than "Normal Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
Values in D100 and D101 are set to coincidence output No.2 point setting of CH1 when M0 turns on.
8
8.10 Dedicated Instructions
8.10.1 Details of dedicated instructions
255
(7) Frequency measurement instructions: ICFCNT1, ICFCNT2
Command
ICFCNT1
ICFCNT1
D
ICFCNT2
D
Command
ICFCNT2
Internal device
Setting
data
Bit
D
⎯
J \
R, ZR
Word
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
Z
⎯
K, H
$
⎯
⎯
Others
⎯
(a) Setting data
Setting data
Setting item
Start number of the device where a measured
D
frequency value is stored
Setting range
Data type
Within the range of the
Device name
specified device
(b) Function
This instruction measures frequencies according to the value set to "Frequency Measurement Unit Time
Setting". When ICFCNT1 is executed, a measured value is stored into
D
and
D
+1. Frequency measurement
starts at rising of the ICFCNT1 execution command and ends at falling.
The number of steps is basically two.
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• The device specified in
D
is exceeding its range.
(Error code: 4101)
• Other than "Frequency Measurement Mode" is selected for "Operation Mode Setting" of the specified
channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
Frequencies are measured at CH1 while M0 is on.
256
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(8) Rotation speed measurement instructions: ICRCNT1, ICRCNT2
Command
ICRCNT1
ICRCNT1
D
ICRCNT2
D
Command
ICRCNT2
Internal device
Setting
data
Bit
D
⎯
J \
R, ZR
Word
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
Z
⎯
K, H
$
⎯
⎯
Others
⎯
(a) Setting data
Setting data
D
Setting item
Setting range
Start number of the device where a measured
Within the range of the
rotation speed value is stored
specified device
Data type
8
Device name
(b) Function
Time Setting". When ICRCNT1 is executed, a measured value is stored into
D
and
D
+1. Rotation speed
measurement starts at rising of the ICRCNT1 execution command and ends at falling.
The number of steps is basically two.
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• The device specified in
D
is exceeding its range.
(Error code: 4101)
• Other than "Rotation Speed Measurement Mode" is selected for "Operation Mode Setting" of the specified
channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
A measured rotation speed value of CH1 is stored into D100 and D101 while M0 is on.
257
8.10 Dedicated Instructions
8.10.1 Details of dedicated instructions
This instruction measures rotation speed according to the value set to "Rotation Speed Measurement Unit
(9) Measured pulse value read instructions: ICPLSRD1(P), ICPLSRD2(P)
Command
ICPLSRD1
ICPLSRD1
D
ICPLSRD1P
D
ICPLSRD2
D
ICPLSRD2P
D
Command
ICPLSRD1P
Command
ICPLSRD2
Command
ICPLSRD2P
Internal device
Setting
data
Bit
D
⎯
J \
R, ZR
Word
Bit
Word
⎯
Constant
Bit
Word
⎯
⎯
U \G
Z
⎯
K, H
$
⎯
⎯
Others
⎯
(a) Setting data
Setting data
D
Setting item
Setting range
Start number of the device where a measured pulse
Within the range of the
value is stored
specified device
Data type
Device name
(b) Function
This instruction stores a measured pulse into
D
and
D
+1.
The number of steps is basically two.
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• The device specified in
D
is exceeding its range.
(Error code: 4101)
• Other than "Pulse Measurement Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
A measured pulse value of CH1 is stored into D100 and D101 when M0 turns on.
258
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(10)PWM output instructions: ICPWM1, ICPWM2
Command
ICPWM1
ICPWM1
S1
S2
ICPWM2
S1
S2
Command
ICPWM2
Setting
Internal device
data
Bit
S1
⎯
S2
⎯
Word
J \
R, ZR
Constant
U \G
Z
Word
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
⎯
Word
K, H
$
Others
Bit
Bit
(a) Setting data
Setting data
Setting item
• PWM output on width setting value
(constant)
S1
• Start number of the device where a
stored
• PWM output cycle setting value
(constant)
S2
• Start number of the device where a
PWM output cycle setting value is
stored
8
Data type
• Constant: 0 or a value within 10 to 107
+1)
• Constant: BIN 32-bit
• Device: within the range of the specified
• Device: device name
(0.1µs) and is ( S1 ,
S1 +1)
≤ ( S2 ,
S2
device
• Constant: a value within 50 to 107 (0.1µs)
and is ( S1 ,
S1 +1)
≤ ( S2 ,
S2
+1)
• Device: within the range of the specified
• Constant: BIN 32-bit
• Device: device name
device
259
8.10 Dedicated Instructions
8.10.1 Details of dedicated instructions
PMW output on width setting value is
Setting range
(b) Function
This instruction outputs PWM waveforms. The PWM waveform of the on width ( S1 and
and
S2
S1 +1)
and cycle ( S2
+1) is output from the coincidence output No.1 signal while ICPWM1 is being executed. Outputting of
the PWM waveform starts from the off status of the instruction.
S1 , S1
S2 , S2
+1
+1
The number of steps is basically three.
(c) Error
In the following cases, an operation error occurs. The error flag (SM0) turns on and an error code is stored into
SD0.
• Values outside the range are specified in
S1
and
S2
.
(Error code: 4100)
• The data set to
S1
and
S1 +1
is greater than
S2
and
S2
+1.
(Error code: 4100)
• The devices specified in
S1
and
S2
are exceeding their range.
(Error code: 4101)
• Other than "PWM Output Mode" is selected for "Operation Mode Setting" of the specified channel.
(Error code: 4116)
• High-speed counter function of the specified channel is not enabled.
(Error code: 4116)
(d) Program example
The PWM waveform with 1µs of on width and 5µs of cycle is output from CH1 while M0 is on.
260
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.10.2
Precautions on dedicated instructions
This section describes the precautions for the following instructions.
• ICFCNT1
• ICRCNT1
• ICPWM1
(1) Multiple instruction executions in one scan
The instruction may not be successfully processed if it is executed to the same channel more than one time in
one scan.
(2) Programs with single instruction execution
Programs do not normally processed if any of the instructions is executed in the program that is executed only
once, because the off status of the execution command cannot be detected. Use the instruction in a program,
such as a scan program, where the off status of an execution command can be detected.
(3) Instructions not requiring an execution command
The following instructions are executed even while the execution command is off, because they can be executed
at any time. Therefore, errors can occur even while an execution command is off.
• ICFCNT1
8
• ICRCNT1
• ICPWM1
8.10 Dedicated Instructions
8.10.2 Precautions on dedicated instructions
261
8.11
Programming
This section describes the programs for the high-speed counter function. When applying the program examples
introduced in this section to an actual system, ensure the applicability and confirm that it will not cause system control
problems.
(1) Programming procedure
Start
Use the program in Normal mode?
NO
YES
Common programs in Normal mode
Page 265, Section 8.11 (3) (a)
Programs for each function
Preset function program
Coincidence output function program
Latch counter 1 program
Latch counter 2 program
Count disable function program
Sampling counter function program
Latch counter and preset function program
Overflow detection processing program
Programs for each operation mode
Frequency measurement mode program
Rotation speed measurement mode program
Pulse measurement mode program
PWM output mode program
Page 266, Section 8.11 (3) (j)
to Page 266, Section 8.11 (3) (m)
Page 265, Section 8.11 (3) (b)
to Page 266, Section 8.11 (3) (i)
Errors and warnings reset programs
Page 266, Section 8.11 (3) (n)
End
(a) Precautions
Create programs only for the functions to be used.
An error may be caused if a program for the function that is not to be used is executed.
Ex. A frequency mode program is created and executed in the normal mode.
262
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(2) System configuration and programing condition
The following system configuration is used to introduce program examples.
(a) System configuration
LCPU
CH1 encoder
LY42NT1P (Y70 to YAF)
CH2 encoder
LX42C4 (X30 to X6F)
(b) Programming conditions
Device
Function
X50
CH1 count start signal
X51
CH1 count stop signal
X52
CH1 current value read signal
X53
CH1 preset command signal
CH1 counter function execution start signal
X55
CH1 counter function execution stop signal
X56
CH1 latch 1 execution command signal
X57
CH1 latch count data 1 read signal
X58
CH1 latch count data 2 read signal
X59
CH1 sampling count start signal
X5A
CH1 sampling count data read signal
X5B
CH1 coincidence output enable signal
X5C
CH1 coincidence LED clear signal
X5D
CH1 frequency measurement command signal
X5E
CH1 rotation speed measurement command signal
X5F
CH1 pulse measurement command signal
X60
CH1 measured pulse value read signal
X61
CH1 PWM output command signal
X62
CH1 error reset command signal
Y70
CH1 coincidence confirmation LED signal
Y71
CH1 overflow occurrence confirmation LED
D2000
D2001
D2002
D2003
D2004
D2005
D2006
D2007
8
8.11 Programming
X54
LX42C4 (X30 to X6F)
LY42NT1P (Y70 to YAF)
CH1 current value storage
CH1 latch count value 1 storage
CH1 latch count value 2 storage
CH1 sampling count value storage
(To the next page)
263
Device
D2008
D2009
D2010
D2011
D2012
D2013
CH1 measured frequency value storage
CH1 measured rotation value storage
CH1 measured pulse value storage
D2014
CH1 error code storage
D2015
CH1 warning code storage
D2020
CH1 error code acquisition
D2021
CH1 warning code acquisition
SM1881
CH1 counter value coincidence (No.1)
SM1887
CH1 error
SM1888
CH1 warning
SM1890
CH1 coincidence signal No.1 reset command
SM1892
CH1 coincidence output enable command
SM1893
CH1 preset command
SM1894
CH1 count down command
SM1895
CH1 count enable command
SM1896
CH1 selected counter function start command
SM1897
CH1 external preset (phase Z) request detection reset command
SM1898
CH1 pulse measurement command signal
SM1899
CH1 error reset command
SD1880
SD1881
SD1882
264
Function
CH1 current value
CH1 status monitor
SD1887
CH1 error code
SD1888
CH1 warning code
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(3) Program example
The following are program examples of CH1. Note that the coincidence output signal No.2 is on by default (not
indicated in the examples below).
Also note that when CH1 coincidence output enable command (SM1892) turns on, Coincidence output No.2
signal also turns on.
(a) Common program in Normal mode
Preset value: 1000
Ring counter lower limit value: -30000
Ring counter upper limit value: 30000
Coincidence output No.1 point: 1000
Coincidence signal No.1 reset
command: On
Count enable command: On
Count enable command: Off
The current value is stored in D2000.
(b) Preset function program
Preset command
8
(c) Coincidence output function program
Coincidence output enable command
Coincidence confirmation LED signal
Coincidence signal No.1 reset command: Off
(d) Latch counter 1 program
Selected counter function start command
A latch count value 1 is stored in D2002.
(e) Latch counter 2 program
A latch count value 2 is stored in D2004.
(f) Count disable function program
Selected counter function start command: On
Selected counter function start command: Off
(g) Sampling counter function program
Selected counter function start
command
A sampling count value is stored
in D2006.
265
8.11 Programming
Coincidence signal No.1 reset command: On
(h) Latch counter and preset function program
A latch count value is stored in D2002.
(i) Overflow detection processing program
Overflow occurrence confirmation
LED signal
(j) Frequency measurement mode program
A measured frequency value is stored
in D2008.
(k) Rotation speed measurement mode program
A measured rotation speed value is
stored in D2010.
(l) Pulse measurement mode program
Pulse measurement start command
A measured pulse value is stored
in D2012.
(m) PWM output mode program
PWM output on time: 0.1ms
PWM output cycle setting value: 0.2ms
and 5kH are output.
(n) Error, warning reset program
An error code is stored in D2014.
A warning code is stored in D2015.
CH1 error reset command
266
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
(4) Program example with the coincidence detection interrupt function
This section introduces an example of interrupt program where CH1 counter value coincidence (No.1) (SM1881)
is used. Before using an interrupt pointer, enable an interruption with the IMASK instruction. For details on the
IMASK instruction, refer to the following.
MELSEC-Q/L Programming Manual (Common Instruction)
(a) System configuration
LCPU
(b) Programming conditions
Provide D20 to enable an interruption of I0.
Device
Function
Setting value
1
D21
0
D22
0
D23
0
D24
0
D25
0
D26
0
D27
D28
IMASK instruction interruption enable flag storage device
8
8.11 Programming
D20
0
0
D29
0
D30
0
D31
0
D32
0
D33
0
D34
0
D35
0
267
(c) Program example
Program for the high-speed counter function
Interrupt program
268
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.12
Errors and Warnings
This section describes errors and warnings of the high-speed counter function.
(1) Error
When an error occurs, the following operations are performed.
• The I/O ERR. LED turns on.
• The CH1 error (SM1887) turns on.
• An error code corresponding to the error is stored to the CH1 error code (SD1887) in decimal.
Interface
Special relay
Special register
Channel
Number
CH1
SM1887
CH2
SM1907
CH1
SM1899
CH2
SM1919
CH1
SD1887
CH2
CH
error
CH1
CH
error code.
• Resets CH
error reset
command
error.
• Turns off CH
An error code is stored upon error. The stored value
CH
error code
is reset when CH
error reset command is turned
on.
error codes.
Operation at error
Error name
Description
Normal
⎯
CH2
0
high-speed counter function.Turns off when CH
error reset command is turned on.
error code
(decimal)
Description
Indicates whether to an error has occurred in the
SD1907
The following table lists the CH
CH
Name
occurrence
CH with an
The other
error
CH
⎯
⎯
Corrective action
⎯
value (SD1880, SD1881) has
3100
4100
exceeded the following range.
error
-2147483648 to 2147483647
The linear
Replace the value by
counter function
performing the preset
stops counting.
(Linear counter function only)
Pulse
3200
4200
measurement
range overflow
error
function.
Note
affected.
Enter the measurement
The measurement target pulse
Stops
target again, or turn on,
has exceeded the measurable
measurement
off, and then on CH1 pulse
range (approx. 214s)
of pulse.
measurement start
command.
● If another error occurs while an error is present, the latest error code will not be stored.
● To reset an error code, remove the error cause first and then reset with CH1 error reset command (SM1899). If the error
is reset without removing the error cause, it is detected again and the error code is stored.
269
8.12 Errors and Warnings
The value in CH1 current
Over/Underflow
8
(2) Warning
When a warning occurs, the following operations are performed.
• The CH1 warning (SM1888) turns on.
• A warning code corresponding to the warning is stored to the CH1 warning code (SD1888) in decimal.
Different from errors, occurrence of a warning does not stop the operation of CH1. The SD value is always
updated with the latest warning code.
Interface
Special relay
Special register
Channel
Number
CH1
SM1888
CH2
SM1908
CH1
SM1899
CH2
SM1919
CH1
SD1888
CH2
CH1
CH
error reset
• Resets CH
warning code.
• Turns off CH
warning.
A corresponding warning code is stored upon
CH
warning code
warning. The stored value is reset when CH
error reset command is turned on.
warning codes.
Name
Description
Normal
⎯
The sampling count value
4050
error reset command is turned on.
Operation at warning
Sampling
3050
counter function has occurred.Turns off when
command
CH2
0
warning
CH
warning code
(decimal)
Description
Indicates whether to a warning of the high-speed
CH
SD1908
The following table lists the CH
CH
Name
count value
has exceeded the following
range.
overflow
-2147483648 to 2147483647
occurrence
CH with a
The other
warning
CH
⎯
⎯
⎯
Check that the value
Store either value
of -2147483648 or
Note
2147486347 and
affected.
continue counting.
Corrective action
obtained from "Input pulse
speed (pulse/s) × sampling
time" does not exceed the
range.
To reset a warning code, remove the cause first and then reset with CH1 error reset command (SM1899). If the warning is
reset without removing the cause, it is detected again and the warning code is stored.
270
CHAPTER 8 HIGH-SPEED COUNTER FUNCTION
8.13
When the LCPU Stops Operation
The following shows the function status when the LCPU stopped its operation.
Function
Operation
Linear counter function
Ring counter function
Preset function
Coincidence
output
function
Preset at coincidence output function
Coincidence detection interrupt function
Latch counter function
Continues the previous operation before the LCPU stopped.
Latch counter function
Counter
Count disable function
function
Sampling counter function
selection
Count disable/preset function
Latch counter/preset function
Internal clock function
Stops the frequency measurement. The frequency that has been used for
Frequency measurement function
moving average processing is abandoned. When the CPU module is switched
to the RUN status, executing Frequency measurement instruction (ICFCNT1)
starts measuring frequencies.
Stops the rotation speed measurement. The rotation speed that has been used
Rotation speed measurement function
8
for moving average processing is abandoned. After the CPU module is
switched to the RUN status, turning on Rotation speed measurement
instruction (ICRCNT1) starts measuring rotation speed.
the RUN status, this function operates according to CH1 pulse measurement
start command (SM1898).
Stops outputting PWM waveforms. When the CPU module is switched to the
PWM output function
RUN status, executing PWM output instruction (ICPWM1) starts outputting
PWM waveforms.
271
8.13 When the LCPU Stops Operation
Stops the rotation speed measurement. When the CPU module is switched to
Pulse measurement function
8.14
Monitoring with a Programming Tool
When the high-speed function is executed, the operating status can be checked on the "High-Speed Counter Monitor"
window of the programming tool.
[Tool]
[Built-in I/O Module Tool]
For details, refer to the follwoing.
GX Works2 Version1 Operating Manual (Common).
272
APPENDICES
APPENDICES
Appendix 1
A
Processing Time of Each Instruction
The following tables list operation processing time values of the instructions introduced in this manual.
For the operation processing time of the LCPU, refer to the following.
MELSEC-Q/L Programming Manual (Common Instruction)
(1) Dedicated instructions for the positioning function
Processing time (µs)
Category
Instruction
IPPSTRT1
IPPSTRT2
IPDSTRT1
IPDSTRT2
IPSIMUL
IPOPR1
IPOPR2
Dedicated
instruction
(positioning
function)
IPJOG1
IPJOG2
IPABRST1
IPSTOP1
IPSTOP2
IPSPCHG1
IPSPCHG2
IPTPCHG1
IIPTPCHG2
L02CPU, L02CPU-P
L26CPU-BT, L26CPU-PBT
Minimum
Maximum
Minimum
Maximum
⎯
9.90
9.90
7.30
7.30
⎯
15.60
15.60
11.90
11.90
⎯
14.70
14.70
11.80
11.80
⎯
15.50
15.50
11.40
11.40
⎯
21.30
21.30
16.20
16.20
⎯
31.60
31.60
26.00
26.00
⎯
3.80
3.80
3.10
3.10
⎯
17.50
17.50
13.40
13.40
⎯
6.90
6.90
5.30
5.30
273
Appendix 1 Processing Time of Each Instruction
IPABRST2
Trigger
(2) Dedicated instructions for the high-speed counter function
Processing time (µs)
Category
Instruction
ICCNTRD1
ICCNTRD2
ICRNGWR1
ICRNGWR2
ICPREWR1
ICPREWR2
ICLTHRD1
ICLTHRD2
ICSMPRD1
Dedicated
instruction
(high-speed
counter
function)
ICSMPRD2
ICCOVWR1
ICCOVWR2
ICFCNT1
ICFCNT2
ICRCNT1
ICRCNT2
L26CPU-BT, L26CPU-PBT
Maximum
Minimum
Maximum
⎯
2.10
4.60
1.60
3.80
⎯
3.40
6.70
2.70
5.40
⎯
2.50
4.90
1.70
3.80
⎯
3.60
8.90
3.20
6.30
⎯
2.70
7.00
2.40
5.20
⎯
3.00
6.40
2.50
4.80
Contact OFF → ON
9.50
9.50
6.90
6.90
Contact OFF → ON
10.00
10.00
7.20
7.20
2.70
7.10
2.30
5.20
Contact OFF → ON
10.00
10.00
8.00
8.00
Contact ON → ON
6.90
6.90
4.60
4.60
Contact OFF → ON
10.00
10.00
8.00
8.00
Contact ON → ON
6.90
6.90
4.60
4.60
⎯
ICPLSRD2
⎯
ICPWM2
L02CPU, L02CPU-P
Minimum
ICPLSRD1
ICPWM1
274
Condition
APPENDICES
Appendix 2
Appendix 2.1
Connection Examples with Servo Amplifiers
A
Connection examples with servo amplifiers
manufactured by Mitsubishi
(1) Connection example with MR-JN series*5
Configure a sequence program in which MC is turned off using Alarm signal
and an emergency stop switch.
NF
MC
Power
Single phase
(200VAC)
Servo motor
CNP1 MR-JN
L1
L2
P
C
U
V
W
CNP1 U
V
W
PE
PE
RA2
24VDC
EM1
*1
OUT4
OUT-COM
OUT6
OUT-COM
B03
B01
B02
B01
OUT2
OUT-COM
B04
B01
IN4-24V
IN4-DIFF
IN4-COM
B14
B13
B12
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
B20
B19
B18
B17
B16
B15
CN1
PP
23
NP
25
CR
DO COM
DI COM
OPC
5
13
1
2
LZ
LZR
19
20
LA
LAR
15
16
LB
LBR
17
18
SD
Plate
EM1
SON
RES
8
4
3
LSP
LSN
DO COM
6
7
13
DI COM
ALM
RD
MBR
INP
1
9
11
12
10
*3
This relay is turned off when
Servo on signal turns off and
Alarm signal turns on.
CN2
Personal computer
24VDC 0.3A
24V power
Near-point watchdog
INA
B08
INC
B07
INE
IN-COM
B06
B11
+
External emergency stop
Servo on
Reset
Lower limit
*2 Forward run stroke end
*2 Reverse run stroke end
24VDC
Failure
Ready
Electromagnetic brake interlock
Positioning completion
*1
*2
*3
*4
*5
RA1
RA2
RA3
RA4
CN3
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
These are limit switches for the servo amplifier (for stop).
For details on connection, refer to the instruction manual of the servo amplifier MR-JN.
This is a distance between the LCPU and the servo amplifier.
This series cannot be connected to the L02CPU-P and L26CPU-PBT.
Page 48, Section 7.2.
275
Appendix 2 Connection Examples with Servo Amplifiers
Appendix 2.1 Connection examples with servo amplifiers manufactured by Mitsubishi
Upper limit
B2 Electromagnetic
brake
Encoder
Within 2m*4
LCPU
SM
E
B1
A series*5
(2) Connection example with MR-J3-
Configure a sequence program in which MC is turned off using Alarm signal
and an emergency stop switch.
NF
MC
*1
B03
B01
B02
B01
OUT2
OUT-COM
B04
B01
IN4-24V
IN4-DIFF
IN4-COM
B14
B13
B12
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
B20
B19
B18
B17
B16
B15
U
V
W
CNP3 U
V
W
PE
PE
CN1
PP
10
NP
35
CR
DO COM
DI COM
OPC
41
46
20
12
LZ
LZR
8
9
LA
LAR
4
5
LB
LBR
6
7
SD
Plate
24VDC
EMG
*3
CN2
Personal computer
+
24V power
-
Near-point watchdog
B08
INC
B07
INE
IN-COM
B06
B11
Upper limit
Lower limit
*2
*2
24VDC
B2 Electromagnetic
brake
This relay is turned off when
Servo on signal turns off and
Alarm signal turns on.
24VDC 0.3A
INA
SM
E
B1
Encoder
LCPU
CNP1 MR-J3- A
L11 CNP2
L21
C
D
P
Within 2m*4
OUT4
OUT-COM
OUT6
OUT-COM
Servo motor
L1
L2
L3
N
P1
P2
Power
3-phase
(200VAC)
CN5
External emergency stop
Servo on
Reset
Proportional control
Torque control
Forward run stroke end
EMG
SON
RES
PC
TL
LSP
Reverse run stroke end
LSN
DO COM
42
15
19
17
18
43
44
47
DI COM
ALM
ZSP
TLC
INP
21
48
23
25
24
P15R
TLA
LG
SD
1
27
28
Plate
Failure
Zero speed detection
Torque limit
Positioning completion
RA1
RA2
RA3
RA4
Monitor output
CN6
3
1
2
MO1
LG
MO2
10k
10k
Analog torque limit
+10V/maximum current
Within 2m
*1
*2
*3
*4
*5
276
Within 2m
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
Page 48, Section 7.2.
These are limit switches for the servo amplifier (for stop).
For details on connection, refer to the manual of the servo amplifier MR-J3.
This is a distance between the LCPU and the servo amplifier.
Cannot be connected to L02CPU-P and L26CPU-PBT. This series cannot be connected to the L02CPU-P and L26CPUPBT.
APPENDICES
Appendix 2.2
Connection examples with stepping motors
manufactured by ORIENTAL MOTOR CO.,LTD.
A
(1) Connection example with RK series*4
Within 2m*3
RK series*2
LCPU
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
*1
B20
B19
B18
B17
B16
B15
IN4-24V
IN4-DIFF
IN4-COM
B14
B13
B12
OUT2
OUT-COM
B04
B01
OUT4
OUT-COM
B03
B01
OUT6
OUT-COM
B02
B01
P5V
5VG
17 +TIM.
18 -TIM.
1 CW+
2 CW3 CCW+
4 CCWConnect as necessary.
B08
INC
B07
INE
IN-COM
B06
B11
19 +O.H.
20 -O.H.
Near-point watchdog
Upper limit
Lower limit
24VDC
*1
*2
*3
*4
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
Page 48, Section 7.2.
Refer to the manual of the stepping motor drive for information on the stepping motor drive side wiring and various signal
wire shields not shown above.
This is a distance between the LCPU and the stepping motor.
This series cannot be connected to the L02CPU-P and L26CPU-PBT.
277
Appendix 2 Connection Examples with Servo Amplifiers
Appendix 2.2 Connection examples with stepping motors manufactured by ORIENTAL MOTOR
CO.,LTD.
INA
5 +A.W.OFF
6 -A.W.OFF
(2) Connection example with AR series*4
Within 2m*3
AR series*2
LCPU
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
IN4-24V
IN4-DIFF
IN4-COM
*1
B20
B19
B18
B17
B16
B15
B14
B13
B12
OUT2
OUT-COM
B04
B01
OUT4
OUT-COM
B03
B01
OUT6
OUT-COM
B02
B01
3 ASG+
4 ASG5 BSG+
6 BSG7 TIM1+
8 TIM1-
24 CLR/ALM-RST
31 CW+/PLS+
32 CW-/PLS35 CCW+/DIR+
36 CCW-/DIR-
P5V
5VG
INA
B08
INC
B07
INE
IN-COM
B06
B11
22
23
26
21
IN-COM
C-ON
CS
GND
Near-point watchdog
Upper limit
Lower limit
24VDC
*1
*2
*3
*4
278
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
Page 48, Section 7.2.
Refer to the manual of the stepping motor drive for information on the stepping motor drive side wiring and various signal
wire shields not shown above.
This is a distance between the LCPU and the stepping motor.
This series cannot be connected to the L02CPU-P and L26CPU-PBT.
APPENDICES
Appendix 2.3
Connection examples with servo amplifiers
manufactured by Panasonic Corporation
A
(1) Connection example with MINAS-A4 series*4
Within 2m*3
MINAS-A4 series*2
LCPU
OUT2
OUT-COM
B04
B01
OUT4
OUT-COM
B03
B01
OUT6
OUT-COM
B02
B01
INA
B08
INC
B07
INE
IN-COM
B06
B11
21 OA+
22 OA48 OB+
49 OB23 OZ+
24 OZ-
30 CL
1
4
2
6
P24V
24VG
7
29
9
8
OPC1
PULS2
OPC2
SIGN2
COM+
SRV-ON
CCWL
CWL
Near-point watchdog
Upper limit
Lower limit
24VDC
*1
*2
*3
*4
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
Page 48, Section 7.2.
Refer to the manual of the servo amplifier for information on the servo amplifier side wiring and various signal wire
shields not shown above.
This is a distance between the LCPU and the servo amplifier.
This series cannot be connected to the L02CPU-P and L26CPU-PBT.
279
Appendix 2 Connection Examples with Servo Amplifiers
Appendix 2.3 Connection examples with servo amplifiers manufactured by Panasonic Corporation
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
IN4-24V
IN4-DIFF
IN4-COM
*1
B20
B19
B18
B17
B16
B15
B14
B13
B12
(2) Connection example with MINAS-E series*4
Within 2m*3
MINAS-E series*2
LCPU
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
IN4-24V
IN4-DIFF
IN4-COM
*1
B20
B19
B18
B17
B16
B15
B14
B13
B12
OUT2
OUT-COM
B04
B01
OUT4
OUT-COM
B03
B01
OUT6
OUT-COM
B02
B01
INA
B08
INC
B07
INE
IN-COM
B06
B11
15 OA+
16 OA17 OB+
18 OB19 OZ+
20 OZ-
4 CL
2k
1/2W
2k
1/2W
P24V
24VG
22
23
24
25
1
2
8
7
PULS1
PULS2
SIGN1
SIGN2
COM+
SRV-ON
CCWL
CWL
Near-point watchdog
Upper limit
Lower limit
24VDC
*1
*2
*3
*4
280
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
Page 48, Section 7.2.
Refer to the manual of the servo amplifier for information on the servo amplifier side wiring and various signal wire
shields not shown above.
This is a distance between the LCPU and the servo amplifier.
This series cannot be connected to the L02CPU-P and L26CPU-PBT.
APPENDICES
Appendix 2.4
Connection examples with servo amplifiers
manufactured by SANYODENKI CO.,LTD.
A
(1) Connection example with R series*4
Within 2m*3
R series*2
LCPU
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
IN4-24V
IN4-DIFF
IN4-COM
*1
B20
B19
B18
B17
B16
B15
B14
B13
B12
OUT2
OUT-COM
B04
B01
34 CLR (CONT4)
OUT4
OUT-COM
B03
B01
26 F-PC
47 SG
OUT6
OUT-COM
B02
B01
28 R-PC
48 SG
3 A
4 A
5 B
6 B
7 Z
8 Z
P24V
24VG
B08
INC
B07
INE
IN-COM
B06
B11
CONT-COM
SON (CONT1)
PROT (CONT6)
NROT (CONT5)
Near-point watchdog
Upper limit
Lower limit
24VDC
*1
*2
*3
*4
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
Page 48, Section 7.2.
Refer to the manual of the servo amplifier for information on the servo amplifier side wiring and various signal wire
shields not shown above.
This is a distance between the LCPU and the servo amplifier.
This series cannot be connected to the L02CPU-P and L26CPU-PBT.
281
Appendix 2 Connection Examples with Servo Amplifiers
Appendix 2.4 Connection examples with servo amplifiers manufactured by SANYODENKI CO.,LTD.
INA
50
37
32
33
Appendix 2.5
Connection examples with servo amplifiers
manufactured by YASKAWA Electric Corporation
(1) Connection example with Σ-V series*4
Within 2m*3
-V series*2
LCPU
IN0-24V
IN0-DIFF
IN0-COM
IN1-24V
IN1-DIFF
IN1-COM
IN4-24V
IN4-DIFF
IN4-COM
*1
B20
B19
B18
B17
B16
B15
B14
B13
B12
OUT2
OUT-COM
B04
B01
OUT4
OUT-COM
B03
B01
OUT6
OUT-COM
B02
B01
33 PAO
34 /PAO
35 PBO
36 /PBO
19 PCO
20 /PCO
18 PL3
15 CLR
14 /CLR
FG
3 PL1
7 PULS
8 /PULS
13 PL2
11 SIGN
12 /SIGN
P24V
24VG
INA
B08
INC
B07
INE
IN-COM
B06
B11
Near-point watchdog
Upper limit
47
40
41
42
43
44
45
46
1
+24VIN
/S-ON
/P-CON
P-OT
N-OT
/ALM-RST
/P-CL
/N-CL
SG
Lower limit
24VDC
*1
*2
*3
*4
282
This is an example for axis 1. For the pin assignment when connecting to axis 2, refer to
Page 48, Section 7.2.
Refer to the manual of the servo amplifier for information on the servo amplifier side wiring and various signal wire
shields not shown above.
This is a distance between the LCPU and the servo amplifier.
This series cannot be connected to the L02CPU-P and L26CPU-PBT.
APPENDICES
A
Memo
Appendix 2 Connection Examples with Servo Amplifiers
Appendix 2.5 Connection examples with servo amplifiers manufactured by YASKAWA Electric
Corporation
283
INDEX
0 to 9
1-Phase Multiple of 1 . . . . . . . . . . . .
1-Phase Multiple of 1 (A Phase Only) .
1-Phase Multiple of 2 . . . . . . . . . . . .
1-Phase Multiple of 2 (A Phase Only) .
2-Phase Multiple of 1 . . . . . . . . . . . .
2-Phase Multiple of 2 . . . . . . . . . . . .
2-Phase Multiple of 4 . . . . . . . . . . . .
D
.........
.........
.........
.........
.........
.........
.........
198
198
198
198
199
199
199
DEC/STOP time at speed change . . . . . . . . . . . . 158
Deceleration stop time . . . . . . . . . . . . . . . . . . 95,142
Deviation counter clear signal . . . . . . . . . . . . . . . . 50
Deviation counter droop pulse amount . . . . . . . . . . 46
Direct input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
Direct output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
Drive unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16,43
Drive unit ready signal . . . . . . . . . . . . . . . . . . . . . 50
Droop pulse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
Duty ratio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241
Dwell time . . . . . . . . . . . . . . . . . . . . . . . . . . . 95,142
A
A phase/B phase mode (multiple of 1), A phase/B phase
mode (multiple of 4) . . . . . . . . . . . . . . . . . . . . . . . 56
ABS request flag . . . . . . . . . . . . . . . . . . . . . . . . 137
ABS transfer mode . . . . . . . . . . . . . . . . . . . . . . . 137
ABS transmission data bit 0 . . . . . . . . . . . . . . . . 137
ABS transmission data bit 1 . . . . . . . . . . . . . . . . 137
ABS transmission data ready . . . . . . . . . . . . . . . 137
ACC/DEC time at speed change . . . . . . . . . . . . . 158
Acceleration/deceleration system selection . . . . . . . 58
Acceleration/deceleration time . . . . . . . . . . . . . 95,142
Axis operation status . . . . . . . . . . . . . . . . . . . . . . 61
E
Encoder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Error time output mode . . . . . . . . . . . . . . . . . . . . . 31
Example of wiring when the controller is a line driver
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
190
Example of wiring with a controller (sink type) . . . .
Example of wiring with a line driver
(equivalent to AM26LS31) encoder . . . . . . . . . . .
Example of wiring with an encoder . . . . . . . . . . .
Example of wiring with an open collector output
type encoder (24VDC) . . . . . . . . . . . . . . . . . . . .
Example of wiring with external output equipment
B
Bias speed at start . . . . . . . . . . . . . . . . . . . . . . . . 58
Built-in I/O module tool . . . . . . . . . . . . . . 27,180,272
190
189
189
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
External command signal . . . . . . . . . . . . . . . . . . . 50
External preset (phase Z) request detection setting
C
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206
CCW/SIGN/B phase output . . . . . . . . . . . . . . . . . . 50
Coincidence detection interrupt setting (counter value
coincidence No.n) . . . . . . . . . . . . . . . . . . . . . . . 213
Coincidence output No.1 signal . . . . . . . . . . . . . . 187
Coincidence output No.2 signal . . . . . . . . . . . . . . 187
Coincidence output No.n point number . . . . . . . . . 254
Coincidence output No.n point setting . . . . . . . . . 254
Coincidence output time preset setting . . . . . . . . . 211
Command pulse frequency . . . . . . . . . . . . . . . . . . 46
Command speed . . . . . . . . . . . . . . . . . . . . . . 95,142
Common terminal arrangement . . . . . . . . . . . . . . . 21
Connectable encoders . . . . . . . . . . . . . . . . . . . . 188
Control system. . . . . . . . . . . . . . . . . . . . . 93,94,142
Count 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Count 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
Count disable function . . . . . . . . . . . . . . . . . . . . 219
Count disable/preset function . . . . . . . . . . . . . . . 222
Count range of the ring counter . . . . . . . . . . . . . . 205
Count source selection . . . . . . . . . . . . . . . . . . . . 196
Counter type . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
Counting speed setting . . . . . . . . . . . . . . . . . . . . 200
Creep speed . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
Current feed value . . . . . . . . . . . . . . . . . . . . . . . . 61
CW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
CW/CCW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
CW/CCW mode . . . . . . . . . . . . . . . . . . . . . . . . . . 55
CW/PULSE/A phase output. . . . . . . . . . . . . . . . . . 50
284
F
Feedback pulses . . . . . . . . . . . . . . . . . . . . . . . .
Frequency measurement time unit setting . . . . . .
Frequency moving average processing count . . . .
Function input logic setting . . . . . . . . . . . . . . . . .
Function input signal . . . . . . . . . . . . . . . . . . . . .
Function input status . . . . . . . . . . . . . . . . . . . . .
. 43
226
226
216
187
239
I
I/O connector pin numbers and corresponding I/O
signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Input resistance . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Input signal assignment . . . . . . . . . . . . . . . . . . . . 25
Insulation rasistance . . . . . . . . . . . . . . . . . . . . 20,21
Internal circuits . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Internal clock . . . . . . . . . . . . . . . . . . . . . . . . . . . 197
J
JOG ACC time . . . . . . . . . . . . . . . . . . . . . . . . . 151
JOG DEC time . . . . . . . . . . . . . . . . . . . . . . . . . 151
JOG speed . . . . . . . . . . . . . . . . . . . . . . . . . . . . 151
L
Latch count value . . . . . . . . . . . .
Latch count value number . . . . . .
Latch counter function . . . . . . . . .
Latch counter input signal . . . . . .
Latch counter/preset function . . . .
LCPU . . . . . . . . . . . . . . . . . . . .
Leakage current at OFF . . . . . . . .
Lower limit signal . . . . . . . . . . . .
Program example with the coincidence detection
interrupt function. . . . . . . . . . . . . . . . . . . . . . . . . 267
Programming tool . . . . . . . . . . . . . . . . . . . . . . . . . 16
Pulse frequency . . . . . . . . . . . . . . . . . . . . . . . . . . 44
Pulse generator . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Pulse input mode . . . . . . . . . . . . . . . . . . . . . . . . 198
Pulse measurement target setting . . . . . . . . . . . . 238
Pulse output mode . . . . . . . . . . . . . . . . . . . . . . . . 55
PULSE/SIGN mode . . . . . . . . . . . . . . . . . . . . . . . 56
PWM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
PWM output cycle setting value . . . . . . . . . . . . . . 259
PWM output on width setting value . . . . . . . . . . . . 259
. . . . . . . . . . . . 250
. . . . . . . . . . . . 250
. . . . . . . . . . . . 218
. . . . . . . . . . . . 187
. . . . . . . . . . . . 224
. . . . . . . . . . . . . 16
. . . . . . . . . . . . . 21
. . . . . . . . . . . . . 50
M
Maximum voltage drop at ON . .
Measured frequency value . . . .
Measured pulse value . . . . . . .
Measured rotation speed value .
Minimum count pulse width . . .
Movement amount per pulse . .
. . . . . . . . . . . . . . . 21
. . . . . . . . . . . . . . 256
. . . . . . . . . . . . . . 258
. . . . . . . . . . . . . . 257
. . . . . . . . . . . . . . 243
. . . . . . . . . . . . 44,46
R
Near-point dog method . . . . . . . . . . . . . . . . . . . . . 72
Near-point dog signal . . . . . . . . . . . . . . . . . . . . . . 50
Near-point watchdog . . . . . . . . . . . . . . . . . . . . . . . 16
Negative logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
New speed value . . . . . . . . . . . . . . . . . . . . . . . . 158
No method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
Number of pulses per rotation (pulse) . . . . . . . . . . 232
S/W stroke upper limit, S/W stroke lower limit . . . . . 57
Sampling count value setting . . . . . . . . . . . . . . . . 252
Sampling counter function . . . . . . . . . . . . . . . . . . 220
Sampling time setting . . . . . . . . . . . . . . . . . . . . . 216
S-curve acceleration/deceleration . . . . . . . . . . . . . . 58
Servo amplifier . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Servo motor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Servo on . . . . . . . . . . . . . . . . . . . . . . . . . . . 16,137
Setting of movement amount after near-point dog
ON . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
Signal assignment of the connector for external
devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Signal loaded from the servo amplifier . . . . . . . . . 154
Signal output to the servo amplifier . . . . . . . . . . . . 154
Specification of JOG operation direction . . . . . . . . 151
Speed limit value . . . . . . . . . . . . . . . . . . . . . . . . . 58
Standby address . . . . . . . . . . . . . . . . . . . . . . . . 148
Stepping motor . . . . . . . . . . . . . . . . . . . . . . . . 16,58
Stopper 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
Stopper 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79
Stopper 3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
OFF voltage/OFF current . . . . . . . . . . . . . . . . . . . . 20
ON voltage/ON current . . . . . . . . . . . . . . . . . . . . . 20
OP address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Operation mode setting . . . . . . . . . . . . . . . . . . . . 196
Operations of the linear counter . . . . . . . . . . . . . . 203
Operations of the ring counter . . . . . . . . . . . . . . . 204
OPR acceleration/deceleration time . . . . . . . . . . . . 67
OPR deceleration stop time . . . . . . . . . . . . . . . . . . 68
OPR direction . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
OPR dwell time . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
OPR method . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
OPR method and I/O signal . . . . . . . . . . . . . . . . . . 70
OPR methods and OPR parameters . . . . . . . . . . . . 65
OPR speed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Original position return type . . . . . . . . . . . . . . . . . 148
Output signal assignment . . . . . . . . . . . . . . . . . . . . 26
Output waveform setting . . . . . . . . . . . . . . . . . . . 241
Phase A . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Phase B . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Phase Z . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Phase Z settings . . . . . . . . . . . . . . . . . . . . . .
Position loop gain . . . . . . . . . . . . . . . . . . . . .
Positioning address/movement amount . . . . . .
Positioning data No. . . . . . . . . . . . . . . . . . . .
Preset by a program . . . . . . . . . . . . . . . . . . .
Preset by phase Z input . . . . . . . . . . . . . . . . .
Preset value setting . . . . . . . . . . . . . . . . . . . .
. . . 187
. . . 187
. . . 187
. . . 206
. . . . 46
93,142
. . . 140
. . . 208
. . . 207
. . . 249
7
S
O
P
3
4
Rated input current . . . . . . . . . . . . . . . . . . . . . . . . 20
Rated input voltage . . . . . . . . . . . . . . . . . . . . . . . . 20
Rated load current . . . . . . . . . . . . . . . . . . . . . . . . 21
Rated load voltage . . . . . . . . . . . . . . . . . . . . . . . . 21
Response time . . . . . . . . . . . . . . . . . . . . . . . . 20,21
Ring counter lower limit value . . . . . . . . . . . . . . . 247
Ring counter upper limit value . . . . . . . . . . . . . . . 247
Rotation direction setting . . . . . . . . . . . . . . . . . . . . 57
Rotation speed measurement time unit setting . . . . 232
Rotation speed movement averaging processing
count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
N
I
T
Target position change value . . . . . . . . . . . . . . . . 161
Temperature derating curve for the input signal . . . . 20
Trapezoid acceleration/deceleration . . . . . . . . . . . . 58
U
Upper limit signal . . . . . . . . . . . . . . . . . . . . . . . . . 50
285
8
W
Warning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Withstand voltage . . . . . . . . . . . . . . . . . . . . . . 20,21
Worm gear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
Z
Zero signal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
286
INSTRUCTION INDEX
I
ICCNTRD1(P),ICCNTRD2(P) . .
ICCOVWR1(P), ICCOVWR2(P)
ICFCNT1, ICFCNT2 . . . . . . . .
ICLTHRD1(P),ICLTHRD2(P) . .
ICPLSRD1(P), ICPLSRD2(P) . .
ICPREWR1(P),ICPREWR2(P) .
ICPWM1, ICPWM2 . . . . . . . . .
ICRCNT1, ICRCNT2 . . . . . . . .
ICRNGWR1(P),ICRNGWR2(P)
ICSMPRD1(P),ICSMPRD2(P) .
IPABRST1,IPABRST2 . . . . . . .
IPDSTRT1(P),IPDSTRT2(P) . .
IPJOG1,IPJOG2 . . . . . . . . . . .
IPOPR1(P),IPOPR2(P) . . . . . .
IPPSTRT1(P),IPPSTRT2(P) . . .
IPSIMUL(P) . . . . . . . . . . . . . .
IPSPCHG1(P),IPSPCHG2(P) . .
IPSTOP1,IPSTOP2 . . . . . . . . .
IPTPCHG1(P),IPTPCHG2(P) . .
I
. . . . . . . . . . . . . . 246
. . . . . . . . . . . . . . 254
. . . . . . . . . . . . . . 256
. . . . . . . . . . . . . . 250
. . . . . . . . . . . . . . 258
. . . . . . . . . . . . . . 249
. . . . . . . . . . . . . . 259
. . . . . . . . . . . . . . 257
. . . . . . . . . . . . . . 247
. . . . . . . . . . . . . . 252
. . . . . . . . . . . . . . 154
. . . . . . . . . . . . . . 142
. . . . . . . . . . . . . . 151
. . . . . . . . . . . . . . 148
. . . . . . . . . . . . . . 140
. . . . . . . . . . . . . . 145
. . . . . . . . . . . . . . 158
. . . . . . . . . . . . . . 156
. . . . . . . . . . . . . . 161
3
4
7
8
287
REVISIONS
*The manual number is given on the bottom left of the back cover.
Print date
Manual number
Revision
January 2010
SH(NA)-080892ENG-A
First edition
October 2010
SH(NA)-080892ENG-B
Revised due to changes in PWM output specifications
July 2011
SH(NA)-080892ENG-C
Descriptions regarding the L02CPU-P and L26CPU-PBT are added.
September 2011
SH(NA)-080892ENG-D
Descriptions regarding the L6EXB, L6EXE, LC06E, LC10E, and LC30E are added.
Japanese Manual Version SH-080876-D
This manual confers no industrial property rights or any rights of any other kind, nor does it confer any patent licenses.
Mitsubishi Electric Corporation cannot be held responsible for any problems involving industrial property rights which may
occur as a result of using the contents noted in this manual.
© 2010 MITSUBISHI ELECTRIC CORPORATION
288
WARRANTY
Please confirm the following product warranty details before using this product.
1. Gratis Warranty Term and Gratis Warranty Range
If any faults or defects (hereinafter "Failure") found to be the responsibility of Mitsubishi occurs during use of the
product within the gratis warranty term, the product shall be repaired at no cost via the sales representative or
Mitsubishi Service Company.
However, if repairs are required onsite at domestic or overseas location, expenses to send an engineer will be
solely at the customer's discretion. Mitsubishi shall not be held responsible for any re-commissioning,
maintenance, or testing on-site that involves replacement of the failed module.
[Gratis Warranty Term]
The gratis warranty term of the product shall be for one year after the date of purchase or delivery to a designated
place.
Note that after manufacture and shipment from Mitsubishi, the maximum distribution period shall be six (6) months,
and the longest gratis warranty term after manufacturing shall be eighteen (18) months. The gratis warranty term of
repair parts shall not exceed the gratis warranty term before repairs.
[Gratis Warranty Range]
(1) The range shall be limited to normal use within the usage state, usage methods and usage environment, etc.,
which follow the conditions and precautions, etc., given in the instruction manual, user's manual and caution
labels on the product.
(2) Even within the gratis warranty term, repairs shall be charged for in the following cases.
1. Failure occurring from inappropriate storage or handling, carelessness or negligence by the user. Failure
caused by the user's hardware or software design.
2. Failure caused by unapproved modifications, etc., to the product by the user.
3. When the Mitsubishi product is assembled into a user's device, Failure that could have been avoided if
functions or structures, judged as necessary in the legal safety measures the user's device is subject to or
as necessary by industry standards, had been provided.
4. Failure that could have been avoided if consumable parts (battery, backlight, fuse, etc.) designated in the
instruction manual had been correctly serviced or replaced.
5. Failure caused by external irresistible forces such as fires or abnormal voltages, and Failure caused by
force majeure such as earthquakes, lightning, wind and water damage.
6. Failure caused by reasons unpredictable by scientific technology standards at time of shipment from
Mitsubishi.
7. Any other failure found not to be the responsibility of Mitsubishi or that admitted not to be so by the user.
2. Onerous repair term after discontinuation of production
(1) Mitsubishi shall accept onerous product repairs for seven (7) years after production of the product is
discontinued.
Discontinuation of production shall be notified with Mitsubishi Technical Bulletins, etc.
(2) Product supply (including repair parts) is not available after production is discontinued.
3. Overseas service
Overseas, repairs shall be accepted by Mitsubishi's local overseas FA Center. Note that the repair conditions at
each FA Center may differ.
4. Exclusion of loss in opportunity and secondary loss from warranty liability
Regardless of the gratis warranty term, Mitsubishi shall not be liable for compensation of damages caused by any
cause found not to be the responsibility of Mitsubishi, loss in opportunity, lost profits incurred to the user by Failures
of Mitsubishi products, special damages and secondary damages whether foreseeable or not, compensation for
accidents, and compensation for damages to products other than Mitsubishi products, replacement by the user,
maintenance of on-site equipment, start-up test run and other tasks.
5. Changes in product specifications
The specifications given in the catalogs, manuals or technical documents are subject to change without prior notice.
289
Microsoft, Windows, Windows NT, and Windows Vista are registered trademarks of Microsoft Corporation in the United
States and other countries.
Pentium is a trademark of Intel Corporation in the United States and other countries.
Ethernet is a trademark of Xerox Corporation.
The SD logo and SDHC logo are trademarks.
All other company names and product names used in this manual are trademarks or
registered trademarks of their respective companies.
290
SH(NA)-080892ENG-D
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Download PDF

advertising