Mitsubishi Electric melsec q00ujcpu User Manual

Mitsubishi Electric melsec q00ujcpu User Manual

Programmable controller
Hide thumbs Also See for melsec q00ujcpu:
Table of Contents

Advertisement

Quick Links

MITSUBISHI ELECTRIC
Programmable Controller
User's Manual
(Function Explanation,
Program Fundamentals)
QnUCPU
01 12 2008
INDUSTRIAL AUTOMATION
MITSUBISHI ELECTRIC
SH(NA)-080807ENG
Version A

Advertisement

Table of Contents
loading

Summary of Contents for Mitsubishi Electric melsec q00ujcpu

  • Page 1 MITSUBISHI ELECTRIC Programmable Controller User's Manual (Function Explanation, Program Fundamentals) QnUCPU 01 12 2008 INDUSTRIAL AUTOMATION MITSUBISHI ELECTRIC SH(NA)-080807ENG Version A...
  • Page 4: Safety Precautions

    SAFETY PRECAUTIONS (Read these precautions before using this product.) Before using this product, please read this manual and the relevant manuals carefully and pay full attention to safety to handle the product correctly. In this manual, the safety precautions are classified into two levels: " DANGER"...
  • Page 5 [Design Precautions] DANGER 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) Configure external safety circuits, such as an emergency stop circuit, protection circuit, and protective interlock circuit for forward/reverse operation or upper/lower limit positioning.
  • Page 6 [Design Precautions] DANGER In an output module, when a load current exceeding the rated current or an overcurrent caused by a load short-circuit flows for a long time, it may cause smoke and fire. To prevent this, configure an external safety circuit, such as a fuse. Configure a circuit so that the programmable controller is turned on first and then the external power supply.
  • Page 7 [Installation Precautions] CAUTION Use the programmable controller in an environment that meets the general specifications in the QCPU User's Manual (Hardware Design, Maintenance and Inspection). Failure to do so may result in electric shock, fire, malfunction, or damage to or deterioration of the product.
  • Page 8 [Wiring Precautions] DANGER Shut off the external power supply for the system in all phases before wiring. Failure to do so may result in electric shock or damage to the product. After wiring, attach the included terminal cover to the module before turning it on for operation. Failure to do so may result in electric shock.
  • Page 9 [Wiring Precautions] DANGER A protective film is attached to the top of the module to prevent foreign matter, such as wire chips, from entering the module during wiring. Do not remove the film during wiring. Remove it for heat dissipation before system operation. Mitsubishi programmable controllers must be installed in control panels.
  • Page 10 [Startup and Maintenance Precautions] CAUTION Before performing online operations (especially, program modification, forced output, and operation status change) for the running CPU module from the peripheral connected, read relevant manuals carefully and ensure the safety. Improper operation may damage machines or cause accidents. Do not disassemble or modify the modules.
  • Page 11 [Disposal Precautions] CAUTION When disposing of this product, treat it as industrial waste. When disposing of batteries, separate them from other wastes according to the local regulations. (For details of the Battery Directive in EU countries, refer to the QCPU User's Manual (Hardware Design, Maintenance and Inspection).) [Transportation Precautions] CAUTION...
  • Page 12: Revisions

    This manual confers no industrial property rights or any rights of any other kind, nor does it confer any patent licenses. Mit- subishi 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. 2008 MITSUBISHI ELECTRIC CORPORATION A - 9...
  • Page 13 Memo A - 10...
  • Page 14: Introduction

    INTRODUCTION This manual describes the memory maps, functions, programs, I/O number assignment, and devices of the Universal model QCPU. Before using this product, please read this manual and the relevant manuals carefully and develop familiarity with the functions and performance of the Q series programmable controller to handle the product correctly. Relevant CPU module CPU module Model...
  • Page 15: Table Of Contents

    CONTENTS CONTENTS SAFETY PRECAUTIONS........................A - 1 REVISIONS ............................A - 9 INTRODUCTION ........................... A - 11 MANUALS ............................. A - 18 MANUAL PAGE ORGANIZATION ......................A - 20 GENERIC TERMS AND ABBREVIATIONS ..................A - 21 CHAPTER1 OVERVIEW 1-1 to 1-14 1 - 1 Processing Order in the CPU Module..................
  • Page 16 3 - 9 3.8.1 Refresh mode........................3 - 12 3.8.2 Direct mode ........................CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER 4-1 to 4-17 4 - 1 Base Unit Assignment......................4 - 1 4.1.1 Base mode ........................4 - 2 4.1.2 Base unit assignment setting ....................
  • Page 17 6 - 25 6.6.5 Relationship between remote operation and RUN/STOP status of the CPU module ..6 - 26 Q Series-compatible Module Input Response Time Selection (I/O Response Time) .... 6 - 28 Error Time Output Mode Setting .................... 6 - 29 H/W Error Time PLC Operation Mode Setting ...............
  • Page 18 CHAPTER7 COMMUNICATIONS WITH INTELLIGENT FUNCTION MODULE 7-1 to 7-9 7 - 1 Communications between CPU Module and Intelligent Function Module ......7 - 2 7.1.1 Initial setting and auto refresh setting by GX Configurator..........7 - 5 7.1.2 Initial setting by initial device value ................... 7 - 5 7.1.3 Communications with the FROM and TO instructions ............
  • Page 19 9.6.3 Switching from the scan execution type program to the interrupt/fixed scan execution ....................9 - 49 type program 9 - 53 File Register (R)........................9 - 54 9.7.1 File register data storage location ..................9 - 54 9.7.2 File register size ........................ 9 - 55 9.7.3 Differences in available accesses by storage memory .............
  • Page 20 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST 12-1 to 12-78 12 - 1 12.1 SPECIAL RELAY LIST......................12 - 27 12.2 SPECIAL REGISTER LIST....................APPENDICES App-1 to App-69 App- 1 Appendix 1 List of Parameter Numbers ..................App- 6 Appendix 2 Functions Added or Changed by Version Upgrade.............
  • Page 21: Manuals

    MANUALS To understand the main specifications, functions, and usage of the CPU module, refer to the basic manuals. Read other manuals as well when using a different type of CPU module and its functions. Order each manual as needed, referring to the following list. :Basic manual, :Other CPU module manuals Manual name...
  • Page 22 Other relevant manuals Manual name Description CC-Link IE Controller Network Reference Specifications, procedures and settings before system operation, parameter Manual setting, programming, and troubleshooting of the CC-Link IE controller network module < SH-080668ENG (13JV16) > Q Corresponding MELSECNET/H Network Specifications, procedures and settings before system operation, parameter System Reference Manual (PLC to PLC setting, programming, and troubleshooting of a MELSECNET/H network network)
  • Page 23: Manual Page Organization

    MANUAL PAGE ORGANIZATION Note (icon) Reference Chapter The section in this manual or The detailed explanation of "Note . " is The chapter of the current page can be another relevant manual that can provided under the corresponding easily identified by this indication on the be referred to is shown with "Note .
  • Page 24: Generic Terms And Abbreviations

    GENERIC TERMS AND ABBREVIATIONS Unless otherwise specified, this manual uses the following generic terms and abbreviations. indicates a part of the model or version. (Example): Q33B, Q35B, Q38B, Q312B Q3 B Generic term/abbreviation Description Series Q series Abbreviation for Mitsubishi MELSEC-Q series programmable controller CPU module type CPU module Generic term for the Universal model QCPU...
  • Page 25 Generic term/abbreviation Description Power supply module Generic term for the Q series power supply module, slim type power supply Power supply module module, and redundant power supply module Generic term for the Q61P-A1, Q61P-A2, Q61P, Q61P-D, Q62P, Q63P, Q64P, and Q series power supply module Q64PN power supply modules Slim type power supply module...
  • Page 26: Chapter1 Overview

    CHAPTER1 OVERVIEW CHAPTER1 OVERVIEW The CPU module performs sequence control by executing programs. This chapter describes the processing order in the CPU module, locations where the created programs are stored, and devices and instructions useful for programming. 1.1 Processing Order in the CPU Module The CPU module performs processing in the following order.
  • Page 27: Storing And Executing Programs

    1.2 Storing and Executing Programs This section describes where to store and how to execute the programs in the CPU module. (1) Programming Programs are created with GX Developer. For details of program configuration and execution conditions, refer to CHAPTER 2. (2) Storing programs Created programs and set parameters are stored in the following memories of the CPU module.
  • Page 28: Structured Programming

    CHAPTER1 OVERVIEW 1.3 Structured Programming The programs to be executed in the CPU module can be structured in the following two ways. • In one program • By dividing into multiple files (1) Structuring in one program Structured programming is available by creating one program as a collection of three program sections: main routine program ( Section 2.2.1), subroutine program ( Section 2.2.2), and interrupt program...
  • Page 29 (2) Structuring by dividing into multiple files A program is stored in a file format. Changing the file name allows the CPU module to store multiple programs. Multiple programs can be stored by changing the file name. File name: PARAM File name: ABC File name: ABC File name: DEF Device Parameter...
  • Page 30 CHAPTER1 OVERVIEW (b) Dividing into multiple files according to the functions Program memory/memory card Initial processing Program A The execution order and Main processing Program B conditions for program Processing contents A to D can be set. *1 Communication are divided according Program C processing to the functions.
  • Page 31: Devices And Instructions Useful For Programming

    1.4 Devices and Instructions Useful for Programming The CPU module is provided with devices and instructions useful for programming. This section describes the outline of these devices and instructions. (1) Various ways of device specification (a) Using each bit of a word device as a contact or coil By specifying a bit of a word device, the bit can be used as a contact or coil.
  • Page 32 CHAPTER1 OVERVIEW (d) Direct access to the buffer memory of the intelligent function module The buffer memory of the intelligent function module can be used as a device area in a program. Section 9.5.1) U4\G12 The CPU module can read the data in the buffer memory address 12 of the Q64AD.
  • Page 33 (2) Structural description of programs Use of the index register and edge relay enables easy structured programming including the pulse conversion processing. ( Section 9.2.6) PLS M0 FOR n X10 X11 PLS M10 X0Z0 X1Z0 V0Z1 Y8Z2 Multiple number (n) of similar programs can be executed by one description.
  • Page 34 CHAPTER1 OVERVIEW (4) Flexible management of subroutine programs (a) Subroutine program sharing The number of steps in a program can be reduced by sharing subroutine programs. In addition, creating and managing programs become easier. Subroutine programs can be created within the same program and called. Subroutine programs in other programs can also be called by using the common pointer.
  • Page 35 (b) Subroutine call instruction with argument passing Subroutine program that is called more than one time can be created easily. Main routine program Argument specification CALLP K4X0 Argument from FD2 Argument to FD1 Argument to FD0 Subroutine program specification Argument specification CALLP K4X10 Argument from FD2...
  • Page 36: Features

    CHAPTER1 OVERVIEW 1.5 Features This section describes the features specific to the Universal model QCPU. (1) High-speed processing more than ever The processing time required for the basic instructions, floating-point operations, and accesses to the file register becomes shorter than the existing Q series CPU modules. Use of a standard device register (Z) achieves high-speed processing between register operations (transfer instruction).
  • Page 37 (5) 32-bit index modification Since the index modification range is expanded to 32 bits, index modification for the entire file register areas is possible. ( Section 9.6.1) File register in the serial SM400 number access method DMOV K1042431 ZR0Z0 Use the index register (Z) when indexing the file register (ZR) in the serial number access ZR32767 method by 32 bits.
  • Page 38: Checking Serial Number And Function Version

    CHAPTER1 OVERVIEW 1.6 Checking Serial Number and Function Version The serial number and function version of the CPU module can be checked on the rating plate, on the front of the module, and on the System monitor screen in GX Developer. (1) Checking on the rating plate The rating plate is located on the side of the CPU module.
  • Page 39 (3) Checking on the System monitor (Product Information List) screen To open the screen for checking the serial number and function version, select [Diagnostics] [System monitor] and click the button in GX Developer. Product Inf. List... On the same screen, the serial number and function version of intelligent function modules can also be checked. Serial Function Product...
  • Page 40: Chapter2 Sequence Programs

    CHAPTER2 SEQUENCE PROGRAMS CHAPTER2 SEQUENCE PROGRAMS 2.1 Sequence Program Overview (1) Definition Sequence program is one of the programs that can be executed in the CPU module. A sequence program consists of instructions, such as sequence instructions, basic instruction, and application instruction.
  • Page 41 (2) Programming method There are two programming modes for sequence programs. Ladder mode • List mode • (a) Ladder mode Ladder mode is a mode based on the concept of sequential control by relay circuits. A program in ladder mode is similar to a schematic for a set of relay circuits. Programming in units of ladder blocks is available.
  • Page 42: Sequence Program Configuration

    CHAPTER2 SEQUENCE PROGRAMS (3) Sequence program operation A sequence program is sequentially operated from the step 0 to the END or FEND instruction. In ladder mode, a sequence program is operated from left to right and top to bottom in a ladder block. [Ladder mode] [List mode] From left to right...
  • Page 43: Main Routine Program

    2.2.1 Main routine program (1) Definition Main routine program is an entire program from the step 0 to the END or FEND instruction. (2) Program operation A main routine program executes its operations from the step 0 to the END or FEND instruction and then performs END processing.
  • Page 44: Subroutine Program

    CHAPTER2 SEQUENCE PROGRAMS 2.2.2 Subroutine program (1) Definition Subroutine program is a program from a pointer (P ) to the RET instruction. This program is executed only when it is called by a subroutine program call instruction (such as CALL(P), FCALL(P)) from a main routine program. (2) Application •...
  • Page 45 2.2.3 Interrupt program (1) Definition Interrupt program is a program from an interrupt pointer (I ) to the IRET instruction. Main routine program Indicates the end of the main routine FEND program. Interrupt program (I0) IRET Interrupt program (I29) IRET Interrupt pointer Figure 2.7 Interrupt program The interrupt factor varies depending on the interrupt pointer (I ) number.
  • Page 46 CHAPTER2 SEQUENCE PROGRAMS Only one interrupt program can be created with one interrupt pointer number. FEND Interrupt program (I0) IRET Interrupt program (I29) IRET Remark For details of the interrupt factors and interrupt pointers, refer to Section 9.11. (2) Programming of interrupt programs (a) Programming location Create interrupt programs between the FEND and END instructions in the main routine program.
  • Page 47 (b) Programming order When creating multiple interrupt programs, it is not necessary to set the interrupt pointer numbers in ascending order. (c) Before executing an interrupt program Before executing the interrupt programs of the interrupt pointers I0 to I15, I28 to I31, I45, and I50 to I255, enable interrupts with the EI instruction.
  • Page 48 CHAPTER2 SEQUENCE PROGRAMS (3) Operation when an interrupt factor occurs There are restrictions on interrupt programs depending on the interrupt factor occurrence timing. (a) When an interrupt factor occurs before the interrupt program execution status is enabled The CPU module stores the interrupt factor occurred. As soon as the interrupt program execution status is enabled, the CPU module executes the interrupt program corresponding to the stored interrupt factor.
  • Page 49 (c) When multiple interrupt factors occur simultaneously in the interrupt program execution enabled status The interrupt programs are executed in the order of interrupt pointers (I ) with high priority. Section 9.11.1) Other interrupt programs have to wait until processing of the interrupt program being executed is completed.
  • Page 50 CHAPTER2 SEQUENCE PROGRAMS (e) When an interrupt factor occurs during link refresh The link refresh is suspended and an interrupt program is executed. Even if the Block data assurance per station setting is enabled in the CC-Link IE controller network or MELSECNET/H network, this setting does not work when a device set as a refresh target is used in the interrupt program.
  • Page 51 (4) Processing at program execution type change When the program execution type is changed from the scan execution type to the interrupt, the CPU module saves and restores the following data. ( Section 9.6.3) • Data in the index register •...
  • Page 52: Settings When Program Is Divided

    CHAPTER2 SEQUENCE PROGRAMS 2.3 Settings When Program is Divided When one sequence program is divided into multiple programs, execution conditions, such as executing a program only once at start-up or executing a program at fixed intervals, can be set for each program. (1) Application The CPU module can store multiple programs divided on the basis of each control unit.
  • Page 53 (a) Program name Enter the name (file name) of the program to be executed in the CPU module. (b) Execute type Select an execution type of the program set under "Program name". The CPU module executes programs whose execution type has been set here according to the setting order 1) Initial execution type ("Initial") This program is executed only once when the CPU module is powered on or its status is switched...
  • Page 54 CHAPTER2 SEQUENCE PROGRAMS (c) File usability setting íç1 Note2.1 For each program, determine whether to use the file specified for the local device in the PLC file tab of the PLC parameter dialog box. Figure 2.17 File usability setting The default is set to "Use PLC file setting". When "Not used"...
  • Page 55 (3) Program sequence in the CPU module Figure 2.18 shows the program sequence after the CPU module is powered on or its operating status is changed from STOP to RUN. Powered off on/STOP Executed only once when Initial execution the CPU module is powered type program on or its status is switched from STOP to RUN.
  • Page 56: Initial Execution Type Program

    CHAPTER2 SEQUENCE PROGRAMS 2.3.1 Initial execution type program (1) Definition Initial execution type program is executed only once when the CPU module is powered on or its operating status is changed from STOP to RUN. This type of program can be used as a program that need not be executed from the next scan and later once it is executed, like initial processing to an intelligent function module.
  • Page 57 (b) Initial scan time Initial scan time is the execution time of initial execution type program. When multiple programs are executed, the initial scan time will be the time required for completing all the initial execution type program execution. 1) Initial scan time storage location The CPU module measures the initial scan time and stores it into the special register (SD522 and SD523).
  • Page 58 CHAPTER2 SEQUENCE PROGRAMS Initial execution monitoring time setting Initial execution monitoring time is a timer for monitoring initial scan time. Set a time value in the PLC RAS tab of the PLC parameter dialog box. The setting range is 10 to 2000ms (in increments of 10ms). No default value is set.
  • Page 59: Scan Execution Type Program

    2.3.2 Scan execution type program (1) Definition Scan execution type program is executed once in every scan, starting in the next scan of which the initial execution type program is executed and later. STOP Power supply ON 1st scan 2nd scan 3rd scan 4th scan END processing...
  • Page 60: Stand-By Type Program

    CHAPTER2 SEQUENCE PROGRAMS 2.3.3 Stand-by type program (1) Definition Stand-by type program is executed only when its execution is requested. This type of program can be changed to any desired execution type by a sequence program instruction. (2) Application (a) Program library Stand-by type program is used as a program library, a collection of subroutine programs and/or interrupt programs, and managed separately from a main routine program.
  • Page 61 (3) Execution method Execute stand-by type programs in either of the following methods. • Create subroutine and/or interrupt programs in a stand-by type program and call them using a pointer or when an interrupt occurs. • Change a stand-by type program to any other execution type using instructions. Creating subroutine and/or interrupt programs in a single stand-by type program When creating subroutine and/or interrupt programs in a single stand-by type program, start the program from the step 0.
  • Page 62 CHAPTER2 SEQUENCE PROGRAMS 1) Executing a subroutine program and interrupt program in a stand-by type program After execution of the stand-by type program, the CPU module reexecutes the program that called a program in the stand-by type program. Figure 2.26 shows the operation when the subroutine and interrupt programs in the stand-by type program are executed.
  • Page 63 (b) Changing the program execution type using instructions Use the PSCAN, PSTOP, or POFF instruction to change a program execution type. 1) Changing the execution type (in the case of scan execution type program) • Set the programs "ABC" and "GHI" as scan execution type programs and the program "DEF" as a stand- by type program.
  • Page 64 CHAPTER2 SEQUENCE PROGRAMS 2) Execution type change timing The program execution type is changed in END processing. Therefore, the execution type will not be changed in the middle of program execution. If different types are set to the same program in the same scan, the program will be changed to the type specified by the last instruction executed.
  • Page 65: Fixed Scan Execution Type Program

    2.3.4 Fixed scan execution type program (1) Definition Fixed scan execution type program is a program executed at specified time intervals. This type of programs, unlike interrupt programs, can be interrupted in units of files without interrupt pointers or the IRET instruction. For the restrictions on programming, refer to Section 2.2.3(2)(d).
  • Page 66 CHAPTER2 SEQUENCE PROGRAMS (2) Processing (a) When two or more fixed scan execution type programs exist Each fixed scan execution type program is executed at specified time intervals. If two or more fixed scan execution type programs reach the specified time at the same timing, programs will be executed in ascending order of the numbers set in the Program tab of the PLC parameter dialog box.
  • Page 67 (d) When the execution condition is established during END processing When the execution condition is established during the waiting time of the constant scan execution or the END instruction, a fixed scan execution type program is executed. Constant scan Fixed scan interval END processing Condition established...
  • Page 68 CHAPTER2 SEQUENCE PROGRAMS (4) Precautions (a) Execution interval of a fixed scan execution type program Execution interval of a fixed scan execution type program may increase from the preset interval depending on the time set for disabling interrupts by the DI instruction (interrupt disabled time). If the interrupt disabled time by the DI instruction becomes too long, use an interrupt program by fixed scan interrupt (I28 to I31) instead of a fixed scan execution type program.
  • Page 69: Changing The Program Execution Type

    2.3.5 Changing the program execution type Changing the execution type using instructions (a) Instructions used to change the execution type The execution type of sequence programs can be changed using instructions even during execution. Use the PSCAN, PSTOP, or POFF instruction to change the execution type. PSCAN instruction Scan execution...
  • Page 70 CHAPTER2 SEQUENCE PROGRAMS Execution type change example In a control program, a stand-by type program matching the preset condition is changed to a scan execution type program in the course of program execution. An unused scan execution type program can also be changed to a stand-by type program. shows the case where the execution type of the stand-by type programs "ABC", "DEF", Figure 2.34 "GHI", and "JKL"...
  • Page 71: Data Used In Sequence Programs

    2.4 Data Used in Sequence Programs The CPU module represents numeric and alphabetic data using two symbols (states): 0 (off) and 1 (on). Data represented using these two symbols is called binary number (BIN). The CPU module can also use hexadecimal (HEX) (each hexadecimal digit represents four binary bits), binary-coded decimal (BCD), or real numbers.
  • Page 72 CHAPTER2 SEQUENCE PROGRAMS (1) Inputting numeric values externally to the CPU module When setting a numeric value to the CPU module externally using a digital switch, BCD (binary-coded decimal) can be used as DEC (decimal) by the method given in (b). (a) Numeric values used inside the CPU module The CPU module performs program operations in binary.
  • Page 73 (2) Outputting numeric values externally from the CPU module When externally displaying numeric values operated in the CPU module, a digital indicator can be used. (a) Outputting numeric values The CPU module performs program operations in binary. If the binary values used in the CPU module are output to a digital indicator, the indicator does not show the values correctly.
  • Page 74: Bin (Binary Code)

    CHAPTER2 SEQUENCE PROGRAMS 2.4.1 BIN (Binary Code) (1) Definition Binary is a numeral system that represents numeric values using two symbols, 0 (off) and 1 (on) Decimal notation uses the symbols 0 through 9. When the symbols for the first digit are exhausted (a digit reaches 9), the next-higher digit (to the left) is incremented, and counting starts over at 0.
  • Page 75 (2) Numeric representation in BIN (a) Bit configuration of BIN used in the CPU module Each register (such as the data register, link register) in the CPU module consists of 16 bits. (b) Numeric data available in the CPU module Each register in the CPU module can store numeric values in the range of -32768 to 32767.
  • Page 76: Hex (Hexadecimal)

    CHAPTER2 SEQUENCE PROGRAMS 2.4.2 HEX (Hexadecimal) (1) Definition Hexadecimal (HEX) is a numeral system that represents four binary bits as one digit. With four binary bits, sixteen different numeric values, 0 to 15, can be represented. Hexadecimal notation uses 16 symbols to represent numeric values 0 to 15 in one digit, the symbols 0 to 9 to represent values zero to nine, and A to F to represent values ten to fifteen.
  • Page 77: Bcd (Binary-Coded Decimal)

    2.4.3 BCD (Binary-coded Decimal) (1) Definition BCD is a numeral system that uses four binary bits to represent the decimal digits 0 through 9. The difference from hexadecimal is that BCD does not use letters A to F. shows the numeric representations in BIN, BCD, and DEC. Table2.5 Table2.5 Numeric representations in BIN,BCD,and DEC DEC (Decimal)
  • Page 78: Real Number (Floating-Point Data)

    CHAPTER2 SEQUENCE PROGRAMS 2.4.4 Real number (Floating-point data) There are two types of real number data: single-precision floating-point data and double-precision floating-point data. (1) Single-precision floating-point data (a) Internal representation Internal representation of real numbers used in the CPU module is given below. Real number data can be represented as follows, using two word devices.
  • Page 79 (b) Calculation example Calculation examples are shown below. (The "X" in (nnnnnn) indicates the numeral system used.) 1) Storing "10" (10) (1010) (1.010000..Sign: Positive Exponent: (10000010) Mantissa: (010 00000 00000 00000 00000) In this case, the value will be encoded as 41200000 Sign Exponent Mantissa...
  • Page 80 CHAPTER2 SEQUENCE PROGRAMS (2) Double-precision floating-point data (a) Internal representation Real number data used in the CPU module is internally represented as follows, using four word devices. [Exponent] [Sign] 1. [Mantissa] The bit configuration and the meaning of each bit are described below b52 to b62 b0 to b51 Exponent (11 bits)
  • Page 81 (b) Calculation example Calculation examples are shown below. (The "X" in (nnnnnn) indicates the numeral system used.) Storing "10" (10) (1010) (1.010000..Sign: Positive Exponent: (100 0000 0001) Mantissa: 0100 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 In this case, the value will be encoded as 4014000000000000 Sign Exponent...
  • Page 82: Character String Data

    CHAPTER2 SEQUENCE PROGRAMS 2.4.5 Character string data (1) Definition The CPU module uses ASCII code data. (2) ASCII code character strings Table2.6 lists the ASCII code character strings. "00 " (NULL code) in Table2.6 is used at the end of a character string as a terminator. Table2.6 ASCII code character strings Column b1 Low...
  • Page 83: Chapter3 Cpu Module Operation

    CHAPTER3 CPU MODULE OPERATION This section describes operation of the CPU module. 3.1 Initial Processing The CPU module performs preprocessing required for sequence program operations. The preprocessing is executed only once when any of the operations described in is performed to Table3.1 the CPU module.
  • Page 84: I/O Refresh (Refresh Processing With Input/Output Modules)

    CHAPTER3 CPU MODULE OPERATION 3.2 I/O Refresh (Refresh Processing with Input/Output Modules) The CPU module performs the following before sequence program operations. • On/off data input from the input module or intelligent function module to the CPU module • On/off data output from the CPU module to the output module or intelligent function module When the constant scan time is set, I/O refresh is performed after the constant scan waiting time has elapsed.
  • Page 85: Operation Processing In The Run,Stop, Or Pause Status

    3.5 Operation Processing in the RUN,STOP, or PAUSE Status There are three types of operating status of the CPU module. • RUN status • STOP status • PAUSE status This section describes program operation processing in the CPU module based on its operating status. (1) Operation processing in the RUN status RUN status is a status where sequence program operations are repeatedly performed in a loop between the step 0 and the END (FEND) instruction.
  • Page 86 CHAPTER3 CPU MODULE OPERATION Operation processing in the CPU module when switch operation is performed Table3.2 Operation processing when switch operation is performed CPU module operation processing RUN/STOP Device memory Sequence program status External output operation processing M,L,S,T,C,D The CPU module saves The CPU module saves The CPU module the output (Y) status...
  • Page 87: Operation Processing During Momentary Power Failure

    3.6 Operation Processing during Momentary Power Failure When the input voltage supplied to the power supply module drops below the specified range, the CPU module detects a momentary power failure and performs the following operation. (1) When a momentary power failure occurs for a period shorter than the allowable power failure time The CPU module registers error data and suspends the operation processing.
  • Page 88: Data Clear Processing

    CHAPTER3 CPU MODULE OPERATION Data Clear Processing This section describes how to clear data in the CPU module and the setting required for the latch data clear. (1) Clearing data in the CPU module Data in the CPU module are cleared when the reset operation (by the RUN/STOP/RESET switch or by powering the module off and then on) is performed.
  • Page 89 Latch specification of devices Set a latch range for each latch-target device in the Device tab of the PLC parameter dialog box. Section 6.3(5)) (a) Latch range setting Two kinds of latch range can be set by GX Developer. Latch clear operation enable range ("Latch (1) start/end") Data in this latch range can be cleared with the remote latch clear operation.
  • Page 90: I/O Processing And Response Delay

    CHAPTER3 CPU MODULE OPERATION I/O Processing and Response Delay The CPU module performs I/O processing in the refresh mode. Using the direct access input/output in a sequence program, however, allows the CPU module to perform I/O processing in the direct mode at the time of each instruction execution. This section describes these I/O processing modes of the CPU module and response delays.
  • Page 91: Refresh Mode

    3.8.1 Refresh mode (1) Definition Refresh mode is a mode for the CPU module to access input/output modules and perform I/O processing collectively before the start of sequence program operations. Input of on/off data by input refresh Device memory Output of on/off data by output refresh On/off data On/off...
  • Page 92 CHAPTER3 CPU MODULE OPERATION (3) Output The operation results of the sequence program is output to the output (Y) device memory in the CPU module every time program operation is performed. Then, the CPU module batch-outputs the on/off data in the output (Y) device memory to an output module before the start of sequence program operations.
  • Page 93 The remote input refresh area indicates the area to be used when auto refresh is set to the input (X) in the CC-Link IE controller network, MELSECNET/H, or CC-Link. Data in the remote input refresh area will be refreshed automatically during END processing. Data in the GX Developer input area can be turned on/off by the following operation.
  • Page 94: Direct Mode

    CHAPTER3 CPU MODULE OPERATION 3.8.2 Direct mode (1) Definition The direct mode is a mode for the CPU module to access input/output modules and performs I/O processing at the timing when each instruction is executed in a sequence program. Input of on/off data upon instruction execution Device memory Output of on/off data upon...
  • Page 95 CPU module Remote Network input refresh CPU (operation module area processing area) Input Developer module Input (X) input area device memory Output (Y) Output device module DY25 memory •When a contact instruction for input is executed: The CPU module performs a logical OR operation between input data from the input module (1)) and input data in the GX Developer input area (2)) or data in the remote input refresh area.
  • Page 96 CHAPTER3 CPU MODULE OPERATION (2) Response delay An output response which corresponds to the status change in the input module delays for one scan (maximum) depending on the on timing of an external contact. Examples A program that turns on the output DY5E DY5E when the input DX5 turns on.
  • Page 97: Chapter4 Assignment Of Base Unit And I/Onumber

    CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER This chapter describes the base unit and I/O number assignment required for the CPU module to communicate data with I/O modules and/or intelligent function modules. 4.1 Base Unit Assignment 4.1.1 Base mode Use this mode when assigning the number of available slots to the main base unit and extension base units.
  • Page 98: Base Unit Assignment Setting

    CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER (b) Setting the number of slots smaller than the actual one Set the smaller number than the actual number of slots when slots with no module mounted need not be recognized. For example, four slots from the right end of the base unit will be the prohibited slots when using a 12-slot base unit and setting the number of available slots to eight.
  • Page 99 (3) Power model name Enter the model name of the mounted power supply module within 16 characters. CPU modules do not use entered model names. (Use the entered model names for user reference or when printing out parameters.) (4) Extension cable Enter the connected extension cable name within 16 characters.
  • Page 100: I/O Number Assignment

    CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER 4.2 I/O Number Assignment The I/O number indicates addresses used for sequence programs in the following cases. • Input of on/off data to the CPU module • Output of on/off data from the CPU module to the external device (1) Input and output of on/off data The input (X) is used to input on/off data to the CPU module, and the output (Y) is used to output on/ off data from the CPU module.
  • Page 101: Concept Of I/O Number Assignment

    4.2.1 Concept of I/O number assignment The CPU module assigns I/O numbers at power on or reset, according to the I/O assignment setting. (1) I/O number assignment The Figure 4.5 shows an example of I/O number assignment to base units in the system where the CPU module is mounted on the main base unit.
  • Page 102 CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER (2) I/O assignment on a remote I/O stations CPU module device input (X) and output (Y) can be assigned to I/O modules and intelligent function modules, which allows to control the modules in the remote I/O system such as MELSECNET/H remote I/O network and CC-Link.
  • Page 103 (b) Precautions for using remote station I/O numbers 1) Setting for future extension When the input (X) and output (Y) of the CPU module are used for the I/O numbers on the remote station, consider future extension of I/O modules and/or intelligent function modules on the CPU module side Input/output (X/Y) X/Y0...
  • Page 104: Setting I/O Numbers

    CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER 4.2.2 Setting I/O numbers Set the I/O number on the I/O assignment tab. (1) Purpose of I/O number assignment (a) Reserving points for future module changes The number of points can be reserved to prevent the I/O number modification when the current module is changed in the future to the one with the different number of occupied I/O points.
  • Page 105 (2) I/O assignment The I/O assignment is set on the I/O assignment tab of the PLC parameter dialog box. On the I/O assignment tab, the following items can be set for each slot on the base unit. • "Type" (module type) •...
  • Page 106 CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER (b) Type Select the type of the mounted module from the followings: • Empty (empty slot) • Input (input module) • Hi input (high-speed input module) • Output (output module) • I/O Mix (I/O combined module) •...
  • Page 107 (3) Precautions (a) Type setting The type set to the I/O assignment tab must be the same as that of the mounted module. Setting a different type may cause incorrect operation. For the intelligent function module, the I/O points must also be the same in addition to the I/O assignment setting.
  • Page 108 CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER (c) Start XY setting The CPU module When the start XY has not been entered, the CPU module automatically assigns it. automatically assigns the start XY if it is not set. For this reason, the start XY setting of each slot may be duplicated with the one assigned by the CPU module in the case of 1) or 2) below.
  • Page 109: I/O Number Setting Example

    4.2.3 I/O number setting example I/O number setting examples are provided as follows. (1) Changing the number of points of an empty slot from 16 to 32 Reserve 32 points for the currently empty slot (Slot 3) so that the I/O numbers of Slot No. 4 and later do not change when a 32-point input module is mounted there in the future.
  • Page 110 CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER (b) I/O assignment Select "32 points" for the number of I/O points of Slot 3 in the I/O assignment setting of PLC parameter in GX Developer. Select 32 points. (When the type is not selected, the type of the mounted module will be set.) Figure 4.12 I/O assignment setting (When changing points of Slot 3)
  • Page 111 (2) Changing the I/O number of an empty slot Change the I/O number of the currently empty slot (Slot 3) to X200 through 21F so that the I/O numbers of Slot 4 and later do not change when a 32-point input module is mounted there in the future.
  • Page 112 CHAPTER4 ASSIGNMENT OF BASE UNIT AND I/O NUMBER (b) I/O assignment Set "200" for the start XY of Slot 3 and "70" to Slot 4 in the I/O assignment setting of PLC parameter in GX Developer. Set "200" to start XY. Set "70"...
  • Page 113: Checking I/O Numbers

    I/O number assignment after the I/O assignment using GX Developer Q38B Slot number 32 points 32 points 32 points 32 points 32 points 32 points 32 points 32 points Number of I/O points X00 X20 X200 Y70 Y90 YB0 YD0 I/O number X1F X3F X5F X21F...
  • Page 114: Chapter5 Memories And Files Used For Cpu Module

    CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE 5.1 Memories Used for CPU Module 5.1.1 Memory composition and storable data This section describes the memories used for the Universal model QCPU and data that can be stored in the memories.
  • Page 115 (a) Program memory ( Section 5.1.2) This memory is for storing programs and parameters for CPU module operation. The CPU module transfers a program from the program memory to the program cache memory for operation. Section 5.1.3) (b) Standard ROM ( Section 5.1.4) This memory is for storing data such as parameters and programs.
  • Page 116 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE Data that can be stored in each memory provides the data that can be stored in each memory Table5.1 Table5.1 Storable data and storage location Memory Memory card CPU module built-in memory (ROM) card ( RAM)
  • Page 117 (3) Memory capacities and necessity of formatting provides the memory capacities and necessity of formatting of each memory Table5.2 Format a memory requiring formatting by GX Developer beforehand. Table5.2 Memory capacities and necessity of formatting Q03UDCPU, Q04UDHCPU, Q00UJCPU Q00UCPU Q01UCPU Q02UCPU Formatting Q03UDECPU...
  • Page 118: Program Memory

    CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE 5.1.2 Program memory (1) Definition This memory is for storing programs and parameters for CPU module operation. The CPU module transfers a program from the program memory to the program cache memory for operation.
  • Page 119 When a user setting system area is created, the available area reduces by the number of steps created in the area. Checking the memory capacity after formatting Select [Online] [Read from PLC] in GX Developer. 1) Select "Program memory/Device memory" in “Target memory” on the Read from PLC screen. Click the button.
  • Page 120 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE Writing to the program memory Select [Online] [Write to PLC] in GX Developer Select "Program memory/Device memory" in “Target memory” on the Write to PLC screen Figure 5.4 Write to PLC screen The file size has its minimum unit.
  • Page 121: Program Cache Memory

    5.1.3 Program cache memory (1) Definition This memory is for program operation The CPU module transfers a program from the program memory to the program cache memory for operation. The program is transferred from the program memory to the program cache memory during: •...
  • Page 122 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE Writing a program When writing data from GX Developer, programs and parameters are written to the program cache memory in the CPU module. After the completion of the writing, the data are transferred to the program memory. Figure 5.6 provides the flow of writing a program.
  • Page 123 (4) Checking status during data transfer to the program memory The status during data transfer to the program memory can be checked either in the progress screen of GX Developer or by the special relay and special register. (a) Checking the status in the progress screen Figure 5.7 provides the progress screen of GX Developer Figure 5.7 Screen showing status of data transfer to the program memory (b) Checking the status by the special relay and special register...
  • Page 124: Standard Rom

    CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE 5.1.4 Standard ROM (1) Definition This memory is for storing data such as parameters and programs. (2) Checking the memory capacity Select [Online] [Read from PLC] in GX Developer 1) Select "Standard ROM" in “Target memory” on the Read from PLC screen. Click the button.
  • Page 125: Standard Ram

    5.1.5 íç1 Standard RAM Note5.2 (1) Definition This memory is for using file registers, local devices, and sampling trace files without a memory card. Storing the file registers in the standard RAM allows fast access as data registers do. If the size of files to be stored exceeds the standard RAM capacity: •...
  • Page 126 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (b) Checking the memory capacity after formatting Select [Online] [Read from PLC] in GX Developer. 1) Select "Standard RAM" in “Target memory” on the Read from PLC screen. Click the button. Free space volume The memory capacity appears in “Total free space volume”.
  • Page 127: Memory Card

    5.1.6 Note5.3 íç1 Memory card Definition This memory is for expansion of a memory in the CPU module. The following three types are available: • SRAM card • Flash card • ATA card (a) SRAM card File registers in the SRAM card can be written or read by the sequence program. The SRAM card is used when: •...
  • Page 128 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (2) Before using the SRAM card or ATA card Format the SRAM card or ATA card by GX Developer. (a) Formatting Select [Online] [Format PLC memory] in GX Developer. • When formatting the SRAM card, select "Memory card (RAM)" in “Target memory”. •...
  • Page 129 Checking the memory capacity after formatting Select [Online] [Read from PLC] in GX Developer. 1) Select "Memory card (RAM)" or "Memory card (ROM)" in “Target memory” on the Read from PLC screen. 2) Click the button. Free space volume 3) The memory capacity appears in “Total free space volume”. 1) Select the target memory.
  • Page 130 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (b) Writing to the Flash card The following two methods are available. • Writing by "Write the program memory to ROM" ( Section 5.1.7(1)(a)) • Writing by "Write to PLC (Flash ROM)” ( Section 5.1.7(1)(b)) The file size has its minimum unit.
  • Page 131: Writing To The Flash Card By Gx Developer

    5.1.7 Writing to the Flash card by GX Developer (1) Methods for writing data to the Flash card and applications Figure 5.15 provides the methods for writing data to the Flash card. Writing by "Write the program memory to ROM" Program memory Writing by "Write to PLC...
  • Page 132 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (2) Writing to the Flash card The following describes the operations before writing and the methods for writing. (a) Before writing Check the following. 1) Preparing files to be written Writing a file to the Flash card automatically deletes all files stored in the Flash card. Also write all files same as the stored files together.
  • Page 133 2) Procedure using [Write to PLC (Flash ROM)] in GX Developer • Select [Online] [Write to PLC (Flash ROM)] [Write to PLC (Flash ROM)]. • The Write to PLC (Flash ROM) screen appears. Figure 5.17 Write to PLC (Flash ROM) screen •...
  • Page 134 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (4) Precautions (a) Setting the communication time check period in GX Developer Since writing a file to the Flash card takes time, set "Check at communication time" in GX Developer to 60 seconds or longer.
  • Page 135 (c) Time required for “Write to PLC (Flash ROM)” Using "Write to PLC (Flash ROM)” writes data to the entire space in the Flash card. Therefore, even if a program having the small number of steps is written to the Flash card, the processing takes time.
  • Page 136: Operating The Program In The Memory Card (Boot Operation)

    CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE 5.1.8 Operating the program in the memory card (boot operation) This section describes methods for operating the program stored in the memory card. (1) Operating the program in the memory card To operate the program stored in the memory card, make setting so that the program is booted to the program memory after the CPU module is powered off and then on or is reset.
  • Page 137 (3) Procedure before boot operation (a) Creating a program Create a program for boot operation. (b) Boot file setting by GX Developer Set the names of files to be booted to the program memory in the Boot file tab of the PLC parameter dialog box.
  • Page 138 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (4) Operation for stopping boot operation To stop boot operation and operate the CPU module by the parameters and program files written to the program memory, perform the following operations. 1) Remove the memory card and write parameters without boot file setting to the program memory by GX Developer.
  • Page 139 (d) Boot operation when the ATA card is used When data are booted from the ATA card, the processing time of maximum 200ms may be required per 1K step (4K bytes). (e) When data in the program memory are changed after the CPU module is powered off and then on or is reset If the program memory data are changed after the sequence program is written to the program memory and the CPU module is powered off and then on or is reset, a boot operation may be active.
  • Page 140: Details Of Written Files

    CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE 5.1.9 Details of written files For each file written to the CPU module, its name, size, and created date and time set at the file creation are appended. The file is displayed on the Read from PLC screen, opened by selecting [Online] [Read from PLC] in GX Developer, as shown below.
  • Page 141: Specifying Valid Parameters (Parameter-Valid Drive Setting)

    5.1.10 Specifying valid parameters (parameter-valid drive setting) Drives (memories) storing valid parameters are automatically specified by the system. The valid parameters are determined by the priority of the drives where parameters are stored. Settings by an user is unnecessary. (1) Priority of the parameter-valid drives Table5.6 provides the priority of the drives where parameters are stored.
  • Page 142 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (2) When to determine valid parameters The CPU module automatically searches for parameters in the following timing and operates by the settings of the parameters stored in the drives when: • the CPU module is powered off and then on, or •...
  • Page 143: Program File Structure

    Program File Structure A program file consists of a file header, execution program, and reserved area for online change. Program file structure 34 steps File header (By default) Execution program These areas are reserved in units of file sizes. ( Section 5.3.4) Reserved area for 500 steps...
  • Page 144 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE screen Displaying the program capacity on the GX Developer During programming by GX Developer, the program size (total of the file header size and the number of steps in the created program) is displayed by the number of steps as shown in Figure 5.25. The program size is displayed.
  • Page 145: File Operations By Gx Developer And Handling Precautions

    File Operations by GX Developer and Handling Precautions 5.3.1 File operations Table5.7 shows the functions can be performed to files stored in the program memory, standard ROM, and memory card by the online functions of GX Developer. However, the executable operations depends on the password registration setting by GX Developer and CPU module status (RUN/STOP).
  • Page 146: Precautions For Handling Files

    CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE 5.3.2 Precautions for handling files (1) Power-off or reset at file operation When the CPU module is powered off or reset at file operation, files in each memory are held (for a memory card, when the CPU module where a memory card has been mounted before power-off is powered on).
  • Page 147: File Size

    5.3.3 File size The size of a file used for the CPU module depends on the file type. When a file is written to the memory area, the unit of the stored file depends on the CPU module and memory area to be written.
  • Page 148 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE Table5.8 Calculation of file size(continued) Rough file capacity (unit: Byte) Function 362 + (number of word device points + number of bit device points) 12 + (N1 + N2 + N3 + number of word device points 2 + (number of bit device points/16) the number of traces (total number of...
  • Page 149: Units Of File Sizes

    5.3.4 Units of file sizes (1) Definition When a file is written to the memory area, the unit of the stored file depends on the CPU module and memory area to be written. This unit is referred to as a file size unit. for each memory area File size unit The following table shows the file size unit depending on the CPU module and memory area to be written.
  • Page 150 CHAPTER5 MEMORIES AND FILES USED FOR CPU MODULE (2) Calculation example of memory capacity The following shows an calculation example of memory capacity when the parameters and sequence program are written to the program memory. (a) Conditions 1) CPU module to be written: Q26UDHCPU 2) Writing file Table5.11 File sizes File name...
  • Page 151 2) Calculation of program size The program size is found by the formula: sequence program size + reserved area for online change. Since a program is stored in units of file sizes (1 step), only the amount equal to the program size is occupied. 3) Result The calculation results of the memory capacities are as shown below.
  • Page 152: Chapter6 Functions

    CHAPTER6 FUNCTIONS CHAPTER6 FUNCTIONS This chapter describes the functions of the Universal model QCPU. Function List Table6.1 lists the functions of the Universal model QCPU. Table6.1 Function list Built-in Q00UJ Q00UCPU, Q02U QnUD(H) Item Description Reference Ethernet Q01UCPU port QCPU Executes a program in a set time interval Constant scan Section 6.2...
  • Page 153 Table6.1 Function list (Continued) Built-in Q00UJ Q00UCPU, Q02U QnUD(H) Item Description Reference Ethernet Q01UCPU port QCPU Makes settings for the intelligent function modules and interrupt Switch setting of intelligent Section modules. (Refer to manuals of function module 6.10 intelligent function modules and interrupt modules for setting details.) Reads the status of programs and Section...
  • Page 154 CHAPTER6 FUNCTIONS Table6.1 Function list (Continued) Built-in Q00UJ Q00UCPU, Q02U QnUD(H) Item Description Reference Ethernet Q01UCPU port QCPU Prohibits writing/reading data to/from Section Password registration each file in the CPU module using GX 6.19.1 Developer. Prevents illegal access from external Section Remote password sources with serial communication...
  • Page 155: Constant Scan

    6.2 Constant Scan (1) Definition Scan time of the CPU module is not constant because the processing time varies depending on the execution status of instructions used in a sequence program. This function allows sequence programs to be executed repeatedly, maintaining its scan time constant.
  • Page 156 CHAPTER6 FUNCTIONS (3) Constant scan time setting Set a constant scan time value in the PLC RAS tab of the PLC parameter dialog box. The setting range is 0.5 to 2000ms (in increments of 0.5ms). When not executing the constant scan function, leave the constant scan time setting box blank Set a constant scan time value here.
  • Page 157 (4) Waiting time from when END processing is executed until next scan starts Sequence program processing is stopped during the waiting time from when END processing of a sequence program is executed until next scan starts. (a) When an interrupt factor occurs during waiting time Either of the following programs is executed •...
  • Page 158: Latch Function

    CHAPTER6 FUNCTIONS 6.3 Latch Function (1) Definition Data in each device of the CPU module is cleared and set back to its default (bit device: off, word device: 0) when; • the CPU module is powered off and then on, •...
  • Page 159 (5) Latch range setting Set a latch range in the Device tab of the PLC parameter dialog box. There are two types of latch ranges: the latch clear operation enable range (Latch (1)) and the latch clear operation disable range (Latch (2)) Figure 6.4 Latch range setting The latch range of the file register (ZR), extended data register (D), and extended link register (W) can also be set.
  • Page 160 CHAPTER6 FUNCTIONS (6) Device data latch method and influence on the scan time Data latch processing is performed during END processing. For this reason, the scan time increases. Consider an influence on the scan time when latching devices. ( Section 10.1.2 To shorten the scan time due to latch, minimize the number of latch points (latch (1) setting, latch (2) setting, and latch relay (L)) as much as possible.
  • Page 161: Output Mode At Operating Status Change (Stop To Run)

    Output Mode at Operating Status Change (STOP to RUN) (1) Definition When the operating status is changed from RUN to STOP, the CPU module internally stores the outputs (Y) in the RUN status and then turns off all the outputs (Y). The status of the outputs (Y) when the operating status of the CPU module is changed back from STOP to RUN can be selected from the following two options in the parameter setting in GX Developer.
  • Page 162 CHAPTER6 FUNCTIONS (3) Operation when the operating status is changed from STOP to RUN (a) Previous state (Default) The CPU module outputs the output (Y) status immediately before changing to the STOP status and then performs sequence program operations. (b) Recalculate (output is 1 scan later) All outputs are turned off.
  • Page 163 (5) Precautions shows the output status of the CPU module when the operating status is changed from STOP Table6.3 to RUN after the outputs (Y) are forcibly turned on in the STOP status. Table6.3 Output status when the operating status is changed from STOP to RUN after the output forced on operation is performed Output mode ("Output mode at STOP to RUN") selected Output status The output status prior to STOP is output.
  • Page 164: Clock Function

    CHAPTER6 FUNCTIONS 6.5 Clock Function (1) Definition This function reads the internal clock data of the CPU module by a sequence program and uses it for time management The clock data is used for time management required for some functions in the system, such as storing date into the error history.
  • Page 165 (4) Changing and reading clock data Changing clock data Clock data can be changed either by GX Developer or a program. 1) Changing clock data by GX Developer Select [Online] [Set time] to open the Set time screen and change the clock data. Figure 6.11 Set time screen 2) Changing clock data by a program Use the DATEWR instruction (instruction for writing clock data) to change the clock data.
  • Page 166 CHAPTER6 FUNCTIONS Reading clock data To read clock data to the data register, use either of the following instructions in the program. • DATERD (instruction for reading clock data) • S(P).DATERD (instruction for reading extended clock data) shows a program for storing the clock data read with the DATERD instruction to D10 to Figure 6.13 D16.
  • Page 167 (5) Precautions (a) Initial clock data setting No clock data is set at the factory. Clock data is required for some functions of the CPU module used in the system, such as error history storage, or for intelligent function modules. Before using the CPU module for the first time, set the time correctly.
  • Page 168: Remote Operation

    CHAPTER6 FUNCTIONS 6.6 Remote Operation Remote operation allows to change the operating status of the CPU module externally (by GX Developer or external devices using the MC protocol, with link dedicated instructions of the CC-Link IE controller network module or MELSECNET/H module, or using remote contacts). There are four types of remote operations: •...
  • Page 169 (4) Executing method There are three methods for performing the remote RUN/STOP operation. • Using a RUN contact • By GX Developer or an external device using the MC protocol • With link dedicated instructions of the CC-Link IE controller network module or MELSECNET/H module (a) Using a RUN contact Set a RUN contact in the PLC system tab of the PLC parameter dialog box.
  • Page 170 CHAPTER6 FUNCTIONS (c) With link dedicated instructions of the CC-Link IE controller network module or MELSECNET/H module The remote RUN/STOP operation by link dedicated instructions of the CC-Link IE controller network module or MELSECNET/H module can change the RUN/STOP status of the CPU module. For details, refer to the following.
  • Page 171: Remote Pause

    6.6.2 Remote PAUSE (1) Definition This operation changes the operating status of the CPU module externally to PAUSE, keeping the RUN/STOP/RESET switch of the CPU module in the RUN position. PAUSE status is a status where sequence program operations in the CPU module are stopped, holding the status (on or off) of all outputs (Y).
  • Page 172 CHAPTER6 FUNCTIONS (b) By GX Developer or an external device using the MC protocol Select [Online] [Remote operation] in GX Developer. To perform the remote PAUSE operation from an external device, use the MC protocol command. Q Corresponding MELSEC Communication Protocol Reference Manual The PAUSE contact (SM204) turns on during END processing of the scan where the remote •...
  • Page 173: Remote Reset

    6.6.3 Remote RESET (1) Definition This operation resets the CPU module externally when the CPU module is in the STOP status. Even if the RUN/STOP/RESET switch is in the RUN position, this operation can be performed when the module is stopped due to an error detected by the self-diagnostics function. (2) Application This operation is useful to reset the CPU module remotely when an error occurs in the CPU module placed in an inaccessible location.
  • Page 174 CHAPTER6 FUNCTIONS (4) Precautions (a) Remote RESET in the RUN status When the CPU module is in the RUN status, the remote RESET operation cannot be performed. To perform the operation, change the operating status of the CPU module to STOP by the remote STOP or similar operation.
  • Page 175: Remote Latch Clear

    6.6.4 Remote latch clear (1) Definition This function resets the latched device data from GX Developer or an external device when the CPU module is in the STOP status. (2) Application This function is useful in the following cases if used together with the remote RUN/STOP operation. •...
  • Page 176: Relationship Between Remote Operation And Run/Stop Status Of The Cpu Module

    CHAPTER6 FUNCTIONS 6.6.5 Relationship between remote operation and RUN/STOP status of the CPU module (1) Relationship between remote operation and RUN/STOP status of the CPU module Table6.7 shows the operating status of the CPU module according to the combination of remote operation and RUN/STOP status.
  • Page 177: Q Series-Compatible Module Input Response Time Selection (I/O Response Time)

    6.7 Q Series-compatible Module Input Response Time Selection (I/O Response Time) (1) Definition This function changes the input response time for each Q series-compatible module. shows the modules available for input response time change and selectable time settings. Table6.8 Table6.8 Modules available for input response time change Module name Type Settable time setting...
  • Page 178 CHAPTER6 FUNCTIONS (2) Input response time setting Set input response time values in the I/O assignment tab of the PLC parameter dialog box. Make I/O assignment for the target module Click the button. Detailed setting On the screen opened, select an input response time value (“I/O response time”). 1) Make I/O assignment.
  • Page 179: Error Time Output Mode Setting

    Error Time Output Mode Setting (1) Definition This function determines the output mode (clear or hold) from the CPU module to the Q series- compatible output modules, I/O combined modules, intelligent function modules, and/or interrupt module when a stop error occurs in the CPU module. (2) Error time output mode setting Set the error time output mode in the I/O assignment tab of the PLC parameter dialog box.
  • Page 180: H/W Error Time Plc Operation Mode Setting

    CHAPTER6 FUNCTIONS H/W Error Time PLC Operation Mode Setting (1) Definition This function determines the program operation mode (stop or continue) of the CPU module when a hardware error occurs in an intelligent function module or interrupt module. (2) H/W error time PLC operation mode setting Set the H/W error time PLC operation mode in the I/O assignment tab of the PLC parameter dialog box.
  • Page 181: Intelligent Function Module Switch Setting

    6.10 Intelligent Function Module Switch Setting (1) Definition This function sets the switches of each Q series-compatible intelligent function module and interrupt module in GX Developer. (2) Writing the switch settings The switch settings will be written from the CPU module to each intelligent function module and interrupt module when: •...
  • Page 182 CHAPTER6 FUNCTIONS (3) Switch settings Set the switch details for each intelligent function module and interrupt module in the I/O assignment tab of the PLC parameter dialog box. Make I/O assignment for the target module Click the button. Switch setting Set the switch details for each module.
  • Page 183: Monitor Function

    6.11 Monitor Function (1) Definition This function reads program and device data in the CPU module, and intelligent function module status using GX Developer. Table6.9 List of monitor functions and availability Availability Built-in Monitor function Reference Q00UJ Q00UCPU, QnUD(H) Q02UCPU Ethernet Q01UCPU port QCPU...
  • Page 184: Monitor Condition Setting

    CHAPTER6 FUNCTIONS 6.11.1 Monitor condition setting Note6.1 This function is used to monitor data in the CPU module under the specified condition. íç1 (1) Monitor condition setting for ladder monitor Switch GX Developer into monitor mode. Select [Online] [Monitor] [Monitor condition setup] to open the Monitor condition screen. Set the condition as shown below to monitor data on the rising edge of Y70.
  • Page 185 ● If a step between the AND/OR blocks is specified as a monitor condition, monitor data is collected when the status previous to execution of the specified step is specified by the LD instruction. The monitor timing depends on the step specified as a monitor condition. The following shows examples of monitoring when the step 2 is on (Step No.
  • Page 186 CHAPTER6 FUNCTIONS (b) When only a device is specified Either word device or bit device can be specified. 1) When a word device is specified Monitor data is collected when the current value of the specified word device becomes the specified value. Enter the current value (in decimal or hexadecimal).
  • Page 187 (2) Monitor stop condition setting Set a monitor stop condition on the screen opened by selecting [Online] [Monitor] [Monitor stop condition setup]. Set the condition as shown in Figure 6.33 to stop a monitor operation on the rising edged of Y71. Figure 6.33 Monitor stop condition screen (a) When a device is specified Either word device or bit device can be specified.
  • Page 188 CHAPTER6 FUNCTIONS (3) Precautions (a) Files to be monitored When monitor conditions are set, GX Developer monitors the file displayed on the screen. Select [Online] {Read from PLC] in GX Developer and read data from the CPU module so that the file name in the CPU module to be monitored matches the file named displayed on the screen of GX Developer.
  • Page 189 (i) During monitor condition registration Do not reset the CPU module while monitoring conditions are being registered. (j) Monitor operation with monitor condition setting When monitor operation with monitor condition setting is performed, other applications on the same personal computer cannot execute any online function using the same route for the monitor operation. The following applications must be noted.
  • Page 190: Local Device Monitor/Test

    CHAPTER6 FUNCTIONS 6.11.2 Local device monitor/test Note6.2 This operation is useful for debugging a program, monitoring local devices ( Section 9.14.2) in the program monitored by GX Developer. íç1 (1) Monitoring a local device Table6.10 shows the monitor operation when the CPU module executes three programs "A", "B", and "C" and D0 to D99 are set as a local device.
  • Page 191 When local devices are set to be monitored and the program "B" is displayed for monitoring, the local device(s) used in the program "B" can be monitored. CPU module Program execution (A MOVP K2 DO Program: A MOVP K3 D99 MOVP K4 DO Program: B MOVP K8 D99...
  • Page 192 CHAPTER6 FUNCTIONS (2) Monitoring procedure The following shows the local device monitoring procedure. Connect a personal computer to the CPU module. Display a program in ladder mode. Select [Online] Switching to the [Monitor] [Monitor mode]. monitor mode Select [Local device monitor] Setting of the local from the monitor window.
  • Page 193: External Input/Output Forced On/Off

    6.11.3 External input/output forced on/off Note6.3 The external input/output can forcibly be turned on/off on the screen opened by selecting [Online] [Debug] [Forced input output registration/cancellation] in GX Developer.íç1 The information registered for forced on/off can be cancelled by an operation from GX Developer. Figure 6.36 Forced input output registration/cancellation screen (1) Input/output operation when a forced on/off operation is performed There are three kinds of forced on/off operations: forced on ("Set forced ON"), forced off ("Set forced OFF"), and...
  • Page 194 CHAPTER6 FUNCTIONS Figure 6.37 shows the input/output operation when a forced on/off operation is performed. Output forced on/off operation Y10 device forced off Y10 output Output refresh External output (off) (Y10 off) Input refresh X0 input (on) External input Input forced on/off operation (X0 on) X0 device forced off Program execution...
  • Page 195 (d) Cancelling on/off registration data The registered forced ON/OFF data can be canceled by GX Developer. Once the registered data is canceled, the status of the forced on/off registered devices will be as follows. Table6.12 Status of devices after forced on/off registration data is canceled Sequence program operations Sequence program operations Forced on/off registered device...
  • Page 196 CHAPTER6 FUNCTIONS (f) Number of registerable devices Forced on/off can be registered for 32 devices in total. (g) When output Y contact is used in a sequence program On/off operations in a sequence program are given priority. (h) Checking forced on/off registration status Forced on/off execution status can be checked by: •...
  • Page 197 (3) Operating procedure Operating procedure is described below. • To register forced on/off for a device, select [Online] [Debug] [Forced input output registration/ cancellation] in GX Developer. • On the screen opened, specify a device and click the "Set forced ON" or "Set forced OFF" button. Figure 6.38 Forced input output registration/cancellation screen Table6.14 Items on the Forced input output registration/cancellation screen Item...
  • Page 198: Executional Conditioned Device Test

    CHAPTER6 FUNCTIONS 6.11.4 Executional conditioned device testíç1 Note6.4 This function changes a device value within the specified step of a sequence program. This enables debugging of the specified ladder block without modifying the sequence program. *1: The executional conditioned device test is targeted for sequence programs only. (SFC programs are not supported.) (1) Operation of the executional conditioned device test A device value will be changed based on the registration data once after the executional conditioned device test setting is registered.
  • Page 199 (2) Available devices and number of settable devices Table6.15 Available devices and number of settable devices Number of settable Type Available device devices X, Y, M, L, B, F, SB, V, SM, T (contact), ST (contact), C (contact), J \X, J Bit device \B, J \SB, FX, FY, DX, and DY...
  • Page 200 CHAPTER6 FUNCTIONS (4) Operating instructions (a) Registering executional conditioned device test settings Select the registration target step number on the program editing screen in GX Developer. Then, select [Online] [Debug] [Executional conditioned device test] [Register executional conditioned device test]. Figure 6.41 Screen for registering executional conditioned device test settings Table6.16 Items on the screen for registering executional conditioned device test settings Setting range Item...
  • Page 201 ● When setting a word device with a different data type, a device is regarded as the same device. Example When a word device is set in the order of "D100 (16 bit integer)" and then "D100 (Real number (single precision))", "D100 (Real number (single precision))"...
  • Page 202 CHAPTER6 FUNCTIONS Note that there may be a case where a device value will not be changed depending on the execution timing even though the specified step is executed. The following instructions need to be noted when registering executional conditioned device test settings. •...
  • Page 203 4) Number of settings that can be registered simultaneously in one scan Eight executional conditioned device test settings can be registered into the CPU module simultaneously in one scan. When nine or more executional conditioned device test settings are to be registered simultaneously by GX Developer, they will be registered over multiple scans.
  • Page 204 CHAPTER6 FUNCTIONS (d) Checking executional conditioned device test settings Select [Online] [Debug] [Executional conditioned device test] [Check/disable executional conditioned device test]. Figure 6.45 Screen for checking executional conditioned device test settings Remark For the operating instruction of checking or disabling executional conditioned device test settings, refer to the following.
  • Page 205 (5) Precautions (a) Operations from multiple GX Developers Executional conditioned device test setting can be registered in the same CPU module from multiple GX Developers connected via network. Note, however, that if multiple executional conditioned device test settings are registered with the same device name in the same step, the registration data will be overwritten.
  • Page 206 CHAPTER6 FUNCTIONS 2) When the online change function is executed during execution of the executional conditioned device test The Online change function completes normally. If any executional conditioned device test setting has been registered in the program to be changed online, the corresponding setting will be disabled. (5)(e) in this section) 6 - 55...
  • Page 207 (e) Online change of the CPU module with executional conditioned device test registration 1) Online change (ladder mode) If any executional conditioned device test setting has been registered in the ladder block to be changed online, the CPU module disables the corresponding setting. Example 1) Step numbers of registrations 1 to 3 are specified in the executional conditioned device test settings.
  • Page 208 CHAPTER6 FUNCTIONS Example 3) When a ladder block is to be added online, the executional conditioned device test setting included in the ladder block followed after the added ladder block will be disabled. For this reason, if the online change function is executed as shown in Figure 6.49, the registration 2 is disabled.
  • Page 209: Writing Programs While Cpu Module Is In Run Status

    6.12 Writing Programs While CPU Module is in RUN Status There are two ways of writing programs in the RUN status. Online change (ladder mode • Section 6.12.1 Online change (files) : • Section 6.12.2 Data can also be written in the RUN status using a pointer. ( Section 6.15.2) 6.12.1 Online change (ladder mode)
  • Page 210 CHAPTER6 FUNCTIONS This function also can write programs by GX Developer connected to another station on the network. GX Developer MELSECNET/H PLC-to-PLC network Change a program with GX Developer and write it to the CPU module in the RUN status. Figure 6.51 Outline of online change via network (2) Memory for online change A program cache memory (program memory) is available.
  • Page 211 (4) Changing the reserved area for online change A program file has an area designated as reserved area for online change to support the online change that changes program file size. The following provides precautions when changing the size of reserved area for online change. (a) Size of a program file The size of a program file is addition of created program size and reserved area for online change.
  • Page 212: Online Change (Files)

    CHAPTER6 FUNCTIONS 6.12.2 Online change (files) (1) Definition This function batch-writes files shown in to the CPU module in the RUN status by online Table6.20 operation from GX Developer. Table6.20 Files that can be written to the CPU module in the RUN status Memory card CPU module built-in memory Memory card (ROM)
  • Page 213 (2) Availability (a) For the Q00UJCPU,Q00UCPU,and Q01UCPU The function cannot be performed in the following cases. • A program memory does not have enough area for storing a program file to be written. • A program memory stores the maximum number of files can be stored. (b) For the Q02UCPU,QnUD(H)CPU, and Built-in Ethernet port QCPU A file can be written to the CPU module in the RUN status regardless of space of a memory to be written...
  • Page 214: Precautions For Online Change

    CHAPTER6 FUNCTIONS 6.12.3 Precautions for online change The following shows precautions for online change. (1) Online change during boot operation When data are written to the CPU module in the RUN status during boot operation, the status of boot source program is not changed.
  • Page 215 (3) Instructions do not operate normally during online change When data are written to the CPU module in the RUN status, the following instructions do not operate normally. • Fall instruction • Rise instruction • SCJ instruction (a) Fall instruction The fall instruction is executed when the instruction is in the data written to the CPU module in the RUN status, even if the execution condition (on off) is not met.
  • Page 216 CHAPTER6 FUNCTIONS (b) Rise instruction The rise instruction is not executed when the instruction is in the data written to the CPU module in the RUN status, even if the execution condition (off on) is met. Completion of online change [ PLS MO ] 1 scan X0 status...
  • Page 217 To avoid execution of the fall instruction even when the execution condition (on off) is not met after data are written to the CPU module in the RUN status, select "Trailing edge instructions are not executed" in the Options screen in GX Developer. The option is deselected by default.
  • Page 218 CHAPTER6 FUNCTIONS (4) Writing to the program memory during online change and T/C setting value change Contents changed due to online change and TC setting value change are automatically transferred to the program memory simultaneously when the data are written to the program cache memory. The time required for writing data to the CPU module in the RUN status and changing T/C setting value is increased due to automatic transfer of the program memory by the time shown in Table6.21.
  • Page 219 Automatic transfer to the program memory can be set to be disabled in the Options screen of GX Developer. Data are not automatically transferred to the program memory by deselecting here. Figure 6.58 Online change/TC setting value change program memory transfer settings When the automatic transfer is set to be disabled, the following message appears after online change.
  • Page 220: Execution Time Measurement

    CHAPTER6 FUNCTIONS 6.13 Execution Time Measurement (1) Definition This function displays the processing time of the program being executed. (2) Applications and types This function can be used to know the effect of processing time of each program on the total scan time when the system is adjusted.
  • Page 221 (a) Total Scan Time The monitoring time set in "WDT (Watchdog timer) setting" of the PLC RAS tab of the PLC parameter dialog box and total scan time for each program type during execution by the CPU module are displayed. 1) Monitor time The monitoring time of each program is displayed.
  • Page 222 CHAPTER6 FUNCTIONS Remark When the POFF instruction is executed, a non-execution processing is performed for one scan. The number of execution times displayed is the addition of the execution times of the non-execution processing. For details of the POFF instruction, refer to the following. QCPU Programming Manual (Common Instructions) (3) Program start and stop Program cannot be started and stopped from the Program list monitor screen.
  • Page 223: Interrupt Program Monitor List

    6.13.2 Interrupt program monitor list (1) Definition This function displays the number of executions of an interrupt program. This function is used to check the execution status of the interrupt program. (2) Execution Selecting [Online] [Monitor] [Interrupt program monitor list] of GX Developer displays the Interrupt program monitor list screen.
  • Page 224: Scan Time Measurement

    CHAPTER6 FUNCTIONS 6.13.3 Scan time measurement íç1 Note6.6 (1) Definition This function displays the processing time of set program section during ladder monitoring. The time required for the subroutine and interrupt programs can be measured. (2) Range specification of scan time measurement There are following two types for specifying a scan time measurement range.
  • Page 225 (5) Execution Measure the scan time by the following procedure. • Display the start of the ladder program where scan time is measured in GX Developer and set the monitor mode. • Select [Online] [Monitor] [Scan time measurement] to open the Scan time measurement screen. •...
  • Page 226 CHAPTER6 FUNCTIONS (6) Precautions (a) Measurement range setting Set the measurement range so that "Start step < End step" is satisfied. (b) Scan time measurement across program files Scan time cannot be measured across program files. (c) Minimum unit of measurement time The minimum unit of measurement time is 0.01ms.
  • Page 227 • When the end step is executed before the start step The start step is specified as the next step of the CALL instruction and the end step is Example specified in a subroutine program executed by the CALL instruction. CALL P0 Start step: 3 The start step is executed...
  • Page 228: Sampling Trace Function

    CHAPTER6 FUNCTIONS 6.14 Sampling Trace Function Note6.7 (1) Definition This function samples the data of the specified device at a preset timing and at a preset interval (sampling cycle), and then stores the trace results in the sampling trace file. íç1 (2) Application This function is useful to check the change of the device data used in the program during debugging at...
  • Page 229 (4) Sampling trace operation (a) Operation of the CPU module When a sampling trace trigger is issued by GX Developer, the CPU module executes traces for the preset number of times. The number of traces will be a value of which the number of bytes for the sampling trace area divided by the number of bytes of the specified device (N1 + N2 + N3 + word device points 2 + (bit device points/16) *1 *2...
  • Page 230 CHAPTER6 FUNCTIONS (b) Operation of the special relay 1) When the sampling trace is executed normally The execution status of the sampling trace can be checked in the special relay listed in Table6.22. Table6.22 Execution status of the sampling trace Number Name Description...
  • Page 231 2) When the sampling trace is interrupted If SM801 (Trace start) is turned off during sampling trace, execution of the sampling trace will be interrupted. When the sampling trace is interrupted, the trace count is cleared. The sampling trace restarts by turning on SM801. SM801 Trace Trigger...
  • Page 232 CHAPTER6 FUNCTIONS (5) Operating procedure Select [Online] [Trace] [Sampling trace...] in GX Developer. On the screen opened, select the method for operating the sampling trace. • "Wizard setting/execution" GX Developer Version 8 Operating Manual) • "Individual setting/execution" (5)(a) in this section) (a) Setting "Trace data (setting + result) storage"...
  • Page 233 (b) Setting trace conditions button Set trace conditions on the screen opened by clicking on the screen Trace condition setting shown in Figure 6.67. On the Trace condition settings screen, set the following items. • Number of traces ("No. of traces", "After trigger number of times") •...
  • Page 234 CHAPTER6 FUNCTIONS 2) Trace point setup Select the timing for collecting trace data from the items listed in Table6.23. Table6.23 Trace point setup item Item Description Each scan Collects trace data during END processing of each scan. Interval Collects trace data at specified time intervals. Collects trace data in a cycle of 0.88m specified time intervals.
  • Page 235 4) Trigger point setup Select the trigger point from the items listed in Table6.24. Table6.24 Trigger point setup item Item Description At the time of TRACE The time of execution of the TRACE instruction is set as a trigger. instuction execution At the time of trigger operation The time when a trigger is issued by GX Developer is set as a trigger.
  • Page 236 CHAPTER6 FUNCTIONS (c) Setting trace data Set trace data on the screen opened by clicking the button on the screen shown in Trace data setting Figure 6.67. Table6.25 shows the devices can be set as trace data. Figure 6.70 Trace data settings screen Table6.25 Devices can be set as trace data Item Description...
  • Page 237 (d) Writing the trace condition settings and trace data settings Write the set trace conditions and trace data to the memory selected as a sampling trace file for "Trace data (setting + result) storage". Click the button on the screen shown in Figure 6.67 to write the settings. Write to PLC When storing the sampling trace file into a memory card (SRAM card), more than one sampling trace files can be stored by changing the file name.
  • Page 238 CHAPTER6 FUNCTIONS (f) Displaying trace results Read trace results form the CPU module and display the data. 1) Click the button on the screen shown in Figure 6.71 to read trace results. Trace result PLC read 2) Click the button on the same screen to display the trace results read. Trace result The trace results shows the on/off status of each bit device for every sampling cycle and the current value of each word device.
  • Page 239 (6) Method for clearing trace execution status The trace execution status can be cleared by latch clear using the remote latch clear operation. Section 6.6.4) To perform the sampling trace again after latch clear, select “Start trace” or “Registry trace”. (7) Precautions (a) Areas where sampling trace can be performed The sampling trace can be performed from other stations on the network or serial communication module.
  • Page 240 CHAPTER6 FUNCTIONS 3) When selecting "Memory card (RAM)" in "Target memory" while the SRAM card where the sampling trace file has been registered is not mounted, either of the following operations were performed. • The CPU module is powered off and then on. •...
  • Page 241 (g) Performing sampling trace during execution of another sampling trace The first sampling trace is performed normally. The second sampling trace cannot be performed. (h) Executing online change When sampling trace and online change are performed simultaneously, they operate as follows. 1) Performing sampling trace during online change •...
  • Page 242: Debug Funct(Ion From Multiple Gx Developers

    CHAPTER6 FUNCTIONS 6.15 Debug Funct(ion from Multiple GX Developers (1) Definition This function allows debugs from multiple GX Developers connected to such as a CPU module or serial communication module. When files are divided according to the processes or functions, this function can be used when multiple GX Developers debug different files.
  • Page 243 (2) Setting for simultaneous monitoring from multiple GX Developers Create a user setting system area in the following procedure. • Selecting [Online] [Format PLC memory] in GX Developer displays the screen shown in Figure 6.75. • Select "Program memory/Device memory" in "Target Memory". •...
  • Page 244: Write During Run Function From Multiple Gx Developers

    CHAPTER6 FUNCTIONS 6.15.2 Write during RUN function from multiple GX Developers (1) Definition This function allows multiple GX Developers to perform Write during RUN to one file or different files. • Write during RUN to one file: Select "Relative step No. by pointer". •...
  • Page 245 (b) Setting “After conversion writing behavior” and “Step No. specification used in writing” Set them as follows: 1) Select "Write during RUN (while PLC is running)" in “After conversion writing behavior”. 2) Select “Absolute step No. (default)” or “Relative step No. by pointer” in “Step No. specification used in writing”.
  • Page 246 CHAPTER6 FUNCTIONS 6.16 (WDT) Watchdog Timer (1) Definition This function serves as an CPU module internal timer to detect errors of CPU module hardware and sequence programs. (2) Setting and resetting (a) Setting The watchdog timer setting can be changed in the PLC RAS setting of PLC parameter. 200ms is set by default.
  • Page 247 (b) Resetting a watchdog timer when a program is repeatedly executed between the FOR and NEXT instructions The watchdog timer can be reset by executing the WDT instruction in the sequence program. To avoid the time up of watchdog timer while a program is repeatedly executed between the FOR and NEXT instructions, reset the watchdog timer by the WDT instruction.
  • Page 248: Self-Diagnostic Function

    CHAPTER6 FUNCTIONS 6.17 Self-diagnostic Function (1) Definition This function allows the CPU module to diagnose itself to check for errors. This function aims to preventive measures and prevention of malfunction of the CPU module. (2) Self-diagnostic timing When an error occurs at power-on or during the RUN or STOP status of the CPU module, the error is detected and displayed by the self-diagnostic function, and the CPU module stops an operation.
  • Page 249 CPU module operation at error detection (a) Mode at error detection When an error is detected by the self-diagnostic function, the CPU module enters either of the following modes. 1) Mode that stops CPU module operation When an error is detected, the CPU module stops an operation and turns off all external outputs of the module set to "Clear"...
  • Page 250 CHAPTER6 FUNCTIONS (6) Error check options Whether to check the following errors or not can be selected in the PLC RAS tab of the PLC parameter dialog box (All the options are checked (executed) by default). 1) Carry out battery check 2) Carry out fuse blown check 3) Verify module 4) Check device range at indexing.
  • Page 251 Self-diagnostics list The following table shows the self-diagnostics performed by the CPU module. To check the error messages in the "Error message" column of Table6.29, select [Diagnostics] [PLC diagnostics] of GX Developer. Table6.29 Self-diagnostics list LED status Q00U Built-in Q00UJ CPU, Q02U QnUD(H)
  • Page 252 CHAPTER6 FUNCTIONS Table6.29 Self-diagnostics list (continued) LED status Q00U Built-in Q00UJ CPU, Q02U QnUD(H) Ethernet Diagnostics Error message Diagnostic timing module Q01U port ERR. status QCPU Voltage drop of power supply for SINGLE PS. • Always Continue redundant base DOWN unit Redundant SINGLE PS.
  • Page 253 Table6.29 Self-diagnostics list (continued) LED status Q00U Built-in Q00UJ CPU, Q02U QnUD(H) Ethernet Diagnostics Error message Diagnostic timing module Q01U port ERR. status QCPU • Switching from STOP to RUN Flashi Stop SFC parameter error • Writing to PARA.ERROR programmable controller Intelligent function module SP.PARA.
  • Page 254 CHAPTER6 FUNCTIONS Table6.29 Self-diagnostics list (continued) LED status Q00U Built-in Q00UJ CPU, Q02U QnUD(H) Ethernet Diagnostics Error message Diagnostic timing module Q01U port ERR. status QCPU SFC syntax SFCP. FORMAT • Switching from Flashi Stop error ERR. STOP to RUN SFC block •...
  • Page 255: Leds Indicating Errors

    6.17.1 LEDs indicating errors When an error occurs, the LEDs on the front of the CPU module turns on/flashes. ( Section 6.21) 6.17.2 Error clear The CPU module can clear an error by a program if the error does not stop program operation. (1) Procedures for error clear Clear an error by the following procedures.
  • Page 256: Error History

    CHAPTER6 FUNCTIONS 6.18 Error History This function stores an error detected by the self-diagnostic function and the detection time as an error history in a memory. Select [Diagnostics] [PLC diagnostics] of GX Developer to check the history. The detection time is based on the clock in the CPU module. Make sure to set the correct time before the first use of the CPU module.
  • Page 257: System Protection

    6.19 System Protection The CPU module has protection functions (system protection) to prevent programs being modified by a third party other than the designer with GX Developer or serial communication module. Table6.31 System protection types File that can be Valid Protection target Description Method...
  • Page 258 CHAPTER6 FUNCTIONS (3) Setting method button Select [Online] [Password setup] or click the on the Write to PLC screen in Password setup GX Developer. Figure 6.80 Password registration/change screen (a) Target memory Select a memory storing a file where a password is to be registered. (b) Data type Displays the type of a file stored in the target memory.
  • Page 259: Remote Password

    (4) Precautions (a) Password management A password registered with a file cannot be read from the file. Forgetting the registered password disables the following operations. • Program memory or memory card: Format PLC memory • Standard ROM: Batch-writing Make sure to record the registered password and store the recording paper. (b) Operations that overwrite a file independent of the password registration setting The following operations overwrite a file in the target drive (program memory, standard ROM) independent of the password registration setting.
  • Page 260 CHAPTER6 FUNCTIONS (3) Flow from remote password setting to reflection of the password Set a remote password ( (5) in this section) and then write it to the CPU module. The remote password is transferred to the target module when the CPU module is powered off and then on or is reset.
  • Page 261 (4) Remote password lock/unlock Unlock the remote password of a serial communication module via a modem or the Ethernet module via Ethernet. When entered remote password matches with the registered password, the module can access the CPU module. GX Developer Unlocks (releases) the remote password and accesses the CPU module.
  • Page 262 CHAPTER6 FUNCTIONS (5) Procedures for setting/changing/clearing a remote password (a) Setting a remote password • In the project data list of GX Developer, select [Parameter] [Remote pass]. Remote password setting For the QnUDE(H)CPU or QJ71E71, configure setting in "Detail". Figure 6.83 Remote password settings screen Table6.33 Setting items on the Remote password settings screen Item Description...
  • Page 263 After setting a remote password, store the parameters to the valid drive ( Section 5.1.10). (b) Changing a remote password Change set password in the Remote password settings screen and write a new password to the CPU module. (c) Clearing a remote password •...
  • Page 264: System Display Of Cpu Module With Gx Developer

    CHAPTER6 FUNCTIONS 6.20 System Display of CPU Module with GX Developer When the CPU module is connected to GX Developer, this function can check the following items of the modules on the base unit in the System Monitor screen. • Installed status •...
  • Page 265 (3) Base The status of the base unit and modules on the base unit can be checked. When there is even one faulty module, the "Module" field color changes according to the status described at the bottom of the screen. (4) Mode The mode cannot be selected since modules cannot be replaced online.
  • Page 266 CHAPTER6 FUNCTIONS (9) Detailed information of power supply module This screen displays "ON/OFF status", "Error existence", and "Number of momentary power failures" of the power supply module. This screen can be displayed when using the power supply module supporting a redundant base unit and this screen.
  • Page 267: Led Indication

    6.21 LED Indication Operating status of the CPU module can checked by the LEDs on the front of the CPU module. For details of LED indications, refer to the following. QCPU Userís Manual (Hardware Design, Maintenance and Inspection) Figure 6.87 LEDs on the front of the CPU module 6.21.1 Methods for turning off the LEDs (1) Methods The LEDs can be turned off by the following operations (except for reset operation.)
  • Page 268: Led Indication Priority

    CHAPTER6 FUNCTIONS (2) Methods for not turning on the ERR. LED, USER LED, and BAT. LED There is a priority in indications of the ERR.LED, USER LED, and BAT.LED. ( Section 6.21.2) When an cause number of an LED is deleted in the priority, the LED will not turn on even if an error with the cause number occurs.
  • Page 269 (2) Priorities and cause numbers The following table shows the description and priority of the cause numbers set to the special registers SD207 to SD209. Table6.36 List of cause numbers and priorities Cause number Priority Displayed error message Remarks (hexadecimal) •...
  • Page 270: Interrupt From Intelligent Function Module

    CHAPTER6 FUNCTIONS 6.22 Interrupt from Intelligent Function Module The CPU module can execute an interrupt program (I ) by the interrupt request from the intelligent function module. For example, the serial communication module can receive data by an interrupt program when the following data communication functions are executed.
  • Page 271: Serial Communication Function

    6.23 íç1 Serial Communication Function Note6.11 (1) Definition This function communicates in the MC protocol by connecting the RS-232 interface of the CPU module, personal computer, and HMI by RS-232 cable. This section describes the specifications, functions, and various settings of the function. *1: The MC protocol is an abbreviation for the MELSEC communication protocol.
  • Page 272 CHAPTER6 FUNCTIONS (2) Specifications (a) Transmission specifications Table6.37 shows the transmission specifications of RS-232 for the serial communication function of the CPU module. Check that the specifications of the personal computer and HMI match those of Table6.37 before using the function.
  • Page 273 (b) RS-232 connector specifications Table6.39 shows the specifications of the RS-232 connector for the CPU module. Table6.39 RS-232 connector specifications Appearance Pin number Signal Signal name RD(RXD) Receive data SD(TXD) Send data Signal ground Mini-DIN 6 pins DSR(DR) Data setting ready (female) DTR(ER) Data terminal ready...
  • Page 274 CHAPTER6 FUNCTIONS (3) Functions Table6.40 shows the MC protocol commands that can be executed by the serial communication function. Table6.40 MC protocol commands supported by the serial communication function Number of processing Function Command Processing points In units of ASCII: 3584 points 0401(00 Reads bit devices in units of 1 point.
  • Page 275 (4) Accessible devices Table6.41 shows accessible devices by the serial communication function. Table6.41 Accessible devices by the serial communication function Device number range*1 Category Device Device code Write Read (default value Function input 000000 to 00000F Hexadecimal Function output 000000 to 00000F Hexadecimal Internal Function register...
  • Page 276 CHAPTER6 FUNCTIONS (5) Setting of transmission specifications Set Transmission speed, Sum check, Transmission wait time, and Run write setting of the serial communication function in the Serial tab of the PLC parameter dialog box. • Select "Use serial communication" in communication with the personal computer or HMI. •...
  • Page 277 (c) Communication error If any of the following status is met, responses are not returned and therefore communication cannot be made. Review the transmission frame. 1) The serial communication function is set not to be used. 2) Communication is made at different transmission speed and data format. 3) A frame to be sent has no correct starting end or terminal.
  • Page 278 CHAPTER6 FUNCTIONS (7) Error codes during communication with the serial communication function Table6.42 shows the error codes, error description, and corrective actions sent from the CPU module to the external device when an error occurs during communication with the serial communication function. Table6.42 Error codes sent from the CPU module to external device Error code Error item...
  • Page 279: Service Processing

    6.24 Service Processing 6.24.1 Service processing setting (1) Definition This function allows to set the time and the number of times of service processing performed at END processing by parameters. This function also improves the response of communication with a peripheral and restrains the increase of scan time due to service processing.
  • Page 280 CHAPTER6 FUNCTIONS (2) Parameter setting Set the parameters in the PLC system tab of the PLC parameter dialog box. Figure 6.95 Parameter setting screen To perform the service processing, select any of the parameter items in Table6.43. The setting value of deselected parameter cannot be entered (default: Execute the process as the scan time proceeds.
  • Page 281 (3) Operations for service processing setting Operations for each service processing setting is described below. (a) Operation when "Execute the process as the scan time proceeds." is selected 1) Operation when 10% is set Program execution GX Developer END processing Request 1 When the time required for processing Program execution...
  • Page 282 CHAPTER6 FUNCTIONS (b) Operation when "Specify service process execution counts." is selected 1) Operation when 1 time is set Program execution GX Developer END processing Request 1 Regardless of request data size, one request Program execution is processed at one END processing. END processing Request 2 Even if the program execution time are the same,...
  • Page 283 (c) Operation when "Specify service process time." is selected Operation when 0.5ms is set 0.5ms Program execution GX Developer END processing Request 1 When the time required for processing one request exceeds the service processing time (0.5ms) , the Program execution service processing is suspended and the processing is performed at END processing in the next scan.
  • Page 284 CHAPTER6 FUNCTIONS (d) Operation when "Execute it while waiting for constant scan setting." is selected Constant scan Program execution END processing GX Developer Request 1 Waiting time Request 2 The service processing is performed during waiting time. Program execution END processing Request 3 Waiting time Request 4...
  • Page 285 (4) Precautions The following describes precautions when the service processing setting is configured. 1) For the following functions, scan time will be increased longer than the specified time during service processing even if the service processing time specification is set. •...
  • Page 286: Initial Device Value

    CHAPTER6 FUNCTIONS 6.25 Initial Device Value (1) Definition This function registers data used in a program to the device or the buffer memory of the intelligent function module without a program. (2) Application Using an initial device value can omit device data setting program by initial processing program. Device memory SM402 H100...
  • Page 287 (3) Timing when initial device values are written to the specified device The CPU module writes data in the specified initial device value file to the specified device or the buffer memory of the intelligent function module when the CPU module is powered off and then on, is reset, or is set to the STOP status and then the RUN status.
  • Page 288 CHAPTER6 FUNCTIONS (5) Procedures and settings for using initial device values To use initial device values, create initial device value data with GX Developer beforehand, and store the data as a initial device value file in the program memory, standard ROM, or memory card of the CPU module. •...
  • Page 289 • Select the name of a file where the initial device value data are stored in the PLC file tab of the PLC parameter dialog box. Figure 6.106 PLC file tab • Write the set initial device value and parameters to the CPU module. (6) Precautions (a) When initial device value and latch range are overlapped In that case, initial device value takes priority.
  • Page 290: Battery Life-Prolonging Function

    CHAPTER6 FUNCTIONS 6.26 Battery Life-prolonging Function (1) Definition This function extends the life of battery installed in the CPU module by restricting data to be held by the battery to clock data only. This function initializes all data other than the clock data when the CPU module is powered off or is reset. Table6.44 Initialization details Data held by a battery Description...
  • Page 291: Memory Check Function

    6.27 Memory Check Function This function checks whether data in the memories of the CPU module are not changed due to such as excessive electric noise. Since the CPU module automatically checks a memory, setting for enabling this function is unnecessary. This function does not require processing time.
  • Page 292: Latch Data Backup To Standard Rom Function

    CHAPTER6 FUNCTIONS 6.28 Latch Data Backup to Standard ROM Function (1) Definition This function holds (backs up) latch data, such as device data and error history, to the standard ROM without using a battery when the system is stopped for a long period. This function helps to extend battery life. Remark When this function is performed, the battery life-prolonging function is enabled regardless of the parameter setting for the battery life-prolonging function.
  • Page 293 When backing up the data in the file register, extended data register (D), and extended link register (W), pay attention to the following. • The data are backed up only when the file register in the standard RAM is set to be used. •...
  • Page 294 CHAPTER6 FUNCTIONS (4) Execution method (a) Execution by contacts 1) Setting method Set "Latch data backup operation valid contact" in the PLC system tab of the PLC parameter dialog box (Devices X, M, or B can be selected). Specify a contact Figure 6.109 Setting screen of latch data backup start contact to standard ROM 2) Execution method Backup starts at the rise of a contact (off Å®...
  • Page 295 (5) Restoring backup data The backup data is automatically restored by the following operations. • At power-off on of the CPU module • At reset Whether to restore data once after backup or per above operation is set by SM676 (Specification of restore repeated execution).
  • Page 296 CHAPTER6 FUNCTIONS (7) Checking with special relays and special registers The status of execution of latch data backup to the standard ROM or restoration operation can be checked by SM671, SM676, SD671 to SD679. (8) Precautions The following provides precautions for backing up latch data. 1) Do not power off or reset the CPU module during backup of latch data.
  • Page 297: Writing/Reading Device Data To/From Standard Rom

    6.29 Writing/Reading Device Data to/from Standard ROM (1) Definition This function writes device data to the standard ROM. Writing the fixed values for operation and operation results to the standard ROM can prevent losing data due to low battery. Also, timing of writing to the standard ROM can be set by an instruction. (2) Execution method Device data are written to the standard ROM by the SP.DEVST instruction.
  • Page 298: Cpu Module Change Function With Memory Card

    CHAPTER6 FUNCTIONS 6.30 CPU Module Change Function with Memory Card Note6.12 (1) Definition This function backs up data in the CPU module to a memory card and restores the backup data to another CPU module.íç1 Universal model QCPU 1) Backs up to a Program memory memory card.
  • Page 299 (2) Backup data file After data are backed up, a backup data file "MEMBKUP0.QBP" is created in a memory card. Only one backup data file can be stored to a memory card. When data are backed up to a memory card containing a backup data file again, the stored backup data file is overwritten.
  • Page 300: Backup Function To Memory Card

    CHAPTER6 FUNCTIONS 6.30.1 Backup function to memory card This function can save data in the CPU module to a memory card. If a memory card is used in running system, data can be backed up by replacing the current memory card with the one for storing a backup data.
  • Page 301 2) Operating procedure Turn on in the order of the backup start setup contact and the backup start contact. Data are not backed up when only the backup start contact is on. Turn on the backup start setup contact. Preparation for backup: 1) Set the CPU module to the STOP status.
  • Page 302 CHAPTER6 FUNCTIONS 3) Operation of contacts Operations of the backup start setup contact, backup start contact, SM691 (Backup start preparation status flag), and SD690 (Backup status) at backup are shown in Figure 6.116. Backup start setup request from Backup start request from GX Developer or the backup start GX Developer or the backup setup contact is turned on.
  • Page 303 (b) Backup from GX Developer Select [Online] [PLC module change] [Create backup data...]. Figure 6.117 Create backup data screen For details of the operating procedure by the GX Developer wizard, refer to the following. GX Developer Version 8 Operating Manual Clicking the button on the screen shown in Figure 6.117 displays the size of backup data created at Confirm data size...
  • Page 304 CHAPTER6 FUNCTIONS (2) Operations of backup to a memory card (a) Mounting/removal of a memory card In a system using a memory card, the memory card can be changed/removed after preparation for backup has been completed (Turning on SM609 (Memory card remove/insert enable flag) is unnecessary). After preparation for backup has been completed, the CPU module turns off SM604 (Memory card in-use flag).
  • Page 305 (c) Operations of special relays and special register Figure 6.119 shows the operations of the SM609 (Memory card remove/insert enable flag), SM691 (Backup start preparation status flag), and SD690 (Backup status). Backup start setup request from Backup start request from GX Developer or the backup GX Developer or the backup start setup contact is turned on.
  • Page 306 CHAPTER6 FUNCTIONS (3) LEDs indicating backup status The LEDs on the front of the CPU module indicate backup status. Table6.53 LEDs indicating backup status Value stored in Backup status LED indication SD690 Backup start preparation MODE: Flash (green), BAT.: Flash (green) completed The color changes at intervals of 800ms as follows.
  • Page 307 (5) Functions that cannot be performed during backup Table6.55 shows functions that cannot be performed during backup. Table6.55 Functions that cannot be performed during backup Category Function Category Function Format PLC memory Trace Sampling trace registration Write the program memory to ROM Remote operation Remote latch clear Drive operation...
  • Page 308: Backup Data Restoration Function

    CHAPTER6 FUNCTIONS 6.30.2 Backup data restoration function This function restores data backed up to a memory card to the CPU module. (1) Methods (a) Restoration from GX Developer Select [Online] [PLC module change] [Restore...]. Figure 6.121 Restore screen After selecting "Execute" on the screen above and powering off and then on the CPU module or reset the CPU module, the restored data become valid.
  • Page 309 (2) Operation for restoring backup data Figure 6.122 shows operation for restoration. Automatic restoration Restoration from GX Developer Start Start 1: Before restoration start 1: Before restoration start Mount a memory card storing the backup data Mount a memory card storing the to the CPU module and power off and then on backup data to the CPU module and Restoration is...
  • Page 310 CHAPTER6 FUNCTIONS (4) LEDs indicating restoration status The LEDs on the front of the CPU module indicate restoration status. Table6.58 LEDs indicating restoration status Value stored in Restoration status LED indication SD693 Before restoration start MODE: On (green) The color changes at intervals of 800ms as follows. Restoration in execution : Flashing (orange) : On (red)
  • Page 311 When automatic restoration is not normally completed, “RESTORE ERROR” (error code: 2225 to 2227) is detected. Table6.60 Error when automatic restoration is not normally completedÅ@ Error code Error message Error cause The CPU module where data are restored is different model with the one where the backup 2225 source data are stored.
  • Page 312: Communications Between Cpu Module And Intelligent Function Module

    CHAPTER7 COMMUNICATIONS WITH INTELLIGENT FUNCTION MODULE CHAPTER7 COMMUNICATIONS WITH INTELLIGENT FUNCTION MODULE (1) Intelligent function module The intelligent function module allows the CPU module to process analog quantity and high speed pulses that cannot be processed by the I/O modules. For example, the analog-digital conversion module, one of the intelligent function modules, uses analog quantity by converting it into a digital value.
  • Page 313: Initial Setting And Auto Refresh Setting By Gx Configurator

    7.1.1 Initial setting and auto refresh setting by GX Configurator The initial setting and auto refresh setting can be made by adding in GX Configurator that is supported by the intelligent function module to GX Developer. After the initial and auto refresh settings, data can be read or written without creating a program for communications with intelligent function modules.
  • Page 314 CHAPTER7 COMMUNICATIONS WITH INTELLIGENT FUNCTION MODULE (b) Auto refresh setting The CPU module devices for storing the following data can be set in the Auto refresh setting screen. • Digital output of the Q64AD • Maximum and minimum values of the Q64AD •...
  • Page 315 (3) Limitation on the number of parameter settings Limitations are placed on the number of parameters (initial setting and auto refresh setting) set in GX Configurator. When multiple intelligent function modules are mounted, make setting in GX Configurator so that the number of parameter settings for all intelligent function modules may not exceed the limitation shown in Table7.2.
  • Page 316: Initial Setting By Initial Device Value

    CHAPTER7 COMMUNICATIONS WITH INTELLIGENT FUNCTION MODULE 7.1.2 Initial setting by initial device value (1) Initial device value Using an initial device value ( Section 6.25) allows the initial setting of the intelligent function module without a program. The set initial device values are written from the CPU module to the intelligent function module when the CPU module is powered off and then on or is reset.
  • Page 317: Communications Using The Intelligent Function Module Device

    7.1.4 Communications using the intelligent function module device (1) Intelligent function module device The intelligent function module device ( Section 9.5.1) represents the buffer memory of the intelligent function module as one of the CPU module devices. The data stored in the buffer memory of the intelligent function module can be treated by the sequence instruction as well as the device memory.
  • Page 318 CHAPTER7 COMMUNICATIONS WITH INTELLIGENT FUNCTION MODULE The intelligent function module device accesses the intelligent function module every time when an instruction is executed. When writing or reading buffer memory data using multiple intelligent function module devices in a sequence program, write or read the data with the FROM or TO instruction in one location of the program.
  • Page 319: Communications Using The Intelligent Function Module Dedicated Instruction

    7.1.5 Communications using the intelligent function module dedicated instruction (1) Intelligent function module dedicated instruction This instruction enables easy programming for the use of functions of the intelligent function module. (a) Example with the serial communication module dedicated instruction (OUTPUT instruction) The OUTPUT instruction allows communications with external device by nonprocedural protocol regardless of the buffer memory address of the serial communication module.
  • Page 320 CHAPTER7 COMMUNICATIONS WITH INTELLIGENT FUNCTION MODULE (3) Precautions (a) When the CPU module is set from RUN to STOP before the completion device turns When a intelligent function module dedicated instruction is executed and the CPU module is set from RUN to STOP before the completion device turns on, the completion device will not turn on until the CPU module is set to RUN and then finishes one scan.
  • Page 321 CHAPTER8 PARAMETERS This chapter describes the parameters required to be set for configuring a programmable controller system. (1) Parameter types The following parameters are provided for CPU module setting. • PLC parameters ( Section 8.1) These parameters are set when a programmable controller is used. •...
  • Page 322: Plc Parameters

    CHAPTER8 PARAMETERS 8.1 PLC Parameters This section provides the list of PLC parameters and describes parameter details. (1) PLC name A label and a comment for the CPU module are set. The settings will be displayed in the list for the find CPU function. íç1 Note8.1 Figure 8.1 PLC name...
  • Page 323 (2) PLC system Parameters required for use of the CPU module are set. Figure 8.2 PLC system Table8.2 PLC system setting list Parameter Item Description Setting range Default Reference Low speed 1ms to 1000ms (in increments of 1ms) 100ms Section 9.2.10 Timer limit Set the time limit for the low 1000...
  • Page 324 CHAPTER8 PARAMETERS Table8.2 PLC system setting list (continued) Parameter Item Description Setting range Default Reference Common pointer No. 1005 Set the start number of common pointers. P0 to 4095 Blank Section 9.10.2 Points occupied by Set the number of points for empty slots 0, 16, 32, 64, 128, 256, 512, or 1007 16 points...
  • Page 325 (3) PLC file Parameters required for the files used in the CPU module are set. Figure 8.3 PLC file Table8.3 PLC file setting list Parameter Item Description Setting range Default Reference • Not used Set a file for the file register used in •...
  • Page 326 CHAPTER8 PARAMETERS (4) PLC RAS Parameters required for performing the RAS functions are set. Figure 8.4 PLC RAS Table8.4 PLC RAS setting list Parameter Item Description Setting range Default Reference 10ms to 2000ms Set a watchdog timer value for WDT Setting (in increments of 200ms Section 6.16...
  • Page 327 (5) Device Number of points, latch range, and local device range are set for each device. Figure 8.5 Device Table8.5 Device setting list Parameter Item Description Setting range Default Reference • X: 8K • Y: 8K • M: 8K • L: 8K •...
  • Page 328 CHAPTER8 PARAMETERS Table8.5 Device setting list (continued) Parameter Item Description Setting range Default Reference Point assignment to the file register (ZR), extended data Set points for the file register register (D), or extended link (ZR), extended data register Section 9.1, Device points 2000 register (W).
  • Page 329 (6) Program File names and execution types (execution conditions) are set for each program when two or more programs are written to the CPU module. Figure 8.6 Program Table8.6 Program setting list Parameter Item Description Setting range Default Reference When writing two or more programs to •...
  • Page 330 CHAPTER8 PARAMETERS (7) Boot file Parameters required for a boot from a memory card are set. Figure 8.7 Boot file Table8.7 Boot file setting list Parameter Item Description Setting range Default Reference Select whether to clear the Clear program Boot option program memory at the time of Selected/deselected Deselected...
  • Page 331 (8) SFC The mode and conditions for starting an SFC program, and the output mode in the case of a block stop are set. Figure 8.8 SFC Table8.8 SFC setting list Parameter Item Description Setting range Default Reference SFC program start mode 8002 Initial start Set the mode and conditions for...
  • Page 332 CHAPTER8 PARAMETERS (9) I/O assignment The mounting status of each module in the system is set. Figure 8.9 I/O assignment Table8.9 I/O assignment setting list Parameter Item Description Setting range Default Reference • CPU No.2 to No.4: No.n/Empty (Set "CPU (Empty)" for the slot where no Type Set the type of the mounted module.
  • Page 333 Table8.9 I/O assignment setting list (continued) Parameter Item Description Setting range Default Reference Set various switches of an Refer to the manual for the Switch setting 0407 Blank Section 6.10 intelligent function module. intelligent function module used. Set whether to clear or hold the Error time 0403 output in case of a stop error in...
  • Page 334 CHAPTER8 PARAMETERS (10) Serial íç1 Note8.2 The transmission speed, sum check, transmission wait time, and RUN write setting for using the serial communication function of the CPU module are set. Figure 8.10 Serial Table8.10 Serial setting list Parameter Item Description Setting range Default Reference...
  • Page 335 (11) Acknowledge XY assignment The parameters set in the I/O assignment, Ethernet/CC IE/MELSECNET setting, and CC-Link setting can be confirmed. Figure 8.11 Acknowledge XY assignment Table8.11 Acknowledge X/Y assignment list Parameter Item Description Setting range Default Reference The data set in the I/O assignment, Ethernet/CC IE/ X/Y assignment MELSECNET setting, and CC-Link setting can be checked.
  • Page 336 CHAPTER8 PARAMETERS (12) Multiple CPU settings íç1 Note8.3 Parameters required for configuring a multiple CPU system are set. Figure 8.12 Multiple CPU settings Table8.12 Multiple CPU setting list Parameter Item Descriptionì‡Å@óe Setting range Default Reference Set the number of CPU modules used in a multiple No.
  • Page 337 Table8.12 Multiple CPU setting list (continued) Parameter Item Description Setting range Default Reference Enable or disable the online module change in the multiple CPU system. (When enabled, E006 Selected/deselected Deselected Online module change the CPU module cannot read the I/O data outside the specified group.) Select whether to read the All CPUs...
  • Page 338 CHAPTER8 PARAMETERS (13) Built-in Ethernet port íç1 Note8.4 Parameters required for use of the built-in Ethernet port are set. Figure 8.13 Built-in Ethernet port Table8.13 Built-in Ethernet port setting list Parameter Item Description Setting range Default Reference • IP address: 0.0.0.1 to 223.255.255.254 •...
  • Page 339 Table8.13 Built-in Ethernet port setting list (continued) Parameter Item Description Setting range Default Reference Set data when using MC protocol or Open settings Blank socket communication. Set data when using the file transfer FTP settings Blank function (FTP). Set data when using the time Time settings Blank setting function.
  • Page 340: Network Parameters

    CHAPTER8 PARAMETERS 8.2 Network Parameters This section provides the list of network parameters and describes parameter details. Symbols, M and N, used in the "Parameter No." column M and N in "Parameter No." in this section denote the following: Indicates the module number. •...
  • Page 341 CC-Link IE controller network setting Network parameters for the CC-Link IE controller network are set. Figure 8.14 Setting the number of Ethernet/CC IE/MELSECNET cards (CC-Link IE controller network setting) Table8.16 CC-Link IE controller network setting list Item Parameter No. Description Setting range Default Reference...
  • Page 342 CHAPTER8 PARAMETERS MELSECNET/H setting Network parameters for MELSECNET/H are set Figure 8.15 Setting the number of Ethernet/CC IE/MELSECNET cards (MELSECNET/H setting) Table8.17 MELSECNET/H setting list Item Parameter No. Description Setting range Default Reference Number of modules on MELSECNET/H 5000 Starting I/O No. Network No.
  • Page 343 (3) Ethernet setting Network parameters for Ethernet are set Figure 8.16 Setting the number of Ethernet/CC IE/MELSECNET cards (Ethernet setting) Table8.18 Ethernet setting list Item Parameter No. Description Setting range Default Reference Number of modules on Ethernet 9000 Starting I/ONo. Network No.
  • Page 344 CHAPTER8 PARAMETERS (4) CC-Link setting Parameters for CC-Link are set Figure 8.17 Setting the CC-Link list Table8.19 CC-Link setting list Item Parameter No. Description Setting range Default Reference Number of modules C000 Start I/O No. Operational setting CNM2 All connect count Remote input (RX) Remote output (RY) Remote register (RWr)
  • Page 345: Remote Password

    8.3 Remote Password This section provides the list of parameters for use of remote password and describes parameter details. Figure 8.18 Remote password settings dialog box A remote password are set for an Ethernet module, serial communication module, modem interface module, or Built-in Ethernet port QCPU Table8.20 Remote password setting list Item...
  • Page 346: Device List

    CHAPTER9 DEVICES CHAPTER9 DEVICES This chapter describes the devices that can be used in the CPU module. 9.1 Device List Table 9.1 lists the names and data ranges of the devices that can be used in the CPU module. Table9.1 Device list Default Parameter-set Classification...
  • Page 347 ï\9.1 Device list (continued) Default Classification Type Device name Parameter-set range Reference Points Range Word File register Section 9.7 File register device Extended data Word 0 to 4086K points Extended data register Section 9.8 device register Extended link Word Extended link register Section 9.8 device register...
  • Page 348: Internal User Device

    CHAPTER9 DEVICES Internal User Device (1) Definition Internal user devices can be used for various user applications. (2) Points for internal user devices The default values can be changed in the Device tab of the PLC parameter dialog box. However, the points for the input (X), output (Y), and step relay (S) cannot be changed.íç1 Note9.1...
  • Page 349 When changing device points, the following refresh ranges must not exceed the corresponding ● device ranges. • Refresh range of network module • Auto refresh range of intelligent function module If device points are set exceeding the corresponding device range, data may be written to any other device or an error may occur.
  • Page 350 CHAPTER9 DEVICES (4) Device point assignment example shows a device point assignment example. Table9.2 uses the same format as the device point assignment sheet shown in Appendix 4. Table9.2 Table9.2 Device point assignment example *1 *2 Restriction check Number of device point Numeric Device name Symbol...
  • Page 351: Input (X)

    9.2.1 Input (X) (1) Definition from external devices such as push- The input (X) is used to send commands or data to the CPU module button switches, selector switches, limit switches, and digital switches. Push-button switch Selector switch Input (X) Sequence operation Digital switch...
  • Page 352 CHAPTER9 DEVICES ● When debugging a program, the input (X) can be set to on or off by the following: • Device test in GX Developer • OUT Xn instruction OUTX1 ON/OFF command Figure 9.5 Input (X) on/off with the OUT Xn instruction ●...
  • Page 353: Output (Y)

    9.2.2 Output (Y) (1) Definition The output (Y) is used to output control results on programs to external devices such as signal lamps, digital displays, electromagnetic switches (contactors), or solenoids. Data can be output to the outside like using a normally open contact. Signal lamp Digital display Output (Y)
  • Page 354: Internal Relay (M)

    CHAPTER9 DEVICES 9.2.3 Internal relay (M) (1) Definition The internal relay (M) is a device for auxiliary relays used in the CPU module. All of the internal relay are set to off in the following cases: • When the CPU module is powered off and then on •...
  • Page 355: Latch Relay (L)

    9.2.4 Latch relay (L) (1) Definition The latch relay (L) is a device for auxiliary relays that can be latched inside the CPU module. Latch relay data are retained by batteries in the CPU module during power failure. Operation results (on/off information) immediately before the following will be also retained.
  • Page 356: Annunciator (F)

    CHAPTER9 DEVICES 9.2.5 Annunciator (F) (1) Definition The annunciator (F) is an internal relay which can be effectively used in fault detection programs for user-created system. (2) Special relay and special register after annunciator ON When the annunciator is turned on, the special relay (SM62) is set to on, and the numbers and quantity of the annunciator numbers are stored in the special register (SD62 to SD79).
  • Page 357 (5) Turning on the annunciator and processing (a) Turning on the annunciator The following instructions can be used. 1) SET F instruction instruction can be used to turn on the annunciator only on the leading edge (off to on) The SET F of an input condition.
  • Page 358 CHAPTER9 DEVICES (6) Turning off the annunciator and processing (a) Turning off the annunciator The following instructions can be used. 1) RST F instruction This is used to turn off the annunciator number that was turned on with the SET F instruction.
  • Page 359 (b) Processing after annunciator off LEDR instruction Data stored in the special register (SD62 to SD79) after execution of the • The annunciator number in SD64 is deleted, and the other annunciator numbers in the register addressed SD65 and after are shifted accordingly. •...
  • Page 360: Edge Relay (V)

    CHAPTER9 DEVICES 9.2.6 Edge relay (V) (1) Definition The edge relay (V) is a device in which the on/off information from the beginning of the ladder block. Contacts only can be used. (Coils cannot be used). Stores on/off information of X0, X1, and X10.
  • Page 361: Link Relay (B)

    9.2.7 Link relay (B) (1) Definition for refreshing the link relay (LB) data of The link relay (B) is a relay on the CPU module side, and it is used another module such as a MELECNET/H network module to the CPU module or refreshing the CPU module data to the link relay (LB) of the MELECNET/H network module.
  • Page 362 CHAPTER9 DEVICES (3) Using the link relay in the network system Network parameters must be set. The link relay range areas that is not set by network parameters (not used for a network system such as a MELSECNET/H network) can be used as the internal relay or latch relay. Link relay range where no latch is performed •...
  • Page 363: Link Special Relay (Sb)

    9.2.8 Link special relay (SB) (1) Definition The Link special relay (SB) is a relay that indicates various communication status and detected errors of intelligent function modules such as CC-Link IE controller modules or MELSECNET/H network modules. Each of this device area is turned on or off according to a factor occurred during data link. The communication status and errors on the network can be confirmed by monitoring the link special relay (SB).
  • Page 364: Step Relay (S)

    CHAPTER9 DEVICES 9.2.9 Step relay (S) This device is provided for SFC programs. Because the step relay is a device exclusively used for SFC programs, it cannot be used as an internal relay in the sequence program. If used, an SFC error will occur, and the system may go down. Remark For use of the step relay, refer to the following.
  • Page 365: Timer (T)

    9.2.10 Timer (T) (1) Definition Time counting starts when a coil is turned on, and it times out and the contact turns on when the current value reaches the set value. The timer is of an incremental type. (2) Timer types Timers are mainly classified into the following two types.
  • Page 366 CHAPTER9 DEVICES Low-speed timer (a) Definition This type of timer measures time in increments of 1 to 1000ms. The timer starts time measurement when its coil is turned on, and when it times out, the contact is turned on. If the timerís coil is turned off, the current value is changed to "0" and the contact is turned off.
  • Page 367 Retentive timer (a) Definition This timer measures the period of time during which the coil is on. The timer starts time measurement when its coil is turned on, and when it times out, the contact is turned on. Even if the timerís coil is turned off, the current value and the on/off status of the contact are retained.
  • Page 368 CHAPTER9 DEVICES Timer processing and accuracy Processing instruction is executed, the on/off switching of the timer coil, current When the OUT T or OUT ST value update, and on/off switching of the contact are performed. In the END processing, the current timer value is not updated and the contact is not turned on/off. [Ladder example] [Processing at execution of OUT T0 instruction] OUT TO...
  • Page 369 Accuracy The value obtained by the END instruction is added to the current value when the OUT T or OUT instruction is executed. The current value is not updated while the timer coil is off even if the OUT T or OUT ST instruction is executed.
  • Page 370 CHAPTER9 DEVICES Precautions for using timers (a) Use of the same timer Do not use the OUT T instruction that describes the same timer more than once within one scan. If this occurs, the current timer value will be updated by each OUT T instruction execution, resulting in incorrect time measurement.
  • Page 371 (f) When using multiple timers When using multiple timers to update the respective current values at execution of each OUT T instruction, pay attention to the ladder sequence. For example, to create an on/off ladder using two timers, refer to examples shown in Figure 9.28. [Correct ladder example] Coil of T1 is turned on one scan after T0 is turned on.
  • Page 372: Counter (C)

    CHAPTER9 DEVICES 9.2.11 Counter (C) (1) Definition The counter (C) is a device that counts the number of rises for input conditions in sequence programs. When the count value matches the set value, the counting stops and its contact is turned on. The counter is of an incremental type.
  • Page 373 (c) Resetting the counter The current counter value is not cleared even if the OUT C instruction is turned off. To clear the current value and to turn off the contact of the counter, use the RST C instruction. At the time of execution of the RST C instruction, the counter value is cleared, and the contact is also turned off.
  • Page 374 CHAPTER9 DEVICES 1) Precautions for resetting the counter Execution of the RST C instruction also turns off the coil of C . If the execution condition for the OUT C instruction is still ON after execution of the RST C instruction, turn on the coil of C at execution of the OUT C instruction and update the current...
  • Page 375 Maximum counting speed The counter can count only when the on/off time of the input condition is longer than the execution interval of the corresponding OUT C instruction. The maximum counting speed is calculated by the following expression: n: Duty (%) Maximum counting [times/s] speed (Cmax)
  • Page 376: Data Register (D)

    CHAPTER9 DEVICES 9.2.12 Data register (D) (1) Definition The data register (D) is a memory in which numeric data (-32768 to 32767, or 0000 to FFFF ) can be stored. (2) Bit structure of the data register (a) Bit structure and read/write unit One point of the data register consists of 16 bits, and data can be read or written in units of 16 bits.
  • Page 377: Link Register (W)

    9.2.13 Link register (W) (1) Definition The link register (W) is a memory in the CPU module, which is refreshed with link register (LW) data of an intelligent function module such as a MELSECNET/H network module. CPU module MELSECNET/H network module Link register Link register Link refresh...
  • Page 378 CHAPTER9 DEVICES (b) When using a 32-bit instruction for the link register For a 32-bit instruction, two consecutive points of the data register (Wn and Wn+1) are the target of the processing. The lower 16 bits correspond to the link register number (Wn) specified in the sequence program, and the higher 16 bits correspond to the specified link register number + 1.
  • Page 379: Link Special Register (Sw)

    9.2.14 Link special register (SW) (1) Definition The link special register (SW) is used to store communication status data and error data of intelligent function modules, such as CC-Link IE controller network modules and MELSECNET/H network modules. Because the data link information is stored as numeric data, error locations and causes can be checked by monitoring the link special register.
  • Page 380: Internal System Devices

    CHAPTER9 DEVICES 9.3 Internal System Devices Internal system devices are provided for system operations. The allocations and sizes of internal system devices are fixed, and cannot be changed by the user. 9.3.1 Function devices (FX, FY, FD) (1) Definition Function devices are used in subroutine programs with argument passing. Data are read or written between such subroutine programs and calling programs, using function devices.
  • Page 381 (b) Function output (FY) • The function output is used for passing an operation result (on/off data) in a subroutine program to a calling program. • An operation result is stored in the device specified in the subroutine program with argument passing. •...
  • Page 382 CHAPTER9 DEVICES In subroutine programs with argument passing, do not use any devices that are used by the function register. If this occurs, function register values will not be normally passed to the calling program. CALLP P0 D0 R0 R10 FD0 MOV K0 D3 Since D0 to D3 are used for FD0, D3 cannot be used in the...
  • Page 383: Special Relay (Sm)

    9.3.2 Special relay (SM) (1) Definition The special relay (SM) is an internal relay of which details are specified inside the programmable controller, and the CPU module status data are stored in this special relay. (2) Special relay classifications Table9.3 shows special relay classifications. Table9.3 Special relay classification list Classification Special relay...
  • Page 384: Special Register (Sd)

    CHAPTER9 DEVICES 9.3.3 Special register (SD) (1) Definition The special register (SD) is an internal relay of which details are specified inside the programmable controller, and the CPU module status data (such as error diagnostics or system information) are stored in this special register.
  • Page 385: Link Direct Device (J\)

    9.4 Link Direct Device (J \ ) (1) Definition The link direct device is a device for direct access to the link device in a CC-Link IE controller network module or MELSECNET/H network module. The CPU module can directly write data to or read data from the link device in a CC-Link IE controller network module or MELSECNET/H network module using sequence programs regardless of link refresh.
  • Page 386 CHAPTER9 DEVICES (3) Specification range A link device that is not set in the Network parameter dialog box can be specified. (a) Writing • The write range must be within the link device send range that is set by common parameters on Network parameter setting dialog box, and it must be outside the refresh range set by network refresh parameters.
  • Page 387 (b) Reading The link device ranges of network modules can be read. Writing or reading data by using a link direct device is allowed for only one network module that is on the same network. If two or more network modules are mounted on the same network, a network module with the lowest slot number is the target of writing or reading by the link direct device.
  • Page 388: Module Access Devices

    CHAPTER9 DEVICES 9.5 Module Access Devices 9.5.1 (U \G ) Intelligent function module device (1) Definition The intelligent function module device allows direct access from the CPU module to the buffer memories of the intelligent function modules which are mounted on the main and extension base units. (2) Specification method and application example (a) Specification method Specify the I/O number and buffer memory address of the intelligent function module.
  • Page 389 (3) Processing speed The processing speed of the intelligent function module device is as follows: • The processing speed of writing or reading using the intelligent function module device is slightly higher compared with the case of using the FROM or TO instruction. "MOV U2\G11 D0"...
  • Page 390: Cyclic Transmission Area Device (U3En\G)

    CHAPTER9 DEVICES 9.5.2 Cyclic transmission area device (U3En\G ) (1) Definition The cyclic transmission area device is used to access the CPU shared memory of each CPU module in a multiple CPU system. (2) Features • The transfer speed is higher than the case of using the write (S.TO or TO) or read (FROM) instruction to the CPU shared memory, resulting in reduced programing steps.
  • Page 391: Index Register (Z)/Standard Device Resister (Z)

    9.6 Index Register (Z)/Standard Device Resister (Z) 9.6.1 Index register (Z) (1) Definition The index register is used for indirect specification (index modification) in sequence programs. Index modification uses one point of the index register. MOVP K5 Z0 SM400 D0Z0 K4Y30 Specify the index register by one point (16 bits).
  • Page 392 CHAPTER9 DEVICES (b) When using the index register for a 32-bit instruction The processing target is Zn and Zn+1. The lower 16 bits correspond to the specified index register number (Zn), and the higher 16 bits correspond to the specified index register number + 1. When Z2 is specified in the DMOV instruction, Z2 represents the lower 16 bits and Z3 represents Example the higher 16 bits.
  • Page 393: Standard Device Register (Z)

    9.6.2 Standard device register (Z) (1) Definition By using the index register between register operations, operations can be executed at a higher speed. The index register used in this case is called the standard device resister. (2) Device number Since the standard device register is the same device as the index register, pay attention not to use the same device number when using the index modification.
  • Page 394: Type Program

    CHAPTER9 DEVICES 9.6.3 Switching from the scan execution type program to the interrupt/fixed scan execution type program The CPU module performs the following when switching from the scan execution type program to the interrupt/ fixed scan execution type program. • Saving and restoring the index register data •...
  • Page 395 (2) Processing of the index register (a) When "High-speed execution" is not selected 1) When switching from the scan execution type program to the interrupt/fixed scan execution type program The CPU module saves index register values in the scan execution type program, and passes them to the interrupt/fixed scan execution type program.
  • Page 396 CHAPTER9 DEVICES (b) When "High-speed execution" is selected 1) When switching from the scan execution type program to the interrupt/fixed scan execution type program The CPU module does not save/restore any index register values. 2) When switching from the interrupt/fixed scan execution type program to the scan execution type program If data are written to the index register by the interrupt/fixed scan execution type program, the values of the index register used in the scan execution type program will be corrupted.
  • Page 397 (3) Processing of file registerís block numbers (a) When switching from the scan execution type program to the interrupt/fixed scan execution type program The CPU module saves the file register block numbers in the scan execution type program, and passes them to the interrupt/fixed scan execution type program.
  • Page 398: File Register (R)

    CHAPTER9 DEVICES 9.7 File Register (R) Note9.4 (1) Definition The file register (R) is a device provided for extending the data register. The file register can be used at the same processing speed as the data register.íç1 K100 R2 File register 100 is written to R2.
  • Page 399: File Register Data Storage Location

    (3) Clearing the file register The file register contents are backed up by the battery built in the CPU module, and they are held if the CPU module is powered off or reset. (Not initialized even if the latch is cleared. *1: The latch range of the file register can be set in the Device tab of the PLC parameter dialog box.
  • Page 400: Differences In Available Accesses By Storage Memory

    CHAPTER9 DEVICES (2) When using an SRAM card Up to 4086K points can be stored in one file. Since one block consists of 32K words, up to 128 blocks can be stored. Note that the number of points or blocks that can be added depends on the size of the programs and device comments stored in the memory card.
  • Page 401: Registration Procedure For The File Register

    9.7.4 Registration procedure for the file register To use a file register, register the file of the file register to the CPU module in the following steps. Start Setting a file register ………… "PLC file" tab of the PLC parameter dialog box Select "Use the following file."...
  • Page 402 CHAPTER9 DEVICES (1) Setting the file register In the PLC file tab of the PLC parameter dialog box, specify the standard RAM or a memory card to use the file register in the sequence program. Figure 9.71 File register setting (a) Not used Select this in the following cases.
  • Page 403 2) Point setting for file registers Select [Online] [Write to PLC] in GX Developer and set the number of file register points. When each of file registers A to C has the same name with the corresponding one of the program Example A to C, the operation is as described below.
  • Page 404 CHAPTER9 DEVICES (2) File register setting In a new device memory window, set data for the specified file register. Figure 9.73 Device memory window (a) Devices Setting R (R0 in the case shown above)and clicking the button will display the file register list. Display (b) Data setting Enter data that are set for the file register.
  • Page 405 (a) Target memory Select the Standard RAM, Memory card (RAM), or Memory card (ROM) from this list box. When using the same file name as that of the program, register the file register to the memory specified in the PLC File tab of the PLC parameter dialog box. (b) Selecting a file register file By selecting a memory for the file register, file names of the set file registers are displayed.
  • Page 406: Specification Methods Of The File Register

    CHAPTER9 DEVICES 9.7.5 Specification methods of the file register (1) Block switching method The file register points used are divided and specified in units of 32K points (R0 to R32767). If multiple blocks are used, the desired block is specified with the block number in the RSET instruction. Each block has a specification range of R0 to R32767.
  • Page 407: Precautions For Using The File Register

    9.7.6 Precautions for using the file register (1) No registration or use of an invalid file register number (a) When the file of the file register has not been registered Writing to or reading from the file register will result in "OPERATION ERROR" (error code: 4101). (b) When writing to or reading from the file register exceeding the registered size (points) "OPERATION ERROR"...
  • Page 408 CHAPTER9 DEVICES (c) File register size checking procedure • Check the file register size used for each sequence program. • Check the total file register size set in SD647 on the sequence program to see if there are sufficient number of points to be used or not. [Program example 1] The file register range of use is checked at the beginning of each program.
  • Page 409: Extended Data Register (D) And Extended Link Register (W)

    9.8 Extended Data Register (D) and Extended Link Register Note9.5 (1) Definition The extended data register (D) and extended link register (W) are devices for using the large-capacity file register (ZR) area as an extended area of the data register (D) and link register (W). These devices can be programmed as the data register (D) and link register (W) together with the file register (ZR) area.íç1 Device numbers can be assigned to the...
  • Page 410 CHAPTER9 DEVICES (2) Device numbers Device numbers for the extended data register (D) and extended link register (W) can be assigned consecutively after those for the internal user devices, data register (D) and link register (W). ● Even though device numbers are consecutively assigned, there is no physical area contiguity between the data register (D) (internal user device) and the extended data register (D), and between the link register (W) (internal user device) and the extended link register (W).
  • Page 411 (3) Setting method Since the extended data register (D) and extended link register (W) use the file register area, data must be set for both the file register setting and the device setting. (a) File register setting Select "Use the following file." in the PLC file tab of the PLC parameter dialog box, and enter data in the boxes indicated in Figure 9.79.
  • Page 412 CHAPTER9 DEVICES (b) Device setting Set each number of points for the file register (ZR), extended data register (D), and extended link register (W) in the File register extended setting in the Device tab of the PLC parameter dialog box. Assign a part of the points set for the file register (ZR) in the PLC file tab to the extended data register (D) and extended link register (W).
  • Page 413 (4) Checking the points by the special register The points for each of the file register (ZR), extended data register (D), and extended link register (W) can be checked in the following special register areas. • SD306, SD307: File register (ZR) •...
  • Page 414 CHAPTER9 DEVICES 6) To access the extended data register (D) or extended link register (W) from a module that does not support the use of these devices, device numbers need to be specified with those of the file register (ZR). Calculation formulas for obtaining device numbers of the file register (ZR) to be specified to access the extended data register (D) and extended link register (W) and calculation examples are described below.
  • Page 415: Nesting (N)

    9.9 Nesting (N) (1) Definition Nesting (N) is a device used in the master control instructions (MC and MCR instructions) to program operation conditions in a nesting structure. (2) Specification method using master control instructions The master control instruction opens or closes a common ladder gate to switch the ladder of a sequence program efficiently.
  • Page 416: Pointer (P)

    CHAPTER9 DEVICES 9.10 Pointer (P) (1) Definition The pointer (P) is a device used in jump instructions (CJ, SCJ, or JMP) or subroutine call instructions (such as CALL). (2) Applications Pointers can be used in the following applications. • Specification of the jump destination in a jump instruction (CJ, SCJ, or JMP) and a label (start address of the jump destination) •...
  • Page 417: Local Pointer

    9.10.1 Local pointer (1) Definition The local pointer is a pointer that can be used independently in jump instructions and subroutine call instructions in each program. The same pointer number can be used in respective programs. Program A Program B The same pointer No.
  • Page 418 CHAPTER9 DEVICES (3) Precautions for using the local pointer (a) Program where the local pointer is described A jump from another program is not allowed. jump instructions and sub-routine CALL instructions. Use the ECALL instruction from another program when calling a subroutine program in a program file that contains any local pointer.
  • Page 419: Common Pointer

    9.10.2 Common pointer (1) Definition The common pointer is used to call subroutine programs from all programs that are being executed. Program A Program C P204 CALL P204 CALL P0 FEND P205 Program B CALL P205 FEND Label Figure 9.87 Calling pointers in another program (common pointer) (2) Common pointer range In the PLC system tab of the PLC parameter dialog box, set the start number for the common pointer.
  • Page 420 CHAPTER9 DEVICES (3) Precautions 1) The same pointer number cannot be used as a label. Doing so will result in a "Pointer configuration error" (error code: 4021). 2) If the total number of the local pointer points used in several programs exceeds the start number of the common pointer, a "Pointer configuration error (error code: 4020) will occur.
  • Page 421: Interrupt Pointer(I)

    9.11 Interrupt Pointer(I) (1) Definition The interrupt pointer (I) is used as a label at the beginning of an interrupt program, and can be used in all programs that are being executed. Interrupt pointer (interrupt program label) Interrupt program IRET Figure 9.90 Interrupt pointer (2) Number of available points The number of points available for the interrupt pointer is 256 (I0 to I255).
  • Page 422: List Of Interrupt Pointer Numbers And Interrupt Factors

    CHAPTER9 DEVICES 9.11.1 List of interrupt pointer numbers and interrupt factors The list of interrupt pointer numbers and interrupt factors are shown below. Table9.11 List of interrupt pointer numbers and interrupt factors I No. Interrupt factor Priority I No. Interrupt factor Priority 1st point 2nd point...
  • Page 423: Other Devices

    9.12 Other Devices 9.12.1 SFC block device (BL) The SFC block is used to check that the specified block in the SFC program is activated. Remark For use of the SFC block device, refer to the following. QCPU (Q Mode)/QnACPU Programming Manual (SFC) 9.12.2 Network No.
  • Page 424: I/O No. Specification Device (U)

    CHAPTER9 DEVICES 9.12.3 I/O No. specification device (U) (1) Definition The I/O No. specification device is used to specify I/O numbers in the intelligent function module dedicated instructions. (2) Specification method In the intelligent function module dedicated instruction, this device is specified as shown in Figure 9.92. GP.READ S1 S2 S3 D I/O No.
  • Page 425: Macro Instruction Argument Device (Vd)

    9.12.4 Macro instruction argument device (VD) (1) Definition The macro instruction argument device (VD) is used with ladders registered as macros. When a VD setting is specified, the value is converted to the specified device when the macro instruction is executed.
  • Page 426: Constants

    CHAPTER9 DEVICES 9.13 Constants 9.13.1 Decimal constant (K) (1) Definition The decimal constant (K) is used to specify decimal data in sequence programs. Specify it as K (example: K1234) in sequence programs. In the CPU module, data are stored in binary (BIN). ( Section 2.4.1) (2) Specification range The specification ranges for decimal constants are as follows:...
  • Page 427: Real Number (E)

    9.13.3 Real number (E) (1) Definition The real number (E) is a device used to specify real numbers in sequence programs. In sequence programs, specify it as E (example: E1.234). ( Section 2.4.4) EMOVP E1.234 D0 Figure 9.95 Real number specification (2) Specification range (a) Real number setting range •...
  • Page 428: Character String (" ")

    CHAPTER9 DEVICES 9.13.4 Character string (" ") (1) Definition The character string is a device used to specify a character string in sequence program. Characters enclosed in quotation marks (example: "ABCD1234") are specified. (2) Available characters All ASCII code characters can be used in character strings. The CPU module distinguishes between upper and lower case characters.
  • Page 429: Convenient Usage Of Devices

    9.14 Convenient Usage of Devices When multiple programs are executed in the CPU module, each program can be executed independently by specifying an internal user device as a local device. Devices of the CPU module are classified into the following two types: •...
  • Page 430: Local Device

    CHAPTER9 DEVICES ● All of the devices that have not been set as local devices ( Section 9.14.2) are global devices. ● For execution of multiple programs, the range to be shared by all programs and the range to be used independently by each program ( Section 9.14.2) must be specified in advance.
  • Page 431 (1) Devices that can be used as local devices The following devices can be used as local devices. • Internal relay (M) • Edge relay (V) • Timer (T, ST) • Counter (C) • Data register (D) • Index register (Z) íç1 Note9.7 (2) Saving and restoring a local device file...
  • Page 432 CHAPTER9 DEVICES (3) Local device setting (a) Setting the local device range In the Device tab of the PLC parameter dialog box, set the range that is used as a local device. Figure 9.100 Device Note that the local device range is common to all programs, and cannot be changed for each program. For example, if a local device range is specified as M0 to M100, this range setting applies to all programs that use the local device.
  • Page 433 (b) Setting the drive and file name After setting the local device range, set a memory for storing the local device file and a file name in the PLC file tab of the PLC parameter dialog box. Figure 9.102 PLC file (c) Writing the setting data Write the data set in (a) and (b) to the CPU module.
  • Page 434 CHAPTER9 DEVICES ● If the size setting of the local device in the standard RAM is changed with a sampling trace file stored in the standard RAM, the sampling trace file is cleared. To save the trace results in your personal computer, perform the following operations. 1) Click the Trace result PLC read button on the Sampling trace dialog box to read the trace result into the...
  • Page 435 (a) Setting method In addition to the setting in (3) in this section, set the following. Select the File usability setting button in the Program tab of the PLC parameter dialog box, and specify the programs that use the local device. Click the File usability setting button.
  • Page 436 CHAPTER9 DEVICES (5) Using the local device corresponding to the file where a subroutine program is stored When executing a subroutine program, you can utilize the local device corresponding to the file where the subroutine program is stored. Use of the relevant local device is set by ON/OFF of SM776. Table9.14 Local device switching by ON/OFF of the special relay (SM776) SM776 Operation...
  • Page 437 (c) Precautions • When SM776 is on, local device data are read out when a subroutine program is called, and the data are saved after execution of the RET instruction. Because of this, the scan time is increased if one subroutine program is executed with SM776 set to on. •...
  • Page 438 CHAPTER9 DEVICES (6) When executing an interrupt/fixed scan execution type program When executing an interrupt/fixed scan execution type program, you can utilize the local device corresponding to the file where the program is stored. Use of the relevant local device is set by ON/OFF of SM777. *1: The index register set as the local device uses the local device area for the program executed before the interrupt/fixed scan execution type program, regardless of the on/off status of SM777.
  • Page 439 (c) Precautions • When SM777 is on, local device data are read out before execution of an interrupt/fixed scan execution type program, and the data are saved after execution of the IRET instruction. Because of this, the scan time is increased if one interrupt/fixed scan execution type program is executed with SM777 set to on.
  • Page 440: Scan Time

    CHAPTER10 CPU MODULE PROCESSING TIME CHAPTER10 CPU MODULE PROCESSING TIME This chapter describes the CPU module processing time. 10.1 Scan Time This section describes the scan time structures and CPU module processing time. 10.1.1 Scan time structure A CPU module sequentially performs the following processing in the RUN status. Scan time is the time required for all processing and executions to be performed.
  • Page 441: Time Required For Each Processing Included In Scan Time

    (1) How to check scan time The CPU module measures current, minimum, and maximum values of the scan time. The scan time can be checked by monitoring the special register (SD520, SD521, and SD524 to SD527). Accuracy of each stored scan time is 0.1ms.
  • Page 442 CHAPTER10 CPU MODULE PROCESSING TIME Instruction execution time in END processing This is the processing time of the DUTY instruction in END processing. The user timing clock (SM420 to 424 and SM430 to SM434) specified with the DUTY instruction is turned on/off during the END processing.
  • Page 443 (a) Overhead time at execution of interrupt and fixed scan execution type programs When calculating instruction execution time, add the overhead time given in the following table to the instruc- tion execution time, which is described in (3). Two kinds of overhead time (pre-start and program-end) need to be added to interrupt programs. Table10.3 Pre-start overhead time for interrupt programs Interrupt (I0 to I15) from QI60 or...
  • Page 444 CHAPTER10 CPU MODULE PROCESSING TIME 1) Overhead time when local devices in the interrupt program are enabled When SM777 (Enable/disable local device in interrupt program) is turned on, the time given in Table10.6 and Table10.7 will be added to the overhead time given in Table10.3 and Table10.4. Each n, N1, N2, and N3 in the table indicates the following: •...
  • Page 445 Module refresh time Module refresh time is the total time required for the CPU module to refresh data with CC-Link IE con- troller network, MELSECNET/H, and CC-Link modules. (a) Refresh via CC-Link IE controller network This is the time required for refreshing data between link devices in a CC-Link IE controller network module and devices in the CPU module.
  • Page 446 CHAPTER10 CPU MODULE PROCESSING TIME (d) Auto refresh with an intelligent function module This is the time required for refreshing data between the buffer memory of an intelligent function module and devices in the CPU module. Use intelligent function module utility package (GX Configurator) for auto refresh settings. Calculation method Use the following expression to calculate the auto refresh time with an intelligent function module.
  • Page 447 (5) Function execution time in END processing This is the time required for updating calender or clearing error in END processing. (a) Calendar update processing time When the clock data set request (SM210 changes from off to on) or the clock data read request (SM213 turns on) is issued, the processing time for changing or reading the clock data is required in END processing.
  • Page 448 CHAPTER10 CPU MODULE PROCESSING TIME Device data latch processing time *1 *2 *3 When the latch range is set in the Device tab of the PLC parameter dialog box , the processing time shown in Table10.12 is required. Each N1, N2, and N3 in the table indicates the following: •...
  • Page 449 Service processing time Service processing is the communication processing with GX Developer and external devices. When monitoring device data, reading programs, and setting monitor conditions in GX Developer, the processing time shown in Table10.13 or Table10.14 is required. Table10.13 Processing time to monitor device data and read programs Processing time Monitoring device CPU module...
  • Page 450: Factors That Increase The Scan Time

    CHAPTER10 CPU MODULE PROCESSING TIME 10.1.3 Factors that increase the scan time When executing any of the functions or operations described in this section, add the given processing time to the time value calculated in Section 10.1.2. (1) Sampling trace When the sampling trace function ( Section 6.14) is executed, the processing time shown in Table10.16 is required.
  • Page 451 (2) Use of local devices When local devices are used, the processing time shown in Table10.17 is required. Each n, N1, N2, and N3 in the table indicates the following: • n: Number of programs using a local device • N1: Number of devices that specified a local device •...
  • Page 452 CHAPTER10 CPU MODULE PROCESSING TIME (a) When local devices in a subroutine program are enabled When SM776 (Enable/disable local device at CALL) is turned on, the processing time shown in Table10.18 or Table10.19 is required for each subroutine call. Each n, N1, N2, and N3 in the table indicates the following: •...
  • Page 453 (3) Execution of multiple programs When multiple programs are executed, the processing time shown in Table10.20 is required for each program. Table10.20 Processing time for each program (when multiple programs are executed) CPU module Processing time Q00UJCPU, Q00UCPU, Q01UCPU 0.053 Q02UCPU 0.04 Q03UDCPU, Q03UDECPU...
  • Page 454 CHAPTER10 CPU MODULE PROCESSING TIME (6) Online change When data is written to the running CPU module, the processing time described below is required. (a) Online change (ladder mode) When a program in the running CPU module is changed in ladder mode, the processing time shown in Table10.23 is required.
  • Page 455 (7) Non-group output status read In multiple CPU systems, the scan time increases when “All CPUs can read all outputs” is selected in the Multiple CPU settings screen of the PLC parameter dialog box. The scan time increases when this parameter is set. Figure 10.3 Multiple CPU settings screen (8) Scan time measurement When the scan time is measured by GX Developer, the processing time shown in Table10.25 is required (...
  • Page 456 CHAPTER10 CPU MODULE PROCESSING TIME (9) Batch transfer of data to the program memory When data in the program cache memory is batch-transferred to the program memory by GX Devel- oper, the processing time shown in Table10.26 is required. *1: The time in the table is for the case where the service processing count is set to one. Table10.26 Processing time (when data is batch-transferred to the program memory) Processing time CPU module...
  • Page 457: Items To Be Considered For Creating Programs

    CHAPTER11 PROCEDURES FOR WRITING PROGRAM TO CPU MODULE This chapter describes procedures for writing a program created by GX Developer to the CPU module. Remark For procedures for starting the CPU module, refer to the following. QCPU Userís Manual (Hardware Design, Maintenance and Inspection) 11.1 Items to be Considered for Creating Programs To create a program, the number of device points, size, and file name of the program must be predetermined.
  • Page 458 CHAPTER11 PROCEDURES FOR WRITING PROGRAM TO CPU MODULE (4) Setting the applications of devices and the number of device points Consider the applications of devices and the number of device points used in the program. CHAPTER 9) (5) Setting the initial device value Set data necessary as an initial value to the device memory and the buffer memory of the intelligent function module.
  • Page 459: Hardware Check

    11.2 Hardware Check This section describes a procedure for checking hardware before writing a created program. In the following procedure, indicates an operation on the CPU module side. Start GX Developer Version 8 Operating Manual Start GX Developer and create a project. Connect the personal computer to which GX Developer is installed to the CPU module.
  • Page 460 CHAPTER11 PROCEDURES FOR WRITING PROGRAM TO CPU MODULE Power off the programmable controller and then on or reset the CPU module. Set the RUN/STOP/RESET switch to RUN to change the CPU module in the RUN status. Is the RUN LED on? To Section 11.3 Is the ERR.
  • Page 461: Procedure For Writing One Program

    11.3 Procedure for Writing One Program This section describes a procedure for writing a program to the program memory. ( Section 5.1.2) Follow the procedure below and then the procedure provided in Section 11.5 before storing the program in the memory card for boot operation. In the following procedure, indicates an operation on the CPU module side.
  • Page 462 CHAPTER11 PROCEDURES FOR WRITING PROGRAM TO CPU MODULE Select [Online] [Format PLC memory] in GX Developer and format the program Write to PLC screen memory. To write the parameters, created program, and initial device value, make settings in the Write to PLC screen displayed by selecting [Online] [Write to PLC] in GX Developer.
  • Page 463: Procedure For Writing Multiple Programs

    11.4 Procedure for Writing Multiple Programs This section describes a procedure for writing multiple programs to the program memory. ( Section 5.1.2) Follow the procedure below and then the procedure provided in Section 11.5 before storing the programs in the memory card for boot operation. In the following procedure, indicates an operation on the CPU module side.
  • Page 464 CHAPTER11 PROCEDURES FOR WRITING PROGRAM TO CPU MODULE Set local devices? Set the local device range in the Device Section 9.14.1 tab of the PLC parameter dialog box. Set a file name for the local devices in the Section 9.14.1 PLC file tab of the PLC parameter dialog box.
  • Page 465 Is the ERR. LED on the CPU module on (flashing)? Check the error cause in the System Monitor screen displayed by selecting [Diagnostics] QCPU User's Manual [System Monitor] in GX Developer or in the (Hardware Design, Maintenance and Inspection) "PLC diagnostics" screen and remove the error. Start boot operation? To Section 11.5 Figure 11.3 Flowchart for writing multiple programs...
  • Page 466: Procedure For Boot Operation

    CHAPTER11 PROCEDURES FOR WRITING PROGRAM TO CPU MODULE 11.5 Procedure for Boot Operation This section describes a procedure for boot operation. In the following procedure, indicates an operation on the CPU module side. Start (continued from Section 11.3 Section 11.4 If the RUN/STOP/RESET switch is in RUN, set the switch to STOP.
  • Page 467 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGIS- TER LIST 12.1 SPECIAL RELAY LIST Special relays, SM, are internal relays whose applications are fixed in the Programmable Controller. For this reason, they cannot be used by sequence programs in the same way as the normal internal relays.
  • Page 468 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST (1) Diagnostic Information Table12.2 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU • Turns ON if an error occurs as a result of diagnosis. (Includes when an annunciator is ON, and when an Qn(H) error is detected with CHK instruction) S (Error)
  • Page 469 Table12.2 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • ON when operation error is generated OFF : Normal SM56 Operation error • Remains ON if the condition is restored to normal S (Error) M9011 ON : Operation error thereafter.
  • Page 470 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST (2) System information Table12.3 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU Qn(H) • When this relay goes from OFF to ON, the LEDs QnPH SM202 LED OFF command ON : LED OFF corresponding to the individual bits at SD202 go off...
  • Page 471 Table12.3 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • Goes OFF when reset of the No. 1 CPU is canceled. OFF : No. 1 CPU reset • Comes ON when the No. 1 CPU is resetting SM240 No.
  • Page 472 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.3 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Goes ON for standby network(If no designation has OFF : Operative network SM255 been made concerning active or standby, active is S (Initial) ON : Standby network assumed.)
  • Page 473 Table12.3 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • The SFC program starting mode in the SFC setting of the PLC parameter dialog box is set as the initial SFC program start OFF : Initial start M9102form SM322 value.
  • Page 474 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST (3) System clocks/counters Table12.4 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) S (Every END SM400 Always ON • Normally is ON M9036 processing) QCPU S (Every END SM401 Always OFF •...
  • Page 475 Table12.4 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation (When Set) ACPU • This relay alternates between ON and OFF at intervals of the time (unit: ms) specified in SD415. • When Programmable Controller power supply is Qn(H) turned ON or a CPU module reset is performed, QnPH...
  • Page 476 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST (6) Memory cards Table12.7 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Memory card usable OFF : Unusable SM600 • ON when memory card is ready for use by user S (Status change) flags ON : Use enabled...
  • Page 477 Table12.7 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation (When Set) ACPU Qn(H) OFF : File register not used QnPH SM650 Comment use • Goes ON when comment file is in use S (Status change) ON : File register in use QnPRH OFF : Internal memory Qn(H)
  • Page 478 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST (7) Instruction-Related Special Relays Table12.8 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) OFF : Carry OFF S (Instruction SM700 Carry flag • Carry flag used in application instruction M9012 QCPU ON : Carry ON...
  • Page 479 Table12.8 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) OFF : Not executed by • During OFF, XCALL instructions will not be executed XCALL instruction execution condition even if execution condition is risen. SM734 execution condition risen Qn(H)
  • Page 480 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.8 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • Turns ON when the number of the remaining blocks Block information of the dedicated instruction transmission area used S (When using multiple CPU OFF : Block is secured...
  • Page 481 (9) A to Q conversion correspondences Special relays SM1000 to SM1255 are the relays which correspond to ACPU special relays M9000 to M9255 after A to Q conversion. (However, the Basic model QCPU and Redundant CPU do not support the A to Q conversion.) These special relays are all set by the system, and cannot be set by the user program.
  • Page 482 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.11 Special relay ACPU Special Special Corresponding Special Relay after Relay for Name Meaning Details Relay Conversion Modification • Turns ON if an instantaneous power failure of within 20ms occurs during use of the AC power supply module. OFF : AC DOWN not •...
  • Page 483 Table12.11 Special relay ACPU Special Special Corresponding Special Relay after Relay for Name Meaning Details Relay Conversion Modification • Alternates between ON and OFF according to the seconds specified at SD414. (Default: n = 30) 2n minute clock(1 • Not turned on or off per scan but turned on and off even –...
  • Page 484 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.11 Special relay ACPU Special Special Corresponding Special Relay after Relay for Name Meaning Details Relay Conversion Modification OFF : Other than when P, I Main side P, I set set being requested M9056 SM1056 request...
  • Page 485 Table12.11 Special relay ACPU Special Special Corresponding Special Relay after Relay for Name Meaning Details Relay Conversion Modification OFF : Continuous transition Presence/absence • Set whether continuous transition will be performed for the not effective M9103 SM1103 SM323 of continuous block where the "continuous transition bit"...
  • Page 486 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST (11) Process control instructions Table12.13 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Specifies whether or not to hold the output value OFF : No-hold SM1500 Hold mode when a range over occurs for the S.IN instruction...
  • Page 487 Table12.13 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Turns on when the CPU module is started up by the OFF : Power supply on system switching (switching from the standby system CPU module startup startup SM1517 to the control system).
  • Page 488 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.13 Special relay Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU SM1549 SM1549 Block 30 SM1550 SM1550 Block 31 SM1551 SM1551 Block 32 SM1552 SM1552 Block 33 SM1553 SM1553 Block 34 SM1554...
  • Page 489 Table12.13 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Sets the operation for the case accessing buffer memory of the intelligent function module mounted on the extension base unit from the standby system CPU in separate mode.
  • Page 490 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST (14) For redundant system (tracking) Either the backup mode or the second mode is valid for SM1700 to SM1799. All is turned off for stand-alone system. Table12.15 Special relay Corres- ponding Set by Corresponding Number Name...
  • Page 491 Table12.15 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) SM1712 SM1712 Block 1 SM1713 SM1713 Block 2 SM1714 SM1714 Block 3 SM1715 SM1715 Block 4 SM1716 SM1716 Block 5 SM1717 SM1717 Block 6 SM1718 SM1718 Block 7 SM1719...
  • Page 492 CHAPTER12 SPECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.15 Special relay Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) SM1760 SM1760 Block 49 SM1761 SM1761 Block 50 SM1762 SM1762 Block 51 SM1763 SM1763 Block 52 SM1764 SM1764 Block 53 SM1765...
  • Page 493 12.2 SPECIAL REGISTER LIST The special registers, SD, are internal registers with fixed applications in the Programmable Controller. For this reason, it is not possible to use these registers in sequence programs in the same way that normal registers are used. However, data can be written as needed in order to control the CPU modules.
  • Page 494 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (1) Diagnostic Information Table12.18 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) D9008 Diagnostic Diagnosis error • Error codes for errors found by diagnosis are stored as BIN data. S (Error) format errors...
  • Page 495 Table12.18 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • Common information corresponding to the error codes (SD0) is stored here. • The following ten types of information are stored here: • The error common information type can be judged by the "common infor- mation category code"...
  • Page 496 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.18 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) Time (value set) Number Meaning Time : 1 s units (0 to 999 s) Time : 1ms units (0 to 65535ms) SD10 (Empty) SD11...
  • Page 497 Table12.18 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Reason(s) for system switching Number Meaning System switching condition Control system switching instruction argument SD10 (Empty) SD11 SD12 SD13 SD14 SD15 *13: Details of reason(s) for system switching 0 : No system switching condition (default) 1 : Power-OFF, reset, hardware failure,...
  • Page 498 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.18 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU Tracking transmission data classification Stores the data classification during tracking. Number Meaning Data type SD10 (Empty) SD11 SD12 SD13 SD14...
  • Page 499 Table12.18 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Individual information corresponding to error codes (SD0) is stored here. • There are the following eight different types of information are stored. • The error individual information type can be judged by the "individual SD16 information category code"...
  • Page 500 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST *6 : Extensions are shown below. Table12.19 Extension name SDn+1 Extension File Type Name Higher 8 bits Lower 8 bits Higher 8 bits Parameters • Sequence program • SFC program Device comment Initial device value File register Local device...
  • Page 501 Table12.18 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Reason(s) for system switching failure Number Meaning System switching prohibition SD16 condition 14 SD17 SD18 SD19 SD20 SD21 (Empty) SD22 SD23 SD24 SD25 SD26 *14: Details of reason(s) for system switching failure 0 : Normal switching completion QnPRH (default)
  • Page 502 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.18 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU Error number that SD50 Error reset performs error • Stores error number that performs error reset reset •...
  • Page 503 Table12.18 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Annunciator Annunciator S (Instruction SD62 • The first annunciator number (F number) to be detected is stored here. D9009 number number execution) Number of Number of S (Instruction SD63 •...
  • Page 504 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.18 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU Stores the transmission Transmission speed specified in : 9.6kbps, : 19.2kbps, 384 : 38.4kbps, S (Power-ON or SD100 speed storage the serial...
  • Page 505 Table12.18 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • The numbers of output modules whose fuses have blown are input as a SD130 bit pattern (in units of 16 points). (If the module numbers are set by parameter, the parameter-set SD131 numbers are stored.) Bit pattern in units...
  • Page 506 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (2) System information Table12.20 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • The CPU switch status is stored in the following format: b12 b11 b8 b7 b4 b3 Empty 0: RUN...
  • Page 507 Table12.20 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • Specify the LEDs to be turned off using this register, and turn SM202 from OFF to ON to turn off the specified LEDs. USER and BOOT can be specified as the LEDs to be turned off. •...
  • Page 508 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.20 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU • When error is generated, the LED display (flicker) is made according to the error number setting priorities. (The Basic model QCPU supports only the annunciator (error item No.
  • Page 509 Table12.20 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • The year (first two digits) and the day of the week are stored as BCD code as shown below. Example: 1993, Friday 1905 Clock data Day of the week SD213 Clock data...
  • Page 510 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.20 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU Fixed to 0 Base type Main base unit differentiation Qn(H) 1st extension 0: QA**B is A/Q base S (Initial) QnPH base...
  • Page 511 Table12.20 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Number of • Indicates the number of mounted MELSECNET/10 modules or SD254 modules installed MELSECNET/H modules. • Indicates I/O number of mounted MELSECNET/10 module or SD255 I/O No.
  • Page 512 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.20 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU 1) When Xn0 of the mounted CC-Link module turns ON, the bit of the corresponding station turns to 1 (ON). 2) When either Xn1 or XnF of the mounted CC-Link module turns OFF, the bit of the corresponding station turns to 1 (ON).
  • Page 513 Table12.20 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • Stores the number of points of index register (Z) to be modified in the Device 16 bit modification range of 16 bits. SD305 assignment Number of points S (Initial) (The assignment is set by the ZR device index modification setting...
  • Page 514 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.20 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU Not used Instruction reception status of channel 1 Instruction reception status of channel 2 Instruction reception status of channel 3 Instruction reception Ethernet Instruction...
  • Page 515 Table12.20 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation (When Set) ACPU Number of • The number of CPU modules that comprise the multiple CPU system is Q00/Q01 SD393 multiple CPUs stored. (1 to 3, Empty also included) •...
  • Page 516 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (4) Scan information Table12.22 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Qn(H) Execution Program No. in • Program number of program currently being executed is stored as BIN S (Status QnPH SD500...
  • Page 517 Table12.22 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Minimum scan SD524 time (in 1 ms • Stores the minimum value of the scan time into SD524 and SD525. units) Minimum scan (Measurement is made in 100 s units.) S (Every END time SD524: Stores the ms place.
  • Page 518 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (5) Memory card Table12.23 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation (When Set) ACPU • Indicates the type of the memory card installed. b8 b7 b4 b3 0: Does not exist Drive 1 Qn(H) (RAM) type...
  • Page 519 Table12.23 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Indicates the drive 3/4 type. Drive 3 Qn(H) (Standrd Fixed to 1 QnPH S (Initial) RAM) QnPRH Drive 4 (Standrd Fixed to 3 ROM) SD620 Drive 3/4 typs Drive 3/4 typs...
  • Page 520 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.23 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Stores file register file name (with extension) selected at parameters or SD641 by use of QDRSET instruction as ASCII code. SD642 2nd character 1st character...
  • Page 521 Table12.23 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Stores information of parameter storage destination drive which is enabled. 0: Drive 0 (Program memory) Parameter Parameter enable 1: Drive 1 (SRAM card) SD670 enable drive S (Initial) drive No.
  • Page 522 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Stores the last 2 digits of year and month when data is restored in 2-digit BCD code. Example: Restore time SD676 July, 1993 (Year and month)
  • Page 523 Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) Backup execution • Displays the execution status of data backup to the memory card in Backup S (Status SD691 status display percentage (0 to 100%). execution status change) (Percentage) •...
  • Page 524 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (6) Instruction-Related Registers Table12.24 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • During block operations, turning SM705 ON makes it possible to use the Q00J/Q00/Q01 SD705 mask pattern being stored at SD705 (or at SD705 and SD706 if double Qn(H)
  • Page 525 Table12.24 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • Specify the limit of each PID loop as shown below. SD774 PID limit setting Qn(H) 0: With limit (for complete QnPRH SD774 Loop16 Loop2 Loop1 1: Without limit SD775...
  • Page 526 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.24 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Selects whether or not the data is refreshed when the COM, CCOM instruction is executed. • Designation of SD778 is made valid when SM775 turns ON. SD778 0/1 0/1 I/O refresh...
  • Page 527 Table12.24 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Maximum number of • Specifies the maximum number of blocks used for the multiple CPU blocks used for high-speed transmission dedicated instruction (target CPU=CPU No.1). the multiple When the dedicated instruction of Multiple CPU transmission is CPU high-...
  • Page 528 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (7) Debug Table12.25 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) Stores the status of the debug function usage as shown below. 0: Forced ON/OFF for external I/O 1: Executional conditioned device test 2 to 15:Absent (0 fix) b1 b0...
  • Page 529 (10) A to Q conversion ACPU special registers D9000 to D9255 correspond to Q special registers SD1000 to SD1255 after A to Q/QnA conversion. (However, the Basic model QCPU and Redundant CPU do not support the A to Q conversion.) These special registers are all set by the system, and cannot be set by the user program.
  • Page 530 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.28 Special register Special ACPU Special Register Corresponding Special Register for Name Meaning Details after Register Modification Conversion • When fuse blown modules are detected, the first I/O number of the lowest number of the detected modules is stored in hexadecimal. (Example: When fuses of Y50 to 6F output modules have blown, Qn(H) "50"...
  • Page 531 Table12.28 Special register Special ACPU Special Register Corresponding Special Register for Name Meaning Details after Register Modification Conversion • When one of F0 to 2047 is turned on by OUT F or SET F instruction, the F number, which has been detected earliest Qn(H) F number at which Annunciator...
  • Page 532 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.28 Special register Special ACPU Special Register Corresponding Special Register for Name Meaning Details after Register Modification Conversion 0: Main program (ROM) 1: Main program (RAM) 2: Subprogram 1 (RAM) 3: Subprogram 2 (RAM) 4: Subprogram 3 (RAM)
  • Page 533 Table12.28 Special register Special ACPU Special Register Corresponding Special Register for Name Meaning Details after Register Modification Conversion • The day of the week is stored as BCD code as shown below. Example: Friday H0005 Day of the week Clock data –...
  • Page 534 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.28 Special register Special ACPU Special Register Corresponding Special Register for Name Meaning Details after Register Modification Conversion Transition condition • Stores the transition condition number, where error code 84 occurred D9053 SD1053 Error transition number where error...
  • Page 535 Table12.28 Special register Special ACPU Special Register Corresponding Special Register for Name Meaning Details after Register Modification Conversion • Output module numbers (in units of 16 points), of which fuses have D9100 SD1100 blown, are entered in bit pattern. (Preset output module numbers when parameter setting has been performed.) D9101 SD1101...
  • Page 536 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.28 Special register Special ACPU Special Register Corresponding Special Register for Name Meaning Details after Register Modification Conversion • When any of F0 to 2047 is turned on by SET F instruction, the D9125 SD1125 SD64...
  • Page 537 (11) QCPU with built-in Ethernet port Table12.29 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Stores the operation result of the time setting function. Operation Stores 0: Not executed SD1270 result operationresult. 1: Success FFFF : Failure Stores years (last two digits of the Christian Era) and monthes by two digits of...
  • Page 538 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.30 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) Open completion status of connections (whose open system is socket communication) using socket communication functions is stored. All bits corresponding to connections using any communications other than the socket communication are fixed to "0".
  • Page 539 (12) Fuse blown module Table12.31 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) SD1300 • The numbers of output modules whose fuses have blown are input as a D9100 bit pattern (in units of 16 points). SD1301 D9101 (If the module numbers are set by parameter, the parameter-set...
  • Page 540 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (15) For redundant systems (Host system CPU information SD1510 to SD1599 are only valid for redundant systems. They are all set to 0 for stand-alone systems. Table12.34 Special register Corres- Set by ponding Corresponding Number...
  • Page 541 (16) For redundant systems (Other system CPU information SD1600 to SD1659 is only valid during the back up mode for redundant systems, and refresh cannot be done when in the separate mode. SD1651 to SD1699 are valid in either the backup mode or separate mode. When a stand-alone system SD1600 to SD1699 are all 0.
  • Page 542 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST Table12.35 Special register Corres- ponding Set by Corresponding Number Name Meaning Explanation ACPU (When Set) • Stores the error code of the error to be cleared by clearing a standby system error. •...
  • Page 543 (17) For redundant systems (Trucking) SD1700 to SD1779 is valid only for redundant systems. These are all 0 for stand-alone systems. Table12.36 Special register Corres- Set by ponding Corresponding Number Name Meaning Explanation ACPU (When Set) • When the tracking error is detected, count is added by one. Tracking error Tracking error SD1700...
  • Page 544 CHAPTER12 PECIAL RELAY LIST AND SPECIAL REGISTER LIST (18) Redundant power supply module information SD1780 to SD1789 are valid only for a redundant power supply system. The bits are all 0 for a singular power supply system. Table12.37 Special register Corres- ponding Set by...
  • Page 545: Appendix 1 List Of Parameter Numbers

    APPENDICES Appendix 1 List of Parameter Numbers Each parameter number will be stored in the special register (SD16 to SD26) when an error occurs in the parameter settings. lists the parameter items and corresponding parameter numbers ï\ït.1 For explanation of M and N shown in the "Parameter No." column, refer to Section 8.2 TableApp.1 List of parameter numbers Item...
  • Page 546 APPENDICES TableApp.1 List of parameter numbers (Continued) Item Parameter No. Referance Use serial communication Transmission speed Section 6.23, Section Sum check 100E 8.1(10) Transmission wait time RUN write setting Section 6.24.1, Section Service processing setting 1013 8.1(2) Section 6.28, Section Latch data backup operation valid contact 1014 8.1(2)
  • Page 547 TableApp.1 List of parameter numbers (Continued) Item Parameter No. Referance Nunber of modules on MELSECNET/H 5000 Valid module during other station access 5001 Interlink transmission parameters 5002 Routing parameters 5003 Starting I/O No. Network No. 5NM0 Total stations Mode 5NM0 Section 8.2(2) Refresh parameters 5NM1...
  • Page 548 APPENDICES TableApp.1 List of parameter numbers (Continued) Item Parameter No. Referance Number of modules on CC-Link IE controller network A000 Interlink transmission parameters A002 Routing parameters A003 Starting I/O No. Network No. ANM0 Total stations Section 8.2(1) Station No. Mode ANM0 APPEN- Refresh parameters...
  • Page 549 TableApp.1 List of parameter numbers (Continued) Item Parameter No. Referance E002 Communication area setting (refresh setting) E003 Online module change E006 Refresh parameter detailed device specification E007 Section 8.1 (12), E008 CPU specific send range QCPU User’s Manual Multiple CPU high speed (Muitiple CPU System) E009 Auto refresh setting...
  • Page 550: Appendix 2 Functions Added Or Changed By Version Upgrade

    APPENDICES Appendix 2 Functions Added or Changed by Version Upgrade The universal model QCPU is upgraded when some functions are added or when specifications are changed. Therefore, the functions and specifications differs depending on the function version and serial number. (1) Function comparisons and supported GX Developer versions TableApp.2 Functions added and supported GX Developer versions Function...
  • Page 551 *1: Some models do not support the function. For details, refer to the corresponding reference. *2: Data of the extended data register (D) and extended link register (W) can be retained in the standard ROM by using the latch data backup to standard ROM function ( Section 6.28) if the serial number (first five digits) of the Universal model QCPU is "10042"...
  • Page 552: Appendix 3 Method Of Replacing Basic Model Qcpu Or High Performance Model Qcpu With Universal Model Qcpu

    APPENDICES Appendix 3 Method of Replacing Basic Model QCPU or High Performance Model QCPU with Universal Model QCPU Appendix 3.1 Pre cautions for Replacement This section describes precautions for replacing the Basic model QCPU or High Performance model QCPU with the Universal model QCPU and the replacement methods.
  • Page 553 TableApp.4 Precautions for replacement and replacement methods (Program) (Continued) Item Precautions Replacement method Reference The latch function of the Universal model QCPU is enhanced. (1) Large-capacity file register (R, ZR) (2) Writing/reading device data to the If latch ranges of internal user devices are standard ROM (SP.DEVST and specified, the processing time is added in Section 6.3, Appendix...
  • Page 554 APPENDICES TableApp.4 Precautions for replacement and replacement methods (Program) (Continued) Item Precautions Replacement method Reference To use the file register, capacity setting is Set the capacity of the file register used in File register required. the PLC file tab of the PLC parameter. The following settings are required for using SFC programs.
  • Page 555 (6) Program size TableApp.8 Precautions for replacement and replacement methods (Program size) Item Precautions Replacement method Reference Data in the program memory of the Basic model QCPU may exceed the size of the Store parameter and device comment Program size program memory of the Universal model files in the standard ROM.
  • Page 556: Appendix 3.1.2 Replacing High Performance Model Qcpu With Universal Model Qcpu

    APPENDICES Appendix 3.1.2 Replacing High Performance model QCPU with Universal model QCPU System configuration TableApp.9 Precautions for replacement and replacement methods (System configuration) Item Precautions Replacement method Reference Use of AnS/A series AnS/A series modules are not supported. Use Q series modules. module GOT900 series cannot be connected.
  • Page 557 Program TableApp.10 Precautions for replacement and replacement methods (Program) Item Precautions Replacement method Reference Replace the instructions not supported in Language and Some instructions are not supported. the Universal model QCPU are described Appendix 3.3 instruction in Appendix 3.3. Instructions for floating-point double- precision operations are added for the The Universal model QCPU performs Universal model QCPU.
  • Page 558 APPENDICES TableApp.9 Precautions for replacement and replacement methods (Program) (Continued) Item Precautions Replacement method Reference The interrupt pointer (I49) for the high- Consider the use of interrupt pointers for speed interrupt function is not supported. fixed scan interrupt (I28 to I31). Check the numbers of executions for Section 6.13.2, 9.2.11 interrupt programs on the Interrupt...
  • Page 559 Drive and file TableApp.11 Precautions for replacement and replacement methods (Drive and file) Item Precautions Replacement method Reference Since the Universal model QCPU holds the data in the program memory even when the battery voltage drops, the boot Files in the standard ROM cannot be file setting is not necessary.
  • Page 560 APPENDICES Debugging TableApp.14 Precautions for replacement and replacement methods (Debugging) Item Precautions Replacement method Reference Use the sampling trace function for checking device data under the specified monitoring condition. With this function, changes of the specified device data can be recorded at the following timings: The monitoring condition cannot be set.
  • Page 561 Switch on the front of the CPU module TableApp.15 Precautions for replacement and replacement methods (Switch on the front of the CPU module) Item Precautions Replacement method Reference The RESET/STOP/RUN switch of the Section 4.4 in the Universal model QCPU can be used for QCPU User's Manual The operation method with the RESET/ the reset operation of the CPU module...
  • Page 562 APPENDICES TableApp.16 Precautions for replacement and replacement methods (SFC) Item Precautions Replacement method Reference Section 4.6 and Change the program as described in Appendix 3.1 in the Step transition The step transition monitoring timer is not Appendix 3.1 in the manual in the QCPU (Q Mode)/ monitoring timer supported.
  • Page 563: Appendix 3.2 Applicable Devices And Software

    Appendix 3.2 Applicable devices and software (1) Products need to be replaced for the compatibility with the Universal model QCPU The following tables show products need to be replaced for the compatibility with the Universal model QCPU. (As for products not listed in the tables below, replacement is not required.) TableApp.17 Product need to be replaced (Communication module) Serial number (first five digits) of the product compatible with the Universal model QCPU...
  • Page 564 APPENDICES TableApp.20 Product need to be replaced (Network module and serial communication module) Module version compatible with the Universal model QCPU Used with Q00UJ/Q00U/Q01U/Q02U/ Product Model Q03UD/Q04UDH/Q06UDH/Q10UDH/ Used with Built-in Ethernet port QCPU Q13UDH/Q20UDH/Q26UDHCPU • QJ71LP21-25 Some restrictions depending on use •...
  • Page 565 (2) CPU modules that can configure a multiple CPU system with the Universal model QCPU CPU modules that can configure a multiple CPU system with the Universal model QCPU are shown below. (a) For the QnUD(H)CPU or Built-in Ethernet port QCPU TableApp.21 CPU module that can configure a multiple CPU system with the QnUD(H)CPU or Built-in Ethernet port QCPU Applicable version Configured with...
  • Page 566 APPENDICES (3) Software need to be upgraded for the compatibility with the Universal model QCPU The following table shows software need to be upgraded for the communication with the Universal model QCPU. (As for software not listed in the table below, version upgrade is not required.) The latest version can be downloaded from the MELFANSweb.
  • Page 567: Appendix 3.3 Instructions

    Appendix 3.3 Instructions Appendix 3.3.1 Instructions not supported in the Universal model QCPU and replacing methods The Universal model QCPU does not support instructions listed in the TableApp.24. and TableApp.25. Instructions need to be replaced using replacing methods described in the tables. (If no instruction in the list is used, replacement is not required.) TableApp.25 Instructions not supported in the Universal model QCPU and replacing methods Symbol...
  • Page 568 APPENDICES TableApp.26 SFC control instructions not supported in the Universal model QCPU and replacing methods Symbol Instruction Replacing method LD TRn AND TRn OR TRn LDI TRn ANDI TRn ORI TRn Forced transition check When the programmable controller type is changed, these instructions are instruction converted into SM1255.
  • Page 569 Appendix 3.3.2 Replacing programs using multiple CPU transmission dedicated instructions (1) Replacing the module with the QnUD(H)CPU or Built-in Ethernet port QCPU TableApp.26 shows instructions need to be replaced and corresponding alternative instructions. For the specifications of each instruction, refer to the manuals for the Motion CPU. TableApp.27 SFC instructions not supported in the QnUD(H)CPU and Built-in Ethernet port QCPU and thier alternatives Symbol of alternative Symbol...
  • Page 570: Appendix 3.3.3 Program Replacement Examples

    APPENDICES Appendix 3.3.3 Program replacement examples This section shows program replacement examples for the instructions of which replacement programs are available in Appendix 3.3. (Skip this section if instructions listed in Appendix 3.3.1 are not used.) (1) Replacement example of the IX and IXEND instructions Since index registers are saved using the ZPUSH instruction, a 23-word index register save area is required.
  • Page 571 (c) Program after replacement • Replace the IX instruction with the ZPUSH instruction and the processing for setting the contents of index modification table to index registers. • Replace the IXEND instruction with the ZPOP instruction. Current index register is saved.
  • Page 572 APPENDICES Replacement example of the IXDEV and IXSET instructions Change the program so that the device offset value specified by the contacts between the IXDEV and the IXSET instructions are directly set to the index modification table using the MOV instruction. For the devices whose device offset value is not specified by the IXDEV and IXSET instructions, set the device offset value to 0 in the program after replacement.
  • Page 573 Program before replacement The device offset values for input (X), output (Y), internal relay (M), data register (D), link register (W), and pointer (P) are set to the index modification table starting from D0. Figure App.4 Sample program Program after replacement The device offset values specified by the IXDEV and IXSET instructions are set to the index...
  • Page 574 APPENDICES Replacement example of the PR instruction The number of output characters can be switched by the on/off status of SM701. Example of device assignment TableApp.29 Example of device assignment Before replacemen After replacement Application Device Application Device Output string D0 to D3 Output string D0 to D3...
  • Page 575 (c) Program after replacement In the sequence program after replacement, three programs are required as shown below. <Before transition> <After transition> Main routine Main routine program program Output strings and output string storage address are set. FEND Subroutine program Initial processing IInterrupt program The strings stored in D0 are output.
  • Page 576 APPENDICES 2) Subroutine program • In the subroutine program, the data for outputting ASCII codes using a fixed scan interrupt program (10ms) are set to work devices. Also, the flag for activating the processing in the fixed scan interrupt pro- gram is turned on.
  • Page 577 3) Interrupt program The following processing is added to a fixed scan interrupt program (10ms). The fixed scan interrupt program outputs ASCII codes from the output module and controls the strobe signal. The following signals are all turned off when all strings are output.
  • Page 578 APPENDICES Replacement example of the CHKST and CHK instructions In the example below, if the replacement program for the CHKST and CHK instructions detects a failure, a failure number (contact number + coil number) is stored in D200 and the annunciator F200 is turned on. Example of device assignment TableApp.30 Example of device assignment Before replacement...
  • Page 579 (c) Program after replacement In the sequence program after replacement, two programs are required as shown below. <Before transition> <After transition> Main routine Main routine program program Initial processing FEND Subroutine program An failure status is checked, and if a failure is detected, a failure number is stored in D200.
  • Page 580 APPENDICES 2) Subroutine program • In the subroutine program, an failure status is checked using a failure detection ladder pattern. • If a failure is detected, a failure number is stored in D200 and the annunciator F200 is turned on. •...
  • Page 581 Replacement example of the KEY instruction Example of device assignment TableApp.31 Example of device assignment Before replacemen After replacement Application Device Application Device Numeric input execution Numeric input execution instruction instruction Input complete flag Input complete flag Input data area D200 to D203 Input data area D200 to D203...
  • Page 582 APPENDICES (c) Program after replacement In the sequence program after replacement, two programs are required as shown below. <Before transition> <After transition> Main routine Main routine program program Initial processing FEND Subroutine program ASCII code is added to the input data area. APPEN- Figure App.16 Program execution 1) Main routing program...
  • Page 583 2) Subroutine program • In the subroutine program, ASCII codes specified by an argument are added to the input data area and the completion status is checked. Specify the following arguments for the subroutine program • First argument ASCII code input from the input module (K2Xn) (Input) Second argument Number of digits to be input...
  • Page 584: Appendix 3.4 Functions

    APPENDICES Appendix 3.4 Functions Appendix 3.4.1 Floating-point operation instructions (1) Differences between High Performance model QCPU and Universal model QCPU (a) High Performance model QCPU The High Performance model QCPU can perform only the single-precision floating-point operation instructions. Note, however, that internal operation processing can be performed in double precision by selecting the item shown below (default: selected).
  • Page 585 (2) Floating-point operation instructions for the Universal model QCPU TableApp.30 lists floating-point operation instructions for the Universal model QCPU. Specifications of the single-precision floating-point operation instructions are compatible with those for the High Performance model QCPU. TableApp.32 List of floating-point operation instructions supported in the Universal model QCPU Instruction symbol Instruction name Remarks...
  • Page 586 APPENDICES (3) Advantages and disadvantages when using the double-precision floating-point data of the Universal model QCPU TableApp.32 shows the advantages and disadvantages when executing the double-precision floating-point opera- tion instructions in the Universal model QCPU. If higher accuracy is required in floating-point operations, it is recommended to replace the instruc- tions with the double-precision floating-point operation instructions.
  • Page 587 Replacing the High Performance model QCPU with the Universal model QCPU (a) Replacing all single-precision floating-point operation instructions with double-precision floating-point operation instructions Single-precision floating-point data occupy two points of word device per data. On the other hand, four points are required per double-precision floating-point data. Therefore, all device numbers for storing floating-point data need to be reassigned.
  • Page 588 APPENDICES (b) Replacing a part of floating-point operation instructions with double-precision floating-point operation instructions Only operations that require high accuracy are replaced with double-precision floating-point opera- tion instructions. Using the ECON and EDCON instructions, convert floating-point data mutually between single pre- cision and double-precision.
  • Page 589 Program after replacement Floating-point data are converted from single precision to double precision. Operation is performed using double-precision floating-point data. The floating-point operation result data are converted from double precision to singe precision. Figure App.23 Sample program App - 45...
  • Page 590 APPENDICES (c) Replacing a part of floating-point operation instructions with double-precision floating-point operation instructions using subroutine programs The flow of a replacement program described in (b) can be regarded as one subroutine program. Create a subroutine program for each floating-point operation instruction and then replace the original floating- point operation instructions with the CALL(P) instruction so that the corresponding subroutine program is called.
  • Page 591 Program after replacement A subroutine program for multiplication using the double-precision floating-point operation instruction A subroutine program for addition using the double-precision floating-point operation instruction Figure App.25 Sample program App - 47...
  • Page 592: Appendix 3.4.2 Error Check Processing For Floating-Point Data Comparison Instructions

    APPENDICES Appendix 3.4.2 Error check processing for floating-point data comparison instructions (1) Input data check Error check processing for floating-point data comparison instructions performed in the Universal model QCPU are enhanced. Input of a "special value" (-0, nonnumeric, unnormalized number, or ) is checked, and if those special values are input, the CPU module detects “OPERATION ERROR”...
  • Page 593 Example 2) Not detecting “OPERATION ERROR” (error code: 4140) in the ANDE instruction [Ladder mode] [List mode] In the ladder block starting from the step 104, the ANDE<= instruction of the step 105 is not executed when the M101 (valid data flag) is off. The ANDE<= instruction of the step 105 is not executed when the M101 is off in the LD instruction of the step 104 in the program above.
  • Page 594 APPENDICES Method of avoiding “OPERATION ERROR” (error code: 4140) in the floating-point data comparison instructions As shown in the modification examples below, connect the contacts of valid data flag in series for each floating- point data comparison instruction. (Use AND connection for connecting the contact of the valid data flag and the floating-point data comparison instruction.) Make sure that there is no line (OR connection) between the valid data flag and the floating-point data compari- son instruction.
  • Page 595 Program examples after modification for Example 1) and 3) in (1) are shown below. Example 4) Program after modification for Example 1) ("OPERATION ERROR" (error code: 4140) is no longer detected.) [Ladder mode] [List mode] Example 5) Program after modification for Example 3) ("OPERATION ERROR" (error code: 4140) is no longer detected.) [Ladder mode] [List mode]...
  • Page 596: Appendix 3.4.3 Device Latch Function

    APPENDICES Appendix 3.4.3 Device latch function (1) Overview The device latch function for the Universal model QCPU is more enhanced compared to that for the Basic model QCPU and High performance model QCPU. This section describes the enhanced device latch function in the Universal model QCPU. *1: The latch function is used to hold device data even when the CPU module is powered off or reset.
  • Page 597 (c) Specifying the latch range of internal user devices Device data of the Universal model QCPU can be latched by specifying a latch range of internal user devices in the same way as for the Basic model QCPU and High Performance model QCPU. The ranges can be set in the Device tab of the PLC parameter dialog box.
  • Page 598: Appendix 3.4.4 File Usability Setting

    APPENDICES Appendix 3.4.4 File usability setting (1) Differences between High Performance model QCPU and Universal model QCPU (a) High Performance model QCPU In the High Performance model QCPU, file usability ("Use PLC file setting" or "Not used") of the following files can be set for each program on the screen opened by clicking the "File usability setting"...
  • Page 599 (b) Universal model QCPU In the Universal model QCPU, file usability of the following files cannot be set for each program on the screen opened by clicking the "File usability setting" button on the Program tab of the PLC parameter dialog box. •...
  • Page 600 APPENDICES (2) Method of replacing High Performance model QCPU with Universal model QCPU Replacement method varies depending on the settings in the PLC file tab of the PLC parameter dialog box. TableApp.41 Replacement method Setting in the PLC file tab Setting in Universal model QCPU No change in parameter settings is required.
  • Page 601 Appendix 3.4.5 Parameter-valid drive and boot file setting (1) Differences between High Performance model QCPU and Universal model QCPU (a) High Performance model QCPU The parameter-valid drive is specified by the switches on the front panel of the High Performance model QCPU.
  • Page 602 APPENDICES TableApp.42 When the parameter-valid drive is set to the standard ROM (Continued) Setting in High Performance model QCPU Setting in Universal model QCPU Setting in the Boot file tab of the PLC parameter dialog box Change the setting so that the Universal model QCPU can refer to the Settings in the Boot file tab parameters in the memory card, and programs and parameters are booted from the memory card to the program memory.
  • Page 603 When the parameter-valid drive is set to the memory card (RAM) or memory card (ROM) in the High Performance model QCPU TableApp.43 When the parameter-valid drive is set to the memory card (RAM) or memory card (ROM) Setting in High Performance model QCPU Setting in Universal model QCPU Setting in the Boot file tab of the PLC parameter dialog box...
  • Page 604 APPENDICES Appendix 3.4.6 External input/output forced on/off function (1) Differences between High Performance model QCPU and Universal model QCPU (a) High Performance model QCPU External input/output can be forcibly turned on/off on the screen opened by selecting [Online] [Debug] [Forced input output registration/cancellation] in GX Developer. íç1 Universal model QCPU The external input/output forced on/off function is not supported in the Universal model QCPU.
  • Page 605 Example) Forcibly turning X40, X77, and X7A on, and X41 and Y7B off The programs, "SETX" and "SETY", turns on or off the X and Y devices, which have been registered for forced on/off using the external input/output forced on/off function, at each scan using the SET and RST instructions.
  • Page 606 APPENDICES (3) Replacing the COM instruction If the COM instruction is used, add subroutine calls for P10 and P11 before and after the COM instruc- tion. (P10 and P11 are pointers shown in the program examples in (2).) When SM775 is on (Executes refresh set by SD778) and also the 0 bit of SD778 is off (Do not execute I/O refresh), replacement of the instruction is not necessary.
  • Page 607 (4) Replacing the RFS instruction If any I/O numbers targeted for forced on/off are included in the partial refresh range specified by the RFS instruc- tion, add subroutine calls for P10 and P11 before and after the RFS instruction. (P10 and P11 are pointers shown in the program examples in (2).) If no I/O number targeted for forced on/off is included, addition of subroutine calls for P10 and P11 is not neces- sary.
  • Page 608: Appendix 3.5 Special Relay And Special Register

    APPENDICES Appendix 3.5 Special Relay and Special Register The Universal model QCPU does not support the use of the special relay and special register described in Appendix 3.5.1 and Appendix 3.5.2. Replace them using the method described in the table or delete the corresponding sections. Appendix 3.5.1 Special relay list TableApp.41 lists the special relay not supported in the Universal model QCPU and measures to be taken.
  • Page 609 TableApp.45 Special relay not supported in the Universal model QCPU and measures (Continued) Number Name/Description Measures Replace the relay with the I/O signals (Xn0, Xn1, and XnF) of the mounted CC-Link SM280 CC-Link error module. Communication reserved time delay Set a service processing time value in the PLC system tab of the PLC parameter dia- SM315 enable/disable flag log box.
  • Page 610 APPENDICES TableApp.45 Special relay not supported in the Universal model QCPU and measures (Continued) Number Name/Description Measures Power supply off detection flag SM1780 Power supply failure detection flag SM1781 The Universal model QCPU does not store redundant power supply system Momentary power failure detection information in SM1780 to SM1783.
  • Page 611 Appendix 3.5.2 Special register list TableApp.42 lists the special register not supported in the Universal model QCPU and measures to be taken TableApp.46 Special register not supported in the Universal model QCPU and measures Number Name/Description Measures The Universal model QCPU does not support the CHK instruction. For the replacing SD80 CHK number method of the CHK instruction, refer to Appendix 3.3.
  • Page 612 APPENDICES TableApp.46 Special register not supported in the Universal model QCPU and measures (Continued) Number Name/Description Measures Service interval measurement SD550 module The Universal model QCPU does not support the service interval measurement SD551 function. Delete the corresponding sections. Service interval time SD552 Program No.
  • Page 613: Appendix 4 Device Point Assignment Sheet

    Appendix 4 Device Point Assignment Sheet TableApp.47 Device point assignment sheet *1 *2 Restriction check Number of device point Numeric Device name Symbol notation Points Range Size (words) Points (bits) 8K (8192) X0000 to X1FFF Input relay Hexadecimal 8192 8K (8192) Y0000 to Y1FFF Output relay Hexadecimal 8192...
  • Page 614 INDEX DX (Direct access input) ....3-12 DY (Direct access output) ....3-12 ASCII code .
  • Page 615 Formatting the ATA card ....5-15 Interrupt program monitor list ... . . 6-72 Formatting the SRAM card .
  • Page 616 Monitor condition setting ....6-33 Q6 RB ....... .A-21 Motion CPU .
  • Page 617 T (Timer) ....... 9-20 Timer (T) Accuracy ......9-24 Processing .
  • Page 618 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.
  • Page 619 Microsoft, Windows, Windows NT, Windows Vista are registered trademarks of Microsoft Corporation in the United States and other countries. Pentium and Celeron are trademarks of Intel Corporation in the United States and other countries. Ethernet is a trademark of Xerox Co., Ltd. in the United States. CompactFlash is a trademark of SanDisk Corporation.
  • Page 622 Phone: +370 (0)5 / 232 3101 Fax: +370 (0)5 / 232 2980 MITSUBISHI ELECTRIC Mitsubishi Electric Europe B.V. /// FA - European Business Group /// Gothaer Straße 8 /// D-40880 Ratingen /// Germany Tel.: +49(0)2102-4860 /// Fax: +49(0)2102-4861120 /// info@mitsubishi-automation.com /// www.mitsubishi-automation.com FACTORY AUTOMATION...

Table of Contents