Mitsubishi Electric 700 Series Programming Manual

Mitsubishi Electric 700 Series Programming Manual

700 series plc function programming manual
Hide thumbs Also See for 700 Series:
Table of Contents
INVERTER
FR-A
700
PLC FUNCTION
PROGRAMMING MANUAL
PLC FUNCTION
CC-Link
COMMUNICATION
SEQUENCE
PROGRAMMING
ERROR CODE
LIST
Chapter 1
Chapter 2
Chapter 3
Chapter 4
Table of Contents
loading

Summary of Contents for Mitsubishi Electric 700 Series

  • Page 1 INVERTER FR-A PLC FUNCTION PROGRAMMING MANUAL Chapter 1 PLC FUNCTION CC-Link Chapter 2 COMMUNICATION SEQUENCE Chapter 3 PROGRAMMING ERROR CODE Chapter 4 LIST...
  • Page 2: Table Of Contents

    1. PLC FUNCTION Function Block Diagram ...2 PLC Function Specifications...3 System Configuration ...4 Wiring of the Inverter and Personal Computer Using GX Developer for RS-485 Communication...5 Prior to Sequence Program Creation ...6 1.5.1 Precautions for sequence program creation ... 6 1.5.2 Usable main GX Developer functions ...
  • Page 3 2. CC-Link COMMUNICATION System Configuration... 46 2.1.1 System configuration example... 46 2.1.2 Function block diagram... 47 CC-Link Parameters... 49 2.2.1 CC-Link Extended Setting (Pr. 544)... 49 CC-Link I/O Specifications ... 50 Buffer Memory... 57 2.4.1 Remote output signals (Master module to inverter(FR-A7NC))... 57 2.4.2 Remote input signals Pr.544=100 (Inverter(FR-A7NC) to master module)...
  • Page 4 3.9.5 100ms, 10ms and 100ms retentive timers ... 80 3.9.6 Timer processing method and accuracy ... 81 3.10 Counters C ...83 3.10.1 Count processing in refresh system ... 84 3.10.2 Maximum counting speed of counter ... 85 3.11 Data Registers D...86 3.12 Special Relays, Special Registers ...87 3.13 Function List ...89 3.14 How to RUN/STOP the Built-in PLC Function from Outside (Re-...
  • Page 5 3.25.6 Output Instructions : Device set, reset ... SET, RST... 126 3.25.7 Output Instructions : Leading edge, trailing edge differential outputs ... PLS, PLF ... 129 3.25.8 Shift Instructions : Bit device shift ... SFT, SFTP ... 131 3.25.9 Master Control Instructions : Master control set, reset ... MC, MCR... 133 3.25.10End Instruction : Sequence program end ...
  • Page 6: Plc Function

    1. PLC FUNCTION This manual describes the functions and devices necessary for programming. 1.1 Function Block Diagram ... 2 1.2 PLC Function Specifications... 3 1.3 System Configuration ... 4 Wiring of the Inverter and Personal Computer Using GX Developer for RS-485 Communication... 5 1.5 Prior to Sequence Program Creation ...
  • Page 7: Function Block Diagram

    Function Block Diagram 1.1 Function Block Diagram How I/O data are transferred to/from the inverter by the built-in PLC function is explained using function blocks. (1) I/O data read, write, etc. can be performed by accessing the inverter in the predetermined method using special relays, special registers, etc.
  • Page 8: Plc Function Specifications

    1.2 PLC Function Specifications The following table indicates the program capacity and devices of the PLC function. Control method I/O control method Programming language PLC instructions Basic instructions Application instructions Processing speed Number of I/O points Number of analog I/O points Watchdog timer Memory capacity Program capacity...
  • Page 9: System Configuration

    The following shows the system configuration for use of the PLC function. GX Developer: Programming tool 3-phase AC power supply Communication specifications Set the following setting in communication parameters of the inverter. Inverter Parameter Pr.118 PU communication speed Pr.119 PU communication stop bit length...
  • Page 10: Wiring Of The Inverter And Personal Computer Using Gx Developer For Rs-485 Communication

    1.4 Wiring of the Inverter and Personal Computer Using GX Developer for RS-485 Communication Personal computer GX Developer : Programming tool RS-232C connector Personal computer - inverter connection cable Make connection after conversion between RS-232C and RS-485. Examples of commercially available products (as of Sep., '05) Type SC-FRPC REMARKS...
  • Page 11: Prior To Sequence Program Creation

    Prior to Sequence Program Creation 1.5 Prior to Sequence Program Creation 1.5.1 Precautions for sequence program creation POINT •Online change of the sequence program and access to other stations are not allowed. In addition, program read/write from other stations and all PLC memory clear cannot be performed.
  • Page 12: Sequence Program Execution Key

    1.5.3 Sequence program execution key The sequence program execution key (STOP/RUN) of the PLC is switched by turning off/on the SQ signal. POINT •For the terminal used for SQ signal input, set "50" in any of Pr.178 to Pr. 189 to assign the function.
  • Page 13: Sequence Program Write

    Prior to Sequence Program Creation 1.5.4 Sequence program write POINT Sequence program write can be performed in any operation mode. When rewriting the PLC function parameters and sequence program using GX Developer, check the following: 1) Check that the sequence program execution key is in the STOP position (SQ signal is off) (refer to page 7).
  • Page 14: Setting List Of Built-In Plc Function Parameter

    1.5.5 Setting list of built-in PLC function parameter The built-in PLC function parameters are designed to specify the ranges of using the PLC function, e.g. program capacity, device assignment and various functions. Item Sequence program capacity File register capacity Comment capacity Status latch Sampling trace Microcomputer program...
  • Page 15: Device Map

    Device Map 1.6 Device Map 1.6.1 I/O device map Device Name STF terminal STR terminal RH terminal RM terminal RL terminal JOG terminal RT terminal AU terminal CS terminal MRS terminal STOP terminal RES terminal Empty X0 terminal X1 terminal X2 terminal X3 terminal X4 terminal...
  • Page 16 Device Name Operation mode setting read completion Set frequency read completion (RAM) Set frequency read completion (E PROM) Operation mode setting write completion Set frequency write completion (RAM) Set frequency write completion (E PROM) Alarm definition batch clear completion Parameter clear completion Parameter read completion (RAM)
  • Page 17: Internal Relay (M) Device Map

    Device Map 1.6.2 Internal relay (M) device map Device No. M0 to M63 Use freely on user side. 1.6.3 Data register (D) device map Data Inverter Pr. Register (D) Number D0 to D99 Use freely on user side. Pr.506 to D100 to D119 Pr.515 1.6.4...
  • Page 18 Number Name Inverter operation status M9211 control flag (RES) M9216 Inverter status (RUN) M9217 Inverter status (FWD) M9218 Inverter status (REV) M9219 Inverter status (SU) M9220 Inverter status (OL) M9221 Inverter status (IPF) M9222 Inverter status (FU) M9223 Inverter status (ALM) M9224 Inverter status (LF) M9225...
  • Page 19: Special Registers

    Device Map 1.6.5 Special registers The special registers are data registers with special applications and therefore data should not be written to the special registers in the program. Number Name Self-diagnostic D9008 error Operation error D9010 step Operation error D9011 step I/O control D9014...
  • Page 20 Number Name Output frequency D9133 monitor Output current D9134 monitor Output voltage D9135 monitor D9136 Error history 1, 2 D9137 Error history 3, 4 D9138 Error history 5, 6 D9139 Error history 7, 8 Operation mode D9140 setting read Set frequency D9141 read (RAM) Set frequency...
  • Page 21 Device Map Number Name Inverter operation D9148 status control Inverter operation status control D9149 enable/disable setting Inverter D9150 parameter access error D9151 Inverter status Frequency D9152 setting D9153 Running speed D9154 Motor torque Converter output D9155 voltage Regenerative D9156 brake duty Electronic thermal D9157 relay function load...
  • Page 22 Number Name Converter output D9159 voltage peak value D9160 Input power D9161 Output power Input terminal D9162 status Output terminal D9163 status D9164 Load meter Motor excitation D9165 current D9166 Position pulse Cumulative D9167 energization time D9169 — Actual operation D9170 time D9171...
  • Page 23 Device Map Number Name Option input D9205 terminal status 1 Option input D9206 terminal status 2 Option output D9207 terminal status Description The input status of the FR-A7AX is stored. All off (0) when an option is not fitted. B12B11 B8B7 D9205 B12B11...
  • Page 24 Number Name Second D9234 parameter changing (RAM) When setting the calibration(bias/gain) parameters. Second parameter D9235 changing (EEPROM) Pulse train input D9236 sampling pulse Pulse train input D9237 cumulative count value L Pulse train input D9238 cumulative count value H Reset request of D9239 pulse train input count...
  • Page 25: Inverter Status Monitoring, Special Registers For Control

    for Control 1.7 Inverter Status Monitoring, Special Registers for Control You can assign the data for grasping and changing the inverter's operation status to D9133 - D9147 and read/write them from the user sequence. (Refer to page 14 for the list.) 1.7.1 Data that can be read at all times...
  • Page 26 (2) Error history (error codes and error definitions) The inverter stores the error codes of the errors that occurred. The error codes of up to eight errors are stored in the order as shown below and are always read-enabled (write-disabled). ...
  • Page 27 for Control The following program reads the latest alarm definition of the inverter to D0. Alarm definition read request During execution of a sequence program, any of the following error No. is stored into D9008 due to an operation error.
  • Page 28: Data That Are Read By Controlling (Off To On) The Read Command

    1.7.2 Data that are read by controlling (OFF to ON) the read command You can read the operation mode and set frequency of the inverter. Device Name D9140 Operation mode setting read D9141 Set frequency read (RAM) D9142 Set frequency read (EEPROM) Data are stored into the above data devices as soon as the read completion turns from off to on after the read command has turned from off to on.
  • Page 29 for Control (2) Set frequency (RAM) (D9141) The frequency set to the RAM is read to D9141. The unit is 0.01Hz. (For example, 6000 indicates 60.00Hz.) When the speed is set, the speed is either 1r/min or 0.1r/min. The following program reads the set frequency (RAM) to D0.
  • Page 30: How To Write Data By Controlling (Off To On) The Write Command

    1.7.3 How to write data by controlling (OFF to ON) the write command You can write the operation mode and set frequency to the inverter, batch-clear the alarm definitions, and clear all parameters. Device Name D9143 Operation mode setting write D9144 Set frequency write (RAM) Set frequency write...
  • Page 31 for Control (1) Operation mode setting write (D9143) Data are as follows: Data Setting NET operation mode H0000 External operation mode H0001 PU operation mode H0002 The operation mode switching method is as shown below when the Pr.79 Operation mode selection value is "0". NET mode (CC-Link) When Pr.
  • Page 32 (2) Set frequency (RAM) (D9144) The D9144 data is written to the RAM as a set frequency. The unit is 0.01Hz. (For example, 6000 indicates 60.00Hz.) When the speed is set, the speed is either 1r/min or 0.1r/min. The range where the frequency can be set is 0 to 12000 (0 to 120.00Hz). When the frequency setting is written normally, the write completion signal (X24) turns on, and at the same time, 0 is set to D9150.
  • Page 33 for Control (3) Set frequency (EEPROM) (D9145) The D9145 data is written to the EEPROM as a set frequency. The unit is 0.01Hz. (For example, 6000 indicates 60.00Hz.) When the speed is set, the speed is either 1r/min or 0.1r/min. The range where the frequency can be set is 0 to 12000 (0 to 120.00Hz).
  • Page 34 (4) Alarm definition batch clear (D9146) Writing H9696 to D9146 batch-clears the alarm definitions. At completion of clear, the write completion signal (X26) turns on, and at the same time, 0 is set to D9150. If any value outside the setting range is written or write is performed during inverter operation, HFFFF is set to D9150 as soon as the write completion signal (X26) turns on, resulting in abnormal completion.
  • Page 35 for Control (5) Parameter clear (D9147) Writing H9696 or H9966 to D9147 clears all parameters. Writing H5A5A or H55AA to D9147 clears the parameters other than the communication parameters (Refer to the Inverter instruction manual (applied)). Device No. Setting H9696 H9966 D9147 H5A5A...
  • Page 36: Inverter Operation Status Control

    1.7.4 Inverter operation status control Device No. Inverter operation status control Always D9148 Inverter operation status control D9149 (1) Inverter operation status control (D9148) Device for inverter operation status control. The operation of the inverter can be controlled by turning on/off (1, 0) bits b0 to b11 of D9148. All bits are factory-set to "0".
  • Page 37 for Control (2) Inverter operation status control enable/disable setting (D9149) You can enable or disable D9148 "inverter operation status control". The controls of the corresponding bits of D9148 are enabled by turning on/off (1, 0) bits b0 to b11 of D9149. All bits are factory-set to "0". Example: When H1F is set to D9149, bits b0 to b11 are 1 (ON), the external terminal inputs are therefore all disabled, and operation control using the inverter operation status control (D9148) can be performed.
  • Page 38: Inverter Parameter Access Error (D9150)

    1.7.5 Inverter parameter access error (D9150) Device No. D9150 If any value outside the setting range is written during parameter write, set frequency write, parameter clear, etc. from the sequence program of the inverter, or if write is performed when write is disabled, a write alarm occurs and the corresponding alarm code is stored into D9150.
  • Page 39: Inverter Parameter Read/Write Method

    Inverter Parameter Read/Write Method 1.8 Inverter Parameter Read/Write Method 1.8.1 Reading the inverter parameters Device No. Name D9241 Parameter number (RAM) D9242 Parameter description (RAM) Second parameter changing D9234 (RAM) D9243 Parameter number (EEPROM) Parameter description D9244 (EEPROM) Second parameter changing D9235 (EEPROM When reading the parameter, the parameter description is stored to D9242(D9244) by...
  • Page 40 Inverter parameter data read timing chart 1) Read command is turned on in user sequence. Y28(Y2A) Parameter read command X28(X2A) Parameter read completion Inverter parameter D9242(D9243) Parameter read data User sequence processing 2) Inverter CPU stores inverter parameter data into data registers D9242(D9243), and turns on read completion.
  • Page 41: Writing The Inverter Parameters

    Inverter Parameter Read/Write Method 1.8.2 Writing the inverter parameters Device No. Name D9241 Parameter number (RAM) D9242 Parameter description (RAM) Second parameter changing D9234 (RAM) D9243 Parameter number (EEPROM) Parameter description D9244 (EEPROM) Second parameter changing D9235 (EEPROM Parameter writing is performed when the parameter number is stored to D9241 (D9243) and parameter writing value to D9242 (D9244), and turns ON the Y29 (Y2B).
  • Page 42 Inverter parameter data write timing chart 1) In user sequence, user data are stored into parameter write data area (D9242(D9244)). Y29(Y2B) Parameter write command X29(X2B) Parameter write completion Inverter parameter D9242(D9244) Parameter write data User sequence data 3) Turns on when inverter CPU completes inverter parameter data write.
  • Page 43: User Area Read/Write Method

    User Area Read/Write Method 1.9 User Area Read/Write Method Inverter parameters Pr.506 to Pr.515 can be used as user parameters. Since this parameter area and the devices used with the PLC function, D110 to D119, are accessible to each other, the values set in Pr.506 to Pr.515 can be used in a sequence program.
  • Page 44: Analog I/O Function

    1.10 Analog I/O function 1.10.1 Analog input Analog input value of termianl 1, 2, 4 can be read from D9245 to D9247. Device Terminal Name D9245 Terminal 1 input D9246 Terminal 2 input D9247 Terminal 4 input Actual read processing is performed at the END processing of the sequence. REMARKS Full-scale value of analog input is determined by the setting of Pr.
  • Page 45: Paluse Train Input Function

    Paluse train input function 1.11 Paluse train input function Pulse train (the number of sampling pulses) from terminal JOG is stored to D9236. When the sampling pulses overflow, make adjustment with the setting of Pr. 416 and Pr. 417. The number of sampling pulses = the number of input pulses per count cycle x Pre-scale setting value (Pr.
  • Page 46: Pid Control

    1.12 PID control With PLC function, PID set point/PID deviation value, PID process value can be set by setting Pr. 128. Performing the PID operation using the value of D9248 and D9249 as PID set point/ PID deviation value, PID process value, manipulated variable is stored to D9250. When performing PID control with PLC function, "1"...
  • Page 47 PID control Device No. Name D9248 PID set point / PID deviation D9249 PID measurement value D9250 PID manipulated variable PID operation control D9255 CAUTION • The PID set point/PID deviation value of D9248 automatically switches over by Pr. 128 setting. •...
  • Page 48: Inverter Operation Lock Mode Setting

    1.13 Inverter Operation Lock Mode Setting You can disable a sequence program from being executed until the sequence program execution key is set to RUN (SQ signal is turned on). POINT When you want to perform only inverter operation without using the PLC function, set "0"...
  • Page 49 MEMO...
  • Page 50: Cc-Link Communication

    2. CC-Link COMMUNICATION 2.1 System Configuration ... 46 2.2 CC-Link Parameters ... 49 2.3 CC-Link I/O Specifications... 50 2.4 Buffer Memory ... 57 Chapter 1 Chapter 2 Chapter 3 Chapter 4...
  • Page 51: System Configuration

    Terminating resistor CC-Link dedicated cable REMARKS Refer to the FR-A7NC indtruction manual for the CC-Link communication wiring and CC-Link cables. Inverter Up to 42 inverters can be connected when only inverters are connected. Power supply Motor Inverter Power Motor supply...
  • Page 52: Function Block Diagram

    2.1.2 Function block diagram How I/O data are transferred to/from the inverter in CC-Link will be described using function blocks. (1) Between the master station and inverter in the CC-Link system, link refresh is always made at 3.5 to 18ms (512 points). (2) I/O refresh and master station's sequence program are executed asynchronously.
  • Page 53 System Configuration POINT The difference between CC-Link communication (Pr. 544 = 100, 112, 114, 118) with PLC function and normal CC-Link communication (Pr. 544 =1, 2, 12, 14, 18) is indicated below. Pr.544=0,1,12,14,18 Pr.544=100,112,114,118 Built-in CC-Link module Inverter I/O (RX, RY) RWw RWr Parameter read/write, monitor, operation commands, etc.
  • Page 54: Cc-Link Parameters

    2.2 CC-Link Parameters 2.2.1 CC-Link Extended Setting (Pr. 544) Remote register function can be extended. Parameter Name Number CC-Link extended setting The program used for conventional series inverter (FR-A5NC) can be used. When using double, quadruple and octuple settings of the CC-Link Ver.2, station data of the master station must be set to double, quadruple and octuple also.
  • Page 55: Cc-Link I/O Specifications

    CC-Link I/O Specifications 2.3 CC-Link I/O Specifications 2.3.1 I/O signal when CC-Link Ver.1 one station is occupied (Pr. 544 = 100) The device points usable in CC-Link communication are 32 input (RX) points (16 points are available for PLC function), 32 output (RY) points (16 points are available for PLC function), 4 remote register (RWr) points and 4 remote register (RWw) points.
  • Page 56 Remote output function Signal device device RY(n+1)B  Reserved RY(n+1)F ("n" indicates a value determined according to the station number setting.) Signal names are initial values. Using Pr. 180 to Pr. 186, Pr. 188, and Pr .189, you can change input signal functions. Signals of the RYn0, RYn1, and RYn9 can not be changed.
  • Page 57 CC-Link I/O Specifications 2.3.2 I/O signal when CC-Link Ver.2 double setting is selected (Pr. 544 = 112) The device points usable in CC-Link communication are 32 input (RX) points (12 points are available for PLC function), 32 output (RY) points (12 points are available for PLC function), 4 remote register (RWr) points and 4 remote register (RWw) points.
  • Page 58 ("n" indicates a value determined according to the station number setting.) Signal names are initial values. Using Pr. 180 to Pr. 186, Pr. 188, and Pr .189, you can change input signal functions. Signals of the RYn0, RYn1, and RYn9 can not be changed. Even when changed using Pr. 178, Pr.
  • Page 59 CC-Link I/O Specifications 2.3.3 I/O signal when CC-Link Ver.2 quadruple setting is selected (Pr. 544 = 114) The device points usable in CC-Link communication are 32 input (RX) points (12 points are available for PLC function), 32 output (RY) points (12 points are available for PLC function), 8 remote register (RWr) points and 8 remote register (RWw) points.
  • Page 60 2.3.4 I/O signal when CC-Link Ver.2 octuple setting is selected (Pr. 544 = 118) The device points usable in CC-Link communication are 32 input (RX) points (12 points are available for PLC function), 32 output (RY) points (12 points are available for PLC function), 16 remote register (RWr) points and 16 remote register (RWw) points.
  • Page 61 CC-Link I/O Specifications PLC function Address Upper 8 device No. Bits D9062 RWwn+10 D9063 RWwn+11 D9064 RWwn+12 D9065 RWwn+13 D9066 RWwn+14 D9067 RWwn+15 D9068 RWwn+16 Registers designed to D9069 RWwn+17 read data received D9070 RWwn+18 from the master station D9071 RWwn+19 D9072 RWwn+1A...
  • Page 62: Buffer Memory

    2.4 Buffer Memory 2.4.1 Remote output signals (Master module to inverter(FR-A7NC)) •Input states to the remote device station are stored. •Two words are used for each station. (Do not use address 16n (n = 2(X - 1) + 1, X = station No.)) Master Station Remote inputs (RY) Addresses...
  • Page 63: Remote Input Signals Pr.544=100

    Buffer Memory 2.4.2 Remote input signals Pr.544=100 (Inverter(FR-A7NC) to master module) • Input states from the remote device station are stored. • Two words are used for each station. (Do not use address En (n = 2(X - 1) + 1, X = station No.)) Master station Addresses Remote inputs (RX)
  • Page 64: Remote Registers Pr.544=100

    2.4.3 Remote registers Pr.544=100 (Master module to inverter(FR-A7NC)) • Data to be sent to the remote registers (RWW) of the remote device station are stored. • Four words are used for each station. Master station Remote registers (RWw) Addresses For station No.1 For station No.2...
  • Page 65: Remote Registers Pr.544=100

    Buffer Memory 2.4.4 Remote registers Pr.544=100 (Inverter(FR-A7NC) to master module) • Data sent from the remote registers (RWR) of the remote device station are stored. • Four words are used for each station. Master station Remote registers (RWr) Addresses For station No.1 For station No.2...
  • Page 66: Sequence Programming

    3. SEQUENCE PROGRAMMING 3.1 Overview ... 62 3.2 RUN and STOP Operation Processings ... 64 3.3 Program Makeup ... 64 3.4 Programming Languages ... 65 3.5 Operation Processing Method of PLC Function... 68 3.6 I/O Processing Method ... 69 3.7 Scan Time... 71 3.8 Numerical Values Usable in Sequence Program ..
  • Page 67: Overview

    Overview 3.1 Overview 3.1.1 Outline of Operation Processings This section outlines processings performed from when the inverter is powered on until a sequence program is executed. The built-in PLC function processings are roughly classified into the following three types. (1) Initial processing Pre-processing for executing sequence operation.
  • Page 68 Power on Initial processing I/O initialization Data memory initialization Self-diagnostic checks I/O refresh processing Sequence program operation processing Until execution of END instruction END processing Self-diagnostic checks Updating of timer and counter present values and on/off of their contacts Fig 3.1 Operation Processings of Built-in PLC function Step 0 Overview...
  • Page 69: Run And Stop Operation Processings

    RUN and STOP Operation Processings 3.2 RUN and STOP Operation Processings The built-in PLC function has two different operation statuses: RUN status and STOP status. This section explains the operation processings of the built-in PLC function in each operating status. (1) Operation processing in RUN status A RUN status indicates that a sequence program repeats its operation in order of step 0 to END (FEND) instruction to step 0 when SQ-SD are shorted.
  • Page 70: Programming Languages

    3.4 Programming Languages The built-in PLC function has two different programming methods: one that uses ladders and the other that uses dedicated instructions. • Programming that uses ladders is performed in the relay symbolic language. *1 • Programming that uses dedicated instructions is performed in the logic symbolic language.
  • Page 71 Programming Languages (2) Sequence program operation method Sequence program operation repeats execution from a ladder block at step 0 to an END instruction. In a single ladder block, operation is performed from the left hand side vertical bus to the right, and from the top to the bottom. Beginning of one ladder block Operation...
  • Page 72: Logic Symbolic Language (List Mode)

    3.4.2 Logic symbolic language (List mode) The logic symbolic language uses dedicated instructions for programming contacts, coils, etc. instead of their symbols used by the relay symbolic language. (1) Program operation method Sequence program operation is executed from an instruction at step 0 to an END instruction in due order.
  • Page 73: Operation Processing Method Of Plc Function

    Operation Processing Method of PLC Function 3.5 Operation Processing Method of PLC Function The operation processing method is the repeated operation of a stored program. (1) Stored program system 1) In a stored program system, a sequence program to be operated is stored in the internal memory beforehand.
  • Page 74: I/O Processing Method

    3.6 I/O Processing Method The control system is a refresh system. 3.6.1 What is refresh system? In the refresh system, control input terminal changes are batch-imported into the input data memory of the CPU before execution of each scan, and the data of this input data memory are used as the input data for operation execution.
  • Page 75: Response Delay In Refresh System

    I/O Processing Method 3.6.2 Response delay in refresh system This section describes a delay of an output change in response to an input change. An output change in response to an input change has a delay of up to two scans as shown in Fig.
  • Page 76: Scan Time

    3.7 Scan Time (1) Scan time A scan time is a time from when sequence program operation is executed from step 0 until step 0 is executed again. The scan time of each scan is not equal, and changes depending on whether the used instructions are executed or not.
  • Page 77: Numerical Values Usable In Sequence Program

    Numerical Values Usable in Sequence Program 3.8 Numerical Values Usable in Sequence Program The built-in PLC function represents numerical values, alphabets and other data in two statuses: 0 (OFF) and 1 (ON). The data represented by these 0s and 1s are called BIN (binary code). The built-in PLC function can also use HEX (hexadecimal code) that represents BIN data in blocks of four bits.
  • Page 78: Bin (Binary Code)

    3.8.1 BIN (Binary Code) (1) Binary code BIN is a numerical value represented by 0s (OFF) and 1s (ON). In the decimal code, a number is incremented from 0 to 9, and at this point, a carry occurs and the number is incremented to 10. In BIN, 0, 1 are followed by a carry, and the number is incremented to 10 (2 in decimal).
  • Page 79: Hex (Hex Decimal)

    Numerical Values Usable in Sequence Program the range -32768 to 32767. Therefore, each register of the built-in PLC function can store any value between -32768 and 32767. 3.8.2 HEX (HEX Decimal) (1) HEX HEX represents four bits of BIN data as one digit. Using four bits in BIN, you can represent 16 values from 0 to 15.
  • Page 80: Description Of Devices

    3.9 Description of devices 3.9.1 Device List The following table indicates the device names usable with the built-in PLC function and their ranges of use. Input (X) Output (Y) Internal relay (M) Latch relay (L) Step relay (S) Link relay (B) Points Timer (T) Specifications...
  • Page 81: Inputs, Outputs X, Y

    Description of devices 3.9.2 Inputs, Outputs X, Y Inputs and outputs are devices designed to transfer data between the inverter and external devices. Inputs provide ON/OFF data given to the corresponding control input terminals from outside the inverter. In a program, they are used as contacts (normally open, normally closed contacts) and the source data of basic instructions.
  • Page 82 (1) Inputs X (a) Inputs are designed to give commands and data from external devices, such as pushbuttons, select switches, limit switches and digital switches, to the inverter (built-in PLC function). (b) On the assumption that the PLC function contains a virtual relay Xn for one input point, the normally open (N/O) or normally closed (N/C) contact of that Xn is used in the program.
  • Page 83 Description of devices (2) Outputs Y (a) Outputs are designed to output the control results of a program to outside the inverter (signal lamps, digital indicators, magnetic switches (contactors), solenoids, etc.). (b) An output can be exported to outside the inverter as equivalent to one N/O contact.
  • Page 84: Internal Relays M

    3.9.3 Internal Relays M Internal relays are auxiliary relays that are used in the PLC function and cannot latch data (backup for power failure). All internal relays are turned off when: • Power is switched from off to on; or •...
  • Page 85: Timers T

    Description of devices 3.9.4 Timers T The timers of the PLC function are count up timers. The count up timer starts timing the present value when its coil turns on, and the contact of that timer turns on when the present value reaches the setting (time-out). 3.9.5 100ms, 10ms and 100ms retentive timers (1) 100ms and 10ms timers...
  • Page 86: Timer Processing Method And Accuracy

    (2) 100ms retentive timers 1) A 100ms retentive timer is designed to time the ON period of the timer coil. When its coil turns on, the timer starts timing the present value and maintains the present value and contact ON/OFF state if the coil turns off. When the coil turns on again, the timer resumes timing from the maintained present value.
  • Page 87 Description of devices (2) Present value update timing and accuracy in refresh system 1) The timer accuracy is +2 scan times independently of the used timer and scan time. 2) The following shows the present value update timing and accuracy when the 10ms timer is used in a program where the scan time is 10ms or more.
  • Page 88: Counters C

    3.10 Counters C The counters of the built-in PLC function are up counters. An up counter stops counting and its contact turns on when the count value reaches the setting. (1) Count processing 1) The coil of the counter is turned on/off at execution of the OUT C and its present value is updated and its contact turns on after execution of the END instruction.
  • Page 89: Count Processing In Refresh System

    Counters C 3.10.1 Count processing in refresh system The counter counts on the leading edge of the input condition of the counter imported at an input refresh. Ladder example Counting method Input (X) refresh (Image) C3 coil C3 present value C3 contact REMARKS Refer to page 85 for the maximum counting speed of the counter.
  • Page 90: Maximum Counting Speed Of Counter

    3.10.2 Maximum counting speed of counter The maximum counting speed of the counter is determined by the scan time, and the counter can count only when the ON/OFF period of the input condition is longer than the scan time. Maximum counting speed Cmax REMARKS The duty n is a percent (%) ratio of ON/OFF period to (ON + OFF period) of the count input signal.
  • Page 91: Data Registers D

    Data Registers D 3.11 Data Registers D (1) Data registers are memories that can store numerical data (-32768 to 32767 or H0000 to HFFFF) in the built-in PLC function. One point of data register consists of 16 bits and allows data to be read/written in units of 16 bits.
  • Page 92: Special Relays, Special Registers

    3.12 Special Relays, Special Registers Special relays and special registers are internal relays and data registers, respectively, whose applications are predetermined by the built-in PLC functions. They have the following main applications. (1) Sequence operation check The special relays and special registers can be used to: (a)Check the operating status (RUN/STOP) (b)Detect a fault by the self-diagnostic function (c)Detect an operation error...
  • Page 93 Special Relays, Special Registers Table3.4 Special Relay Application List Special Item Relay (1) This relay turns on for one scan when the built-in PLC function Initial processing M9038 flag (1 scan ON) (2) Using M9038, you can create a sequence program to be Normal OFF This relay remains off while power is on.
  • Page 94: Function List

    3.13 Function List Function Remote RUN/STOP Watchdog timer variable (10 to 2000ms) Self-diagnostic function STOP to RUN-time output setting Keyword registration CAUTION The following functions are unavailable. Constant scan, latch (backup for power failure), PAUSE, status latch, sampling trace, step run, clock, interrupt processing, comment, microcomputer mode, print title registration, annunciator display mode, ERROR LED priority setting Description •...
  • Page 95: How To Run/Stop The Built-In Plc Function From Outside (Remote Run/Stop)

    from Outside (Remote RUN/STOP) 3.14 How to RUN/STOP the Built-in PLC Function from Outside (Remote RUN/STOP) The built-in PLC function is RUN/STOPped by shorting/opening SQ-SD. Remote RUN/STOP is to RUN/STOP the built-in PLC function from outside the inverter with SQ-SD shorted (RUN status). (1) Applications of remote RUN/STOP In the following cases, the function can be RUN/STOPped by remote operation using remote RUN/STOP.
  • Page 96 2) Method using GX Developer RUN/STOP can be performed by remote RUN/STOP operation from GX Developer. For example, this method can be used to STOP the function for sequence program write in a place where the inverter is out of reach. Remote STOP command GX Developer...
  • Page 97: Watchdog Timer (Operation Clog Up Monitor Timer)

    Watchdog Timer (Operation clog up monitor timer) 3.15 Watchdog Timer (Operation clog up monitor timer) (1) Watchdog timer A watchdog timer is the internal timer of the built-in PLC function designed to detect hardware or sequence program faults. Its default value is set to 200ms. (2) Watchdog timer resetting The built-in PLC function resets the watchdog timer before execution of step 0 (after execution of END processing).
  • Page 98: Self-Diagnostic Function

    3.16 Self-diagnostic Function The self-diagnostic function diagnoses faults by the built-in PLC function itself. (1) Self-diagnostic timing The self-diagnostic function is performed at power-on, at reset, at execution of any instruction, or at execution of the END instruction. 1) At power-on, at reset Whether operation can be executed or not is diagnosed.
  • Page 99: Error-Time Operation Mode

    Self-diagnostic Function 3.16.1 Error-time operation mode The built-in PLC function allows you to set whether the sequence program operation will be stopped or continued at occurrence of an operation error. Use the built-in PLC function parameter to set whether operation will be stopped or continued.
  • Page 100: Keyword Registration

    3.17 Keyword Registration The keyword is designed to inhibit the read and rewrite of the program and comments in the built-in PLC function using GX Developer. (1) Read/write from built-in PLC function where keyword has been registered When the keyword has been registered, the built-in PLC function parameters, main program and comments cannot be read/written from the built-in PLC function to the GX Developer device unless the keyword registered to the built-in PLC function is entered.
  • Page 101: Setting Of Output (Y) Status At Switching From Stop Status To Run Status

    STOP Status to RUN Status 3.18 Setting of Output (Y) Status at Switching from STOP Status to RUN Status When the RUN status is switched to the STOP status, the outputs (Y) in the RUN status are stored into the built-in PLC function. Using the built-in PLC function parameter, you can set whether the outputs (Y) will be output again or will be output after execution of operation when the STOP status is switched to the RUN status.
  • Page 102: Instruction Format

    3.19 Instruction Format (1) Many of the instructions can be divided into an instruction part and a device, and their applications are as described below. Instruction part ... Indicates the function of that instruction. Device ... Indicates the data used with the instruction. (2) The instruction format can be roughly classified as follows according to the instruction part and device combinations.
  • Page 103 Instruction Format (3) Source (S) The source contains the data to be used for operation. The data changes depending on the specified device. • Constant ... Specify the numerical value to be used for • Bit device ... Word device (4) Destination (D) The destination stores the data resulting from operation.
  • Page 104: Bit Device Processing Method

    3.20 Bit Device Processing Method As the processing method when the bit device (X, Y, M) is specified, 1-bit processing and 16-bit processing using digit designation processing are available. 3.20.1 1-bit processing When a PLC instruction is used, the device used as the target of operation processing is one bit (one point) of bit device, and multiple bits cannot be specified.
  • Page 105 Bit Device Processing Method Ladder Example Processing For 16-bit instruction Turn to 0s. Source (S) data Fig 3.26 Ladder Example and Processing (b) When there is digit designation on the destination (D) side, the number of points specified by digit designation is the target on the destination side. Ladder Example Processing When source (S) data...
  • Page 106: Handling Of Numerical Value

    3.21 Handling of Numerical Value The built-in PLC function has instructions that handle numerical values indicated in 16 bits. The most significant bit of the 16 bits is used to judge whether the value is positive or negative. Therefore, the numerical values that can be handled as 16 bits are as follows.
  • Page 107: Operation Error

    Operation Error 3.22 Operation Error When a basic instruction is used, an operation error will occur in the following case. (a) If any error described in the description of the corresponding instruction occurs. POINT Note that if the device designation range is outside the corresponding device range, an operation error does not occur and data is written to other than the specified device.
  • Page 108: Instructions List

    3.23 Instructions List 3.23.1 How to use the instruction list Instruction Classification Symbol Transfer MOVP ↑ ↑ 1)... Classifies the instruction by application. 2)... Indicates the instruction symbol used for programming. The instructions are based on 16-bit data instructions. Example 16-bit transfer instruction •...
  • Page 109 Instructions List 4) ...Indicates the operation. Indicates 16 bits. 5) ...Indicates the condition of execution for each instruction as described below: Symbol The instruction is always executed independently of whether its preceding No entry condition is on or off. When the preceding condition is off, the instruction is off.
  • Page 110: Sequence Instruction

    3.23.2 Sequence instruction Instruction Classification Symbol Contacts Connectio Outputs Shift SFTP Symbol Processing Logical operation start (Operation start at N/O contact) Logical NOT operation start (Operation start at N/C contact) Logical product (N/O contact series connection) Logical product NOT (N/C contact series connection) Logical sum (N/O contact parallel...
  • Page 111 Instructions List Instruction Classification Symbol Master control Program operation NOPLF Symbol Processing Master control start Master control reset Must be written at the end of — sequence program to return to step 0. No operation — For program deletion or space No operation —...
  • Page 112: Basic Instructions

    3.23.3 Basic instructions Instruction Classification Symbol AND= LD<> AND<> OR<> LD> 16-bit data AND> comparison OR> LD<= AND<= OR<= LD< AND< OR< LD>= 16-bit data AND>= comparison OR>= Transfer MOVP Symbol Processing Continuity when (S1) = (S2) Non-continuity when (S1) ≠ (S2) <...
  • Page 113 Instructions List Instruction Classification Symbol BIN 16-bit addition/ subtraction ∗ ∗ BIN 16bit multiplication /division Symbol (S) + (D) → (D) (S1) + (S2) → (D) (S) - (D) → (D) (S1) - (S2) → (D) ∗ (S1) x (S2) → (D+1, D) ∗P (S1) / (S2) →...
  • Page 114: Application Instructions

    3.23.4 Application instructions Instruction Classification Symbol WAND WANDP Logical product WAND WANDP WANDP WORP Logical WORP WORP WXOR WXOR WXORP WXORP Exclusive logical sum WXOR WXOR WXORP WXORP WXNR WXNRP WXNRP exclusive logical WXNR WXNR WXNRP WXNRP 2’s complement NEGP Symbol WAND (D) AND (S) →...
  • Page 115: Description Of The Instructions

    Description of the Instructions 3.24 Description of the Instructions In Chapter 6, the instructions are described in the following format. Output Instructions 6.5.2 SET input RST input Functions (1) Turns on the specified device when the SET input turns on. (2) The device turned on is held on if the SET input turns off.
  • Page 116: Sequence Instructions

    3.25 Sequence Instructions Sequence instructions are used for relay control circuits, etc. 3.25.1 Contact Instructions : Operation start, series connection, parallel connection ... LD, LDI, AND, ANI, OR, ORI Usable Devices Bit devices Word (16-bit) devices Constants Device number Sequence Instructions Digit Error Flag Level...
  • Page 117: Or, Ori

    Sequence Instructions Functions LD, LDI (1) LD is an N/O contact operation start instruction, and LDI is an N/C contact operation start instruction. Each of them imports the ON/OFF data of the specified device and uses it as an operation result. AND, ANI (1) AND is an N/O contact series connection instruction, and ANI is an N/C contact series connection instruction.
  • Page 118: Contact Instructions : Ladder Block Series Connection, Parallel Connection

    Program Examples 3.25.2 Contact Instructions : Ladder block series connection, parallel connection ... ANB, ORB Usable Devices Bit devices Word (16-bit) devices Coding ・ Coding ・ Coding ・ Constants Sequence Instructions Digit Error Flag Level Desig nation (M9010,M9011)
  • Page 119 Sequence Instructions Block A Block B Block A Block B Use OR or ORI to connect contacts in parallel.
  • Page 120 Functions (1) ANDs blocks A and B and uses the resultant value as an operation result. (2) The symbol of ANB is not a contact symbol but a connection symbol. (3) ANB can be written up to seven instructions (eight blocks) consecutively. If ANB is written consecutively more than the above, the PLC cannot perform normal operation.
  • Page 121 Sequence Instructions Program Examples Though there are the following two different program coding methods for connecting ladder blocks in series consecutively, use the coding example 1. Coding example 1 Coding example 2 Though there are the following two different program coding methods for connecting ladder blocks in parallel consecutively, use the coding example 1.
  • Page 122: Connection Instructions : Ladder Block Series Connection, Parallel Connection

    3.25.3 Connection Instructions : Ladder block series connection, parallel connection ... ANB, ORB Usable Devices Bit devices Word (16-bit) devices Block A Block A Constants Block B Block B Sequence Instructions Digit Error Flag Level Desig nation (M9010,M9011) Use OR or ORI to connect contacts in parallel.
  • Page 123 Sequence Instructions Functions (1) ANDs blocks A and B and uses the resultant value as an operation result. (2) The symbol of ANB is not a contact symbol but a connection symbol. (3) ANB can be written up to seven instructions (eight blocks) consecutively. If ANB is written consecutively more than the above, the PLC cannot perform normal operation.
  • Page 124 Sequence Instructions Program Examples Though there are the following two different program coding methods for connecting ladder blocks in series consecutively, use the coding example 1. Coding example 1 Coding example 2 Though there are the following two different program coding methods for connecting ladder blocks in parallel consecutively, use the coding example 1.
  • Page 125: Connection Instructions : Operation Result, Push, Read, Pop

    Sequence Instructions 3.25.4 Connection Instructions : Operation result, push, read, pop ... MPS, MRD, MPP Usable Devices Bit devices Word (16-bit) devices Functions (1) Stores the operation result (ON/OFF) immediately before itself. (2) The MPS instruction can be used consecutively up to 12 times. In the ladder mode, however, it can be used up to 11 times.
  • Page 126 POINT (1) Ladders differ as shown below between when MPS, MRD and MPP are used and when they are not used. Ladder using MPS, MRD and MPP (2) Use the same number of MPS and MPP instructions. If they differ in the number of used instructions, operation will be performed as described below.
  • Page 127 Sequence Instructions Program Example 1) Program using MPS, MRD and MPP Coding ・...
  • Page 128: Output Instructions : Bit Device, Timer, Counter

    3.25.5 Output Instructions : Bit device, timer, counter ... OUT Bit devices Bit device Device Timer Setting Device Counter Setting (Y, M) Functions OUT (Y, M) (1) Outputs the operation result up to OUT instruction to the specified device. Operation Result REMARKS Three steps are used for the OUT instruction only when the following device is used.
  • Page 129 Sequence Instructions OUT(T) (1) When the operation result up to the OUT instruction is ON, the coil of the timer turns on and the timer times up to the setting, and when the timer times out (timing value ≥ setting), the contact operates as indicated below. N/O contact Energize N/C contact...
  • Page 130 Program Examples 1) Program that outputs to the output module. 2) Program that turns on Y10 and Y14 10s after X0 has turned on. 3) Program that turns on Y0 when X0 turns on 10 times and turns off Y0 when X1 turns 4) Program that changes the C0 setting to 10 when X0 turns on and to 20 when X1 turns on.
  • Page 131: Output Instructions : Device Set, Reset

    Sequence Instructions 3.25.6 Output Instructions : Device set, reset ... SET, RST Bit devices SET input RST input Functions (1) Turns on the specified device when the SET input turns on. (2) The device turned on is held on if the SET input turns off. It can be turned off by the RST instruction.
  • Page 132: Program Examples

    (3) The function of RST (D) is the same as that of the following ladder. RST input Execution Conditions The SET and RST instructions are executed every scan. REMARKS Three steps are used when the following device is used. SET instruction ... Special relay (M) RST instruction ...
  • Page 133 Sequence Instructions 2) Program that resets the data register contents to 0. Coding 3) Program that resets the 100ms retentive timer and counter. ・ Coding Stores X10 to 1F contents into D8 when X0 turns on. Resets D8 contents to 0 when X5 turns on. When T5 is set as retentive timer, T5 turns on when ON period of X4 reaches 30 minutes.
  • Page 134: Output Instructions : Leading Edge, Trailing Edge Differential Outputs

    3.25.7 Output Instructions : Leading edge, trailing edge differential outputs ... PLS, PLF Bit devices PLS command PLF command Functions (1) Turns the specified device on when the PLS command turns from OFF to ON, and turns it off except when the PLS command turns from OFF to ON. When there is one PLS instruction for the device specified at the specified device turns on for one scan.
  • Page 135 Sequence Instructions (1) Turns the specified device on one scan when the PLF command turns from ON to OFF, and turns it off except when the PLF command turns from ON to OFF. When there is one PLF instruction for the device specified at the specified device turns on for one scan.
  • Page 136: Shift Instructions : Bit Device Shift

    3.25.8 Shift Instructions : Bit device shift ... SFT, SFTP Bit devices SFT commands Functions (1) Shifts the ON/OFF status of the device preceding the one specified at specified device, and turns off the preceding device. (2) Use the SET instruction to turn on the first device from which data will be shifted. (3) When using the SFT or SFTP instructions consecutively, program in order of larger to smaller device numbers.
  • Page 137 Sequence Instructions Program Example 1) Program that shifts the Y7 - B data when X8 turns on. Executes shifts when X8 turns on. Program in order of larger to smaller device numbers. Turns on Y7 when X7 turns on. Coding...
  • Page 138: Master Control Instructions : Master Control Set, Reset

    3.25.9 Master Control Instructions : Master control set, reset ... MC, MCR Bit devices MC ON/OFF command Device Nesting (N0 to 7) Functions (1) The master control instructions are designed to create an efficient ladder switching sequence program by switching on/off the common bus of the ladder. The ladder that uses master control is as shown below.
  • Page 139 Sequence Instructions (1) When the MC ON/OFF command is on at the start of master control, the operation results between MC and MCR are as performed by the instructions (ladder). (2) If the MC instruction is off, the scan between the MC and MCR instructions is executed, and therefore, the scan time does not become short.
  • Page 140 (1) This instruction is designed to reset the master control and indicates the end of the master control range. (2) Do not provide a contact instruction in front of the MCR instruction. The master control instructions can be nested. Their master control ranges are differentiated by the nesting (N).
  • Page 141 Sequence Instructions Note the following when nesting the instructions. (1) The instructions can be nested to a level of eight (N0 to 7). When nesting them, use MC from lower to higher nesting (N) numbers and MCR from higher to lower numbers.
  • Page 142: 10End Instruction : Sequence Program End

    3.25.10 End Instruction : Sequence program end ... END Usable Devices Bit devices Word (16-bit) devices Functions (1) Indicates the end of a program. Execution terminates scanning at this step and returns to step 0. (2) The END instruction cannot be used halfway through the sequence program. CAUTION If the END instruction does not exist in the program, an operation error occurs and the PLC function does not operate.
  • Page 143: 11Other Instructions : No Operation

    Sequence Instructions 3.25.11 Other Instructions : No operation ... NOP Usable Devices Bit devices Word (16-bit) devices Functions (1) No-operation instruction that has no influence on the preceding operation. (2) Use NOP to: 1) Provide space for debugging of a sequence program. 2) Delete an instruction without changing the number of steps.
  • Page 144 Program Examples 1) Contact short-circuit (AND, ANI) Before change Replaced by NOP. After change 2) Contact short-circuit (LD, LDI)...Note that if LD or LDI is replaced by NOP, the Before change Replaced by NOP. After change Before change Replaced Replaced by LD T3. by NOP.
  • Page 145: Basic Instructions

    Basic Instructions 3.26 Basic Instructions The basic instructions can handle numerical data represented in 16 bits . 3.26.1 Comparison Operation Instructions (1) The comparison operation instruction is handled as a contact, compares the magnitudes of two pieces of data (e.g. =, >, <), and turns on when the condition holds.
  • Page 146 CAUTION The comparison instruction regards the specified data as BIN values. Hence, if the value whose most significant bit (b15) is 1 (8 to F) is specified for comparison of hexadecimal data, it is regarded as a negative BIN value. Example Comparison of 4-digit HEX values Regarded...
  • Page 147: Comparison Operation Instructions : 16-Bit Data Comparison

    Basic Instructions 3.26.2 Comparison Operation Instructions : 16-bit data comparison ... =, <>, >, <=, <, >= Bit devices Functions (1) Handled as an N/O contact and performs 16-bit comparison operation. (2) The comparison operation results are as indicated below. Instruction symbol in Condition...
  • Page 148 REMARKS Seven steps are used when: • The digit designation of a bit device is not K4. • The beginning of a bit device is not a multiple of 8. Program Examples 1) Program that compares the X0-F data and D3 data. <>...
  • Page 149: Arithmetic Operation Instructions

    Basic Instructions 3.26.3 Arithmetic Operation Instructions The arithmetic operation instructions are instructions which perform the addition, subtraction, multiplication, and division of two BIN data. (1) Arithmetic operation with BIN (Binary) • If the operation result of an addition instruction exceeds 32767 , the result becomes a negative value.
  • Page 150: Arithmetic Operation Instructions : Bin 16-Bit Addition, Subtraction

    3.26.4 Arithmetic Operation Instructions : BIN 16-bit addition, subtraction ... +, +P, -, -P Bit devices Addition/subtraction commands Addition/subtraction commands Usable Devices Word (16-bit) Constants Level devices Basic Instructions Error Flag Digit Designation (M9010, M9011) K1 to K4 Instruction symbol in +, - Setting data Addend/subtrahend or...
  • Page 151 Basic Instructions Functions (1) Performs the addition of BIN data specifies at , and stores the addition result into the device specified at (2) Performs the addition of BIN data specified at , and stores the addition result into the device specified at (3) At S1 S2 (4) The judgment of whether the data of...
  • Page 152 Functions (1) Performs the subtraction of BIN data specifies at , and stores the subtraction result into the device specified at (2) Performs the subtraction of BIN data specified at , and stores the subtraction result into the device specified at (3) At S1 S2 (4) The judgment of whether the data of...
  • Page 153 Basic Instructions Execution Conditions Addition/subtraction command. Addition/subtraction command Program Examples Program which adds the content of A0 to the content of D3 and outputs the result to Y38 to 3F when X5 turns on. Program which outputs the difference between the set value and present value timer T3 to Y40 to 53 in BCD.
  • Page 154: Arithmetic Operation Instructions : Bin 16-Bit Multiplication, Division

    3.26.5 Arithmetic Operation Instructions : BIN 16-bit multiplication, division ... *, *P, /, /P Bit devices Multiplication/division commands Usable Devices Word (16-bit) Constants Level devices Basic Instructions Error Flag Digit Designation (M9010, M9011) K1 to K4 Instruction symbol in ∗ , / Setting data Multiplicand/dividend or head device number...
  • Page 155 Basic Instructions Functions ∗ (1) Performs the multiplication of BIN data specified at , and stores the multiplication result into the device specified at (2) When is a bit device, specify the bits, beginning with the lower bits. Example K1: Lower 4 bits (b0 to 3) K4: Lower 16 bits (b0 to 15) (3) At , -32768 to 32767 (BIN 16 bits) can be specified.
  • Page 156 (1) Performs the division of BIN data specified at , and stores the result into the device specified at (2) In regards to the operation result, the quotient and remainder are stored by use of 32 bits in the case of word device, and only the quotient is stored by use of 16 bits in the case of bit device.
  • Page 157: Operation Errors

    Basic Instructions Operation Errors In the following case, operation error occurs and the error flag turns on. • A1 or V has been specified at • The divisor is 0. Program Examples ∗ 1) Program which stores the multiplication result of 5678 and 1234 in BIN to D3 and 4 when X5 turns on.
  • Page 158: Data Transfer Instructions

    3.26.6 Data Transfer Instructions The data transfer instructions are designed to transfer data. The data moved by the data transfer instruction is maintained until new data is transferred. 3.26.7 Data Transfer Instructions : 16-bit data transfer ... MOV, MOVP Bit devices Transfer commands Functions Transfers the 16-bit data of the device specified at...
  • Page 159 Basic Instructions Transfer command MOVP Program Examples 1) Program that stores the input X0-B data into D8. 2) Program that stores 155 into D8 in binary when X8 turns on. Executed every Executed every scan. Executed only once. Coding Coding scan.
  • Page 160: Application Instructions

    3.27 Application instructions Application instructions are used when special processing is required. 3.27.1 Logical Operation Instructions (1) The logical operation instructions are instructions which perform the logical operations such as logical add and logical product. (2) The logical operation instructions are available in the following 10 types. Instruction Classification Symbol...
  • Page 161: Logical Operation Instructions : 16-Bit Logical Product

    Application instructions 3.27.2 Logical Operation Instructions : 16-bit Logical Product ... WAND, WANDP Bit devices WAND Operation commands Operation commands WAND WANDP Functions WAND (1) ANDs the 16-bit data of the device specified at device specified at specified at Before execution After execution...
  • Page 162 (2) ANDs the 16-bit data of the device specified at device specified at specified at Before execution After execution (3) More than the digit designation of a bit device is regarded as 0 for operation. Execution Conditions The execution conditions of the logical product instructions are as shown below. Operation command WAND...
  • Page 163 Application instructions 2) Program that ANDs the X10-1B and D33 data and outputs the result to Y0-B when XA turns on. Coding b15 b14 b13 b12 X1B to 10 3) Program that ANDs the X10-1B and D33 data and outputs the result to Y0-B when XA turns on.
  • Page 164: Logical Operation Instructions : 16-Bit Logical Add

    3.27.3 Logical Operation Instructions : 16-bit Logical Add ... WOR, WORP Bit devices Operation commands Operation commands WORP Functions (1) ORs the 16-bit data of the device specified at device specified at specified at Before execution After execution Usable Devices Word (16-bit) Constants Level devices...
  • Page 165 Application instructions (2) ORs the 16-bit data of the device specified at specified at on a bit-by-bit basis, and stores the result into the device specified at Before execution After execution (3) More than the digit designation of a bit device is regarded as 0 for operation. Execution Conditions The execution conditions of the logical add instructions are as shown below.
  • Page 166 2) Program that ORs the X10-1B and D33 data and outputs the result to Y0-F when XA turns on. Coding 3) Program that ORs the D10 and D20 data and stores the result into D33 when XA turns on. 4) Program that ORs the X10-1B and D33 data and outputs the result to Y0-B when XA turns on.
  • Page 167: Logical Operation Instructions : 16-Bit Exclusive Logical Add

    Application instructions 3.27.4 Logical Operation Instructions : 16-bit Exclusive Logical Add ... WXOR, WXORP Bit devices WXOR Operation commands Operation commands WXOR WXORP Usable Devices Word (16-bit) Constants Level devices WXOR WXORP Error Flag Digit Designation (M9010, M9011) K1 to K4 Data for which exclusive OR will be performed or head...
  • Page 168 Functions WXOR (1) Performs the exclusive OR of the 16-bit data of device specified at 16-bit data of device specified at specified at Before execution After execution (2) Performs the exclusive OR of the 16-bit data of device specified at 16-bit data of device specified at specified at Before...
  • Page 169 Application instructions Program Examples WXOR 1) Program which performs exclusive OR of the data of D10 and that of D20, and stores the result to D10 when XA turns on. 2) Program which performs the exclusive OR of the data of X10 to 1B and data of D33, and sends the result to the Y30 to 3B when XA turns on.
  • Page 170: Logical Operation Instructions : 16-Bit Not Exclusive Logical Add

    3.27.5 Logical Operation Instructions : 16-bit NOT Exclusive Logical Add ... WXNR, WXNRP Bit devices WXNR Operation commands Operation commands WXNR WXNRP Usable Devices Word (16-bit) Constants Level devices WXNR WXNRP Application instructions Error Flag Digit Designation (M9010, M9011) K1 to K4 Data for which exclusive NOR will be performed or head...
  • Page 171 Application instructions Functions WXNR (1) Performs the exclusive NOR of the 16-bit data of device specified at 16-bit data of device specified at specified at Before execution After execution (2) Performs the exclusive NOR of the 16-bit data of device specified at 16-bit data of device specified at specified at Before...
  • Page 172 Program Examples WXNR 1) Program which compares the bit pattern of the 16-bit data of X30 to 3F and that of the 16-bit data of D99 and stores the number of the same bit patterns and the number of different bit patterns to D7 and 8, respectively, when XC turns on. 2) Program which compares the bit pattern of the 16-bit data of X30 to 3F and that of the data of D99 and stores the result to D7 when X0 turns on.
  • Page 173: Logical Operation Instructions : Bin 16-Bit 2'S Complement

    Application instructions 3.27.6 Logical Operation Instructions : BIN 16-bit 2’s complement ... NEG, NEGP Bit devices 2's complement execution commands Functions (1) Reverses the sign of the 16-bit data of device specified at result in device specified at Before execution Sign conversion After...
  • Page 174 Execution Conditions 2's complement execution command NEGP Program Examples 1) Program which calculates "D10 - D20" when XA turns on, and obtains the absolute value when the result is negative. Executed every Executed every scan. scan. Executed only once. Application instructions Executed only once.
  • Page 175 MEMO...
  • Page 176: Error Code List

    4. ERROR CODE LIST 4.1 How to Read the Error Code ... 172 Chapter 1 Chapter 2 Chapter 3 Chapter 4...
  • Page 177: How To Read The Error Code

    How to Read the Error Code When the built-in PLC function is in the RUN status or if an alarm occurs during RUN, the self-diagnostic function displays the error and stores the error code and error step into the special registers. This chapter describes the error definitions and corrective actions.
  • Page 178 Error Error Name Code Status (D9008) “OPERATION ERROR” [Checked at (Stop) instruction execution] Definition and Cause Divided by zero How to Read the Error Code Corrective Action Read the error step by use of peripheral device, and check and correct the program at that step.
  • Page 179 MEMO...
  • Page 180: Appendix

    APPENDIX Appendix1Instruction Processing Time ... 176...
  • Page 181: Appendix1Instruction Processing Time

    Instruction Processing Time Appendix1 Instruction Processing Time Condition Number Instruction (Device) of Steps NOPLF SFTP Special M Special M Special M MOVP WAND WANDP WAND WANDP WORP Processing Instruction Time (µs) WORP WXOR WXORP WXOR WXORP WXNR WXNRP WXNR WXNRP NEGP LD<>...
  • Page 182 Condition Number Instruction (Device) of Steps OR<> OR> OR> OR<= OR<= OR< OR< OR>= OR>= REMARKS As inverter control is also performed actually, the scan time is approximately 40ms at 500 steps. Processing Time (µs) 10.3 10.7 10.3 10.7 10.3 10.7 10.4 10.8...
  • Page 183 REVISIONS *The manual number is given on the bottom left of the back cover Print Date *Manual Number Revision Sep., 2005 IB(NA)-0600262ENG-A First edition...

This manual is also suitable for:

Fr-a700

Table of Contents