FX1S-30MR-ES/UL MITSUBISHI, FX1S-30MR-ES/UL Datasheet
![PLC, 16 IN, 14 RELAY OUT, 110V/2](/photos/21/27/212723/42419294_sml.jpg)
FX1S-30MR-ES/UL
Specifications of FX1S-30MR-ES/UL
Related parts for FX1S-30MR-ES/UL
FX1S-30MR-ES/UL Summary of contents
Page 1
PROGRAMMING MANUAL THE FX SERIES OF PROGRAMMABLE CONTROLLER ( 2N, 2NC II ...
Page 2
...
Page 3
... If in doubt at any stage of the installation of the PLC always consult a professional electrical engineer who is qualified and trained to the local and national standards which apply to the installation site. • doubt about the operation or use of the PLC please consult the nearest Mitsubishi Electric distributor. • This manual is subject to change without notice. : April 2000 i ...
Page 4
FX Series Programmable Controllers ii ...
Page 5
... FX Series Programmable Controllers FAX BACK - Combined Programming Manual (J) Mitsubishi has a world wide reputation for its efforts in continually developing and pushing back the frontiers of industrial automation. What is sometimes overlooked by the user is the care and attention to detail that is taken with the documentation. However,to continue this process of improvement, the comments of the Mitsubishi users are always welcomed ...
Page 6
FX Series Programmable Controllers iv ...
Page 7
FX Series Programmable Controllers Guidelines for the Safety of the User and Protection of the Programmable Controller (PLC) This manual provides information for the use of the FX family of PLC’s. The manual has been written to be used by ...
Page 8
FX Series Programmable Controllers vi ...
Page 9
FX Series Programmable controllers Contents 1. Introduction............................................................................................1-1 1.1 Overview.............................................................................................................. 1-1 1.2 What is a Programmable Controller? .................................................................. 1-2 1.3 What do You Need to Program a PLC? .............................................................. 1-2 1.4 Special considerations for programming equipment ........................................... 1-3 1.4.1 Current Generation ...
Page 10
STL Programming .................................................................................3-1 3.1 What is STL, SFC And IEC1131 Part 3? ............................................................. 3-1 3.2 How STL Operates .............................................................................................. 3-2 3.2.1 Each step is a program ............................................................................................. 3-2 3.3 How To Start And End An STL Program ............................................................. 3-3 ...
Page 11
High Speed Counters ........................................................................................ 4-22 4.11.1 Basic High Speed Counter Operation ..................................................................... 4-23 4.11.2 Availability of High Speed Counters ....................................................................... 4-24 4.11.3 1 Phase Counters - User Start and Reset (C235 - C240) ....................................... 4-26 4.11.4 1 Phase Counters ...
Page 12
WXOR (FNC 28) ..................................................................................................... 5-31 5.3.10 NEG (FNC 29) ........................................................................................................ 5-31 5.4 Rotation And Shift - Functions ............................................................. 5-34 5.4.1 ROR (FNC 30)......................................................................................................... 5-35 5.4.2 ROL (FNC 31) ......................................................................................................... 5-35 5.4.3 RCR (FNC 32) ......................................................................................................... 5-36 ...
Page 13
... TAN (FNC 132) ..................................................................................................... 5-120 5.12 Data Operations 2 - FNC 140 to FNC 149 ...................................................... 5-122 5.12.1 SWAP (FNC 147) .................................................................................................. 5-123 5.13 FX1S & FX1N Positioning Control - FNC 150 to FNC 159 .............................. 5-126 5.13.1 ABS (FNC 155) ..................................................................................................... 5-127 5.13.2 ZRN (FNC 156) ..................................................................................................... 5-128 5.13.3 PLSV(FNC157) ..................................................................................................... 5-129 5 ...
Page 14
Diagnostic Devices ................................................................................6-1 6.1 PLC Status (M8000 to M8009 and D8000 to D8009) .......................................... 6-2 6.2 Clock Devices (M8010 to M8019 and D8010 to D8019) .................................... 6-3 6.3 Operation Flags ................................................................................................... 6-4 6.4 PLC Operation Mode (M8030 to M8039 ...
Page 15
Of Technique...........................................................................10-1 10.1 Advanced Programming Points ......................................................................... 10-1 10.2 Users of DC Powered FX Units ......................................................................... 10-1 10.3 Using The Forced RUN/STOP Flags................................................................. 10-2 10.3.1 A RUN/STOP push button configuration ................................................................. 10-2 10.3.2 Remote RUN/STOP control .................................................................................... 10-3 10.4 ...
Page 16
viii ...
Page 17
FX Series Programmable Controllers 1 Introduction 2 Basic Program Instructions 3 STL Programming 4 Devices in Detail 5 Applied Instructions 6 Diagnostic Devices 7 Instruction Execution Times 8 PLC Device Tables 9 Assigning System Devices 10 Points of Technique 11 ...
Page 18
FX Series Programmable Controllers Chapter Contents 1. Introduction............................................................................................1-1 1.1 Overview.............................................................................................................. 1-1 1.2 What is a ProgrammableController? ................................................................... 1-2 1.3 What do You Need to Program a PC? ................................................................ 1-2 1.4 Curent Generation CPU’s, All versions ............................................................... 1-3 1.5 Associated Manuals ...
Page 19
... This is a generic term which is often used to describe all Programmable Controllers without identifying individual types or model names. 4) CPU version numbers and programming support As Mitsubishi upgrades each model different versions have different capabilities. - Please refer to section 1.4 for details about peripheral support for each model. Shaded boxes indicate ...
Page 20
... CPUs through a communication network or bus. 1.3 What do You Need to Program a PLC? A variety of tools are available to program the Mitsubishi FX family of PLCs. Each of these tools can use and access the instructions and devices listed in this manual for the identified PLC. ...
Page 21
Special considerations for programming equipment 1.4.1 Current Generation CPU all versions The introduction of this CPU provides the FX user with many new devices and instructions. To use the full features of the current range of FX units the ...
Page 22
... FX1S Hardware manual FX1N Hardware manual FX2N Hardware manual FX2NC Hardware manual FX Programming FX0, FX0S, FX0N, FX, FX2C, FX2N, FX2NC Programming manual FX1S, FX1N, FX2N, FX2NC Programming manual FX Peripherals FX-10P-E Operation manual FX-20P-E Operation manual FX-10P, 20P-E Supplimentary manual FX-PCS-WIN-E Software manual ...
Page 23
FX DU, GOT and DM units FX-5DM Users manual FX-10DM Users manual FX Positioning FX-1HC Users guide FX2N/FX-1PG-E Users manual E-20P-E Operation manual FX2N-1HC Users guide FX2N-1RM-E-SET Users manual FX2N-10GM Users guide FX2N-20GM Users guide FX2N-10/20GM Hardware/Programming manual FX-PCS-VPS/WIN-E Software ...
Page 24
Memo Introduction 1 1-6 ...
Page 25
FX Series Programmable Controllers 1 Introduction 2 Basic Program Instructions 3 STL Programming 4 Devices in Detail 5 Applied Instructions 6 Diagnostic Devices 7 Instruction Execution Times 8 PLC Device Tables 9 Assigning System Devices 10 Points of Technique 11 ...
Page 26
FX Series Programmable Controllers Chapter Contents 2. Basic Program Instructions ...................................................................2-1 2.1 What is a Program? ............................................................................................. 2-1 2.2 Outline of Basic Devices Used in Programming .................................................. 2-1 2.3 How to Read Ladder Logic .................................................................................. 2-2 2.4 Load, Load Inverse ...
Page 27
FX Series Programmable Controllers 2. Basic Program Instructions 2.1 What is a Program? A program is a connected series of instructions written in a language that the PLC can understand. There are three forms of program format; instruction, ladder and ...
Page 28
FX Series Programmable Controllers 2.3 How to Read Ladder Logic Ladder logic is very closely associated to basic relay logic. There are both contacts and coils that can be loaded and driven in different configurations. However, the basic principle remains ...
Page 29
FX Series Programmable Controllers 2.4 Load, Load Inverse Mnemonic Initial logical LD operation contact (LoaD) type NO (normally open) Initial logical LDI operation contact (LoaD Inverse) type NC (normally closed) Program example LDI T0 Basic points to remember: ...
Page 30
FX Series Programmable Controllers 2.5 Out Mnemonic Function Final logical OUT operation type coil (OUT) drive Basic points to remember: - Connect the OUT instruction directly to the right hand bus bar not possible to use the ...
Page 31
FX Series Programmable Controllers 2.5.2 Double Coil Designation this is NOT ON then the second Y3 coil does NOT activate. Therefore the status of the Y3 coil updates to reflect this new situation, i.e. it turns ...
Page 32
FX Series Programmable Controllers 2.6 And, And Inverse Mnemonic Serial connection AND of NO (normally (AND) open) contacts Serial connection ANI of NC (normally (AND Inverse) closed) contacts Program example ANI AND Basic points to remember: ...
Page 33
FX Series Programmable Controllers 2.7 Or, Or Inverse Mnemonic Parallel OR connection of NO (OR) (normally open) contacts Parallel ORI connection of NC (OR Inverse) (normally closed) contacts Program example M102 Y5 X7 M103 M110 Basic points to ...
Page 34
FX Series Programmable Controllers 2.8 Load Pulse, Load Trailing Pulse Mnemonic Initial logical LDP operation - (LoaDPulse) Rising edge pulse Initial logical LDF operation Falling (LoaD Falling / trailing edge pulse) pulse Program example: LDP X0 X1 LDF X0 Basic ...
Page 35
FX Series Programmable Controllers 2.9 And Pulse, And Trailing Pulse Mnemonic Serial connection ANP of Rising edge (ANd Pulse) pulse Serial connection ANF of Falling / (ANd Falling trailing edge pulse) pulse Program example: M40 X1 X0 Basic points to ...
Page 36
FX Series Programmable Controllers 2.10 Or Pulse, Or Trailing Pulse Mnemonic Parallel ORP connection of (OR Pulse) Rising edge pulse Parallel ORF connection of (OR Falling Falling / trailing pulse) edge pulse Program example: Basic points to remember: - Use ...
Page 37
FX Series Programmable Controllers 2.11 Or Block Mnemonic Parallel connection ORB of multiple contact (OR Block) circuits Program example ORB X4 X5 ORB Basic points to remember ORB instruction is an independent instruction and ...
Page 38
FX Series Programmable Controllers 2.12 And Block Mnemonic Serial connection ANB of multiple (ANd Block) parallel circuits Program example: ANB Basic points to remember ANB instruction is an independent instruction and is not associated with ...
Page 39
FX Series Programmable Controllers 2.13 MPS, MRD and MPP Mnemonic Stores the current MPS result of the (Point Store) internal PLC operations Reads the current MRD result of the (Read) internal PLC operations Pops (recalls and MPP removes) the (PoP) ...
Page 40
FX Series Programmable Controllers Multiple program examples MPS MRD X7 X10 MPP X11 MPS X3 MPP MPS MPP MPS MPP MPS MPP ...
Page 41
FX Series Programmable Controllers 2.14 Master Control and Reset Mnemonic MC Denotes the start (Master of a master control Control) block MCR Denotes the end of (Master a master control block Control Reset) Program example M100 X1 X2 ...
Page 42
FX Series Programmable Controllers M100 M101 M102 X10 A Nested MC program example M100 Level N0: Bus line (B) active when ...
Page 43
FX Series Programmable Controllers 2.15 Set and Reset Mnemonic SET Sets a bit device (SET) permanently ON Resets a bit RST device (ReSeT) permanently OFF Program example Basic points to remember: - Turning ...
Page 44
FX Series Programmable Controllers 2.16 Timer, Counter (Out & Reset) Mnemonic OUT Driving timer or (OUT) counter coils Resets timer and RST counter, coils (ReSeT) contacts and current values Program example T246 C200 Retentive timers: ...
Page 45
FX Series Programmable Controllers 2.16.2 Normal 32 bit Counters The 32 bit counter C200 counts (up-count, down-count) according to the ON/OFF state of M8200. In the example program shown on the previous page C200 is being used to count the ...
Page 46
FX Series Programmable Controllers 2.17 Leading and Trailing Pulse Mnemonic PLS Rising edge (PuLSe) pulse PLF Falling / trailing (PuLse Falling) edge pulse Program example Basic points to remember: - When a PLS instruction is executed, ...
Page 47
FX Series Programmable Controllers 2.18 Inverse Mnemonic Invert the current INV result of the (Inverse) internal PLC operations Program example Basic points to remember: - The INV instruction is used to change (invert) the logical state ...
Page 48
FX Series Programmable Controllers 2.19 No Operation Mnemonic NOP No operation or (No Operation) null step Basic points to remember: - Writing NOP instructions in the middle of a program minimizes step number changes when changing or editing a program. ...
Page 49
FX Series Programmable Controllers 2.20 End Mnemonic Forces the current END program scan to (END) end Basic points to remember: - Placing an END instruction in a program forces that program to end the current scan and carry out the ...
Page 50
FX Series Programmable Controllers MEMO Basic Program Instructions 2 2-24 ...
Page 51
FX Series Programmable Controllers 1 Introduction 2 Basic Program Instructions 3 STL Programming 4 Devices in Detail 5 Applied Instructions 6 Diagnostic Devices 7 Instruction Execution Times 8 PLC Device Tables 9 Assigning System Devices 10 Points of Technique 11 ...
Page 52
FX Series Programmable Controllers Chapter Contents 3. STL Programming .................................................................................3-1 3.1 What is STL, SFC And IEC1131 Part 3? ............................................................. 3-1 3.2 How STL Operates .............................................................................................. 3-2 3.2.1 Each step is a program ............................................................................................. 3-2 3.3 How To Start And ...
Page 53
... SFC. This is not a coincidence as this programming technique has been developed deliberately to achieve an easy to program and monitor system. One of the key differences to Mitsubishi’s STL programming system is that it can be entered into a PLC in 3 formats. These are: ) Instruction - a word/mnemonic entry system ...
Page 54
FX Series Programmable Controllers 3.2 How STL Operates As previously mentioned, STL is a system which allows the user to write a program which functions in much the same way as a flow chart, this can be seen in the ...
Page 55
... There are many different methods to drive a state, for example the initial state coils could be pulsed, SET or just included in an OUT instruction. However, within Mitsubishi’s STL programming language an STL coil which is SET has a different meaning than one that is included in an OUT instruction. ...
Page 56
FX Series Programmable Controllers Initial Steps For an STL program which activated on the initial power up of the PLC, a trigger similar to that shown opposite could be used, i.e. using M8002 to drive the setting ...
Page 57
FX Series Programmable Controllers 3.4 Moving Between STL Steps To activate an STL step the user must first drive the state coil. Setting the coil has already been identified as a way to start an STL program, i.e. drive an ...
Page 58
FX Series Programmable Controllers 3.4.2 Using OUT to drive an STL coil This has the same operational features as using SET. However, there is one major function which SET is not used. This is to make what is termed ‘distant ...
Page 59
FX Series Programmable Controllers 3.5 Rules and Techniques For STL programs It can be seen that there are a lot of advantages to using STL style programming but there are a few points a user must be aware of when ...
Page 60
FX Series Programmable Controllers • When an STL step transfers control to the next STL step there is a period (one scan) while both steps are active. This can cause problems with dual coils; particularly timers. If timers are dual ...
Page 61
FX Series Programmable Controllers 3.5.2 Single Signal Step Control Transferring between active STL steps can be controlled by a single signal. There are two methods the user can program to achieve this result. Method 1 - Using locking devices In ...
Page 62
FX Series Programmable Controllers 3.6 Restrictions Of Some Instructions When Used With STL Although STL can operate with most basic and applied instructions there are a few exceptions general rule STL and MC-MCR programming formats should not be ...
Page 63
FX Series Programmable Controllers 3.7 Using STL To Select The Most Appropriate Program So far STL has been considered as a simple flow charting programming language. One of STL’s exceptional features is the ability to create programs which can have ...
Page 64
FX Series Programmable Controllers Limits on the number of branches • Please see page 3-14 for general notes on programming STL branches. Notes on using the FX-PCS/AT-EE software • Please see page 3-15 for precautions when using the FX-PCS-AT/EE software. ...
Page 65
FX Series Programmable Controllers When a group of branch flows are activated, the user will often either; a) ‘Race’ each flow against its counter parts. The flow which completes fastest would then activate a joining function (“First State Merge” described ...
Page 66
FX Series Programmable Controllers 3.9 General Rules For Successful STL Branching For each branch point 8 further branches may be programmed. There are no limits to the num- ber of states contained in a single STL flow. Hence, the possibility ...
Page 67
FX Series Programmable Controllers Further recommended program changes Program violation! 3.10 General Precautions When Using The FX-PCS/AT-EE Software This software has the ability to ...
Page 68
FX Series Programmable Controllers 3.11 Programming Examples 3.11.1 A Simple STL Flow Start button X0 This simple example is an excerpt from a semi-automatic loading-unloading ore truck program. This example program has a built in, initialization routine which occurs only ...
Page 69
FX Series Programmable Controllers Once at the discharge point the truck opens its bottom doors (Y13). After a timed duration in which the truck empties its contents, the program checks to see if the repeat mode was selected on the ...
Page 70
FX Series Programmable Controllers 3.11.2 A Selective Branch/ First State Merge Example Program The following example depicts an automatic sorting robot. The robot sorts two sizes of ball bearings from a mixed ‘source pool’ into individual storage buckets containing only ...
Page 71
FX Series Programmable Controllers Full STL flow diagram/program X12 Start Y7 Zero-point arrival Lower limit = small ball Upper limit reached Move to small ball ...
Page 72
FX Series Programmable Controllers 3.12 Advanced STL Use STL programming can be enhanced by using the Initial State Applied Instruction. This instruction has a mnemonic abbreviation of IST and a special function number of 60. When the IST instruction is ...
Page 73
FX Series Programmable Controllers 1 Introduction 2 Basic Program Instructions 3 STL Programming 4 Devices in Detail 5 Applied Instructions 6 Diagnostic Devices 7 Instruction Execution Times 8 PLC Device Tables 9 Assigning System Devices 10 Points of Technique 11 ...
Page 74
FX Series Programmable Controllers Chapter Contents 4. Devices in Detail....................................................................................4-1 4.1 Inputs ................................................................................................................... 4-1 4.2 Outputs ................................................................................................................ 4-2 4.3 Auxiliary Relays ................................................................................................... 4-3 4.3.1 General Stable State Auxiliary Relays ...................................................................... 4-3 4.3.2 Battery Backed/ Latched Auxiliary Relays................................................................. 4-4 4.3.3 Special ...
Page 75
FX Series Programmable Controllers 4. Devices in Detail 4.1 Inputs Device Mnemonic: X Purpose: Representation of physical inputs to the programmable controller (PLC) Alias: I/P Inp (X) Input Input contact Available forms and contacts ...
Page 76
FX Series Programmable Controllers 4.2 Outputs Device Mnemonic: Y Purpose: Representation of physical outputs from the programmable controller Alias: O/P Otp Out (Y) Output (Y) Output (coil/ relay/ contact) Available forms and NC contacts and output coils ...
Page 77
... Available devices: PLC General auxiliary relays Battery backed/ latched relays Total available • For more information about device availability for individual PLC’s, please see chapter 8. X0 M507 1 FX1S FX1N 384 384 (M0 - 383) (M0 - 383) 1152 128 (M384 - (M384 - 511) 1535) 1536 ...
Page 78
FX Series Programmable Controllers 4.3.2 Battery Backed/ Latched Auxiliary Relays There are a number of battery backed or latched relays whose status is retained in battery backed or EEPROM memory power failure should occur all output and general ...
Page 79
FX Series Programmable Controllers 4.3.3 Special Diagnostic Auxiliary Relays A PLC has a number of special auxiliary relays. These relays all have specific functions and are classified into the following two types. a) Using contacts of special auxiliary relays - ...
Page 80
FX Series Programmable Controllers 4.4 State Relays Device Mnemonic: S Purpose: Internal programmable controller status flag Alias: State (coil/ relay/ contact/ flag) S (coil/ relay/ contact /flag) STL step (coil/ relay/ contact /flag) Annunciator flag Available forms ...
Page 81
FX Series Programmable Controllers 4.4.2 Battery Backed/ Latched State Relays There are a number of battery backed or latched relays whose status is retained in battery backed or EEPROM memory power failure should occur all output and general ...
Page 82
FX Series Programmable Controllers 4.4.3 STL Step Relays ...
Page 83
FX Series Programmable Controllers 4.4.4 Annunciator Flags Some state flags can be used as outputs for external diagnosis (called annunciation) when certain applied instructions are used. These instructions are; ANS function 46: ANnunciator Set - see page 5-47 ANR function ...
Page 84
FX Series Programmable Controllers 4.5 Pointers Device Mnemonic: P Purpose: Program flow control Alias: Pointer Program pointer P Available forms: Label: appears on the left of the left hand bus bar when the program is viewed in ladder mode. Devices ...
Page 85
FX Series Programmable Controllers 4.6 Interrupt Pointers Device Mnemonic: I Purpose: Interrupt program marker Alias: Interrupt High speed interrupt I Available forms: Label: appears on the left of the left hand bus bar when the program is viewed in ladder ...
Page 86
FX Series Programmable Controllers 4.6.1 Input Interrupts Identification of interrupt pointer number interrupt triggered on trailing/ falling edge of input signal 1: interrupt triggered on leading/ rising edge of input signal Input number; each input number can ...
Page 87
FX Series Programmable Controllers 4.6.3 Disabling Individual Interrupts Individual interrupt devices can be temporarily or permanently disabled by driving an associated special auxiliary relay. The relevant coils are identified in the tables of devices in chapter 6. However for all ...
Page 88
FX Series Programmable Controllers 4.7 Constant K Device Mnemonic: K Purpose: Identification of constant decimal values Alias: Constant K (value/ constant) K Available forms: Numeric data value, when used for 16bit data, values can be selected from the range -32,768 ...
Page 89
FX Series Programmable Controllers 4.9 Timers Device Mnemonic: T Purpose: Timed durations Alias: Timer(s) T Available forms: A driven coil sets internal PLC contacts (NO and NC contacts available). Various timer resolutions are possible, from 1 to 100 msec, but ...
Page 90
FX Series Programmable Controllers 4.9.1 General timer operation Timers operate by counting clock pulses (1, 10 and 100 msec). The timer output contact is activated when the count data reaches the value set by the constant K. The overall duration ...
Page 91
FX Series Programmable Controllers 4.9.3 Retentive Timers A retentive timer has the ability to retain the currently reached present value even after the drive contact has been removed. This means that when the drive contact is re-established a retentive timer ...
Page 92
FX Series Programmable Controllers 4.9.4 Timers Used in Interrupt and ‘CALL’ Subroutines If timers T192 to T199 and T246 to T249 are used in a CALL subroutine or an interruption routine, the timing action is updated at the point when ...
Page 93
FX Series Programmable Controllers 4.10 Counters Device Mnemonic: C Purpose: Event driven delays Alias: Counter(s) C Available forms: A driven coil sets internal PLC contacts (NO and NC contacts available). Various counter resolutions are possible including; General/latched 16bit up counters ...
Page 94
FX Series Programmable Controllers 4.10.1 General/ Latched 16bit UP Counters The current value of the counter increases each time coil C0 is turned ON by X11. The output contact is activated when the coil is turned ON for the tenth ...
Page 95
FX Series Programmable Controllers 4.10.2 General/ Latched 32bit Bi-directional Counters The counter shown in the example below, activates when its coil is driven, i.e. the C200 coil is driven. On every occasion the input X14 is turned from OFF to ...
Page 96
FX Series Programmable Controllers 4.11 High Speed Counters Device Mnemonic: C Purpose: High speed event driven delays Alias: Counter (s) C High speed counter (s) Phase counters Available forms: A driven coil sets internal PLC contacts (NO and NC contacts ...
Page 97
FX Series Programmable Controllers 4.11.1 Basic High Speed Counter Operation Although counters C235 to C255 (21 points) are all high speed counters, they share the same range of high speed inputs. Therefore input is already being used by ...
Page 98
FX Series Programmable Controllers 4.11.2 Availability of High Speed Counters The following device table outlines the range of available high speed counters Phase counter N user start/reset U/D X1 U/D U/D X2 U/D X3 ...
Page 99
... If any high speed comparison instructions (FNC’s 53, 54, 55) are used, X0 and X1 must resort to software counting. In this case, please see the table below: Unit FX & 2NC FX & Calculating the maximum combined counting speed on FX1S: This is calculated as follows: (2 phase counter speed x number of counted edges) Function Max. Combined Number Signal Frequency kHz 55 5.5 kHz ...
Page 100
FX Series Programmable Controllers 4.11.3 1 Phase Counters - User Start and Reset (C235 - C240) These counters only use one input each. When direction flag M8235 is ON, counter C235 counts down. When it is OFF, C235 counts up. ...
Page 101
FX Series Programmable Controllers 4.11.4 1 Phase Counters - Assigned Start and Reset (C241 to C245) These counters have one countable input and 1 reset input each. Counters C244 and C245 also have a start input. When the direction flag ...
Page 102
FX Series Programmable Controllers 4.11.5 2 Phase Bi-directional Counters (C246 to C250) These counters have one input for counting up and one input for counting down. Certain counters also have reset and start inputs as well. When X10 is ON, ...
Page 103
FX Series Programmable Controllers 4.11.6 A/B Phase Counters (C252 to C255) With these counters only the input identified in the previous high speed counter tables can be used for counting. The counting performed by these devices is independent of the ...
Page 104
FX Series Programmable Controllers 4.12 Data Registers Device Mnemonic: D Purpose: A storage device capable of storing numeric data or 16/32bit patterns Alias: Data (register/ device/ word) D (register) D Word Available forms: General use registers - see page 4-34 ...
Page 105
FX Series Programmable Controllers 4.12.1 General Use Registers Data registers, as the name suggests, store data. The stored data can be interpreted as a numerical value series of bits, being either ON or OFF. A single data ...
Page 106
FX Series Programmable Controllers 4.12.2 Battery Backed/ Latched Registers Once data is written to a battery backed register, it remains unchanged until it is overwritten. When the PLC’s status is changed from RUN to STOP, the data in these registers ...
Page 107
FX Series Programmable Controllers 4.12.4 File Registers Program memory registers File registers can be secured in the program memory (EEPROM or EPROM) in units of 500 points. These registers can be accessed with a peripheral device. While the PLC is ...
Page 108
FX Series Programmable Controllers 4.12.5 Externally Adjusted Registers The FX and ” ich jus ...
Page 109
FX Series Programmable Controllers 4.13 Index Registers Device Mnemonic: V,Z Purpose: To modify a specified device by stating an offset. Alias: (V/ Z) Register Index (register/ addressing/ modifier) Offset(s) (register/ addressing/ modifier) Indices Modifier Available forms: For 16bit data V ...
Page 110
FX Series Programmable Controllers 4.13.1 Modifying a Constant Constants can be modified just as easily as data registers or bit devices. If, for example, the constant K20 was actually written K20V the final result would equal: K20 + the contents ...
Page 111
FX Series Programmable Controllers 4.14 Bits, Words, BCD and Hexadecimal The following section details general topics relating to good device understanding. The section is split into several smaller parts with each covering one topic or small group of topics. Some ...
Page 112
FX Series Programmable Controllers Assigning grouped bit devices: As already explained, bit devices can be grouped into 4 bit units. The “n” in KnM0 defines the number of groups of 4 bits to be combined for data operation ...
Page 113
FX Series Programmable Controllers 4.14.2 Word Devices Word devices such and Z can store data about a particular event or action within the PLC. For the most part these devices are 16 bit registers. However, ...
Page 114
FX Series Programmable Controllers The reason this is not -7797 is because a negative value is calculated using two’s compliment (described later) but can quickly be calculated in the following manner: Because this is a negative number, a base is ...
Page 115
FX Series Programmable Controllers c) ABCD conversion Using the original bit pattern as a base but adding the following BCD headers allows the conversion of the binary data into a BCD format ...
Page 116
FX Series Programmable Controllers 4.14.4 Two’s Compliment Programmable controllers, computers etc, use a format called 2’s compliment. This is a mathematical procedure which is more suited to the micro processors operational hardware requirements used to represent negative numbers ...
Page 117
FX Series Programmable Controllers 4.15 Floating Point And Scientific Notation PLC’s can use many different systems and methods to store data. The most common have already been discussed in previous sections e.g. BCD, Binary, Decimal, Hex. These are what is ...
Page 118
FX Series Programmable Controllers 4.15.1 Scientific Notation This format could be called the step between the ‘integer’ formats and the full floating point formats. In basic terms Scientific Notation use two devices to store information about a number or value. ...
Page 119
FX Series Programmable Controllers 4.15.2 Floating Point Format Floating point format extends the abilities and ranges provided by Scientific Notation with the ability to represent fractional portions of whole numbers, for example; Performing and displaying the calculation of 22 divided ...
Page 120
FX Series Programmable Controllers 4.15.3 Summary Of The Scientific Notation and Floating Point Numbers The instruction needed to convert between each number format are shown below in a diagrammatically format for quick and easy reference. ´ Devices in Detail 4 ...
Page 121
FX Series Programmable Controllers 1 Introduction 2 Basic Program Instructions 3 STL Programming 4 Devices in Detail 5 Applied Instructions 6 Diagnostic Devices 7 Instruction Execution Times 8 PLC Device Tables 9 Assigning System Devices 10 Points of Technique 11 ...
Page 122
... SIN (FNC 130) .............................................. 5-119 5.11.3 TAN (FNC 132) ............................................. 5-120 5.12 Data Operations 2 - FNC 140 to FNC 149 ................................................................... 5-122 5.13.1 SWAP (FNC 147).......................................... 5-123 5.13 FX1S & FX1N Positioning Control - Functions 150 to 159 ........................................... 5-126 5.13.1 ABS (FNC 155) ............................................. 5-127 5.13.3 PLSV (FNC 157) ........................................... 5-129 5.13.5 DRVA (FNC 159) ...
Page 123
FX Series Programmable Controllers 5. Applied Instructions Applied Instructions are the ‘specialist’ instructions of the FX family of PLC’s. They allow the user to perform complex data manipulations, mathematical operations while still being very easy to program and monitor. Each ...
Page 124
FX Series Programmable Controlers • For instructions that operate continuously, i.e. on every scan of the program the instruction will operate and provide a new, different result, the following identification symbol will be used ‘ ’ to represent a high ...
Page 125
... Rotation And Shift Data Operation High Speed Processing Handy Instructions External FX I/O Devices External FX Serial Devices Floating Point 1 & 2 Trigonometry (Floating Point 3) Data Operations 2 FX1S & FX1N Positioning Control Real Time Clock Control Gray Codes In-line Comparisons Applied Instructions 5 5-4 5-16 5-24 5-34 ...
Page 126
FX Series Programmable Controlers 5.1 Program Flow-Functions Contents Conditional jump CALL - Call Subroutine SRET - Subroutine Return IRET - Interrupt Return EI - Enable Interrupt DI - Disable Interrupt FEND - First End WDT ...
Page 127
FX Series Programmable Controlers 5.1.1 CJ (FNC 00) Mnemonic Function CJ Jumps to the FNC 00 identified pointer (Conditional position Jump) Points to note: a) Many CJ statements can reference a single pointer. b) Each pointer must have a unique ...
Page 128
FX Series Programmable Controlers instruction can be used to Jump forwards through a program, i.e. towards the END instruction OR it can jump backwards towards step backwards jump is used care must be taken ...
Page 129
FX Series Programmable Controlers 5.1.2 CALL (FNC 01) Mnemonic Function CALL Executes the FNC 01 subroutine ( all sub- program starting C routine at the identified ) pointer position Points to note: a) Many CALL statements can reference a single ...
Page 130
FX Series Programmable Controlers Special subroutine timers: • Because of the chance of intermittent use of the subroutines, if timed functions are required the timers used must be selected from the range T192 to T199 and T246 to T249. Details ...
Page 131
FX Series Programmable Controlers 5.1.4 IRET, EI, DI (FNC 03, 04, 05) Mnemonic Function IRET Forces the FNC 03 program to return (Interrupt from the active return) interrupt routine EI Enables interrupt FNC 04 inputs to be pro- (Enable cessed ...
Page 132
FX Series Programmable Controlers Controlling interrupt operations: The PLC has a default status of disabling interrupt operation. The EI instruction must be used to activate the interrupt facilities. All interrupts which physically occur during the program scan period from the ...
Page 133
FX Series Programmable Controlers 5.1.5 FEND (FNC 06) Mnemonic Function FEND Used to indicate FNC 06 the end of the (First end) main program block Operation: An FEND instruction indicates the first end of a main program and the start ...
Page 134
FX Series Programmable Controlers 5.1.6 WDT (FNC 07) Mnemonic Function WDT Used to refresh FNC 07 the watch dog (Watch dog timer during a timer refresh) program scan there is an error at some point. The PLC will then cease ...
Page 135
FX Series Programmable Controlers 5.1.7 FOR, NEXT (FNC 08, 09) Mnemonic Function FOR Identifies the start FNC 08 position and the (Start of a number of FOR-NEXT repeats for the loop) loop NEXT Identifies the end FNC 09 position for ...
Page 136
FX Series Programmable Controlers Nested FOR-NEXT loops: FOR-NEXT instructions can be nested for 5 levels. This means that 5 FOR-NEXT loops can be sequentially programmed within each other. In the example a 3 level nest has been programmed. As each ...
Page 137
... Rotation And Shift Data Operation High Speed Processing Handy Instructions External FX I/O Devices External FX Serial Devices Floating Point 1 & 2 Trigonometry (Floating Point 3) Data Operations 2 FX1S & FX1N Positioning Control Real Time Clock Control Gray Codes In-line Comparisons Applied Instructions 5 5-4 5-16 5-24 5-34 ...
Page 138
FX Series Programmable Controlers 5.2 Move And Compare - Functions Contents: CMP - Compare ZCP - Zone Compare MOV - Move SMOV - Shift Move CML - Compliment BMOV - Block Move FMOV - Fill Move XCH ...
Page 139
FX Series Programmable Controlers 5.2.1 CMP (FNC 10) Mnemonic Function CMP Compares two FNC 10 data values - (Compare) results of <, = and > are given. Note: The destination (D) device statuses will be kept even if the CMP ...
Page 140
FX Series Programmable Controlers 5.2.3 MOV (FNC 12) Mnemonic Function MOV Moves data from FNC 12 one storage area (Move new storage area Note: This instruction has a special programming technique which allows it to mimic the operation ...
Page 141
FX Series Programmable Controlers Operation 2: (Applicable units, FX allows BCD numbers to be manipulated in exactly the same way as the ‘normal’ SMOV manipulates decimal numbers, i.e. This instruction copies a specified number of digits from a 4 digit ...
Page 142
FX Series Programmable Controlers 5.2.6 BMOV (FNC 15) Mnemonic Function BMOV Copies a specified FNC 15 block of multiple (Block move) data elements to a new destination (S) and a quantity of consecutive data elements (n). This is moved to ...
Page 143
FX Series Programmable Controlers 5.2.7 FMOV (FNC 16) Mnemonic Function FMOV Copies a single FNC 16 data device to a (Fill move) range of destination devices quantity of consecutive elements (n). If the specified number of destination devices (n) exceeds ...
Page 144
FX Series Programmable Controlers 5.2.9 BCD (FNC18) Mnemonic Function BCD Converts binary FNC 18 numbers to BCD ( coded equivalents / Binary decimal) Converts floating point data to scientific format 5.2.10 BIN (FNC 19) Mnemonic Function BIN Converts BCD FNC ...
Page 145
... Rotation And Shift Data Operation High Speed Processing Handy Instructions External FX I/O Devices External FX Serial Devices Floating Point 1 & 2 Trigonometry (Floating Point 3) Data Operations 2 FX1S & FX1N Positioning Control Real Time Clock Control Gray Codes In-line Comparisons Applied Instructions 5 5-4 5-16 5-24 5-34 ...
Page 146
FX Series Programmable Controlers 5.3 Arithmetic And Logical Operations - Functions Contents: ADD - Addition SUB - Subtraction MUL - Multiplication DIV - Division INC - Increment DEC - Decrement WAND - Word AND WOR - Word ...
Page 147
FX Series Programmable Controlers 5.3.1 ADD (FNC 20) Mnemonic Function ADD The value of the FNC 20 two source ( devices is added Addition) and the result stored in the desti- nation device [ ADD D 10 ...
Page 148
FX Series Programmable Controlers 5.3.2 SUB (FNC 21) Mnemonic Function SUB One source FNC 21 device (Subtract) is subtracted from the other - the result is stored in the destination device [ SUB ...
Page 149
FX Series Programmable Controlers 5.3.3 MUL (FNC 22) Mnemonic Function MUL Multiplies the two FNC 22 source devices (Multiplica together the result -tion) is stored in the destination device [ MUL D 0 Points to note: a) ...
Page 150
FX Series Programmable Controlers 5.3.4 DIV (FNC 23) Mnemonic Function DIV Divides one FNC 23 source value by (Division) another the result is stored in the destination device Points to note: a) When operating the DIV instruction in 16bit mode, ...
Page 151
FX Series Programmable Controlers 5.3.5 INC (FNC 24) Mnemonic Function INC The designated FNC 24 device is ( incremented by 1 Increment) on every execution of the instruction next increment will write a value of -32,768 to the destination device. ...
Page 152
FX Series Programmable Controlers 5.3.7 WAND (FNC 26) Mnemonic Function WAND A logical AND is FNC 26 performed on the ( source devices - Logical word AND) result stored at destination The following rules are used to determine the result ...
Page 153
FX Series Programmable Controlers 5.3.9 WXOR (FNC 28) Mnemonic Function WXOR A logical XOR is FNC 28 performed on the (Logical source devices - exclusive result stored at OR) destination The following rules are used to determine the result of ...
Page 154
FX Series Programmable Controlers MEMO Applied Instructions 5 5-32 ...
Page 155
... Rotation And Shift Data Operation High Speed Processing Handy Instructions External FX I/O Devices External FX Serial Devices Floating Point 1 & 2 Trigonometry (Floating Point 3) Data Operations 2 FX1S & FX1N Positioning Control Real Time Clock Control Gray Codes In-line Comparisons Applied Instructions 5 5-4 5-16 5-24 5-34 ...
Page 156
FX Series Programmable Controlers 5.4 Rotation And Shift - Functions Contents: ROR - Rotation Right ROL - Rotation Left RCR - Rotation Right with Carry RCL - Rotation Left with Carry SFTR - (Bit) Shift Right SFTL ...
Page 157
FX Series Programmable Controlers 5.4.1 ROR (FNC 30) Mnemonic Function ROR The bit pattern of FNC 30 the destination (Rotation device is rotated right) ‘n’ places to the right on every execution 5.4.2 ROL (FNC 31) Mnemonic Function ROL The ...
Page 158
FX Series Programmable Controlers 5.4.3 RCR (FNC 32) Mnemonic Function RCR The contents of FNC 32 the destination ( device are rotated Rotation right with right with 1 bit carry) extracted to the carry flag 5.4.4 RCL (FNC 33) Mnemonic ...
Page 159
FX Series Programmable Controlers 5.4.5 SFTR (FNC 34) Mnemonic Function SFTR The status of the FNC 34 source devices are ( right) copied to a Bit shift controlled bit stack moving the existing data to the right 5.4.6 SFTL (FNC ...
Page 160
FX Series Programmable Controlers 5.4.7 WSFR (FNC 36) Mnemonic Function WSFR The value of the FNC 36 source devices are ( copied to a Word shift right) controlled word stack moving the existing data to the right 5.4.8 WSFL (FNC ...
Page 161
FX Series Programmable Controlers 5.4.9 SFWR (FNC 38) Mnemonic Function SFWR This instruction FNC 38 creates and builds ( register a FIFO stack n Shift write) devices long -must be used with SFRD FNC 39 a) FIFO is an abbreviation ...
Page 162
FX Series Programmable Controlers 5.4.10 SFRD (FNC 39) Mnemonic Function SFRD This instruction FNC 39 reads and (Shift reduces FIFO register read) stack- must be used with SFWR FNC 38 Points to note: a) FIFO is an abbreviation for ‘First-In/ ...
Page 163
... Rotation And Shift Data Operation High Speed Processing Handy Instructions External FX I/O Devices External FX Serial Devices Floating Point 1 & 2 Trigonometry (Floating Point 3) Data Operations 2 FX1S & FX1N Positioning Control Real Time Clock Control Gray Codes In-line Comparisons Applied Instructions 5 5-4 5-16 5-24 5-34 ...
Page 164
FX Series Programmable Controlers 5.5 Data Operation - Functions Contents: ZRST - Zone Reset DECO - Decode ENCO - Encode SUM - The Sum Of Active Bits BON - Check Specified Bit Status MEAN - Mean ANS ...
Page 165
FX Series Programmable Controlers 5.5.1 ZRST (FNC 40) Mnemonic Function ZRST Used to reset a FNC 40 range of like ( devices in one Zone Reset) operation The specified device range cannot contain mixed device types, i.e. C000 specified as ...
Page 166
FX Series Programmable Controlers 5.5.3 ENCO (FNC 42) Mnemonic Function ENCO Then location of FNC 42 the highest active (Encode) bit is stored as a numerical position from the head address Points to note: a) The readable range is defined ...
Page 167
FX Series Programmable Controlers 5.5.4 SUM (FNC 43) Mnemonic Function SUM The number FNC 43 (quantity active bits in the Sum of active bits) source data is stored in the destination device 5.5.5 BON (FNC 44) Mnemonic Function ...
Page 168
FX Series Programmable Controlers 5.5.6 MEAN (FNC 45) Mnemonic Function MEAN Calculates the FNC 45 mean of a range (Mean) of devices General rule Example (D0) ...
Page 169
FX Series Programmable Controlers 5.5.7 ANS (FNC 46) Mnemonic Function ANS This instruction FNC 46 starts a timer. (Timed Once timed out annunciator the selected set) annunciator flag is set ON If the instruction is switched OFF during or after ...
Page 170
FX Series Programmable Controlers 5.5.9 SQR (FNC 48) Mnemonic Function SQR Performs a FNC 48 mathematical (Square square root e.g.: root) D= Operation 2: This function is equivalent to FNC 127 ESQR This operation is similar to Operation 1. However, ...
Page 171
FX Series Programmable Controlers 5.5.10 FLT (FNC 49) Mnemonic Function FLT Used to convert FNC 49 data to and from ( floating point Floating point) format Operands M8023 = OFF data is converted from decimal to floating ...
Page 172
FX Series Programmable Controlers MEMO Applied Instructions 5 5-50 ...
Page 173
... Rotation And Shift Data Operation High Speed Processing Handy Instructions External FX I/O Devices External FX Serial Devices Floating Point 1 & 2 Trigonometry (Floating Point 3) Data Operations 2 FX1S & FX1N Positioning Control Real Time Clock Control Gray Codes In-line Comparisons Applied Instructions 5 5-4 5-16 5-24 5-34 ...
Page 174
FX Series Programmable Controlers 5.6 High Speed Processing - Functions Contents: REF - Refresh REFF - Refresh and filter adjust MTR - Input matrix HSCS - High speed counter set HSCR - High speed counter reset HSZ ...
Page 175
FX Series Programmable Controlers 5.6.1 REF (FNC 50) Mnemonic Function REF Forces an FNC 50 immediate update ( of inputs or Refresh) outputs as å specified the REF instruction is used. The REF instruction can only be used to update ...
Page 176
FX Series Programmable Controlers 5.6.3 MTR (FNC 52) Mnemonic Function MTR Multiplexes a FNC 52 bank of inputs (Input into a number of matrix) sets of devices. Can only be used ONCE processed. The result is stored in a matrix-table ...
Page 177
FX Series Programmable Controlers f) Because this instruction uses a series of multiplexed signals it requires a certain amount of ‘hard wiring’ to operate. The example wiring diagram to the right depicts the circuit used if the previous example instruction ...
Page 178
FX Series Programmable Controlers Points to note recommended that the drive input used for the high speed counter functions; HSCS, HSCR, HSCZ is the special auxiliary RUN contact M8000 more than one high speed counter ...
Page 179
FX Series Programmable Controlers 5.6.6 HSZ (FNC 55) Mnemonic Function HSZ Operation 1: FNC 55 The current value (High of a high speed speed zone counter is checked compare) against a specified range Operation 2: The designated range is held ...
Page 180
FX Series Programmable Controlers The following points should be read while studying the example on the right of the page. Please note, all normal rules associated with high speed counters still apply. The data table is p rocessed on e ...
Page 181
FX Series Programmable Controlers Operation 3 - Combined HSZ and PLSY Operation: (Applicable units: FX Operation 3 allows the HSZ and PLSY instructions to be used together as a control loop. This operation is selected when the destination device (D) ...
Page 182
FX Series Programmable Controlers 5.6.7 SPD (FNC 56) Mnemonic Function SPD Detects the FNC 56 number of (Speed ‘encoder’ pulses detection given time frame. Results can be used to calculate speed Points to note : a) When the ...
Page 183
FX Series Programmable Controlers 5.6.8 PLSY (FNC 57) Mnemonic Function PLSY Outputs a FNC 57 specified number (Pulse Y of pulses at a set output) frequency Points to note /FX users may use frequencies 132,767Hz ...
Page 184
FX Series Programmable Controlers 5.6.9 PWM (FNC 58) Mnemonic Function PWM Generates a FNC 58 pulse train with ( width defined pulse Pulse modulation) characteristics Points to note: a) Because this bit instruction, the available time ranges ...
Page 185
FX Series Programmable Controlers 5.6.10 PLSR (FNC 59) Mnemonic Function PLSR Outputs a FNC 59 specified number ( ramp) of pulses, Pulse ramping set frequency and back down to stop M54 PLSR K500 ...
Page 186
FX Series Programmable Controlers e) Two FNC 59 (PLSR) can be used at the same time in a program to output pulses to Y000 and Y001 respectively. Or, only one FNC 57 PLSY and one FNC 59 PLSR can be ...
Page 187
... Rotation And Shift Data Operation High Speed Processing Handy Instructions External FX I/O Devices External FX Serial Devices Floating Point 1 & 2 Trigonometry (Floating Point 3) Data Operations 2 FX1S & FX1N Positioning Control Real Time Clock Control Gray Codes In-line Comparisons Applied Instructions 5 5-4 5-16 5-24 5-34 ...
Page 188
FX Series Programmable Controlers 5.7 Handy Instructions - Functions Contents: IST - Initial State SER - Search ABSD - Absolute Drum INCD - Incremental Drum TTMR - Teaching Timer STMR - Special Timer - Definable ALT - ...
Page 189
FX Series Programmable Controlers 5.7.1 IST (FNC 60) Mnemonic Function IST Automatically sets FNC multi-mode ( state) STL operating Initial system Points to note: a) The IST instruction automatically assigns and uses many bit flags and word ...
Page 190
FX Series Programmable Controlers e) The available operating modes are split into two main groups, manual and automatic. There are sub-modes to these groups. Their operation is defined as: Manual Manual (selected by device S+0)- Power supply to individual loads ...
Page 191
FX Series Programmable Controlers 5.7.2 SER (FNC 61) Mnemonic Function SER Generates a list FNC 61 of statistics (Search a about a single Data Stack) data value located/found in a data stack Destination device D Total number of occurrences of ...
Page 192
FX Series Programmable Controlers 5.7.3 ABSD (FNC 62) Mnemonic Function ABSD Generates FNC 62 multiple output (Absolute patterns in drum response to sequencer) counter data Points to note: a) The current value of the selected counter (S2) is compared against ...
Page 193
FX Series Programmable Controlers 5.7.4 INCD (FNC 63) Mnemonic Function INCD Generates a FNC 63 single output (Incremental sequence in drum response to sequencer) counter data Points to note: a) This instruction uses a ‘data table’ which contains a single ...
Page 194
FX Series Programmable Controlers 5.7.5 TTMR (FNC 64) Mnemonic Function TTMR Monitors the FNC 64 duration of a (Teaching signal and places timer) the timed data into a data regis- ter 5.7.6 STMR (FNC 65) Mnemonic Function STMR Provides FNC ...
Page 195
FX Series Programmable Controlers 5.7.7 ALT (FNC 66) Mnemonic Function ALT The status of the FNC 66 assigned device (Alternate is inverted on state) every operation of the instruction 5.7.8 RAMP (FNC 67) Mnemonic Function Ramps a device RAMP from ...
Page 196
FX Series Programmable Controlers Points to note and FX users may set the operation 2N 2NC mode of the RAMP instruction by controlling the state of special auxiliary relay M8026. When M8026 is OFF, the RAMP instruction will ...
Page 197
FX Series Programmable Controlers 5.7.9 ROTC (FNC 68) Mnemonic Function ROTC Controls a rotary FNC 68 tables movement (Rotary is response to a table requested control) destination/ position Points to note: a) This instruction has many automatically de- fined devices. ...
Page 198
FX Series Programmable Controlers d) When the ‘zero point’ input (D+2) is received the contents of device S+0is reset to ‘0’ (zero). Before starting any new operation it is advisable to ensure the rotary table is initialized by moving the ...
Page 199
FX Series Programmable Controlers 5.7.10 SORT (FNC 69) Mnemonic Function SORT Data in a defined FNC 69 table can be (SORT sorted on selected Tabulated fields while Data) retaining record integrity records integrity. The resulting (new) data table is stored ...
Page 200
FX Series Programmable Controlers MEMO Applied Instructions 5 5-78 ...