Mitsubishi Electric MELSEC iQ-R Series User Manual

Mitsubishi Electric MELSEC iQ-R Series User Manual

Motion module
Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

MELSEC iQ-R
Motion Module
User's Manual (Application)
-RD78G4
-RD78G8
-RD78G16
-RD78G32
-RD78G64
-RD78GHV
-RD78GHW

Advertisement

Table of Contents
loading

Summary of Contents for Mitsubishi Electric MELSEC iQ-R Series

  • Page 1 MELSEC iQ-R Motion Module User's Manual (Application) -RD78G4 -RD78G8 -RD78G16 -RD78G32 -RD78G64 -RD78GHV -RD78GHW...
  • Page 3: Safety Precautions

    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. The precautions given in this manual are concerned with this product only. Refer to the MELSEC iQ-R Module Configuration Manual for a description of the PLC system safety precautions.
  • Page 4 [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.
  • Page 5 [Design Precautions] WARNING ● When connecting an external device with a CPU module or intelligent function module to modify data of a running programmable controller, configure an interlock circuit in the program to ensure that the entire system will always operate safely. For other forms of control (such as program modification, parameter change, forced output, or operating status change) of a running programmable controller, read the relevant manuals carefully and ensure that the operation is safe before proceeding.
  • Page 6 [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 100 mm or more between them. Failure to do so may result in malfunction due to noise.
  • Page 7 [Wiring Precautions] WARNING ● Shut off the external power supply (all phases) used in the system before installation and wiring. Failure to do so may result in electric shock or cause the module to fail or malfunction. ● After installation and wiring, attach a blank cover module (RG60) to each empty slot and an included extension connector protective cover to the unused extension cable connector before powering on the system for operation.
  • Page 8 [Wiring Precautions] CAUTION ● 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.
  • Page 9 [Startup and Maintenance Precautions] CAUTION ● When connecting an external device with a CPU module or intelligent function module to modify data of a running programmable controller, configure an interlock circuit in the program to ensure that the entire system will always operate safely. For other forms of control (such as program modification, parameter change, forced output, or operating status change) of a running programmable controller, read the relevant manuals carefully and ensure that the operation is safe before proceeding.
  • Page 10 [Startup and Maintenance Precautions] CAUTION ● Before testing the operation, set a low speed value for the speed limit parameter so that the operation can be stopped immediately upon occurrence of a hazardous condition. ● Confirm and adjust the program and each parameter before operation. Unpredictable movements may occur depending on the machine.
  • Page 11 [Transportation Precautions] CAUTION ● When transporting lithium batteries, follow the transportation regulations. For details on the regulated models, refer to the MELSEC iQ-R Module Configuration Manual. ● The halogens (such as fluorine, chlorine, bromine, and iodine), which are contained in a fumigant used for disinfection and pest control of wood packaging materials, may cause failure of the product.
  • Page 12: Introduction

    INTRODUCTION Thank you for purchasing the Mitsubishi Electric MELSEC iQ-R series programmable controllers. This manual describes the functions and programming of the relevant products listed below. Before using this product, please read this manual and the relevant manuals carefully and develop familiarity with the functions and performance of the MELSEC iQ-R series programmable controller to handle the product correctly.
  • Page 13: Table Of Contents

    CONTENTS SAFETY PRECAUTIONS ..............1 INTRODUCTION .
  • Page 14 CHAPTER 2 AXIS MANAGEMENT FUNCTIONS Technical Units ............... . . 62 Relevant variables .
  • Page 15 Reset ................. 100 Clear .
  • Page 16 Relevant FB................187 Control details .
  • Page 17 CHAPTER 9 RELEVANT FUNCTIONS TO VELOCITY Acceleration/deceleration Processing Function ..........293 Relevant variables .
  • Page 18 TARGET_REF structure ..............358 12.2 Touch Probe.
  • Page 19 Data logging function..............456 Real-time monitor .
  • Page 20 Log file ................508 Drive operation .
  • Page 21 REVISIONS................622 WARRANTY .
  • Page 22: Relevant Manuals

    For details of the network function blocks, refer to the following. MELSEC iQ-R Ethernet/CC-Link IE Function Block Reference e-Manual refers to the Mitsubishi Electric FA electronic book manuals that can be browsed using a dedicated tool. e-Manual has the following features: •...
  • Page 23: Terms

    GX Works3 and label that can be created for the any of the specified devices. A generic term for Mitsubishi Electric Graphic Operation Terminal GOT1000 and GOT2000 series GX Works3 The product name of the software package for the MELSEC programmable controllers...
  • Page 24 The previous motion control FB of a buffering FB (If only one FB is performed buffering, it indicates on-going FB) The abbreviation for Reliability, Availability, and Serviceability. This term refers to usability of automated equipment. RD78G Another term for the MELSEC iQ-R series Motion module (compatible with CC-Link IE TSN) RD78GH RD78G(H)
  • Page 25 Term Description Virtual drive axis A virtual axis that can generate a command virtually Virtual linked axis An axis that connects FBs and transmits a command in the single axis synchronous control...
  • Page 26: How To Read This Manual

    HOW TO READ THIS MANUAL This section describes how to use motion control FBs (MCFB) and the common specifications.  The MCFB that can be used in the motion system includes FBs established by PLCopen . The basic specifications of I/O ...
  • Page 27 ■Execute type/Enable type Some MCFBs are executed at an Execute input, and the others are executed at an Enable input. The basic operation of each FB is shown below. However, some FBs have different specifications. For details, refer to each FB specifications. [Basic operation of Execute type FB] •...
  • Page 28 [When the I/O variables is abnormal] Execute Done Busy AxisName.Md. Analyzing Active Error CommandAborted ErrorID Error code Position [When the I/O variables is abnormal] Execute Done Busy AxisName.Md. Analyzing Active Error CommandAborted ErrorID Error code Position [Basic operation of Enable type FB] •...
  • Page 29 [When the FB is normal] Enable Busy AxisName.Md. Analyzing Valid Error ErrorID Motion control types The following types exist in the axis/axes group control that can be executed by the motion MCFB. For details, refer to each function. Large classification Middle classification Small classification Reference...
  • Page 30 Units used in control Units of the position, speed, acceleration/deceleration, and jerk that are used in the motion system follow the technical units of the axis to be used. For details, refer to the following. Page 62 Technical Units The following types exist in the control value such as the position and the speed that are used in the motion system. For details of the control value related to the position and the speed, refer to the following.
  • Page 31: Future Support Planned

    FUTURE SUPPORT PLANNED The following model and functions are mentioned in this manual, but it is planned for a future support. The information in this page might be changed for improvement without prior notice. Model Description RD78GH • RD78GHV • RD78GHW Function Description Axis assignment...
  • Page 32 MEMO...
  • Page 33: Part 1 Basic Specifications

    PART 1 BASIC SPECIFICATIONS 1 AXIS SETTING 2 AXIS MANAGEMENT FUNCTIONS 3 BASIC FUNCTIONS...
  • Page 34: Chapter 1 Axis Setting

    AXIS SETTING Axis The target controlled in the motion system is called an axis. Axes are classified into real axes which target the drive units and the I/O devices connected to the network and virtual axes which virtually generate commands and position in the motion system.
  • Page 35: Required Settings For Axes

    Required settings for axes The following items are required to be set in the axis setting window of the engineering tool to set the axes. For axis setting methods, refer to the following. Page 41 Axis Assignment Item Description Axis name Sets an arbitrary axis name.
  • Page 36: Axis Variable Initialization Timing

    Data type The following data types are assigned based on the axis type. For the detail of data type, refer to the relevant variables of each axis type. Axis type Data type Real drive axis AXIS_REAL Virtual drive axis AXIS_VIRTUAL Virtual linked axis AXIS_VIRTUAL_LINK Each data type has the following members respectively.
  • Page 37: State Transition

    State transition The following shows the status that a single axis can be in. The current status can be referred in axis status (AxisName.Md.AxisStatus). Status Description 0: Disabled The status where the axis cannot be used. In case of a real drive axis, this status indicates the servo OFF stop. In case of a real axis, this status occurs also when the slave device is disconnected from the network.
  • Page 38: Precautions

    The status transits as shown below according to the start of the MCFB. The state transition may varies depending on the axis type. Refer to the specifications of each axis type. Synchronized Motion Automatic transition Event transition Synchronized Motion (Synchronous operation) Continuous Motion Discrete Motion Discrete Motion...
  • Page 39: Axis Type

    Axis Type Relevant variables/FB Real drive axis data type AXIS_REAL members (excluding AxisRef) Variable/Structure name Name Details AxisName.PrConst. Page 41 Axis Assignment AxisType Axis type setting Page 41 Axis Assignment AddressOfStation Station address setting PosRestoration_AbsPosBase Absolute position reference setting Page 42 Absolute position control setting Page 41 Axis Assignment OperationCycle Control cycle setting...
  • Page 40: Real Drive Axis

    Virtual linked axis data type AXIS_VIRTUAL_LINK members (excluding AxisRef) Variable/Structure name Name Details AxisName.PrConst. Page 41 Axis Assignment AxisType Axis type setting PosRestoration_AbsPosBase Absolute position reference setting Page 42 Absolute position control setting Page 41 Axis Assignment OperationCycle Control cycle setting AxisName.Md.
  • Page 41: Virtual Drive Axis

    Virtual drive axis This axis can generate commands virtually in the motion system. A real drive unit is not used. The available commands/ functions are partly different from those of the real axis. Since the virtual drive axis is specialized for generating the position command and it does not simulate a situation that the drive unit is connected, available functions are restricted.
  • Page 42: Connectable Stations

    Connectable Stations This section describes stations that are can be connected to the network. Maximum number of stations that can be connected The following shows the maximum number of stations that can be connected to the network. Item RD78G4 RD78G8 RD78G16 RD78G32 RD78G64...
  • Page 43: Axis Assignment

    Axis Assignment Axes are generated/initialized by setting axis settings on the axis setting window in the engineering tool. The axes set on the axis setting window are assigned to the global label as axis variables. For the setting method, refer to Help of the engineering tool.
  • Page 44 ■Absolute position control setting Specify whether applicable axes are used as the absolute position system or not. For details, refer to the following. Page 80 Absolute Position Control ■Control cycle Specify which operation cycle is used for the applicable axis to control. For details, refer to the following. Page 90 Operation Cycle 1 AXIS SETTING 1.4 Axis Assignment...
  • Page 45: Relevant Variables

    Relevant variables AxisName in the following table indicates the instance name of the structure type for each axis type. AXIS_REAL: Real drive axis AXIS_VIRTUAL: Virtual drive axis AXIS_VIRTUAL_LINK: Virtual linked axis Variable/Structure name Name Details AxisName.AxisRef. AxisNo Axis No. Sets the axis No. 0: Not set 1 to 10000: Setting axis No.
  • Page 46: Slave Object Settings

    Slave object settings In the motion system, the data that sends/receives information to/from the connected device in the motion operation processing is called a slave object. With slave object settings, the motion system can be customized to adjust to the slave device by setting the data related to the slave device to the slave object.
  • Page 47: Pdo Mapping Settings

    If unavailable data is set, the error "Mapping Communication Error" (error code: 1A5F) will occur at the axis variable initialization. There are slave objects whose settings are necessary depending on the axis type. A valid setting value other than "no setting" must be set to the applicable slave object.
  • Page 48: Slave Object List

    Slave object list The following shows attributes of slave objects. Attribute Description Data Type Indicates slave object size. Access Indicates whether the object can be read/written or not. • RO: Only read is available. • RW: Read and write are available. PDO mapping When the axis type is real drive axis, it indicates whether the mapping to cyclic communication is enabled or not.
  • Page 49 Slave object name DataType Access Default Description mapping Max motor speed 60800020 Gets the maximum speed of the servo motor from the driver device Max torque 60720010 Gets the maximum torque of the servo motor from the driver device. Watch dog counter DL RxPDO 1D010110 Notifies the watch dog counter value to the driver...
  • Page 50 Slave object name DataType Access Default Description mapping Sync ABS counter TxPDO 2D220010 Gets the encoder multiple revolution counter from the driver device. Sync cycle counter TxPDO 2D210020 Gets the encoder multiple revolution counter from the driver device. Scale measurement encoder reception 2D3C0020 Gets the encoder position within one revolution status...
  • Page 51 Slave object name Real drive axis Virtual drive axis Virtual linked axis    SI unit velocity    Max motor speed    Max torque    Watch dog counter DL Watch dog counter UL ...
  • Page 52: Motion System Function/Command And Slave Object

    Motion system function/command and slave object If no slave object is registered in the axis of the motion system, there will be errors and restrictions in some functions/ commands. Set the required objects as the following. For a real axis, registered slave objects can be checked with the member variable of AxisName.Md.Io_Object. For a virtual axis, registered slave objects are fixed by each axis type.
  • Page 53: Axes Group

    Axes Group Axes group is used for multiple axes control such as linear interpolation control and 3D linear interpolation control, etc. This section describes an overview of axes group. The maximum setting number of axes groups depends on the memory. If an axes group cannot be set for memory shortage, the error "Over Maximum Number of Registrations for Axis Group"...
  • Page 54 ■Restrictions • Axes group No. (GroupNo) of the AXES_GROUP_REF structure must be set in advance before this FB is executed. • This FB can be executed only when axis status (AxisName.Md.AxisStatus) of all configuration axes is the "4: Standstill" or the "0: Disabled"...
  • Page 55 MC_GroupDisable Item Description Function overview Transits specified axes group status to "0: GroupDisabled". Symbol [Structured Ladder] MC_GroupDisable DUT : AxesGroup AxesGroup : DUT B : Execute Done : B Busy : B Error : B ErrorID : UW Applicable hardware and RD78G(H) (Structured Text) software (Language) Number of input area points...
  • Page 56: Settings Required For Axes Group

    ■I/O variable Impor : At start Name Variable name Data type Input Setting range Default Description import value   Page 574 Axes group variables Axes group AxesGroup AXES_GROUP_ Omission information possible ■Input variable Import : At start Name Variable name Data type Import Setting range...
  • Page 57: Axes Group Variables

    Axes group variables Axes group variables are generated by adding the axes group setting in the engineering tool. A generated axes group is assigned to the global label or the local label as an axes group variable. Axes group is defined as an axes group variable configured with monitor information such as parameter information, the current position, and the status.
  • Page 58: Enabling Axes Group

    Enabling axes group When an axes group is used in a motion FB, the axes group status (AxesGroupName.Md.GroupStatus) must be "4: GroupStandby" by executing MC_GroupEnable to the axes group. The axes group can be started in the motion FB when the axes group status (AxesGroupName.Md.GroupStatus) is "4: GroupStandby" and the axis status (AxisName.Md.AxisStatus) of all configuration axes is "4: Standstill".
  • Page 59: Axes Group Enabled

    Axes group enabled This section describes enabling an axes group. Control details Specify AxesGroup and change the axes group status (AxesGroupName.Md.GroupStatus) into the "4: GroupStandby" status. • An axes group can start the motion FB only when the axes group status (AxesGroupName.Md.GroupStatus) is the "4: GroupStandby"...
  • Page 60 Precautions Axes group No. (GroupNo) of the AXES_GROUP_REF structure must be set in advance before this FB is executed. This FB can be executed only when the axis status (AxisName.Md.AxisStatus) of all configuration axes are "4: Standstill" or "0: Disabled". 1 AXIS SETTING 1.5 Axes Group...
  • Page 61: Axes Group Disabled

    Axes group disabled This section describes disabling an axes group. Control details Specify AxesGroup and change the axes group status (AxesGroupName.Md.GroupStatus) into the "0: GroupDisabled" status. • An axes group cannot execute an operation FB when the axes group status (AxesGroupName.Md.GroupStatus) is the "0: GroupDisabled"...
  • Page 62: Axes Group Assignment

    Axes Group Assignment Axes groups can be set in the engineering tool. For the setting method, refer to Help of the engineering tool. Based on parameter settings of the axes group, the instance of the axes group is initialized when the power turns ON or when the PLC READY [Y0] turns ON.
  • Page 63: Setting With Engineering Tool

    Setting with Engineering tool In the axes group setting window of the engineering tool, an axes group can be generated/initialized by setting the axes group setting as a parameter. The axes group set in the axes group setting window is assigned to the global label data as an axes group variable.
  • Page 64: Chapter 2 Axis Management Functions

    AXIS MANAGEMENT FUNCTIONS Technical Units The position command unit and the velocity command unit used in the motion control can be set in the "unit setting". Since the unit can be specified freely depending on the control target, intuitive programming and monitoring are available. Relevant variables For the setting methods, refer to Help of the engineering tool.
  • Page 65 Setting value of AxisName(AxesGroupName).Pr.Unit_Position and display examples of AxisName(AxesGroupName).Md.Unit_PositionDisplay AxisName(AxesGroupNam AxisName(AxesGroupName).Md.Unit_PositionDisplay e).Pr.Unit_Position H00010000 HFD010000 m HFA010000 HF7010000 H00B40000 Revolution H00410000 degree HFA410000 10 degree H00000000 pulse H00C00000 inch If "1" is set in the program when AxisName(AxesGroupName).Pr.Unit_Position is HFD010000, the position will be regarded as 1.0 mm.
  • Page 66 If AxisName(AxesGroupName).Pr.Unit_Position is HFD010000 and AxisName(AxesGroupName).Pr.Unit_Velocity is HFD000300, [mm/ms] is displayed on AxisName(AxesGroupName).Md.Unit_VelocityDisplay. If AxisName(AxesGroupName).Pr.Unit_Position is HFF000000 (An arbitrary unit character string), number of displayable characters from the beginning out of the position command unit character strings is displayed on AxisName(AxesGroupName).Md.Unit_VelocityDisplay.
  • Page 67 ■Circular interpolation control (MCv_MoveCircularInterpolateAbsolute,MCv_MoveCircularInterpolateRelative) • Calculates circular path from the value of current position, AuxPoint input, and EndPoint input. The position command unit of the axes group and the the configuration axes are not affected. • The unit of the axes group is used for the velocity command unit in controlling. Refer to the following for details.
  • Page 68: Precautions

    Precautions • When the parameter is out of the range,the initial value is stored in AxisName(AxesGroupName).Md.Unit_PositionDisplay and AxisName(AxesGroupName).Md.Unit_VelocityDisplay. (the default value of position command unit: pulse, velocity command unit: pulse/s) • Even if AxisName(AxesGroupName).Pr.Unit_Position, AxisName(AxesGroupName).Pr.Unit_Velocity and AxisName(AxesGroupName).Pr.Unit_PositionString is changed, the homing request is not TRUE. •...
  • Page 69: Positioning Range

    Positioning Range  "Positioning range" is "-10000000000.0 positioning range < 10000000000.0". The range of AxisName.Md.SetPosition is determined by AxisName.PrConst.RingCount_UpperValue and AxisName.PrConst.RingCount_LowerValue. Relevant variables Variable/Structure name Name Details AxisName.PrConst. RingCount_Enable Ring counter enable selection Selects the ring counter enable/disable. 0: Disabled 1: Enabled RingCount_UpperValue Ring counter upper limit value...
  • Page 70: Set Position

    Set position AxisName.Md.SetPosition can be set to an arbitrary ring address by setting AxisName.PrConst.RingCount_UpperValue and AxisName.PrConst.RingCount_LowerValue. The ring counter upper/lower limit value can be set within the range of - 10000000000.0 to 10000000000.0. Restrictions The motion control function uses the real number data (floating-point data) for the axis current position and the command target position, etc.
  • Page 71: Combination With Other Devices

    Control details AxisName.Md.SetPosition to be the ring address is calculated based on AxisName.Md.CumulativePosition. The cumulative current position will be the ring address of "-10000000000.0  cumulative current position < 10000000000.0" regardless of the setting of the ring counter upper/lower value. When the ring counter lower limit value is -500000000.0 and the ring counter upper limit value is 500000000.0, the set position is the ring address of "-500000000.0 ...
  • Page 72: Velocity Range

    Velocity Range Relevant variables Variable/Structure name Name Details AxisName.Md. SetVelocity Set velocity • Stores the set output veocity. • Stores the set velocity of the configuration axes during the axes group operation. CommandedVelocity Commanded velocity • Stores the commanded velocity of the positioning data which is being executed.
  • Page 73: Velocity Set Range

    Velocity set range The following table describes the velocity range that can be specified in each parameter. For the set range when using the override function, refer to the following. Page 321 Override Function Name Range Condition Target velocity 0, +0.0001 to +2500000000.0 When positioning control 0, 0.0001 to 2500000000.0 When velocity control...
  • Page 74: Servo On/Off

    Servo ON/OFF Relevant variables/FB This function executes servo ON/OFF of the real axis connected to the motion system. The servo ON enables the operation of the real axis. Variable/Structure name Name Details AxisName.Md. Driver_ReadyOn Driver ready ON status Sets TRUE when the connected driver status (AxisName.Md.Driver_State) is as follows.
  • Page 75 ■Timing chart [When the FB is normally completed] Enable ServoON Status ReadyStatus Busy Error ErrorID [When an error occurs] Enable ServoON Status ReadyStatus Busy Error ErrorID Error code ■I/O variable Input import : At start Name Variable name Data type Input Setting range Default...
  • Page 76 MCv_AllPower Item Description Function overview Switches every axis to the operation possible status. Symbol [Structured Ladder] MCv_AllPower DUT : Axis Axis : DUT B : Enable Busy : B B : ServoON Error : B ErrorID : UW Applicable hardware and RD78G(H) (Structured Text) software (Language) Number of input area points...
  • Page 77 When MC_Power is used together to the axis 38 MCv_AllPower PLC READY [Y0] Enable Busy ServoON MC_Power [Axis38.AxisRef] Axis PLC READY [Y0] Enable Status ReadyStatus ReadyStatus ServoON MCv_AllPower Enable ServoON Busy MC_Power (Axis38) Enable ServoON ReadyStatus Status Axis38.Md.AxisStatus 0: Disabled 0: Disabled 4: Standstill Axis87.Md.AxisStatus...
  • Page 78: Control Details

    Control details Servo ON/OFF The servo ON/OFF of the real axis connected to the motion system is controlled by MC_Power (operation possible) for single axis and MCv_AllPower (all axes operation possible) for all axes. For the driver status, refer to the following. Page 77 Driver state transition ■MC_Power input/output and servo ON/OFF status The servo ON/OFF status and the driver status of the selected axis can be switched as the follows by inputting Enable and...
  • Page 79: Driver State Transition

    Driver state transition The connected driver device as an axis performs operation according to the state transition defined by the CiA402 drive profile shown below. The motion system determines whether the driver is being servo ON or OFF status based on the current driver status.
  • Page 80: Follow Up

    Follow Up In an axis which has the current position (Position actual value) as the slave object, this function can convert the unit of the current position by the driver unit conversion numerator/denominator (electronic gear) and reflect in the set position. •...
  • Page 81: Disabling Follow Up

    Disabling follow up The follow up enabled/disabled can be switched for each axis (default status: enabled). Input from the slave device (the current position) is disabled and not reflected in the set position by switching the follow up to enabled. That the follow up enabled/disabled is switched is recorded in the event history.
  • Page 82: Absolute Position Control

    Absolute Position Control This function restores the current position of axes. Absolute position system The absolute position system maintains the current position of axes. The absolute position system configuration differs depending on the axis type. For details, refer to the following. Page 87 Current position restoration for each axis type The absolute position data used in the absolute position control is maintained inside the motion system as a backup file.
  • Page 83 Variable/Structure name Name Details BackupRestoreStatus Backup restore information Displays the status of backup restore. 0: Backup restore not executed 1: Backup stop required 2: Backup stop 3: Backup stop cancelled 4: Restored data saving 5: Restored data saving completed System.Cd. BackupRestore Backup restore request Executes backup stop and restored data saving.
  • Page 84: Current Position Restoration

    Current position restoration Specify whether the absolute position system is used for the current position restoration or not in the absolute position control setting. If the values out of range is set, the error “Out of Absolute Position Management Setting Range” (error code: 1AD6H) occurs.
  • Page 85 Absolute position system This system restores the current position using the absolute position data. At the current position restoration, the axis current position (set position, cumulative current position, and feed machine position) is restored based on backed up absolute position data. When restoration is completed, the axis current position restoration status becomes "4: RestoredInAbsSystem".
  • Page 86 Homing request The homing request will be TRUE in the following cases. The reason why the homing request became TRUE is recorded in event history. Absolute position Cause Detection timing control setting Common The axis type is changed. At the current position restoration The machine homing is started.
  • Page 87: Absolute Position Data Backup

    Absolute position data backup When the absolute position system is used, the absolute position data of each axis is backed up. The absolute position data is backed up linked to the axis variable and the axis type. At the current position restoration, if the setting values do not match with the axis variable and the axis type of the absolute position data, the absolute position data will be discarded.
  • Page 88 Precautions The current positon of moved axes after backup stop is not saved. To execute backup after confirming all axes stop is recommended. When restoring absolute position data saved in an SD card Set “ABCDH: backup stop request” to System.Cd.BackupRestore. Confirm System.Md.BackupRestoreStatus changes to “1: backup stop executed”...
  • Page 89: Current Position Restoration For Each Axis Type

    Current position restoration for each axis type This section describes the current position restoration for each axis type. Real drive axis Each current position is restored as the following. Current position Incremental system Absolute position system PosRestoration_AbsPosBase is “3: FeedMachinePosition” Feed machine value Restored in "0".
  • Page 90 The current position restoration of the absolute position system can be classified into the following three methods. Current position Basis position Description Remark restoration method  32-bit restoration (Driver Home position Correctly executes the current position restoration within the current position signed 32-bit integral number range [driver-based] from the restoration) reference position.
  • Page 91: Precautions

    [When using MR-J5(W)-G] The following explains the settings and the current position restoration method when the absolute position system is constructed using MR-J5(W)-G. • MR-J5(W)-G setting Select "1: Enabled (absolute position detection system)" in "Absolute position detection system selection (PA03.0)" of the servo parameter (basic setting).
  • Page 92: Chapter 3 Basic Functions

    BASIC FUNCTIONS Operation Cycle In the motion system, operation processing related to the motion control is performed in the fixed cycle (operation cycle). This section describes operation cycles which can be set in the motion system. Relevant variables Variable/Structure name Name Details System.PrConst.
  • Page 93: Operation Cycle Assignment

    Operation cycle assignment An operation cycle of the axis can be set by AxisName.PrConst.OperationCycle. Send/Receive data refresh of network connected devices Network connected devices are distinguished between stations controlled by the motion system and standard stations, and those data refresh methods are different. Station Explanation Motion syncronization station...
  • Page 94 ■Operation cycle precedence method With operation cycle precedence method, data receive, motion operation, and data send are executed in different operation cycles. For the connected device, it takes five cycles to receive a feedback to the data sent from the connected device. Operation cycle = Communication cycle (1) Receive from the connected station...
  • Page 95: Motion Synchronization Station Link Device Auto Refresh

    Motion synchronization station link device auto refresh Read data (RX, RWr) Received data is refreshed to the link device. For details, refer to the following. MELSEC iQ-R Motion Module User’s Manual (Network) Write data (RY, RWw) Write data to send is refreshed to the link device. It is executed in accordance with the refreshing timing of read data. It is refreshed in the next cycle after the cycle in which the data has been sent to the network.
  • Page 96: Add-On Function

    Add-on Function This section describes add-on Function. The Motion module functions are configured with basic functions provided by the Motion module software and functions provided by the add-on library. The Motion module functions can be expanded by installing add-on libraries. Operation of this function for each system state : Possible System state...
  • Page 97: Add-On Library Configuration

    Page 513 Motion software package file configuration details Provision of installation file The installation file is provided in the MITSUBISHI ELECTRIC FA Global Website, etc. The installation file is common between RD78G and RD78GH. (The both BootRoms are packed.) A motion software package includes the simulator module for the engineering tool. It can simulate the functions including add- on library functions by importing it to the engineering tool.
  • Page 98: Management Of Add-On Library

    Management of add-on library Installation/Uninstallation Add-on libraries are installed in the system folder (/sys) of the Motion module. The Motion module recognizes direct add-on libraries of the system folder (/sys). For installation of add-on libraries, refer to the following. Page 512 Motion System Software Installation For the uninstallation of add-on libraries, refer to Help of the engineering tool.
  • Page 99: System Memory Settings

    System Memory Settings This section describes setting methods of memory size used in the add-on library in the system memory (RAM) and the system memory (backup RAM). System memory System memory (RAM) System memory (back up RAM) Add-on A area Add-on A area Add-on B area Variable...
  • Page 100: System Memory (Ram)

    System memory (RAM) System memory (RAM) stores the data used for the control in an add-on library. The following shows the total size of system memory (RAM). Model RD78G RD78GH System memory (RAM) size 96 MB 160 MB System memory (RAM) usage setting The amount of system memory (RAM) available in each add-on library is set by System.PrConst.Addon_AddonLibraryName.RamSizeMax.
  • Page 101: System Memory (Backup Ram)

    System memory (backup RAM) System memory (backup RAM) is a file system (latch drive) which stores the backup data used for the control in an add-on library. System memory (backup RAM) size is as shown below. Model RD78G RD78GH System memory (backupRAM) size 20 kB System memory (backup RAM) usage setting The amount of system memory (backup RAM) available in each add-on library is set by...
  • Page 102: Software Reboot

    Software Reboot The software reboot (system reset) is executed by writing the reboot command to the control command. When "Clear" is specified at the software reboot command, the system restarts and all data of the system is deleted. This function is used to fetch such as parameters again and reset the motion system to the factory setting without stopping the system caused by the system power ON again.
  • Page 103: Clear

    Clear The following data of the Motion module is deleted after the reboot is carried out. • User drive (/rom) storage data • Latch drive (/lch) storage data • Security information • A part of system drive (/sys) storage data •...
  • Page 104 MEMO 3 BASIC FUNCTIONS 3.4 Software Reboot...
  • Page 105: Motion Control 1

    PART 2 MOTION CONTROL 1 4 START AND STOP 5 HOMING 6 AXIS CONTROL FUNCTION 7 DIRECT CONTROL 8 RELEVANT FUNCTIONS to POSITION 9 RELEVANT FUNCTIONS TO VELOCITY 10 RELEVANT FUNCTIONS TO TORQUE 11 CONTROL SUB FUNCTIONS 12 COMMON FUNCTIONS...
  • Page 106: Chapter 4 Start And Stop

    START AND STOP Start This section describes how to start an axis of the motion system. In the motion system, motion control can be executed by executing motion control function blocks with programs of the control CPU module, such as the PLC CPU and the C language CPU, or the motion system built-in program language such as ST language.
  • Page 107: Starting Conditions

    Starting conditions To start the control, the following conditions must be satisfied. The necessary conditions must be incorporated in the program so that the axis is not started when the conditions are not satisfied. Starting conditions of the axis are mainly controlled by the state transition and the signal state of the axis and axes group. Starting conditions for motion function blocks of the axis ■State transition Name...
  • Page 108: Retrigger/Continuous Update

    Retrigger/Continuous Update The following methods can be used to change the control of the on-going FB. • Retrigger (Inputting Execute again) • Continuous update (ContinuousUpdate) With a retrigger/continuous update of the FB, input variables can be imported again to the FB instance in execution without interrupting operation.
  • Page 109: Multiple Start (Buffer Mode)

    Multiple Start (Buffer Mode) MCFBs can be executed continuously without stopping by executing the motion FB of another instance to the axis and the axes group that are executing the motion control FB. • To execute the MCFB with the axis and the axes group stop status ("4: Standstill" or "4: GroupStandby") is called "start".
  • Page 110 • Up to two motion FBs can be buffered after multiple start in one axis and an axes group. If multiple start is executed when two FBs have already been multiple started, the error "Warning Starting over Number of Buffering FBs" (warning code: 0D22H) occurs and waits the analysis of the multiple start FB in order until on-going FB is completed.
  • Page 111: Relevant Variables

    Command omission at multiple start When omitting the specified speed, the acceleration specification, and the deceleration specification in an FB that executes multiple start, specified speed of "the previous FB of buffering FB" at multiple start is taken over. If the specified speed input does not exist in "the previous FB of buffering FB", buffering is executed with speed 0.0.
  • Page 112: Multiple Start During Single Axis Operation

    Multiple start during single axis operation When axis operation state is as the following, multiple start is enabled by starting a motion FB of another instance. (If the axis operation is in the "4: Standstill" status, it is regarded as "start".) [Axis state in which multiple start is available (AxisName.Md.AxisStatus)] 3: Homing (Only MC_Stop is possible) 5: DiscreteMotion...
  • Page 113 When reverse is enabled When reverse rotation permission is set in reverse rotation permission selection (option bit5), a deceleration stop is executed once. After the deceleration stop is completed, operation is started to the changed direction. Deceleration stop setting at reverse (Aborting) Speed Multiple start timing being executed...
  • Page 114 When reverse is disabled When reverse rotation no permission is set in reverse rotation permission selection (option bit5), the error "Overrun Error" (error code: 1A7EH) occurs at switching and the axis decelerates to a stop. Immediate stop setting at reverse Speed Multiple start timing The first command position...
  • Page 115 Buffer mode that can be set The following shows buffer modes that can be specified in the single axis control FB. For operation details of each FB, refer to each FB specifications. : Buffer mode setting possible, : Buffer mode setting not possible (axis error) Setting possible in FB Completion Setting possible in the later operation...
  • Page 116 Aborting during single axis operation On-going FB is interrupted and the next FB is executed. Since a buffer is not used, an error does not occur even if two of the on-going FBs have already been in buffering, and the FB is executed.
  • Page 117 Buffered during single axis operation Multiple started FBs are buffered and wait (Busy = TRUE) until the on-going FB is completed. After the on-going FB is normally completed, multiple started FBs are performed in the order of being buffered. Speed The following FB starts after Multiple start timing stopping at the target position.
  • Page 118 Blending during single axis operation Multiple started FBs are buffered and wait until the on-going FB is completed. After the on-going FB reached the target position, buffering FBs are performed in order. In this case, the switching speed differs depending on the mode specified in the buffer mode.
  • Page 119 ■BlendingNext The FB is operated so that the velocity becomes the target velocity of the FB in buffering at the target position of the on-going When deceleration is carried out Transfer speed uses the set velocity Speed of buffering FB. Multiple start Buffering FB being executed...
  • Page 120 Depending on the multiple start timing, the movement amount in order to change the speed to the target velocity of the FB in buffering may be in short at the target position of the on-going FB. In this case, velocity change is executed immediately, but the velocity cannot reach the target velocity of the FB that is during buffering at the target position of the on-going FB.
  • Page 121: Multiple Start During Multiple Axes Operation

    Multiple start during multiple axes operation When axes group operation state is as the following, multiple start is enabled by executing the motion FB of another instance. (If the axis operation is in the "4: GroupStandby" status, it is regarded as "start".) [Axes group status that can be multiple started (AxesGroupName.Md.GroupStatus)] 5: GroupMoving In multiple start during multiple axes operation, the current interpolation speed of the on-going FB is used as the switching...
  • Page 122 When on-going FB (FB1) or next FB (FB2) has the VelocityMode input and the velocity mode settings are different between FBs, the warning "Multiple Start Speed Mode Specified Mismatch Warning" (warning code: 0D11H) will occur and the operation will become as the following. FB1 VelocityMode is used in FB1 and FB2 VelocityMode is used in FB2 to control.
  • Page 123 Aborting during multiple axes operation On-going FB is interrupted and the multiple started FB is executed. Since a buffer is not used, an error does not occur even if two of the on-going FBs have already been in buffering, and the FB is executed.
  • Page 124 Buffered during multiple axes operation Multiple started FBs are buffered and wait until the on-going FB is completed. After the on-going FB is normally completed, multiple started FBs are performed in the order of being buffered. Interpolation speed The following FB starts Multiple start timing after stopping at the target position Buffering FB...
  • Page 125 Blending during multiple axes operation Multiple started FBs are buffered and wait until the on-going FB is completed. After the on-going FB reached the target position, buffering FBs are performed in order. In this case, the switching speed differs depending on the mode specified in the buffer mode.
  • Page 126 ■BlendingNext The FB is operated so that the interpolation velocity becomes the target velocity of FB that is during buffering at the target position of the on-going FB. Transfer speed uses the set velocity Interpolation speed of buffering FB. Multiple start Buffering FB being executed Execute...
  • Page 127 Depending on the multiple start timing, the movement amount to change velocity to the target velocity of the FB that is during buffering at the target position of the on-going FB. In this case, velocity change is executed immediately, but the velocity cannot reach the target velocity of the FB that is during buffering at the target position of the on-going FB.
  • Page 128: Precautions

    Precautions When deceleration distance of a buffering FB cannot be secured with the switching speed and the target position is overrun at switching to the buffering FB, automatic deceleration operation is performed according to the AxisName(AxesGroupName).Pr.OverrunOperation settings. • For "1: ImmediateStop" The axis starts deceleration immediately, and it stops immediately at reaching the target position after outputting the warning "Overrun Warning"...
  • Page 129 • For ”2: KeepCurrentAcc” (Only for single axis) The axis starts deceleration immediately, and it stops after exceeding the target position. When the stop address is exceeded, the error "Overrun Error" (error code: 1A7EH) is output. However, when the error occurs, the operation stops according to the setting of AxisName.Pr.StopMode_General.
  • Page 130 If an error occurs in the following FB analysis processing at multiple start, the axis status (AxisName.Md.AxisStatus) and the axes group status (AxesGroupName.Md.GroupStatus) will be error stop and the on-going FBs will stop. Instruction stops and stop process starts due to an error occurrence of buffering FB (FB2) Speed Multiple start...
  • Page 131 When the target position or the target velocity is changed at restart or continuous update to on-going FB, the buffering FB may have to be reanalyzed. As a result of reanalysis, if an error occurs in any FB, the axis status (AxisName.Md.AxisStatus) and the axes group status (AxesGroupName.Md.GroupStatus) will be error stop and the on-going FBs will be interrupted and stop.
  • Page 132: Stop

    Stop This section describes how to stop control. Each control is stopped in the following cases. Axis operation stop • When each control is completed normally • When the "forced stop input" is turned OFF • When the drive unit power supply is turned OFF •...
  • Page 133 Variable/Structure name Name Details StopMode_General Stop selection at stop by factors Selects operation when a stop cause for each axis other than the stop cause 1 and 2 occurs. 1: ImmediateStop (Immediate stop) (Initial value) 2: KeepCurrentAcc (Keep current acceleration/deceleration) 3: AlternativeAcc (Alternative acceleration/deceleration) (Immediate stop will be executed when executing an instruction without deceleration specification.)
  • Page 134 Variable/Structure name Name Details StopStatus Stop status Displays the input status of stop signal (STOP) among external input signals. StopMode_DecelerationCurve Stop selection at deceleration to stop Displays input status of the stop processing selection at deceleration stop. StopMode_Deceleration Deceleration at stop Displays input status of the deceleration at stop.
  • Page 135 Variable/Structure name Name Details StopMode_AllDeceleration Deceleration at all axes stop Specifies the deceleration at deceleration stop when an all axes stop cause occurred. • When "acceleration/deceleration method" is Jerk Unit: Specify with U/s Range: 0 , a positive number from 0.0001 to 2147483647.0 U/s •...
  • Page 136 MC_Stop Item Description Function overview Decelerates specified axis to stop. Symbol [Structured Ladder] MC_Stop DUT : Axis Axis : DUT B : Execute Done : B Busy : B L : Deceleration Active : B L : Jerk UD : Options CommandAborted : B Error : B ErrorID : UW...
  • Page 137 ■I/O variable Import : At start Name Variable name Data type Input Setting range Default Description import value   Page 568 Axis variables Axis information Axis AXIS_REF Omission possible ■Input variables Import : At start, R: Retrigger possible Name Variable name Data type Import...
  • Page 138 MC_GroupStop Item Description Function overview Decelerates specified axes group to stop. Symbol [Structured Ladder] MC_GroupStop B : AxesGroup AxesGroup : B B : Execute Done : B L : Deceleration Busy : B L : Jerk Active : B UD : Options CommandAborted : B Error : B ErrorID : UW...
  • Page 139 [When an error occurs] Execute Done Error ErrorID Error code ■I/O variable Import : At start Name Variable name Data type Input Setting range Default Description import value   Page 574 Axes group variables Axes group AxesGroup AXES_GROUP_ Omission information possible ■Input variables...
  • Page 140: Stop Cause Lists

    Stop cause lists Stop causes during axis operation The following shows stop causes during axis operation and the process when each cause occurs. Cause Stop cause Stop axis Axis status Stop process (AxisName.Md.AxisStatus) During After stop deceleration stop  "Forced stop input" is FALSE Each axis/All 1: ErrorStop Immediate stop...
  • Page 141 Stop causes during axes group operation The following shows stop causes during axes group operation and the process when each cause occurs. Cause Stop cause Stop axis Axes group status Stop process (AxesGroupName.Md.Grou pStatus) During After stop deceleration stop Stop cause Axis error Axes group Stop cause...
  • Page 142: Types Of Stop Processes

    Types of stop processes This section describes types of stop processes for a single axis and an axes group. Stop processes for single axis ■Deceleration stop The operation decelerates from the speed during operation to speed 0. The deceleration differs depending on AxisName.Pr.StopMode_DecelerationCurve.
  • Page 143: Deceleration Stop

    Stop processes for axes group ■Deceleration stop The operation decelerates from the interpolation speed during operation to the interpolation speed 0. The deceleration differs depending on AxesGroupName.Pr.StopMode_Deceleration. However, the stop is performed by the MC_GroupStop execution, the deceleration specified in the Deceleration input is applied.
  • Page 144: Order Of Priority For Stop Process

    Order of priority for stop process This section describe processes when multiple stop causes occur. The order of priority is as shown below based on the stop process of occurred stop cause. Priority Stop method Immediate stop Deceleration stop When a deceleration stop cause occurs again during deceleration stop (including a stop cause and automatic deceleration), the deceleration process differs depending on the following parameter settings for a single axis or an axes group.
  • Page 145: Overrun At Stop Cause Occurrence

    Overrun at stop cause occurrence This function selects operation for the case that the positioning address of an instruction which was executed before a stop cause occurs is reached during deceleration stop and immediate stop process. This function is enabled only when the target position exists at stop cause occurrence. The following parameters for a single axis or an axes group are need to be set in this function.
  • Page 146: Stop During Single Axis Operation

    Stop during single axis operation This section explains each stop cause. Stop causes of immediate stop with no condition When the following stop causes occur, the servo OFF is executed in the drive unit and the axis stops immediately. For how to stop the drive unit, refer to each drive unit manual. •...
  • Page 147 ■Axis state transition The axis state changes based on the input combination of Enable and ServoON of MC_Power. Axis status before input Input Processing selection at servo OFF Axis status after input operation operation command during operation (AxisName.Md.AxisStatus) Enable ServoON (AxisName.Md.AxisStat 4: Standstill TRUE...
  • Page 148 Axis error detection When an axis error other than the hardware stroke limit upper/lower limit error, the CPU module error, an error by the PLC READY [Y0] OFF, the software stroke limit upper/lower limit error, and an axis error other than the drive unit error is detected, the operation stops according to the process selected by AxisName.Pr.StopMode_General.
  • Page 149 ■Operation description • During deceleration stop by this FB and while Execute (start) of the input variable is TRUE, any operation command other than MC_Stop is not accepted. • If the deceleration is set to 0 or omitted, immediate stop will be executed. •...
  • Page 150 • When an FB that operates axes other than MC_Stop is executed while the axis status (AxisName.Md.AxisStatus) is the "2: Stopping" status The error "Start Not Possible" (error code: 1AADH) occurs and Error of MC_Stop turns TRUE, and then the axis status (AxisName.Md.AxisStatus) changes to "1: ErrorStop".
  • Page 151 • When the process is stopped by TRUE of AxisName.Pr.StopSignal, the axis status (AxisName.Md.AxisStatus) after stop will not change. • The deceleration can be changed by executing MC_Stop while process stop is executed by TRUE of AxisName.Pr.StopSignal. • The deceleration can be changed when AxisName.Pr.StopSignal is TRUE during MC_Stop execution. In this case, the axis status (AxisName.Md.AxisStatus) after deceleration stop will not change.
  • Page 152: Stop During Axes Group Operation

    Stop during axes group operation This section explains each stop cause. Stop cause occurrence in the configuration axis The following shows axes group operation when a stop cause of the configuration axis occurs. Stop cause occurrence axis Axes group Caus Stop cause Axis status Stop...
  • Page 153 When a stop cause has occurred in a configuration axis of the axes group, operation differs depending on the following four patterns. ■For an axis error (driver servo OFF and immediate stop) The error "Stop Cause of Axes Group Configuration Axis" (error code: 1A3DH) occurs in the axes group. Also, if the driver servo OFF is executed and the configuration axis in which the stop cause occurred stops immediately, the other configuration axes will be operated according to the stop process selected in AxesGroupName.Pr.StopMode_ErrorInGroup.
  • Page 154 • Immediate stop and servo OFF 4: ServoOffAfterImmediateStop In the axes group configuration axes other than the axis which an axis error has occurred in, a command to the drive unit is stopped, and for real drive axes, the servo OFF command is issued to the drive unit. AxesGroupName.
  • Page 155 ■Axis error If an axis error has occurred in the configuration axis, the error "Stop Cause of Axes Group Configuration Axis" (error code: 1A3DH) will occur in the axes group. In this case, the axes group will pass through the path and stop according to the AxesGroupName.Pr.StopMode_General setting.
  • Page 156 ■Hardware stroke limit error/Software stroke limit error When any of the following conditions is satisfied, the axes group will immediately stop regardless of the axes group setting. In this case, the error "Stop Cause of Axes Group Configuration Axis" (error code: 1A3DH) occurs in the axes group and its status changes to the "1: GroupErrorStop".
  • Page 157 Axes group error detection When an axes group error other than the "Stop cause occurrence in the configuration axis" is detected, the operation will be stopped according to the process selected by AxesGroupName.Pr.StopMode_General. The value set in AxesGroupName.Pr.StopMode_Deceleration will be used for the deceleration at this time. •...
  • Page 158 MC_GroupStop (Group forced stop) In MC_GroupStop, the deceleration (Deceleration) is set and on-going instruction is decelerated to a stop. The axes group passes through the previous operation path and decelerates to a stop. When MC_GroupStop is executed, CommandAborted of on-going instruction turns TRUE and the axes group status (AxesGroupName.Md.GroupStatus) transits to the "2: GroupStopping"...
  • Page 159 ■Operation description • During deceleration stop by this FB and while Execute (start) of the input variable is TRUE, any operation command other than MC_GroupStop is not accepted. • If the deceleration is set with 0 or omitted, immediate stop will be executed. •...
  • Page 160 • Even if Execute of command aborted FB is set to FALSE by MC_GroupStop, once the stop operation is started, TRUE of CommandAborted will be continued until it is completed. After it stops completely, changes CommandAborted to FALSE if Execute of command aborted FB is FALSE. MCv_MoveLinearInterpolateRelative Do not change start impossible...
  • Page 161: Forced Stop

    Forced Stop This function stops axes with the forced stop signal. The forced stop function is valid to axes which have function of positioning control and velocity/torque control. For details, refer to the following. Page 37 Axis Type WARNING • When the forced stop is required to be wired, ensure to wire it in the negative logic, and b-contact is recommended. •...
  • Page 162 Variable/Structure name Name Details ForcedStop_Signal Forced stop signal Displays the input status of each axis forced stop signal. ForcedStop_Signal is the structure of SIGNAL_SELECT type. For details of SIGNAL_SELECT type, refer to the following. Page 356 External Signal Selection The specific output of this signal is shown below. •...
  • Page 163: Operation At The Forced Stop Occurrence

    Operation at the forced stop occurrence The following shows the operation when a forced stop has occurred. During axis operation Immediate stop Set velocity Forced stop signal AxisName.Md. ForcedStop_Released AxisName.Md. 1: ErrorStop AxisStatus AxisName.Md.ErrorID Other than 0 AxisName.Md. Driver_ReadyOn AxisName.Md. Driver_ServoOn •...
  • Page 164: Operation At The Forced Stop Release

    During axes group operation The following shows the operation when a forced stop has occurred to the axis A while an axes group configured with the axis A and B is being operated. Immediate stop (Axis A) Set velocity Deceleration stop or immediate stop (Axis B) Set velocity (Axis A) Forced stop signal Axis A.Md.AxisStatus...
  • Page 165: Check Method

    Axes group The following shows the release operation when a forced stop has occurred to the axis A while an axes group configured with the axis A and B is being operated. (Axis A) Forced stop signal AxesGroupName.Cd. ErrorReset Axis A.Md.AxisStatus 1: ErrorStop 0: Disabled Axis B.Md.AxisStatus...
  • Page 166: Chapter 5 Homing

    HOMING In "homing", a position is established as the starting (or "home position") when carrying out positioning control, and positioning is carried out toward that start point. It is used to return a machine system at any position other than the home position to the home position when the motion system issues a "homing request"...
  • Page 167: Relevant Variables/Fb

    Relevant variables/FB Variable/Structure name Name Details AxisName.Md Homing_Status Homing operation status Stores the homing status of the driver. Homing_Request Homing request Turns TRUE when homing is required and turns FALSE when it is completed. For details, refer to the following. Page 166 Homing Request Homing_Complete Homing completed...
  • Page 168: Homing Request

    ■Output variables Name Variable name Data type Default Description value Execution completion Done BOOL FALSE Indicates that the homing is completed. Executing Busy BOOL FALSE Indicates that the FB is in execution. Controlling Active BOOL FALSE Indicates that the FB is controlling the axis. Abortion of execution CommandAborted BOOL...
  • Page 169: Driver Homing Method

    Driver homing method The driver is switched to the Homing mode, and the homing is executed based on the positioning pattern set on the driver side. Change the homing data of the driver with MC_WriteParameter to change the homing method or each parameter. Refer to the manual of the driver because the homing operation and parameters depend on the specification of the driver.
  • Page 170 ■When MC_Stop (forced stop) is executed AxisName.Md.ActualVelocity MC_Stop Execute Busy Done MC_Home Execute Done Busy Active CommandAborted AxisName.Md.AxisStatus 4: Standstill 3: Homing 2: Stopping AxisName.Md.Driver_Mode AxisName.Md.Homing_Request AxisName.Md.Homing_Complete FFFFH AxisName.Md.Homing_Status FFFFH • When MC_Stop is turned TRUE at homing, the "HALT" signal is sent to the driver. When using a driver that does not support HALT, use the forced stop because it does not stop with this signal.
  • Page 171: Data Set Homing Method

    Data set homing method "Data set homing method" is executed to a virtual axis and a real axis that does not have the home position information in the slave device side. It is completed in the motion system, and external signals, etc. are not used. The Position (home position address) at homing is registered in the motion system as the home position, and AxisName.Md.SetPosition and AxisName.Md.CumulativePosition are rewritten to Position (home position address).
  • Page 172: Operation Setting For Incompletion Of Homing

    Operation Setting for Incompletion of Homing The operation setting for incompletion of homing is provided to select whether the axis is started or not when the homing request, AxisName.Md.Homing_Request is TRUE. When starting the axis at homing incompletion, whether the axis can startup or not is determined by the executed FB and AxisName.Pr.StartableAtUnhomed.
  • Page 173: Chapter 6 Axis Control Function

    AXIS CONTROL FUNCTION Single Axis Positioning Control The details and usage of the single axis positioning controls are explained in this section. The single axis positioning controls execute positioning to the specified position by using address information. Relevant FBs MC_MoveAbsolute Item Description Function overview...
  • Page 174 [When an error occurs] Execute Done Busy Active Error ErrorID Error code ■I/O variable Import : At start Name Variable Data type Input Setting range Default Description name import value   Page 568 Axis variables Axis information Axis AXIS_REF Omission not possible ■Input variables...
  • Page 175 Name Variable name Data type Default Description value Controlling Active BOOL FALSE Indicates that the axis is being controlled. Abortion of execution CommandAborted BOOL FALSE It indicates that another FB has aborted the execution of the FB. Turns TRUE when this FB is stopped by an error or this FB is started during an error occurence.
  • Page 176 MC_MoveRelative Item Description Function overview Executes positioning after specifying the movement amount of the relative position. Symbol [Structured Ladder] MC_MoveRelative DUT : Axis Axis : DUT B : Execute Done : B B : ContinuousUpdate Busy : B L : Distance Active : B L : Velocity CommandAborted : B...
  • Page 177 ■I/O variable Import : At start Name Variable Data type Input Setting range Default Description name import value   Page 568 Axis variables Axis information Axis AXIS_REF Omission not possible ■Input variables Import : At start, R: Retrigger possible, C: Continuous update possible Name Variable Data type...
  • Page 178: Absolute Positioning Control

    Absolute Positioning Control In MC_MoveAbsolute, Position, Velocity, Acceleration, Deceleration, Jerk, Direction, BufferMode, and Options can be set, and positioning is executed from the current position at start (start point address) to the address set in Position (end point address). When the start point address (current stop position) is 1000, and Position is 8000, positioning is carried out in the positive direction for a movement amount of 7000 (8000 - 1000).
  • Page 179 ■Deceleration (Deceleration) Set time from the speed limit value to speed 0. For details, refer to the following. Page 293 Acceleration/deceleration Processing Function ■Jerk (Jerk) Set Jerk. For details, refer to the following. Page 293 Acceleration/deceleration Processing Function ■Direction (Direction selection) This setting is ignored when the software stroke limit is valid.
  • Page 180 [Setting the target position exceeding the ring counter (Options bit16)] "1: Allow" The positioning operation that overflows the ring counter upper limit value can be performed. In this case, the ring counter upper limit value is used as a reference, and positioning is performed with the amount of movement exceeded as the relative movement amount.
  • Page 181 Operation when setting the ring counter upper limit value to "100", the ring counter lower limit value to "-50", the current position to "30", and the target position to "350" (the relative value positioning is executed after exceeding the ring counter upper limit value) Current value "50"...
  • Page 182 • Negative direction 2. mcNegativeDirection The positioning is executed from the current position to the target position of negative direction (address decrease). [Setting the target position exceeding the ring counter (Options bit16)] "0: Not allow" The setting range of the target position is "Ring counter lower limit value  Target position < Ring counter upper limit value". Setting Operation Ring counter lower limit value ...
  • Page 183 Setting Operation • Ring counter lower limit value  Target The same operation as the "Setting the target position exceeding the ring counter: Not allow" position  Current value • Current value < Target position < Ring counter upper limit value Positioning range lower limit value ...
  • Page 184 Operation when setting the ring counter upper limit value to "100", the ring counter lower limit value to "-50", the current position to "-20", and the target position to "-220" Current position Position "80" after "-20" positioning completion Ring counter upper limit value Ring counter lower limit value...
  • Page 185 • Current direction 4: mcCurrentDirection The direction of the previous instruction (Motion) is repeated. When no instruction has executed, the positive direction is used for operation. When the movement amount is 0 at the previous instruction, the last-but-one movement direction is used. (Ignored even if specifying the direction at previous instruction).
  • Page 186 Necessary slave object When using MC_MoveAbsolute, set the following slave object to the axis. • Target position If the above slave object is not set, the error "Necessary Slave Object Unset" (error code: 1AA8H) will occur, and the axis will not start.
  • Page 187: Relative Positioning Control

    Relative Positioning Control In MC_MoveRelative, Distance, Velocity, Acceleration, Deceleration, Jerk, and BufferMode can be set, and positioning of movement amount set in Distance is executed from the current position at start (start point address). The movement direction is determined by the sign of the movement amount. The axis status (AxisName.Md.AxisStatus) becomes "5: DiscreteMotion". When the start point address is 5000, and the movement amount is -7000, positioning is carried out to -2000.
  • Page 188 ■Options (Options) Set the function options that are used in MC_MoveRelative by specifying the bit. The details of bit and the functions are shown below. Function description 0 to 2 Acceleration/deceleration method setting 0: mcAccDec (Acceleration/deceleration specification method) 1: mcFixedTime (Acceleration/deceleration time-fixed method) For details, refer to the following.
  • Page 189: Single Axis Speed Control

    Single Axis Speed Control This section describes operation of the single axis speed control (including position loop). For speed control excluding position loop, refer to the following. Page 242 Velocity Control Relevant FB MCv_SpeedControl Item Description Function overview Executes the speed control including position loop. Symbol [Structured Ladder] MCv_SpeedControl...
  • Page 190 [When an error occurs] Execute Busy Active InVelocity CommandAborted Error Error code ErrorID ■I/O variable Import : At start Name Variable Data type Input Setting range Default Description name import value   Page 568 Axis variables Axis information Axis AXIS_REF Omission not possible...
  • Page 191 *1 For bits and function description, refer to the following table. Function description 0 to 2 Acceleration/deceleration method setting 0: mcAccDec Acceleration/deceleration specification method 1: mcFixedTime Acceleration/deceleration time-fixed method For details, refer to the following. Page 293 Acceleration/deceleration Processing Function 3 to 15 Empty (Reserved) 18 to 31...
  • Page 192: Control Details

    Control details Set the control mode of the driver side to csp and execute the speed control for the specified axis with the specified speed. MCv_SpeedControl is used to execute. To stop the axis, use MC_Stop or start another operation instruction. To execute the speed control with csv of the control mode of the driver side, use MC_MoveVelocity, etc.
  • Page 193: Buffermode

    Timing chart when the operation direction is changed When the operation direction is changed due to the case that sign of the target velocity is reversed at ContinuousUpdate TRUE, etc., the axis accelerates toward the target velocity once after deceleration stop. Execute Busy Active...
  • Page 194: Single Axis Manual Control

    Single Axis Manual Control This section describes the single axis manual control. Relevant variables/FB Variable/Structure name Name Details AxisName.Cd SwStrokeLimit_Override Software stroke limit override Temporarily switches valid/invalid of the software stroke limit check. HwStrokeLimit_Override Hardware stroke limit override Temporarily switches valid/invalid of the hardware stroke limit check. MCv_Jog Item Description...
  • Page 195 [When an error occurs] JogForward Done Busy Active CommandAborted Error Error code ErrorID ■I/O variable Import : At start Name Variable name Data type Input Setting range Default Description import value   Page 568 Axis variables Axis information Axis AXIS_REF Omission not possible...
  • Page 196: Types Of Manual Control

    Types of manual control There is the following type of manual control. JOG operation JOG operation is a control method in which the machine is moved by only a movement amount (commands are continuously output while the JOG command is TRUE). Movement continues while the JOG command is TRUE.
  • Page 197 Control details • JOG operation is carried out with MCv_Jog. • The target axis is moved to the specified direction during TRUE, by turning JogForward or JogBackward TRUE. • The axis status (AxisName.Md.AxisStatus) during JOG operation is "6: ContinuousMotion". • A deceleration stop is performed based on the settings of Deceleration and Jerk, by turning JogForward or JogBackward FALSE.
  • Page 198 Details of setting items ■JogForward (Positive rotation JOG operation)/JogBackward (Reverse rotation JOG operation) • Positive rotation JOG operation and reverse rotation JOG operation are started by turning JogForward and JogBackward TRUE respectively, and the target axis is moved to the specified direction during TRUE. •...
  • Page 199 JogForward JogBackward Done Busy Active AxisName.Md. SetVelocity Ignores TRUE of JogForward • Deceleration stop and acceleration are required repeatedly while moving by JOG operation, uses velocity change by override function. For details of the override function, refer to the following. Page 321 Override Function JogForward JogBackward...
  • Page 200 • For safety, set a small value in Velocity first and check the movement, and then gradually increase the value. • Use the hardware stroke limit function when carrying out JOG operation near the upper or lower limits. If the hardware stroke limit function is not used, the workpiece may exceed the moving range and cause an accident.
  • Page 201: Multiple Axes Positioning Control

    Multiple Axes Positioning Control The details and usage of the multiple axes positioning controls are explained in this section. The multiple axes positioning controls use address information and execute positioning to the specified position using interpolation control. Relevant variables/FBs Variable/Structure name Name Details AxesGroupName.AxesGroupRef.
  • Page 202 MCv_MoveLinearInterpolateAbsolute Item Description Function overview Specifies the target position of the absolute position of specified axes group, and executes positioning by linear interpolation control. Symbol [Structured Ladder] MCv_MoveLinearInterpolateAbsolute DUT : AxesGroup AxesGroup : DUT B : Execute Done : B B : ContinuousUpdate Busy : B W[ ] : LinearAxes...
  • Page 203 Name Variable Data type Import Setting range Default Description name value  Speed mode VelocityMode MC_INTERPO 0 to 2 Specifies the speed mode of interpolation control. LATE_SPEED_ 0: VectorSpeed (Vector speed) MODE 1: LongAxisSpeed (Long axis speed) 2: ReferenceAxisSpeed (Reference axis speed) ...
  • Page 204 MCv_MoveLinearInterpolateRelative Item Description Function overview Specifies the movement amount of the relative position of specified axes group, and executes positioning by linear interpolation control. Symbol [Structured Ladder] MCv_MoveLinearInterpolateRelative DUT : AxesGroup AxesGroup : DUT B : Execute Done : B B : ContinuousUpdate Busy : B W[ ] : LinearAxes...
  • Page 205 Name Variable Data type Import Setting range Default Description name value  Speed mode VelocityMode MC_INTERPO 0 to 2 Specifies the speed mode of interpolation control. LATE_SPEED_ 0: VectorSpeed (Vector speed) MODE 1: LongAxisSpeed (Long axis speed) 2: ReferenceAxisSpeed (Reference axis speed) ...
  • Page 206 MCv_MoveCircularInterpolateAbsolute Item Description Function overview Executes positioning by 2-axis circular interpolation by using arbitary configuration axes of set axes group, and by using the specified end point and the sub point of the absolute position. Symbol [Structured Ladder] MCv_MoveCircularInterpolateAbsolute DUT : AxesGroup AxesGroup : DUT B : Execute Done : B...
  • Page 207 Name Variable Data type Import Setting range Default Description name value  Sub point AuxPoint LREAL[1..16] For "0: mcBorder", Sets the absolute position of sub point according "1:mcCenter": to unit of axis. Page 67 It is N-dimentional array data. It is treated as the Positioning Range absolute position of the configuration axis 1, 2, ..., For "2: mcRadius":...
  • Page 208 ■Output variables Name Variable name Data type Default Description value Completion Done BOOL FALSE Indicates that the control is completed. When Execute is TRUE at the operation completion, TRUE remains until Execute turns FALSE. When Execute is FALSE at the operation completion, it becomes TRUE only for one cycle.
  • Page 209 MCv_MoveCircularInterpolateRelative Item Description Function overview Executes positioning by 2-axis circular interpolation by using arbitary configuration axes of set axes group, and by using the relative position from the specified current position at start to the end point and the sub point. Symbol [Structured Ladder] MCv_MoveCircularInterpolateRelative...
  • Page 210 Name Variable Data type Import Setting range Default Description name value  Sub point AuxPoint LREAL[1..16] For "0: mcBorder", Sets the relative position according to unit of axis "1:mcCenter": from the current position at start to the sub point. Page 67 It is N-dimentional array data.
  • Page 211: Operation In Multiple Axes Positioning Control

    ■Output variables Name Variable name Data type Default Description value Completion Done BOOL FALSE Indicates that the control is completed. When Execute is TRUE at the operation completion, TRUE remains until Execute turns FALSE. When Execute is FALSE at the operation completion, it becomes TRUE only for one cycle.
  • Page 212: Positioning Speed In Multiple Axes Positioning Control

    Positioning speed in multiple axes positioning control Positioning speed at multiple axes positioning control can be set in the Velocity input of the motion control FB. In the multiple axes positioning control, a control target is controlled at the specified positioning speed. Linear interpolation control To specify the positioning speed for the linear interpolation control, the following three methods can be used.
  • Page 213 ■Long axis speed specification 1: LongAxisSpeed The control is carried out based on the positioning speed (the long axis speed: V) of the axis whose movement amount is the largest in the addresses set in each axis. The positioning speed of the other axes is calculated by the motion system from the movement amount (D1 to D4) of each axis.
  • Page 214 • For the long axis speed specification, set speed limit value is valid for the Velocity input which is as the long axis speed. For details, refer to the following. Page 318 Speed Limit • Note that the vector speed when specifying the long axis speed may be larger than the speed limit value. (Ex.) When setting a value like the following in the 2-axis linear interpolation, the vector speed exceeds the speed limit value.
  • Page 215 ■Reference axis speed specification 2: ReferenceAxisSpeed The motion system calculates the positioning speed (V1 to V3) of other axes based on the positioning speed of the set reference axis (the reference axis speed: V), and carries out the control. In MCFB, the top array of the LinearAxes input indicates the reference axis. Also, set the Position input or the Distance input as the movement amount of each axis and set the Velocity input as the single axis speed.
  • Page 216 • For the reference axis speed specification, set speed limit value is valid to the Velocity input which is as the reference axis speed. For details, refer to the following. Page 318 Speed Limit • Note that the positioning speed of the axis whose movement amount is larger than that of the reference axis is larger than the set reference axis speed.
  • Page 217 The positioning speed for Blending of the multiple axes positioning control This section explains operation when selecting BlendingLow, BlendingPrevious, BlendingNext, and BlendingHigh in the BufferMode input of the function block and setting different speed mode to the VelocityMode input of the first function block (FB1) and the second function block (FB2) in the multiple axes positioning control.
  • Page 218 The following shows an operation example. • Reaches the target position of FB1 of [100 mm 100 mm] at the reference axis speed of 1000 mm/s of the configuration axis 1that is the reference axis, 1000 mm/s. • Starts operation from the current position of FB2 of [100 mm 100 mm] at the vector speed of 1000 mm/s. •...
  • Page 219 The following shows an operation example. • Operates to the middle of the target position of FB1 of [100 mm 100 mm] at the reference axis speed of the configuration axis 1, 1000 mm/s. • The configuration axis 1 reaches the target position of FB1 of [100 mm 100 mm] at the reference axis speed of 200 mm/s. •...
  • Page 220: Command Unit In The Multiple Axes Positioning Control

    Command unit in the multiple axes positioning control Command unit of the multiple axes positioning control The command unit in the multiple axes positioning control differs depending on the VelocityMode input of the function block for the motion control. For details and precautions, refer to the following. Page 62 Technical Units, Page 119 Multiple start during multiple axes operation Command unit for Blending of the multiple axes positioning control This section explains operation when selecting BlendingLow, BlendingPrevious, BlendingNext, and BlendingHigh in the...
  • Page 221 • FB2 input (Command unit: degree/min from the command unit of the configuration axis 3) Setting item Setting value LinearAxes [3 4 0 0 0 0 0 0 0 0 0 0 0 0 0 0] or [3 4] Position [0 0 200 200 0 0 0 0 0 0 0 0 0 0 0 0] or [0 0 200 200] Velocity VelocityMode...
  • Page 222: Acceleration/Deceleration Processing

    The following shows an operation example. • Operates to the middle of the target position of FB1 of [100 mm 100 mm] at the vector speed of 1000 mm/s. • Decelerates so that it reaches the target position of FB1 of [100 mm 100 mm] at the vector speed of 200 mm/s. •...
  • Page 223: Linear Interpolation Control

    Linear interpolation control Linear interpolation control specifies an axes group and performs interpolation control so that the path from the stat point (move start point) to the end point becomes a straight line. In linear interpolation control, interpolation control using maximum 4 axes is performed.
  • Page 224 The control is as shown below for the following conditions. LinearAxes: [1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] The current stop address: [-3000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] Distance: [-5000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] LinearAxes: [1] The current stop address: [-3000]...
  • Page 225 ■2-axis linear interpolation control (relative value) 2-axis linear interpolation is executed by the movement amount set to Distance from the current position at start (start address). The movement direction is determined by a sign (+/-) of the movement amount. • When the movement direction is positive: Positioning to the positive direction (address increasing direction) •...
  • Page 226 ■3-axis linear interpolation control (absolute value) 3-axis linear interpolation is executed from the current position at start (start address) to the address set to Position. The movement direction is determined by the current position at start (start address) and the end address of each axis. Positive End point address (X direction...
  • Page 227 ■3-axis linear interpolation control (relative value) 3-axis linear interpolation is executed by the movement amount set to Distance from the current position at start (start address). The movement direction is determined by a sign (+/-) of the movement amount. • When the movement direction is positive: Positioning to the positive direction (address increasing direction) •...
  • Page 228 Timing chart ■When the FB is normally completed Velocity AxesGroupName.Md. SetVelocity Execute Done Busy Active Error ErrorID AxesGroupName.Md. 4: GroupStandby 5: GroupMoving 4: GroupStandby GroupStatus ■When an error occurs Execute Done Busy Active Error Error code ErrorID 6 AXIS CONTROL FUNCTION 6.4 Multiple Axes Positioning Control...
  • Page 229 Details of setting items ■ContinuousUpdate (ContinuousUpdate) Continuous update of the FB enables to import input variables again without interrupting the operation to the instance in execution. Input variables that can be change in restart/continuous update are Position/Distance, Velocity, Acceleration, and Deceleration.
  • Page 230 ■Velocity (Velocity) Specify the maximum speed of the way. For details, refer to the following. Page 210 Positioning speed in multiple axes positioning control ■Acceleration (Acceleration) Specify the acceleration. The setting details differ depending on the acceleration/deceleration method. For details, refer to the following.
  • Page 231 ■Direction (Dilection selection) It can be selected from the positive direction, the negative direction, the shortest way, and the current direction. Specify the direction to move from the current position to the target position. Direction has 16 array elements. • Direction [0..(N-1)] indicates the direction selection of the configuration axis 1 to N. Set the value in the configuration axis set in LinearAxes.
  • Page 232: Circular Interpolation Control

    Circular interpolation control Circular interpolation control specifies an axes group and performs interpolation control so that the path from the stat point (move start point) to the end point becomes an arc to a linear axis which is arranged mechanically orthogonally. In circular interpolation control, interpolation control using arbitrary two axes from the configuration axes set to the axes group.
  • Page 233 Details of setting items ■ContinuousUpdate (Continuous update) Continuous update of the FB enables to import input variables again without interrupting the operation to the instance in execution. Input variables that can be change in restart/continuous update are Position/Distance, Velocity, Acceleration, and Deceleration.
  • Page 234 • Absolute value circular interpolation control operation with border point designation In absolute value circular interpolation control with border point designation, positioning is carried out from the current position at start (start point address) to the address set to EndPoint (end point address) in an arc path that passes through the address (border point address) set to AuxPoint.
  • Page 235 2-axis circular interpolation control cannot be set in the following cases. • When the radius exceeds 2147483647.0 (the maximum radius for which 2-axis circular interpolation control is possible is 2147483647.0): The error "Out of Radius Range" (error code: 1A6CH) will occur at positioning start.
  • Page 236 • Circular interpolation control with center point designation When selecting "1: mcCenter" in the CircMode input, two configuration axes specified in CircAxes are used to carry out positioning control in an arc path having the specified center point as a center point. [Circular interpolation path] The path in the absolute value circular interpolation control with center point designation can be set by the PathChoice input of MCFB.
  • Page 237 • Absolute value circular interpolation control operation with center point designation In absolute value circular interpolation control operation with center point designation, positioning is carried out from the current position at start (start point address) to the end position set to EndPoint in an arc path having the center point set in AuxPoint as its center.
  • Page 238 • Relative value circular interpolation control operation with center point designation In relative value circular interpolation control operation with center point designation, positioning is carried out from the current position at start (start point address) to the address of the movement amount set to EndPoint (end point address) in an arc path having the address of the movement amount set in AuxPoint (center point address) as its center.
  • Page 239 • Circular interpolation control with radius designation When selecting "2: mcRadius" in the CircMode input, two configuration axes specified in CircAxes are used to carry out positioning control in an arc path having the specified radius. [Circular interpolation path] The path in the absolute value circular interpolation control with radius designation can be set by the PathChoice input of the MCFB.
  • Page 240 • Relative value circular interpolation control operation with radius designation In relative value circular interpolation control operation with radius designation, positioning is carried out from the current position at start (start point address) to the address of the movement amount set to EndPoint (end point address) in an arc path having the radius set in AuxPoint.
  • Page 241 ■EndPoint (End point) Set the end point position of the absolute position or the movement amount from the current position at start to the end point by the EndPoint input. EndPoint has 16 array elements. EndPoint[0..N] indicates the end point of the configuration axis 1 to N. •...
  • Page 242 ■BufferMode (Buffer mode) Select the buffer mode. Aborting, Buffered, BlendingLow, BlendingPrevious, BlendingNext, and BlendingHigh can be set. For details, refer to the following. Page 107 Buffer mode type ■Options (Options) Set a function option with bit specification. Bit details and the function are as the following table. For details, refer to the following. Page 293 Acceleration/deceleration Processing Function Function description 0 to 2...
  • Page 243: Chapter 7 Direct Control

    DIRECT CONTROL Direct control includes velocity control and torque control. The operation details of each control is as shown below. Control Name Driver control mode Applicable instruction Operation details Velocity control Position control (csp) MCv_SpeedControl This function outputs the commanded position based on the set velocity for each control cycle.
  • Page 244: Velocity Control

    Velocity Control In velocity control, the driver control mode is switched to csv, and the control excluding the position loop is executed. Relevant variables/FB Variable/Structure name Name Details AxisName.Md. SetVelocity Set velocity A value set in TargetVelocity (set velocity during velocity control mode) TargetVelocity Target velocity A value set in target velocity (Velocity)
  • Page 245 ■Timing chart [When the FB is normally completed] Target Velocity 10000 5000 Execute InVelocity Busy Active CommandAborted Error ErrorID Velocity 10000 5000 MC_Stop: Execute AxisName.Md. 4: Standstill 6: ContinuousMotion 2: Stopping 4: Standstill AxisStatus Modes of operation AxisName.Md. 8: csp 9: csv 8: csp Driver_Mode...
  • Page 246 ■Input variables Import : At start, R: Retrigger possible, C: Continuous update possible Name Variable Data type Import Setting range Default Description name value  Execute Execute BOOL TRUE, FALSE FALSE When TRUE, it executes the FB. command  Continuous ContinuousUpd BOOL TRUE, FALSE...
  • Page 247 ■Output variables Name Variable name Data type Default Description value Target velocity reached InVelocity BOOL FALSE Indicates that the set velocity that is calculated by the motion system has reached the target velocity. After reaching, the speed is maintained until Execute turns FALSE or the control is interrupted.
  • Page 248: Control Details

    Control details MC_MoveVelocity switches the driver control mode to csv and executes control. This function controls the set velocity based on the specified acceleration, deceleration, and jerk. To finish this FB, start MC_Stop. Velocity initial value selection Set the "velocity initial value selection (options bit16, 17)" when switching the following control mode. •...
  • Page 249: Buffermode

    BufferMode When starting this FB during another instruction execution ■Single axis position control (FB1)  Velocity control (FB2) • 0: mcAborting Input variables are analyzed, and a switching request to csv is issued to the driver. Until the driver is switched, the axis is operated at the previous velocity with the velocity control including the position loop.
  • Page 250 • 1: mcBuffered Input variables are analyzed, and the axis waits until the previous instruction is completed. When the previous instruction is completed, a switching request to csv is issued to the driver. When the driver switches to csv, the acceleration/deceleration process is started based on the settings of FB2. FB1: Execute FB1: Busy FB1: Active...
  • Page 251 [For Aborting] FB1: Execute FB1: Busy FB1: Active FB1: CommandAborted FB1: InVelocity FB2: Execute FB2: Busy FB2: Active The current speed is maintained while waiting AxisName.Md.SetVelocity for switching. (The set velocity at switching of Velocity(FB1) FB2) =1000 Velocity(FB2) =750 AxisName.Md. 6: ContinuousMotion 5: DiscreteMotion AxisStatus...
  • Page 252 ■Velocity control  Stop instruction (MC_Stop) Target Velocity 10000 5000 Execute InVelocity Busy Active CommandAborted Error ErrorID Velocity 5000.0 10000.0 MC_Stop: Execute AxisName.Md. 4: Standstill 6: ContinuousMotion 4: Standstill AxisStatus Modes of operation AxisName.Md. 8: csp 9: csv 8: csp Driver_Mode 7 DIRECT CONTROL 7.1 Velocity Control...
  • Page 253 ■Velocity control  Torque control The torque control mode switching request is executed to the driver. Started torque control is analyzed, and the axis waits until the driver switches to the torque control. [For Aborting] FB1: Execute FB1: Busy FB1: Active FB1: CommandAborted FB1: InVelocity FB2: Execute...
  • Page 254: Precautions

    [For Buffered] FB1: Execute FB1: Active FB1: Busy FB1: InVelocity FB2: Execute FB2: Busy FB2: Active The current speed is maintained while waiting for switching. (The set velocity when InVelocity AxisName.Md.SetVelocity of the FB1 is TRUE) Velocity(FB1) =1000 LimitVelocity(FB2) =750 AxisName.Md.
  • Page 255: Torque Control

    Torque Control In torque control, the driver control mode is switched to cst and the control is carried out. Relevant variables/FB Variable/Structure name Name details AxisName.Md SetVelocity Set velocity Stores velocity specified value by adding acceleration/deceleration TargetVelocity Target velocity Stores value set to the limit velocity (LimitVelocity) ActualVelocity Actual velocity Actural velecity (same as positioning control)
  • Page 256 ■Timing chart [When the FB is normally completed] Target torque 100.0 50.0 Execute InTorque Busy Active CommandAborted Error ErrorID Torque 100.0 50.0 MC_Stop: Execute AxisName.Md. 4: Standstill 6: ContinuousMotion 2: Stopping 4: Standstill AxisStatus Modes of operation AxisName.Md. 8: csp 10: cst 8: csp Driver_Mode...
  • Page 257 Name Variable name Data type Import Setting range Default Description value  Continuous ContinuousUpdat BOOL TRUE, FALSE FALSE During TRUE, it can continuously change the Update target torque, the limit velocity, the torque positive direction ramp, the torque negative ramp, the acceleration and the deceleration.
  • Page 258 *1 For a bit and the function description, refer to the following table. Function description 0 to 2 Acceleration/deceleration method setting 0: mcAccDec (Acceleration/deceleration specification method) 1: mcFixedTime (Acceleration/deceleration time-fixed method) For details, refer to the following. Page 293 Acceleration/deceleration Processing Function 3 to 15 Empty (Reserved) 16, 17...
  • Page 259: Control Details

    Control details MC_TorqueControl switches the driver control mode to cst and executes control. This function controls the set torque based on the specified TorquePositiveRamp and TorqueNegaiveRamp. To finish this FB, start MC_Stop. Relation between torque generation direction of servomotor and set torque When using the MR-J5(W)-G, it differs based on the settings of the servo parameter "Movement direction selection (PA14)"...
  • Page 260 • For "1: Time constant method" Set the time that the set torque reaches from 0 until the positive/negative torque limit value. Setting range: 0 to 8400.0 [s] Torque 100.0 -50.0 Torque Torque PositiveRamp NegativeRamp Torque limit value =200.0 100.0 -50.0 Torque limit value =200.0...
  • Page 261 Torque initial value selection (Options bit18) Set the torque initial value when switching to the torque control mode. Setting value Description 0: Target torque Target torque (Torque) value at start is set as the set torque regardless of the value of torque positive direction ramp and torque negative direction ramp immediately after the control mode switching.
  • Page 262: Buffermode

    BufferMode When starting this FB during another instruction execution While this FB is executed, only Aborting and Buffered are supported. ■Position control(FB1)  Torque control(FB2) • 0: mcAborting A switching request to cst is issued to the driver. Until the driver is switched, the axis is operated at the previous velocity with the velocity control including the position loop.
  • Page 263 • 1: mcBuffered When the first instruction is completed, a cst change request is issued to the driver. When the driver mode turns to the cst, the acceleration/deceleration process of the torque and the velocity is started from the current actual torque and the set velocity. FB1: Execute FB1: Busy FB1: Active...
  • Page 264 ■Velocity control(FB1)  Torque control (FB2) • 0: mcAborting A cst change request is issued to the driver. While waiting for change, csv is continued. When the driver mode turns cst, the torque increase/decrease is started from the current actual torque, and the acceleration/deceleration process of the velocity from the set velocity is started.
  • Page 265 • 1: mcBuffered FB1: Execute FB1: Busy FB1: Active FB1: InVelocity FB2: Execute FB2: Busy FB2: Active FB2: InTorque AxisName.Md.SetVelocity LimitVelocity(FB2) =1000 The current speed is maintained while waiting for switching. (The set velocity when InVelocity Velocity(FB1) of the FB1 is TRUE) =750 Torque(FB2) =400.0...
  • Page 266 When starting another instruction during this FB execution ■Torque control  Stop instruction (MC_Stop) Velocity 10000.0 5000.0 Execute InTorque Busy Active CommandAborted Error ErrorID LimitVelocity 10000.0 5000.0 MC_Stop: Execute 4: Standstill AxisName.Md. 4: Standstill 6: ContinuousMotion AxisStatus Modes of operation AxisName.Md.
  • Page 267 • 0: mcAborting FB1: Execute FB1: Busy FB1: Active FB1: InTorque FB1: CommandAborted FB2: Execute FB2: Busy FB2: Active The current speed is maintained while waiting for switching. (The set velocity at switching of AxisName.Md.SetVelocity FB2) LimitVelocity(FB1) =1000 Since the velocity may not reach the limit velocity, the actual velocity is used as the set velocity immediately after the csp Velocity(FB2)
  • Page 268 • 1: mcBuffered FB1: Execute FB1: Busy FB1: Active FB1: InTorque FB2: Execute FB2: Busy FB2: Active The current speed is maintained while waiting for switching. (The set velocity when InTorque AxisName.Md.SetVelocity of the FB1 is TRUE) LimitVelocity(FB1) =1000 Since the velocity may not reach the limit velocity, the actual velocity is used as the set velocity immediately after the csp Velocity(FB2)
  • Page 269 ■Torque control (FB1)  Velocity control (FB2) A csv switching request is issued to the driver. Started positioning instruction is analyzed, and the axis waits until the driver switches to the csv. (Even if the axis issues the switching request to the csv during operation, switching may not be carried out depending on the driver specifications.
  • Page 270 • 1: mcBuffered FB1: Execute FB1: Busy FB1: Active FB1: InTorque FB2: Execute FB2: Busy FB2: Active FB2: InVelocity The current speed is maintained while waiting for switching. (The set velocity when AxisName.Md.SetVelocity InTorque of the FB1 is TRUE) LimitVelocity(FB1) =1000 Velocity(FB2) =750...
  • Page 271: Precautions

    Precautions • AxisName.Cd.VelocityOverride and AxisName.Cd.AccelerationOverride are valid. • The set position and the feed machine position are updated by follow up. • Time until the control mode is switched depends on the specifications of the driver. • When the stop cause occurs during the control mode switching, the axis will stop immediately. When using the MR-J5(W)-G When switching from the position control mode to the torque control mode or from the torque control mode to the position control mode without waiting for stop of the motor, note the followings.
  • Page 272: Chapter 8 Relevant Functions To Position

    RELEVANT FUNCTIONS to POSITION Current Position Change Function • This function executes control to change the set position to an arbitrary address. The current position change method includes a method of changing the set position at control execution (MC_SetPosition) and a method of changing to the set position corrected at the trigger input signal detection timing (MCv_SetPositionTriggered).
  • Page 273 ■Function description This FB changes the current position of the specified axis. • When Relative is TRUE, the current position is changed to the position obtained by the addition of the target position (relative distance) and the current position. • When Relative is FALSE, the current position is changed to the target position (absolute position). •...
  • Page 274 ■I/O variable Import : At start Name Variable Data type Input Setting range Default Description name import value   Page 568 Axis variables Axis information Axis AXIS_REF Omission not possible ■Input variables Import : At start Name Variable Data type Import Setting range Default...
  • Page 275 MCv_SetPositionTriggered Item Description Function overview Changes the current position of specified axis (set position, actual position) to the position compensated at the trigger input signal detection timing. Symbol [Structured Ladder] MCv_SetPositionTriggered DUT : Axis Axis : DUT DUT : TriggerInput TriggerInput : DUT B : Execute InTrigger : B...
  • Page 276 [When an error occurs] Execute Busy Done Error ErrorID Error code ■I/O variables Import : At start Name Variable name Data type Input Setting range Default Description import value  Axis information Axis AXIS_REF  Omission Page 568 Axis variables not possible ...
  • Page 277 ■Output variables Name Variable name Data type Default Description value Detecting signal InTrigger BOOL FALSE Indicates the detection status of the trigger input signal. The signal detection status is output as it is regardless of the correction time set in the trigger input signal.
  • Page 278: Position Setting Range

    Position setting range Values that can be specified in Position differs depending on whether Relative is FALSE or TRUE. Specify within each of the following range. Relative Position setting range Ring counter lower limit value  Setting value < Ring counter upper limit value FALSE -(Ring counter upper limit value - Ring counter lower limit value) / 2 ...
  • Page 279 Execution during axis operation ■Execute at completion When "1: mcQueued" is set in ExecutionMode, this FB is executed after the on-going FB is completed. Busy turns TURE by rising edge detection of Execute, and this FB waits until the axis status (AxisName.Md.AxisStatus) turns "4: Standstill".
  • Page 280: Trigger Current Position Change

    Trigger current position change After rising edge detection of Execute, the current position change operation starts at signal detection of TriggerInput. When the correction time of TriggerInput is a positive value, a current position change is immediately executed. When the correction time of TriggerInput is a negative value, this FB waits for operation to start until the correction time has elapsed, and a current position change is executed.
  • Page 281: Cancel

    Cancel Current position change that is in the standby status can be canceled after FB execution. • To enable cancel, execute the FB with the status of "Cancel accepted after FB start" (Options bit16) set to "TRUE: Allowed". • Cancel is started at rising edge detection of Execute. •...
  • Page 282 When canceling while the axis status is waiting for detecting a trigger signal after starting MCv_SetPositionTriggered MCv_SetPositionTriggered TriggerInput.Source (Leading edge detection setting) Position 100.0 Options bit16 Execute Busy CommandAborted CancelAccept The set position is not changed because of cancel 360.0 Set position 100.0 8 RELEVANT FUNCTIONS to POSITION...
  • Page 283: Command In-Position

    Command In-position The command in-position function checks the remaining distance to the target position, and turns the flag to TRUE. This flag is called the "command in-position flag". The command in-position flag is used as a front-loading signal indicating beforehand the completion of the control. The command in-position function is valid to all control that requires commanded address specification.
  • Page 284: Command In-Position Width Check

    Command in-position width check  (Remaining distance) (AxisName.Md.CmdInPos_Width) AxisName.Md.CmdInPos TRUE TRUE FALSE Speed 1000 AxisName.Md.CmdInPos_Width Time A command in-position width check is carried out every operation cycle. However, while the axis stops, AxisName.Md.CmdInPos is not refreshed. When AxisName.Md.CmdInPos_Width is 0.0, a command in-position width check is not carried out. For an axes group, the remaining distance on the composite axis (line/arc) is checked based on AxesGroupName.Md.CmdInPos_Width.
  • Page 285: Software Stroke Limit

    Software Stroke Limit In the "software stroke limit function", an address is set as the movable range. Even if a movement command to the address outside the setting range is issued, the command will not be executed. By not executing the command outside the movable area, even if an incorrect command or unexpected operation occurs, the system will not operate out of the movable area and damage to the machine can be prevented.
  • Page 286 The following drawing shows the differences in the operation when the set position is used or when the feed machine position is used in the movable range limit check. • Conditions Assume the current value is 2000, and AxisName.Pr.SwStrokeLimit_Upper is set to 5000. Movable range Set position 2000...
  • Page 287 ■When selecting the set position when the ring counter is valid • Set position The storing range of the set position upper/lower limit value is shown below. Monitor data Storing range Ring counter lower value  Set position < Ring counter upper value AxisName.Md.SetPosition When the ring counter lower limit value is "0.0"...
  • Page 288 [AxisName.Pr.SwStrokeLimit_Upper = AxisName.Pr.SwStrokeLimit_Lower] Ring counter upper limit Ring counter lower limit Movable range AxisName.Pr.SwStrokeLimit_Upper Positioning which exceeds the value AxisName.Pr.SwStrokeLimit_Lower set to AxisName.Pr.SwStrokeLimit_Upper and AxisName.Pr.SwStrokeLimit_Lower cannot be executed. ■When selecting the set position or the feed machine position when the ring counter is invalid •...
  • Page 289 ■Returning enable direction to the movable range • When setting ONLY_INSIDE in AxisName.Cd.SwStrokeLimit_Override, movement in the returning enable direction from outside the software stroke limit range to the movable range is allowed. • The returning enable direction from outside the software stroke limit range means the direction in which the axis can return to the movable range without exceeding the ring counter value.
  • Page 290: Specifications Of The Software Stroke Limit Check

    Specifications of the software stroke limit check The following table shows the check details of the software stroke limit. Check details Check timing Processing when an error occurs An error shall occur if the target address is outside When starting axis operation The error "Software Stroke Limit Over (Target Position)"...
  • Page 291: Hardware Stroke Limit

    Hardware Stroke Limit In the "hardware stroke limit function", limit switches are set at the upper/lower limit of the physical movable range, and the control is stopped by the input of a signal from the limit switch. Damage to the machine can be prevented by stopping the control before the upper/lower limit of the physical movable range is reached.
  • Page 292 Variable/Structure name Name Details HwStrokeLimit_RlsSignal Lower limit signal Sets a signal using the lower limit signal (RLS). HwStrokeLimit_RlsSignal is the structure of SIGNAL_SELECT type. For details of SIGNAL_SELECT type, refer to the following. Page 356 SIGNAL_SELECT structure The specific setting and the operation of this signal are shown below. •...
  • Page 293: Hardware Stroke Limit Check Details

    Hardware stroke limit check details The following table shows the check details of the hardware stroke limit. Check details Check timing Processing when an error occurs Signal input from the FLS signal is detected at At start The error "FLS Signal Detection (at Start)" (error code: 1A2DH) is start.
  • Page 294: Returning From Outside The Hardware Stroke Limit Range

    Returning from outside the hardware stroke limit range While the limit switch is detected, the operation cannot be performed regardless of the detection direction. After setting ONLY_INSIDE or DISABLE in AxisName.Cd.HwStrokeLimit_Override, execute the axis operation to return to the controllable range. •...
  • Page 295: Chapter 9 Relevant Functions To Velocity

    RELEVANT FUNCTIONS TO VELOCITY Acceleration/deceleration Processing Function The acceleration/deceleration processing function adjusts the acceleration/deceleration of each motion control to the acceleration/deceleration curve suitable for device. Acceleration/deceleration method The following methods can be selected for the acceleration/deceleration method. When a value outside the range is set in the acceleration/deceleration method, the error "Out of Acceleration/Deceleration Method Range"...
  • Page 296 ■Jerk acceleration/deceleration When a value other than "0.0" is set in the jerk, the curve is called the jerk acceleration/deceleration. The speed shows a S- shaped waveform. Speed Target speed (V) Time Acceleration Target acceleration (A) Time Target deceleration (Dec) Jerk Time Jerk...
  • Page 297: Relevant Variables

    Relevant variables Variable/Structure name Name Details AxisName.Pr. VelocityLimit_Positive Positive direction speed limit value Sets the positive direction speed limit value. For details, refer to the following. Page 318 Speed Limit VelocityLimit_Negative Negative direction speed limit value Sets the negative direction speed limit value. For details, refer to the following.
  • Page 298 Variable/Structure name Name Details CommandedAcceleration Commanded acceleration Stores the acceleration specified by users. Unit: U/s • When "1: mcFixedTime" is set in the acceleration/deceleration method, it stores the specified acceleration/deceleration time. Unit: s • During axes group operation, stores "0.0" in AxisName.Md.CommandedAcceleration of the configuration axis.
  • Page 299 Variable/Structure name Name Details SetAcceleration Set current acceleration • Stores the command output acceleration. It is the acceleration/ deceleration speed calculated from the difference of set velocity. Unit: U/s • It indicates accelerating or decelerating by a sign. 0.0: During stop or fixed-speed. "0.0" is stored when the target velocity is reached.
  • Page 300 Settings of motion FB The acceleration/deceleration method can be selected in the UD: Options input of the motion FB. Set the function options by specifying the bit. The details of bit and the functions are shown below. Function description 0 to 2 Acceleration/deceleration method setting 0: mcAccDec (Acceleration/deceleration specification method) 1: mcFixedTime (Acceleration/deceleration time-fixed method)
  • Page 301: Acceleration/Deceleration Method

    Acceleration/deceleration method Acceleration/deceleration specification method When "0: mcAccDec" is selected in the "acceleration/deceleration method setting" (Options bit 0 to 2) of the FB, the acceleration, the deceleration, and the jerk can be set. ■Trapezoidal acceleration/deceleration Speed Target speed (V) Time Section A Section B Section C...
  • Page 302 ■Jerk acceleration/deceleration Speed Target speed (V) Time Sec- Sec- Sec- Section Section Section D Section E tion A tion B tion C Time length of section A and Time length of section E and section C are the same. section G are the same. Acceleration Target acceleration (A) Time...
  • Page 303 • Acceleration/deceleration time parameter calculation Speed Speed Pattern at J = 0.0 Target speed (V) Target speed (V) Time Time Acceleration Acceleration Target acceleration (A) Time Target deceleration (Dec) Time Deceleration time (DT) Acceleration time (AT) Jerk Jerk Jerk (J) Jerk (J) Time Time...
  • Page 304 • Jerk calculation When the speed and the acceleration of operation are fixed, the jerk can be calculated with the following formula by specifying the jerk applying ratio. (2 - Jerk applying ratio) × (the square of acceleration (A)) Jerk (J) Jerk applying ratio ×...
  • Page 305 When the jerk applying ratio is big or the jerk is small, the acceleration time (deceleration time) becomes longer than that of the trapezoidal acceleration/deceleration. When the jerk applying ratio is 100%, the acceleration time (deceleration time) becomes doubled compared with the trapezoidal acceleration/deceleration. When setting the jerk, pay attention to the acceleration time (deceleration time).
  • Page 306 Acceleration/deceleration time-fixed method When "1: mcFixedTime" is selected in the "acceleration/deceleration method setting" (Options bit 0 to 2) of the FB, the acceleration/deceleration time can be set in Acceleration. Deceleration and jerk is not used. Calculates acceleration and deceleration from the acceleration/deceleration time at acceleration/deceleration. When a value smaller than one operation cycle other than 0.0000 is set as the acceleration/deceleration time, the target velocity is reached within one operation cycle.
  • Page 307 • Acceleration/deceleration time parameter calculation : Operation possible, : Operation impossible Section Item Abbr Description Calculation formula Operation eviat Accelera Decelera tion tion     Specified value Target velocity Acceleration/deceleration     time V  ADT ...
  • Page 308: Acceleration/Deceleration Waveform Adjustment When Specifying Jerk

    Acceleration/deceleration waveform adjustment when specifying jerk When the jerk acceleration/deceleration (J  0.0) is specified, the acceleration waveform and the deceleration waveform are adjusted whether the values of the target velocity (V), the target acceleration (A), the target deceleration (Dec), and the jerk (J) satisfy the following condition or not.
  • Page 309 When the condition is not satisfied When accelerating to the target acceleration, the velocity exceeds the target velocity during acceleration. Therefore, the acceleration is adjusted to reach the target velocity at the end of acceleration. (The velocity does not reach the specified target acceleration (deceleration).) When the acceleration is adjusted, there is no maximum acceleration section, and the acceleration waveform becomes a triangle.
  • Page 310: Operation When Specifying Acceleration/Deceleration 0

    Operation when specifying acceleration/deceleration 0 When "0.0" is specified for the acceleration/deceleration, the operation differs at startup and the rest. When "1: mcFixedTime" is selected in the "acceleration/deceleration method setting" (Options bit 0 to 2) of the FB, the operation is the operation when "0.0" is specified for the acceleration/deceleration time. The operation is the same as specifying "0.0"...
  • Page 311: Acceleration Limit Value/Deceleration Limit Value

    Acceleration limit value/deceleration limit value When "0: mcAccDec" is selected in the "acceleration/deceleration method setting" (Options bit 0 to 2) of the FB, the acceleration and the deceleration are limited by the acceleration limit value and the deceleration limit value. When "1: mcFixedTime"...
  • Page 312: Limit Of Acceleration Time/Deceleration Time

    Limit of acceleration time/deceleration time The acceleration time and the deceleration time are limited by 8400 [s]. When "0: mcAccDec" is selected in the "acceleration/deceleration method setting" (Options bit 0 to 2) of the FB, the acceleration time and the deceleration time calculated from the acceleration and the deceleration are limited. For a method of calculating the acceleration time and the deceleration time, refer to the following.
  • Page 313: Automatic Deceleration

    Automatic deceleration Decelerating to a speed of "0.0" to stop at the specified target position is called automatic deceleration. During automatic deceleration, AxisName.Md.AutoDeceleration is TRUE. When automatic deceleration is performed, the deceleration may go ahead or behind the target deceleration. Therefore, AxisName.Md.SetAcceleration may exceed AxisName.Md.TargetDeceleration.
  • Page 314: Changing Control Of Jerk Acceleration/Deceleration

    Changing control of jerk acceleration/deceleration Acceleration/deceleration operation at changing control immediately changes the acceleration and the deceleration for the trapezoidal acceleration/deceleration (J = 0.0). For the jerk acceleration/deceleration (J  0.0), when a control change is carried out during acceleration or deceleration, acceleration/deceleration will be performed taking over the previous acceleration (deceleration).
  • Page 315 ■For the acceleration/deceleration specification method Speed The speed continues to increase until reaching zero acceleration. Target speed (V) Target position before change (P) Time Target position (P') Current position (Pnow) Target speed after switching operation direction Accelerates to zero acceleration. Acceleration Decelerates to zero speed.
  • Page 316 ■Acceleration/deceleration specification method After reaching the acceleration 0 due to velocity change during acceleration, the target deceleration may not be reached when decelerating to the target velocity. Velocity Target velocity before change Accelerates to the target velocity after exceeding the target velocity. Target velocity (V') Time Acceleration...
  • Page 317 ■Acceleration change The acceleration change pattern can be classified based on the operation status when acceleration change is performed. [When executing acceleration change in the acceleration section 1.] Acceleration is increased or decreased to the target acceleration after change by using jerk, and taking over the speed and the acceleration immediately before the acceleration change.
  • Page 318 [When executing acceleration change in the acceleration section 2 or during fixed-speed, deceleration, and automatic deceleration] When acceleration change is executed in the acceleration section 2, the acceleration change is accepted, however acceleration operation during execution does not change. When re-acceleration is performed by velocity change etc, the axis accelerates with the acceleration after change.
  • Page 319: Multiple Start Of The Jerk Acceleration/Deceleration

    Multiple start of the jerk acceleration/deceleration This section describes the acceleration/deceleration operation specific to the jerk acceleration/deceleration. For the basic operation of the buffer mode, refer to the following. Page 107 Multiple Start (Buffer Mode) Term Description Switching point The point where FBs are switched On-going FB FB that is in execution on the axis and the axes group (FB whose Active is TRUE) Next FB...
  • Page 320: Speed Limit

    Speed Limit The "speed limit function" limits the set velocity to a value within the speed limit value setting range when the set velocity during control exceeds the speed limit value. By limiting the set velocity within the preset speed limit value setting range, even if an incorrect command or unexpected operation occurs, damage to the machine can be prevented.
  • Page 321: Operation When The Speed Limit Value Is Exceeded

    Operation when the speed limit value is exceeded The operation when specifying the speed exceeding the speed limit value differs depending on whether it is single axis control or interpolation control. For single axis operation • At start If the set velocity at start exceeds the speed limit value (AxisName.Pr.VelocityLimit_Positive for the positive direction and AxisName.Pr.VelocityLimit_Negative for the negative direction) of each axis, the error "Speed Limit Value Over"...
  • Page 322: Operation Setting When The Speed Limit Value Is Exceeded

    • At speed change Variable to be used Linear interpolation control Circular interpolation control Vector speed Long axis speed Reference axis speed specification specification specification AxisName.Pr.VelocityLimit_P Speed is not restricted. Long axis speed is restricted Reference axis speed is Speed is not restricted. ositive by speed limit value of long restricted by speed limit...
  • Page 323: Override Function

    Override Function • This function sets the factor for the target velocity and performs the control to change the velocity. • This function sets the factor for the acceleration/deceleration and performs the control to change the acceleration/ deceleration. (The ratio to the acceleration/deceleration time cannot be set.) •...
  • Page 324 MC_SetOverride Item Description Function overview Changes the target velocity and the acceleration/deceleration of the specified axis. Symbol [Structured Ladder] MC_SetOverride DUT : Axis Axis : DUT B : Enable Enabled : B E : VelFactor Busy : B E : AccFactor Error : B E : JerkFactor ErrorID : UW...
  • Page 325 [When an error occurs] Enable VelFactor Enabled Error ErrorID Error code ■I/O variable Import : At start Name Variable name Data type Input Setting range Default Description import value  Axis information Axis AXIS_REF  Omission Page 568 Axis variables not possible ■Input variables Import...
  • Page 326 MC_GroupSetOverride Item Description Function overview Changes the target velocity and the acceleration/deceleration of the specified axes group. Symbol [Structured Ladder] MC_GroupSetOverride DUT : AxesGroup AxesGroup : DUT B : Enable Enabled : B E : VelFactor Busy : B E : AccFactor Error : B E : JerkFactor ErrorID : UW...
  • Page 327 [When an error occurs] Enable VelFactor Enabled Error ErrorID Error code ■I/O variable Import : At start Name Variable name Data type Input Setting range Default Description import value   Page 574 Axes group variables Axes group AxesGroup AXES_GROUP_ Omission information not possible...
  • Page 328 Operation overview In MC_SetOverride and MC_GroupSetOverride, AxisName(AxesGroupName).Cd.VelocityOverride and AxisName(AxesGroupName).Cd.AccelerationOverride of the axis or the axes group can be changed. MC_SetOverride VelFactor -1.0 AccFactor Enable Enabled Busy Error ErrorID Error ID AxisName.Cd. VelocityOverride AcceleratoionOverride If a value outside the range is set as the override factor, an error will occur in the FB, and subsequent values will not be imported.
  • Page 329: How To Change Control Data

    How to change control data Override factor setting range The following shows each override factor setting range. Variable/Structure name Name Setting range AxisName.Cd. AxesGroupName.Cd. 0.00 (0%)  Setting value  10.00 (1000%) VelocityOverride Velocity override factor 0.01 (1%)  Setting value  10.00 (1000%) AccelerationOverride Acceleration override factor JerkOverride (Reserved)
  • Page 330 Operation when a value outside the override factor setting range is set If a value outside the setting range is set in each override factor, the warning "Out of Speed Override Coefficient Range Warning" (warning code: 0D0BH) and the warning "Out of Acceleration Override Coefficient Range Warning" (warning code: 0D0CH) will occur, and the override factor will remain unchanged from the previous value.
  • Page 331 AxisName.Cd. AccelerationOverride AxisName.Md. AccelerationOverride Axis warning Acceleration limit value exceeded 20000.0 20000.0 Target acceleration Target deceleration 20000.0 40000.0 Busy Error Axis speed When the acceleration is increased to 400%, Axis acceleration velocity change is not executed because the value 400% exceeds the acceleration limit value.
  • Page 332 ■When velocity/acceleration/deceleration limit value over occurs at switching of FB by buffer mode The control change of buffering FB is executed at swiching of FB. When the control is changed at switching of FB, velocity/acceleration/deceleration limit value over may occur. When velocity/ acceleration/deceleration limit value over occurs, velocity/acceleration/deceleration and override factor at multipul start are used to control.
  • Page 333: Chapter 10 Relevant Functions To Torque

    RELEVANT FUNCTIONS TO TORQUE 10.1 Torque limit The "torque limit function" limits the generated torque to a value within the torque limit value range when the torque generated in the servomotor exceeds the torque limit value. It controls the operation so that unnecessary force is not applied to the load and machine by limiting the generated torque. •...
  • Page 334: Slave Object Map

    Slave object map When using the torque limit function in the "setting of the torque limit value used in the driver", assign the torque limit object to the slave object setting. For details, refer to the following. Page 41 Axis Assignment •...
  • Page 335: Torque Limit Value Change Function

    10.2 Torque Limit Value Change Function • To change a torque limit value, there are a method of using the dedicated FB and a method of using control data. Change method Description Change using a dedicated FB MCv_SetTorqueLimit Change using control data AxisName.Cd.TorqueLimit_Positive, AxisName.Cd.TorqueLimit_Negative •...
  • Page 336 ■Function description • This FB changes a positive/negative direction torque limit value. • When PositiveValid is TRUE, a positive direction torque limit value is changed to PositiveValue. • When NegativeValid is TRUE, a negative direction torque limit value is changed to NegativeValue. •...
  • Page 337 ■Timing chart [When the FB is normally completed] PositiveValid PositiveValue 100.0 NegativeValid NegativeValue 200.0 Execute Busy Done AxisName.Cd. TorqueLimit_Positive 300.0 100.0 TorqueLimit_Negative 300.0 200.0 AxisName.Md. TorqueLimit_Positive 300.0 100.0 TorqueLimit_Negative 300.0 200.0 [When an error occurs] Execute Busy Done Error ErrorID Error code 10 RELEVANT FUNCTIONS TO TORQUE 10.2 Torque Limit Value Change Function...
  • Page 338 ■I/O variable Import : At start Name Variable Data type Input Setting range Default Description name import value   Page 568 Axis variables Axis information Axis AXIS_REF Omission not possible ■Input variables Import : At start, R: Retrigger possible Name Variable Data type...
  • Page 339 ■Operation overview In MCv_SetTorqueLimit, AxisName.Cd.TorqueLimit_Positive and AxisName.Cd.TorqueLimit_Negative are changed. MCv_SetTorqueLimit PositiveValid PositiveValue 100% NegativeValid NegativeValue 500% ExecutionMode 0: mcImmediately Execute Busy Done AxisName.Cd. TorqueLimit_Positive 300% 100% TorqueLimit_Negative 300% 500% If a value outside the range is set in PositiveValue or NegativeValue and Execute is turned to TRUE, an error will occur in the FB, and AxisName.Cd.TorqueLimit_Positive and AxisName.Cd.TorqueLimit_Negative will not be changed.
  • Page 340 ■Details of ExecutionMode When the torque limit value change FB is executed during axis operation, the change timing differs depending on the ExecutionMode setting value of the input variable. • Immediate execution "0: mcImmediately" The change is immediately executed regardless of the axis status (AxisName.Md.AxisStatus). AxisName.Cd.TorqueLimit_Positive and AxisName.Cd.TorqueLimit_Negative are changed at rising edge of Execute.
  • Page 341 ■Cancel Torque limit value change that is in the standby status after FB execution can be canceled. • To enable cancel, execute the FB with the status of "Cancel accepted after FB start" (Options bit16) set to "TRUE: Allowed". • Cancel is started at falling edge detection of Execute. •...
  • Page 342: How To Change Control Data

    How to change control data Positive/Negative direction torque limit value setting range The setting range of AxisName.Cd.TorqueLimit_Positive and AxisName.Cd.TorqueLimit_Negative is as the following table. Control data Setting range 0.0 (0%)  Setting value  AxisName.PrConst.TorqueLimit_Max AxisName.Cd.TorqueLimit_Positive AxisName.Cd.TorqueLimit_Negative Torque limit value change timing A torque limit value can be changed by changing AxisName.Cd.TorqueLimit_Positive and AxisName.Cd.TorqueLimit_Negative.
  • Page 343: Chapter 11 Control Sub Functions

    CONTROL SUB FUNCTIONS 11.1 Compensation Function Compensation function includes the driver unit conversion function, which can be executed by the parameter settings. Relevant variables Variable/Structure name Name Details AxisName.Pr. Drive_UnitConvRatioNum Driver unit conversion numerator Sets the numerator to convert from the command unit of the motion system to the command unit of the driver.
  • Page 344 Control details Set AxisName.Pr.Drive_UnitConvRatioNum and AxisName.Pr.Drive_UnitConvRatioDen in order to output the command value to the driver according to the specified movement amount. The setting examples are shown below. ■For a ball screw When the ball screw pitch is 20 [mm], the controller command unit is [mm], the driver command unit is [pulse], and the motor encoder resolution is 4194304 pulse/rev Set the number of pulses required to rotate a motor once (the encoder resolution) in AxisName.Pr.Drive_UnitConvRatioNum, and set the transfer distance of the machine per motor rotation in AxisName.Pr.Drive_UnitConvRatioDen.
  • Page 345 Precautions • Values less than one which could not be output during machine movement are managed in the motion system, and the cumulated values will be output when the value reaches one pulse or more. • When machine homing is completed, the function clears to "0" the cumulative values of less than one pulse which could not be output.
  • Page 346: Command Filter

    11.2 Command Filter Command filter can perform specified filter processing to inputs of the master axis, and output the result to the slave axis. For example, when setting a virtual drive axis to the master axis and a real drive axis to the slave axis, the result of filter processing to input of the virtual drive axis can be output to the real drive axis.
  • Page 347 ■Timing chart [When the FB is normally completed] Enable Valid Busy Active CommandAborted Error ErrorID AxisName.Md. 4: Standstill 7: SynchronizedMotion AxisStatus *1 Indicates the axis status of the slave axis. [When an error occurs] Enable Valid Busy Active CommandAborted Error ErrorID Error code ■I/O variables...
  • Page 348 ■Input variables : Always, : At start, R: Retrigger possible Import Name Variable name Data type Import Setting range Default Description value Enable Enable BOOL TRUE, FALSE FALSE When TRUE, it executes the FB. Filter disable FilterDisable BOOL TRUE, FALSE FALSE Disables the filter during TRUE, and the master axis input is transmitted to the slave axis as it is.
  • Page 349: Smoothing Filter

    Smoothing filter • Smoothing filter removes frequencies higher than the set Frequency, and the entire waveform higher than the setting value becomes a smooth acceleration/deceleration waveform. • Smoothing filter outputs the result of filter processing that executed to the Master value set in MasterValueSource to Slave. •...
  • Page 350 ■Frequency (Frequency) • The following shows the range that can be set in Frequency. 1/Slave axis operation cycle [s] Setting range 250.00 [Hz] or more 0.20 to 250.00 [Hz] Less than 250.00 [Hz] 0.20 to (1/Slave axis operation cycle [s]) [Hz] •...
  • Page 351: Precaution

    FilterPurge Operation overview FALSE When Enable turns FALSE, the slave axis immediately stops regardless of the FilterPool status. Enable Valid Busy Active Speed of Master Speed of Slave FilterPool ■ValidFrequency (Valid frequency) • It indicates frequencies which are valid in filter processing. ■FilterPool (Filter cumulated value) •...
  • Page 352: Input Variable Change In Execution

    11.3 Input Variable Change in Execution • In the control whose start condition is Execute, data such as Position and Velocity can be re-imported without interrupting the operation by Execute retrigger. • When ContinuousUpdate is TRUE at start, data such as Position and Velocity are imported at each execution cycle during operation.
  • Page 353: Target Position/Movement Distance Change

    Target position/movement distance change This function changes the target position and the movement distance. Target position change The target position is changed. Position change Target position at start Target position after change AxisName.Md. CommandedPosition AxisName.Md. SetVelocity Target position at start Target position after change When Direction can be set, the operation when changing the target position differs depending on the setting value.
  • Page 354 The deceleration distance is not kept by the target position/movement distance change The control is performed according to the selection when having AxisName(AxesGroupName).Pr.OverrunOperation and reverse rotation permission selection (Options bit5). ■When the reverse rotation is allowed When "0: Allow" is set to the reverse rotation permission selection (Options bit5), a deceleration stop is performed once regardless of the AxisName.Pr.OverrunOperation setting.
  • Page 355 When an operation is reversed by changing the target position/movement distance When an operation is reversed by changing the target position/movement distance, the axis is controlled according to the selection when having reverse rotation permission selection (Options bit5). ■When the reverse rotation is allowed When "0: Allow"...
  • Page 356: Set Velocity Change

    Set velocity change The set velocity is changed according to the acceleration/deceleration. Velocity change Speed at start Speed after change AxisName.Md. TargetVelocity Speed at start AxisName.Md. Speed after change SetVelocity Set velocity sign inversion during speed control The negative speed can be set in the speed control. When the sign of set velocity is reversed, the reverse operation will start after a deceleration stop.
  • Page 357: Acceleration/Deceleration And Acceleration/Deceleration Time Change

    Operation during interpolation control When the set velocity is changed during the interpolation control, the set velocity is changed according to the acceleration/ deceleration method or the acceleration. Each axis speed is changed according to the velocity mode. When the vector speed is set in the velocity mode Axis 2 Velocity change Axis 1...
  • Page 358: Chapter 12 Common Functions

    COMMON FUNCTIONS 12.1 External Signal Selection This section describes a setting method of I/O signals which are used in each control. The following indicates the functions that use external signal selection. Page 159 Forced Stop Page 289 Hardware Stroke Limit Relevant variables I/O signals are expressed by the TARGET_REF structure.
  • Page 359 Signal Logic • Specify the signal logic with the MC_SIGNAL_LOGIC enumeration type. For details, refer to the following. Page 586 ENUM enumerator ■Bit input signals Setting Operation 0: HighLevel When the corresponding signal is in the TRUE status, it operates as a signal input status. Input signal 1: LowLevel When the corresponding signal is in the FALSE status, it operates as a signal input status.
  • Page 360: Target_Ref Structure

    TARGET_REF structure This section describes the TARGET_REF structure. Variable/Structure name Name TARGET_REF Input signal IO No. Target Target Specify a signal which is used in the control in Target of the TARGET_REF structure with the following character string format. [Classification](Type)Data name.Bit position@Target modification [Classification](Type)WSTRING type label^ Up to 643 characters can be stored in Target.
  • Page 361 ■MC_SOURCE MC_SOURCE enumeration type enumerators are shown below. Check the specifications of the function to be used for the enumerators that can be specified. Classification Target Modification @Position 1: mcSetValue (Set value) Set value of previous operation cycle Available 2: mcActualValue (Actual value) Actual value of previous operation cycle 101: mcLatestSetValue (Latest set value) Set value of latest operation cycle...
  • Page 362 Common rule • Capital letters and lower case letters are not distinguished. • The space is ignored. 12 COMMON FUNCTIONS 12.1 External Signal Selection...
  • Page 363: 12.2 Touch Probe

    12.2 Touch Probe This function records (latches) arbitrary data at trigger input signal detection. Operation of this function at each status of system : Possible, : Not possible Status Operation availability  STOP   Moderate error  Major error Relevant FBs MC_TouchProbe Item...
  • Page 364 ■Input variables Import : At start, R: Retrigger possible, C: Continuous update possible Name Variable name Data type Import Setting range Default Description value   Execute Execute BOOL FALSE When TRUE, it executes the FB. command   Continuous ContinuousUpdat BOOL FALSE...
  • Page 365 MC_AbortTrigger Item Description Function overview  Symbol [Structured Ladder] MC_AbortTrigger DUT : Axis Axis : DUT DUT : TriggerInput TriggerInput : DUT B : Execute Done : B UW : TouchProbeID Busy : B Error : B ErrorID : UW Applicable hardware and RD78G(H) (Structured Text) software (Language)
  • Page 366: External Latch Valid

    External latch valid This is a function that arbitrary data is recorded (latch) at the timing of detecting the trigger input signal. It is possible to latch only the data within the range by setting the data range to latch. When this function is used, execute MC_TouchProbe.
  • Page 367 For RecordMode = "1: RecordCount" Number of latches: 2 Trigger Input signal Execute Busy Done RecordedCounter RecordedPosition Detection value Detection value CommandAborted FALSE Probe data LastPosition PositionData FirstPosition Latch is not executed more than the specified number. For RecordMode = "2: RingBuffer" Number of latches: 2 Trigger Input signal Execute...
  • Page 368 Details of setting items ■TriggerInput (trigger input signal) Trigger input signal is specified in MC_TRRIGER_REF structure. Setting range of TriggerInput.Signal is shown below. Item Setting range TriggerInput.Signal Source Type BOOL Data type [VAR] [DEV] [ADDR] [CONST] [OBJ] (mapped to cyclic data) Detection 2: RisingEdge 3: FallingEdge...
  • Page 369 LastPosition, FirstPosition relation Touch probe processing LastPosition = FirstPosition The range of the probe data is not checked. The all range is disabled, and the touch probe processing is not executed. ■ProbeData (Probe data) Specify the data to latch by the TARGET_REF structure. The data types of [VAR], [AXIS], [DEV], [ADDR], and [OBJ] (mapped in the cyclic data) can be used.
  • Page 370 ■OutputBuffer (Storage location of latch data) The storage location of latched data can be specified in TARGET_REF structure. Applicable data types are [VAR] and [DEV]. The storage location of the latch data by RecordMode is shown as follows. RecordMode storage location 0: OneShot The area specified by OutputBuffer 1: RecordCount...
  • Page 371: External Latch Invalid

    External latch invalid Touch probe is invalidated. MC_TouchProbe which is specified in TouchProbeID is invalidated.. When MC_AbortTrigger is executed, if the specified MC_TouchProbe specified TouchProbeID is not running, the FB will immediately become Done = TRUE. Axis and TriggerInput can be omitted, because those are ignored. For RecordMode = "2: RingBuffer"...
  • Page 372: Slave Emulate

    12.3 Slave Emulate Slave emulate function controls axes on the real axis without connecting to the slave station. When using emulate function, even if the slave station is not connected, the axis can be operated virtually (regarded as it is connected).
  • Page 373: Part 3 Motion Control2

    PART 3 MOTION CONTROL2 13 OPERATION PROFILE FUNCTION 14 SYNCHRONOUS CONTROL...
  • Page 374: Chapter 13 Operation Profile Function

    OPERATION PROFILE FUNCTION 13.1 Operation Profile Data Waveform data used for control is collectively called operation profile data. This section describes creating and using methods of operation profile data. Operation profile data not only can be used in various functions (ex. cam of the single axis synchronous control), but also can perform opening profile for the cam and reading/writing for the cam.
  • Page 375: Relevant Variables/Fb

    Relevant variables/FB Variable/Structure name Name Details AXIS.Md. ProfileID Execution profile ID No. Stores the profile ID in execution. PROFILE_DATA Location Calculation profile data storage _FILE_LOCATION type location Profile ID _PROFILE_ID type FILE_LOCATION FileName File name Specifies a file name (including the extension). Path Folder specification Specifies the folder path in which the file is stored.
  • Page 376 [When an error occurs] Execute Busy Done Error Error code ErrorID ■I/O variables Input import : At start Name Variable name Data type Input Setting range Default Description import value   Master axis Master AXIS_REF Omission Specifies the reference of the master axis. not possible ...
  • Page 377 Even if specifying Master and Slave, axis information is not given to the cam data, and these are not used for the control. 13 OPERATION PROFILE FUNCTION 13.1 Operation Profile Data...
  • Page 378 MCv_ProfileSelect Item Description  Function overview Symbol [Structured Ladder] MCv_ProfileSelect DUT : ProfileData ProfileData : DUT B : Execute Done : B B : Periodic Busy : B B : MasterAbsolute Error : B B : SlaveAbsolute ErrorID: UW EM : ExecutionMode ProfileID : DUT Applicable hardware and RD78G(H) (Structured Text)
  • Page 379 ■I/O variables Input import : At start Name Variable name Data type Input Setting range Default Description import value   Profile data ProfileData PROFILE_DATA Omission Specifies the operation profile data. not possible ■Input variables Import : At start Name Variable name Data type Import...
  • Page 380 MCv_ProfileCalc Item Description  Function overview Symbol [Structured Ladder] MCv_ProfileCalc DUT : Inputs Inputs : DUT DUT : Output Output : DUT B : Enable InOperation : B L : InputsOffset Busy : B L : OutputOffset Error : B L : InputsScaling ErrorID : UW L : OutputScaling...
  • Page 381 ■I/O variables Name Variable name Data type Input Setting range Default Description import value Input data Inputs TARGET_REF[1.  Omission Specifies the reference of the input value. not possible  Output data Output TARGET_REF Omission Specifies the reference of the output value. not possible ■Input variables Import...
  • Page 382 MCv_ReadProfileData Item Description Function overview Reads the specified operation profile data from the open area or the file. Symbol [Structured Ladder] MCv_ReadProfileData DUT : ProfileData ProfileData : DUT DUT : Data1 Data1 : DUT DUT : Data2 Data2 : DUT B : Execute Done : B UD : Offset...
  • Page 383 ■I/O variables Input import : At start Name Variable name Data type Input Setting range Default Description import value   Profile data ProfileData PROFILE_DATA Omission Specifies the operation profile data to read. not possible   Read data 1 Data1 TARGET_REF Omission...
  • Page 384 MCv_WriteProfileData Item Description Function overview Writes the specified operation profile data from the open area or the file. Symbol [Structured Ladder] MCv_WriteProfileData DUT : ProfileData ProfileData : DUT DUT : Data1 Data1 : DUT DUT : Data2 Data2 : DUT B : Execute Done : B Busy : B...
  • Page 385 ■I/O variables Input import : At start Name Variable name Data type Input Setting range Default Description import value   Profile data ProfileData PROFILE_DATA Omission Specifies the operation profile data to write. not possible   Write data 1 Data1 TARGET_REF Omission...
  • Page 386 MCv_ChangeCycle Item Description Function overview Changes the current value per cycle of the specified operation profile data control FB. Symbol [Structured Ladder] MCv_ChangeCycle B : Execute Done : B DUT : InstanceID Busy : B L : Cycle CommandAborted : B B : Relative Error : B EM : ExecutionMode...