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. For the safety precautions of the programmable controller system, refer to the MELSEC iQ-R Module Configuration Manual.
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 ● Especially, when a remote programmable controller is controlled by an external device, immediate action cannot be taken if a problem occurs in the programmable controller due to a communication failure. To prevent this, configure an interlock circuit in the program, and determine corrective actions to be taken between the external device and CPU module in case of a communication failure.
Page 6
[Installation Precautions] WARNING ● Shut off the external power supply (all phases) used in the system before mounting or removing the module. Failure to do so may result in electric shock or cause the module to fail or malfunction. [Installation Precautions] CAUTION ●...
Page 7
[Wiring Precautions] CAUTION ● Individually ground the FG and LG terminals of the programmable controller with a ground resistance of 100 ohms or less. Failure to do so may result in electric shock or malfunction. ● Use applicable solderless terminals and tighten them within the specified torque range. If any spade solderless terminal is used, it may be disconnected when the terminal screw comes loose, resulting in failure.
Page 8
[Startup and Maintenance Precautions] WARNING ● Do not touch any terminal while power is on. Doing so will cause electric shock or malfunction. ● Correctly connect the battery connector. Do not charge, disassemble, heat, short-circuit, solder, or throw the battery into the fire. Also, do not expose it to liquid or strong shock. Doing so will cause the battery to produce heat, explode, ignite, or leak, resulting in injury and fire.
Page 9
[Startup and Maintenance Precautions] CAUTION ● Startup and maintenance of a control panel must be performed by qualified maintenance personnel with knowledge of protection against electric shock. Lock the control panel so that only qualified maintenance personnel can operate it. ●...
Mitsubishi representative in your region. INTRODUCTION Thank you for purchasing the Mitsubishi Electric MELSEC iQ-R series programmable controllers. This manual describes the functions, parameter settings, and troubleshooting 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.
FUNCTIONS This chapter describes the functions for the high-speed counter module and the setting methods. For details on I/O signals and buffer memory areas, refer to the following. • Page 55 Input signals • Page 57 Output signals • Page 62 Details of buffer memory addresses This chapter describes the I/O numbers (X/Y), buffer memory addresses, and external I/O terminals for CH1.
Page 16
Pulse input mode Count timing Counts on the rising edge () of A while B is off. 2-phase multiple of 1 For counting up φA φB Counts on the falling edge () of A while B is off. For counting down φA φB Counts on the rising edge () of A while B is off.
Page 17
■1-phase pulse input The count method can be selected from 1 multiple and 2 multiples. The following figure shows the relationship between the A phase pulse input and B phase pulse input or CH1 Down count command (Y3). High-speed counter module Pulse input φA Encoder...
Setting a counting method Set a counting method in "Basic setting" For details on the setting method, refer to the following. Page 39 Basic Setting Reading the present value This section describes the details on the present value stored in the buffer memory and the count values selected from the counter function selection, and their reading method.
Selecting a Counter Type Select a counter type in "Counter type" of "Basic setting". Setting method Set "Counter operation mode" to "Pulse count mode". Set "Counter type" to "Linear counter" or "Ring counter". Navigation window [Parameter] [Module Information] Module model name [Module Parameter] [Basic setting] Item Description...
Ring counter function Operation of the ring counter This function repeatedly counts pulses between the values stored in CH1 Ring counter lower limit value setting (Un\G20 to Un\G21) and CH1 Ring counter upper limit value setting (Un\G22 to Un\G23). When the ring counter function is selected, an overflow error does not occur.
Page 21
■When the count range is Present value < Ring counter lower limit value or Ring counter upper limit value < Present value • When pulses are counted up, even when the present value reaches the ring counter lower limit value, the ring counter lower limit value is held as the lower limit, and the value of Ring counter upper limit value + 1 is stored in CH1 Present value (Un\G2 to Un\G3) at the next count-up pulse input.
Coincidence Output Function This function compares the present count value with the preset count value, and outputs a signal when they match. Setting method Set "Counter operation mode" to "Pulse count mode". Set a count value for "Coincidence output point No.1 setting" or "Coincidence output point No.2 setting". Navigation window ...
Page 23
Description When CH1 Present value (Un\G2 to Un\G3) equals to CH1 Coincidence output point No.1 setting (Un\G4 to Un\G5), CH1 Counter value coincident (point No.1) (X2) and the coincidence output point No.1 terminal (EQU1) turn on. Also, CH1 Counter value smaller (point No.1) (X3) turns off. When CH1 Coincidence signal No.1 reset command (Y0) is turned on while the values match, CH1 Counter value coincident (point No.1) (X2) and the coincidence output point No.1 terminal (EQU1) turn off.
Page 24
Precautions for using the coincidence output function When CH1 Coincidence signal enable command (Y2) is turned on before the count is started or while the coincidence output point setting value and the current value match, the coincidence output is performed. To avoid this status, perform one of the following operations before turning on CH1 Coincidence signal enable command (Y2).
Coincidence detection interrupt function This function outputs an interrupt request to the CPU module and starts an interrupt program when the present counter value matches with the preset coincidence output point setting value. For details on the interrupt program, refer to the following. ...
Preset Function This function overwrites the present counter value with the set numerical value. The set value is referred to as a preset value. This function can be used to start counting pulses from the preset value. The function can be performed using a program or an external control signal.
Page 27
Performing the preset function using an external control signal Perform the preset function by applying an ON voltage to the preset input terminal for external input. CH1 Count enable command (Y4) Counter input pulse CH1 Preset value (Un\G0 to Un\G1) Preset command (preset input terminal) CH1 External preset...
Counter Function Selection The count disable function, latch counter function, sampling counter function, or cycle pulse counter function can be used by selecting each item in the counter function selection setting of the "Counter function selection setting". The selected counter function is performed by the counter function selection start command (when CH1 Counter function selection start command (Y6) is turned on using a program or a voltage is applied to the function start input terminal).
Count error A count error may occur when the selected counter function is performed using an external input (A voltage is applied to the function start input terminal) or using a program (CH1 Counter function selection start command (Y6) is turned on). The following describes how to calculate the count error.
Count disable function This function stops counting pulses while CH1 Count enable command (Y4) is on. The following figure shows the relationship among CH1 Count enable command (Y4), Counter function selection start command, and the present counter value. CH1 Count enable command (Y4) CH1 Counter function selection start command (Y6)
Latch counter function This function latches the present counter value when Counter function selection start command is input. The following figure shows the relationship among the present counter value, Counter function selection start command, and CH1 Latch count value (Un\G12 to Un\G13). The latch counter function can be performed regardless of the on/off status of CH1 Count enable command (Y4).
Sampling counter function This function counts pulses input during the specified sampling time (T) and stores the count value in the buffer memory. The following figure shows the relationship among the signals and buffer memory areas used by the sampling counter function. CH1 Count enable command (Y4) CH1 Present value...
Cycle pulse counter function This function stores the current value, previous value, and difference value of the counter in the buffer memory at every specified cycle time (T). The following figure shows the relationship among the signals and buffer memory areas used by the cycle pulse counter function.
Page 34
CH1 Count enable command (Y4) CH1 Present value (Un\G2 to Un\G3) CH1 Counter function selection start command (Y6) Counter function selection start command (function start input) CH1 Cycle pulse count current value (Un\G18 to Un\G19) CH1 Cycle pulse count previous value (Un\G16 to Un\G17) CH1 Cycle pulse count difference value (Un\G24 to Un\G27)
Page 35
Description The present counter value, 0 is stored in CH1 Cycle pulse count current value (Un\G18 to Un\G19). The difference value with the previous value, 0 is stored in CH1 Cycle pulse count difference value (Un\G24 to Un\G27). The present counter value, 200 is stored in CH1 Cycle pulse count current value (Un\G18 to Un\G19). The value 0, which has been stored in CH1 Cycle pulse count current value (Un\G18 to Un\G19), is stored in CH1 Cycle pulse count previous value (Un\G16 to Un\G17).
Pulse Measurement Function This mode measures the following times of the pulse input in the function start input terminal. • ON width • OFF width • From the rising edge of the pulse to the rising edge of the next pulse •...
Page 37
Measurable range of the pulses The measured values of the pulses are stored in CH1 Measured pulse value (Un\G516 to Un\G517). The measurable range of the pulses is between 2000 and 2147483647 (0.2ms to approx.214s). ■Overflow error • When the input pulses are beyond the measurable range, an overflow error will be detected. •...
PWM Output Function This function outputs the PWM waveform of up to 200kHz, 100ns as the minimum ON width (0.1s) from the PWM output point No.1 terminal (EQU1) and PWM output point No.2 terminal (EQU2). Buffer memory High-speed counter module CH1 PWM output cycle time setting Pulse output (Un\G256 to Un\G257)
Page 39
Setting method of the output waveform Set the output waveform as follows. The setting values shown below can be changed during the output. CH1 PWM output ON time setting 1 (Un\G258 to Un\G259) Coincidence output point No.1 CH1 PWM output cycle time setting (Un\G256 to Un\G257) CH1 PWM output ON time setting 2 (Un\G260 to Un\G261)
Page 40
Operation example of the PWM output function The following figure shows an operation example of the PWM output function. CH1 PWM output start command (PWM output) (Y6) CH1 PWM output cycle time 1200 1000 setting (Un\G256 to Un\G257) CH1 PWM output ON time setting 1 (Un\G258 to Un\G259) PWM output PWM output OFF...
PARAMETER SETTINGS This chapter describes the parameter settings of the high-speed counter module. Setting parameters here eliminates the need to program them. Parameter Setting Procedure Add the high-speed counter module to an engineering tool. Navigation window [Parameter] [Module Information] Right-click [Add New Module] The basic setting, application setting, interrupt setting, and refresh settings are included in the parameter setting.
Page 42
Item Setting range Reference Counter operation mode • 0: Pulse count mode (default value) • 1: Pulse measurement mode • 2: PWM output mode Preset value setting -2147483648 to 2147483647 (default value: 0) Page 62 CH1 Preset value setting Coincidence output point No.1 -2147483648 to 2147483647 (default value: 0) Page 62 CH1 Coincidence output point No.1...
Application Setting Set the parameters for the various functions of the high-speed counter module. Item Setting range Reference Counter function selection setting • 0: Count disable function (default value) Page 63 CH1 Counter function selection setting • 1: Latch counter function •...
Interrupt Setting Set the interrupt function of the high-speed counter module. Item Setting range Reference Interrupt pointer I0 to I15, I50 to I1023 Page 23 Coincidence detection interrupt function *1 For details on the interrupt pointers that can be used, refer to the following. ...
Refresh Setting Set the transfer destination of the settings in the buffer memory of the high-speed counter module such as module labels and devices of the CPU module. By configuring the refresh setting, the reading from the program is not required. Select one of the following transfer destinations in "Target".
Page 46
Setting item The following items are provided in the refresh settings. Item Reference Refresh at the set timing Transfer to the CPU Present value Page 62 CH1 Present value Sampling/cycle counter flag Page 64 CH1 Sampling/cycle counter flag Counter function update flag Page 66 CH1 Counter function update flag Latch count value Page 64 CH1 Latch count value...
Refresh processing time A refresh processing time [s] is a constituent of the scan time of the CPU module. For details on the scan time, refer to the following. MELSEC iQ-R CPU Module User's Manual (Application) The refresh processing time [s], which is taken for refresh, is given by: •...
Preset Setting Execute the preset from "Module Tool List" of the engineering tool. Setting method Select "iQ-R Series" from "Module Series Selection", and set "Preset". Select the high-speed counter module to execute the preset in the "Module Selection (Preset)" window. Execute the preset.
TROUBLESHOOTING This chapter describes errors that may occur while using the high-speed counter module, and those troubleshooting. Throughout the chapter, the I/O numbers (X/Y) and buffer memory addresses are described on the basis of the case of CH1. To check them of CH2, refer to the following: Page 54 List of I/O signals Page 60 List of buffer memory addresses Procedure for Troubleshooting...
Troubleshooting by Symptom When the count operation does not start Check item Action Check whether the CPU module indicates any error. If the CPU module indicates an error, refer to the troubleshooting in the following manual. MELSEC iQ-R CPU Module User's Manual (Application) Apply a voltage directly to the pulse input terminals of A and B, and check If the LEDs turn on, check the external wiring and wiring on the encoder side that each LED of A and B turns on.
When the coincidence output function does not operate normally Check item Action Check whether CH1 Coincidence signal No.1 reset command (Y0) and CH1 Turn off CH1 Coincidence signal No.1 reset command (Y0) and CH1 Coincidence signal No.2 reset command (Y7) turn on. Coincidence signal No.2 reset command (Y7).
When the pulses are not measured correctly Check item Action Check whether the shielded twisted pair cables are used for pulse input Use the shielded twisted pair cables for pulse input wiring. wiring. Check whether any noise comes from the grounded part of the high-speed Separate the grounding cable of the high-speed counter module from the counter module.
(/several W) between the pulse input terminals connected to a pulse generator. The greater the load current, the more effective this method is. The following figure shows an example of the connection of a dummy resistor at signal level 24VDC: • Connecting a dummy resister at 24VDC RD62P2, RD62P2E 6.8kΩ Shielded twisted pair cable 1/3W...
APPENDICES Appendix 1 Module Label The functions of the high-speed counter module can be set by using module labels. Module labels of I/O signals The module label name of an I/O signal is defined with the following structure: "Module name"_"Module number"."I/O signal"["(Channel)"].b"Label name" or "Module name"_"Module number"."I/O signal"["(Channel)"].b"Label name"_D RD62_1.stnInputSignal[0].bCoincidenceOutputPoint1CounterValueLarge_D ■Module name...
Page 55
Module labels of buffer memory areas The module label name of a buffer memory area is defined with the following structure: "Module name"_"Module number"."Data type"["(Channel)"]."Data format""Label name" or "Module name"_"Module number"."Data type"_D["(Channel)"]."Data format""Label name"_D RD62_1.stnBufferBlock0_D[0].dPresetValueSetting_D ■Module name The character string of a module model name is given. ■Module number A number starting from 1 is added to identify modules that have the same module name.
Appendix 2 I/O Signals List of I/O signals The following table lists the I/O signals of the high-speed counter module. For details on the I/O signals, refer to the following. Page 55 Input signals Page 57 Output signals • The I/O numbers (X/Y) in this section apply when the start I/O number of the high-speed counter module is set to 0.
Input signals This section describes the details on the input signals from the high-speed counter module to the CPU module. The I/O numbers (X/Y) in this section apply when the start I/O number of the high-speed counter module is set to 0. This section describes the I/O numbers (X/Y), buffer memory addresses, and external I/O terminals for CH1.
Page 58
CH1 Counter value smaller (point No.1) • This signal turns on when the value in CH1 Present value (Un\G2 to Un\G3) is smaller than the one in CH1 Coincidence output point No.1 setting (Un\G4 to Un\G5). • This signal turns off when the value in CH1 Present value (Un\G2 to Un\G3) is equal to or larger than the one in CH1 Coincidence output point No.1 setting (Un\G4 to Un\G5).
CH1 Counter value smaller (point No.2) • This signal turns on when the value in CH1 Present value (Un\G2 to Un\G3) is smaller than the one in CH1 Coincidence output point No.2 setting (Un\G6 to Un\G7). • This signal turns off when the value in CH1 Present value (Un\G2 to Un\G3) is equal to or larger than the one in CH1 Coincidence output point No.2 setting (Un\G6 to Un\G7).
Page 60
CH1 Coincidence signal enable command This signal is turned on to output the statuses of CH1 Counter value coincident (point No.1) (X2) and CH1 Counter value coincident (point No.2) (X6) to the external terminal. ■Device number The following table shows the device number of this output signal. Signal name CH...
Page 61
CH1 Counter function selection start command • The status of Y6 in the pulse count mode is shown. • This signal is turned on to execute the counter function selection. ■Device number The following table shows the device number of this output signal. Signal name CH...
Appendix 3 Buffer Memory Areas List of buffer memory addresses The following table lists the buffer memory addresses of the high-speed counter module. For details on the buffer memory addresses, refer to the following. Page 62 Details of buffer memory addresses Do not write any data to the system area or the area whose data type is monitor in the buffer memory.
Page 63
Address Name Default value Data type Auto refresh Decimal (hexadecimal) 261 (105H) 277 (115H) CH PWM output ON time setting 2 (H) Control 262 to 271 278 to 287 System area (106H to 10FH) (116H to 11FH) ...
Details of buffer memory addresses This section describes the I/O numbers (X/Y), buffer memory addresses, and external I/O terminals for CH1. To check the I/O numbers (X/Y) for CH2, refer to the following. Page 54 List of I/O signals To check the buffer memory addresses for CH2, refer to the following. Page 60 List of buffer memory addresses CH1 Preset value setting •...
Page 65
CH1 Overflow detection • When the counter type is set to linear counter in the pulse count mode, or when the pulse measurement mode is set, the overflow status of the counter is stored in this area. • Either of the following values is stored based on the overflow status. Status Stored value No overflow detected...
Page 66
CH1 Sampling/cycle counter flag • When the sampling counter function or cycle pulse counter function is selected, the operating status of the selected function is stored in this area. • Either of the following values is stored based on the operating status of the function. Operating status Stored value Function stopped...
Page 67
CH1 Cycle pulse count current value • The cycle pulse count current value is stored in this area during the execution of the cycle pulse counter function. • The range of the stored value is between -2147483648 and 2147483647 (32-bit signed binary value). ■Buffer memory address The following shows the buffer memory address of this area.
Page 68
CH1 Counter function update flag The value indicating whether the buffer memory areas for the selected counter function are updated or not is stored in this area. When the buffer memory areas are updated, 1H is stored. When the buffer memory areas are not updated, 0H is stored. Counter function selection Buffer memory area Latch counter function...
Page 69
CH1 Synchronization latch count value • The present counter value is latched by synchronizing with the fall of the synchronization signal during the execution of the synchronization control function (during the inter-module synchronization control). • In this area, the present counter value is latched only in the pulse count mode. •...
Page 70
■Buffer memory address The following shows the buffer memory address of this area. Buffer memory address name CH Pulse measurement section setting CH1 Pulse under-measurement flag • The value indicating whether the pulse is being measured in the pulse measurement function is stored in this area. •...
Appendix 4 Operation Examples of When the Remote Head Module Is Mounted This section describes operation examples of when the remote head module is mounted. System configuration example The following system configuration is used to explain an example of operation. (1) Master station (Network number 1, station number 0) •...
Setting in the master station Connect the engineering tool to the CPU module of the master station and set parameters. Create the project with the following settings. [Project] [New] Configure the setting to use the module labels and add the module labels of the CPU module. Add the master/local module with the following settings.
Page 73
Configure the setting to use the module labels and add the module labels of the master/local module. Set "Required Settings" of "Module Parameter" of the master/local module as shown below. [Navigation window] [Parameter] [Module Information] [RJ71GF11-T2] [Module Parameter] [Required Settings] APPENDICES Appendix 4 Operation Examples of When the Remote Head Module Is Mounted...
Page 74
Set "Network Configuration Settings" of "Module Parameter" of the master/local module as shown below. [Navigation window] [Parameter] [Module Information] [RJ71GF11-T2] [Module Parameter] [Basic Settings] [Network Configuration Settings] Set "Refresh Setting" of "Module Parameter" of the master/local module as shown below. [Navigation window] ...
Setting in the intelligent device station Connect the engineering tool to the remote head module of the intelligent device station and set parameters. Create the project with the following settings. [Project] [New] Set "Network Required Setting" of "CPU Parameter" of the remote head module as shown below. [Navigation window] ...
Page 76
Configure the setting not to use the module labels. Set "Basic setting" of "Module Parameter" of the high-speed counter module as shown below. [Navigation window] [Parameter] [Module Information] [RD62P2] [Module Parameter] [Basic setting] Setting item Setting value Pulse input mode 3: 2-phase multiple of 1...
Page 77
Set "Application setting" of "Module Parameter" of the high-speed counter module as shown below. [Navigation window] [Parameter] [Module Information] [RD62P2] [Module Parameter] [Application setting] Setting item Setting value Counter Function Selection Set the parameter according to the counter function used. Sampling Time Setting/Period Time Setting •...
Page 78
Set "Refresh settings" of "Module Parameter" of the high-speed counter module as shown below. [Navigation window] [Parameter] [Module Information] [RD62P2] [Module Parameter] [Refresh settings] Write the set parameters to the remote head module on the intelligent device station. Then reset the remote head module or power off and on the system.
Checking the network status After setting parameters to the master station and the intelligent device station, check whether data link is normally performed between the master station and the intelligent device station. Check the network status using the CC-Link IE Field Network diagnostics of the engineering tool.
Page 80
Common program The following figure shows an example of the program to check the data link status of the remote head module (station number 1). Checks the data link status of the remote head module (station number 1). Add the MCR instruction shown below to the last of the program. Program example in pulse count mode ■Program example in pulse count mode •...
Page 81
• To perform the preset (126) Turns on 'CH1 Preset command' (Y1001). (148) Turns off 'CH1 Preset command' (Y1001). ■Program example of the counter function selection When using the functions listed below, use the following programs. • To use the count disable function (157) Starts and stops the count disable function •...
Page 82
Program example in pulse measurement mode (32) Starts the pulse measurement. (47) Stops the pulse measurement. Program example in PWM output mode (32) Starts and stops the PWM output. (44) Turns on 'LED signal for PWM under-output check' (Y42) at a PWM output. APPENDICES Appendix 4 Operation Examples of When the Remote Head Module Is Mounted...
Page 83
MEMO APPENDICES Appendix 4 Operation Examples of When the Remote Head Module Is Mounted...
Appendix 5 Added or Changed Functions This section describes the functions added to or changed for the high-speed counter module. Added or changed contents Reference Online module change MELSEC iQ-R Online Module Change Manual APPENDICES Appendix 5 Added or Changed Functions...
Page 85
MEMO APPENDICES Appendix 5 Added or Changed Functions...
Japanese manual number: SH-081240-D This manual confers no industrial property rights of any other kind, nor does it confer any patent licenses. Mitsubishi Electric Corporation cannot be held responsible for any problems involving industrial property rights which may occur as a result of using the contents noted in this manual.
WARRANTY Please confirm the following product warranty details before using this product. 1. Gratis Warranty Term and Gratis Warranty Range If any faults or defects (hereinafter "Failure") found to be the responsibility of Mitsubishi occurs during use of the product within the gratis warranty term, the product shall be repaired at no cost via the sales representative or Mitsubishi Service Company.
TRADEMARKS The company names, system names and product names mentioned in this manual are either registered trademarks or trademarks of their respective companies. In some cases, trademark symbols such as '' or '' are not specified in this manual. SH(NA)-081241ENG-D...
Page 92
SH(NA)-081241ENG-D(1812)MEE MODEL: RD62-U-OU-E MODEL CODE: 13JX14 HEAD OFFICE : TOKYO BUILDING, 2-7-3 MARUNOUCHI, CHIYODA-KU, TOKYO 100-8310, JAPAN NAGOYA WORKS : 1-14 , YADA-MINAMI 5-CHOME , HIGASHI-KU, NAGOYA , JAPAN When exported from Japan, this manual does not require application to the Ministry of Economy, Trade and Industry for service transaction permission.