Mitsubishi Electronics FX1S manual Device specification, Setting range, Direction setting

Page 100

FX Series Programmable Controllers

Devices in Detail 4

4.11.31 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.

When X11 is ON, C235 resets to 0 (zero). All contacts of the counter C235 are also reset. When X12 is ON, C235 is selected. From the previous counter tables, the corresponding counted input for C235 is X0. C235 therefore counts the number of times X0 switches from OFF to ON.

X10

X11

X12

M8235

RST C235

C235

K1234

Device specification:

• All of these counters are 32bit up/down ring counters. Their counting and contact operations are the same as normal 32bit up/down counters described on page 4-21. When the counters current value reaches its maximum or setting value, the counters associated contacts are set and held when the counter is counting upwards. However, when the counter is counting downwards the contacts are reset.

Setting range:

-2,147,483,648 to +2,147,483,647

Direction setting:

The counting direction for 1 phase counters is dependent on their corresponding flag M8✰✰✰; where ✰✰✰ is the number of the corresponding counter, (C235 to C240). When M8✰✰✰ is ON the counter counts down,

When M8✰✰✰ is OFF the counter counts up.

Using the SPD instruction:

Care should be taken when using the SPD applied instruction (FNC 56). This instruction has both high speed counter and interrupt characteristics, therefore input devices X0 through X5 may be used as the source device for the SPD instruction. In common with all high speed processes the selected source device of the SPD instruction must not coincide with any other high speed function which is operating, i.e. high speed counters or interrupts using the same input.

When the SPD instruction is used it is considered by the system to be a 1 phase high speed counter. This should be taken into account when summing the maximum com- bined input signal frequencies - see the previous section.

4-26

Image 100
Contents Programming Manual Page FX Series Programmable Controllers ForewordFX Series Programmable Controllers FAX Back Combined Programming Manual J FX Series Programmable Controllers Hardware Warnings Software WarningsFX Series Programmable Controllers Contents STL Programming Applied Instructions Rotation And Shift Functions 30 to External FX Serial Devices Functions 80 to Execution Times And Instructional 10-1 Viii FX Series Programmable Controllers Chapter Contents Introduction OverviewWhat is a Programmable Controller? What do You Need to Program a PLC?Special considerations for programming equipment Current Generation CPU all versionsAssocciated Manuals Manual name Number FX Base Unit HardwareManual name Number FX DU, GOT and DM units Memo Basic Program Instructions FX Series Programmable ControllersBasic Program Instructions Outline of Basic Devices Used in Programming What is a Program?Detailed device information How to Read Ladder Logic ExampleOUT instruction Load, Load InverseProgram example Timer and Counter Variations OutLast coil effect Use of dual coilsDouble Coil Designation And, And Inverse Peripheral limitationsOr, Or Inverse ORILoad Pulse, Load Trailing Pulse Single Operation flags M2800 to M3071Pulse, And Trailing Pulse LDF ANF OUTOr Pulse, Or Trailing Pulse ORF ORBBatch processing limitations Or BlockSequential processing limitations Block ANB13 MPS, MRD and MPP MPS, MRD and MPP usageMultiple program examples Master Control and Reset MCRNested MC program example Set and Reset Resetting timers and countersRetentive timers Timer, Counter Out & Reset16.1Basic Timers, Retentive Timers And Counters Bit counters Availability of devicesNormal 32 bit Counters High Speed CountersPLF Leading and Trailing PulseInverse Usages for INVNo Operation No Operation20 End Program scanMemo STL Programming FX Series Programmable ControllersSTL Programming What is STL, SFC And IEC1131 Part 3? General noteEach step is a program How STL OperatesLook Inside an STL How To Start And End An STL Program Combined SFC Ladder representationEmbedded STL programs Activating new statesTerminating an STL Program Initial StepsReturning to Standard Ladder Using SET to drive an STL coil Moving Between STL StepsOUT is used for loops and jumps Using OUT to drive an STL coilOut is used for distant jumps Rules and Techniques For STL programs Basic Notes On The Behavior Of STL programsT001 K20 K50 Method 1 Using locking devices Single Signal Step ControlMethod 2 Special Single Pulse Flags Using ‘jump’ operations with STL Restrictions Of Some Instructions When Used With STLRestrictions on using applied instructions Using STL To Select The Most Appropriate Program STL OUT SETUsing STL To Activate Multiple Flows Simultaneously Limits on the number of branchesLimits on the number of branches General Rules For Successful STL Branching Instruction FormatGeneral Precautions When Using The FX-PCS/AT-EE Software Programming Examples Simple STL FlowIdentification of normally closed contacts SET STLPoints to note Selective Branch/ First State Merge Example ProgramFull STL flow diagram/program Advanced STL Use Devices in Detail FX Series Programmable ControllersDevices in Detail Configuration details InputsAvailable devices Device MnemonicDevice Mnemonic Y OutputsAlias O/P Device Mnemonic M Auxiliary RelaysGeneral Stable State Auxiliary Relays Battery Backed/ Latched Auxiliary Relays External loadsSpecial Diagnostic Auxiliary Relays Special Single Operation Pulse RelaysDevice Mnemonic S State RelaysGeneral Stable State State Relays Battery Backed/ Latched State Relays PLC FX 1S FX 1N FX 2NAssigned states Monitoring STL programsSTL/SFC programming IST instructionAnnunciator Flags Pointers Jumping to the end of the programDevice availability Device Mnemonic PInterrupt Pointers Additional applied instructionsNested levels Pointer positionRules of use Timer InterruptsInput Interrupts Driving special auxiliary relays Disabling high speed counter interruptsAdditional notes Disabling Individual InterruptsConstant K Constant HDevice Mnemonic K Example device usage N/ATimer accuracy TimersDevice Mnemonic T Selectable Timers General timer operationDriving special auxiliary coils Using timers in interrupt or ‘CALL’ subroutines Retentive TimersInternal timer accuracy Timers Used in Interrupt and ‘CALL’ SubroutinesTimer Accuracy ConditionSetting ranges for counters CountersHigh speed counters Device Mnemonic CBattery backed/latched counters General/ Latched 16bit UP CountersSelecting the counting direction Battery backed/ latched countersGeneral/ Latched 32bit Bi-directional Counters Basic high speed counter operation Further uses NoneDriving high speed counter coils Basic High Speed Counter OperationCounter Speeds Input assignmentAvailability of High Speed Counters Calculating the maximum combined counting speed on FX1S Device specification Setting rangeDirection setting Using the SPD instructionRST 11.5 2 Phase Bi-directional Counters C246 to C250 Device size11.6 A/B Phase Counters C252 to C255 Device Mnemonic D Data RegistersExample device usage None Data retention Data register updatesGeneral Use Registers Using the FX2-40AW/AP Use of diagnostic registersBattery Backed/ Latched Registers Special Diagnostic RegistersSpecial caution when using FX1S Writing to file registersFile Registers Program memory registersExternally Adjusted Registers UsesIndex Registers Use of Modifiers with Applied Instruction ParametersDevice Mnemonic V,Z Available formsModifying a Constant Using Multiple Index RegistersMisuse of the Modifiers Bits, Words, BCD and Hexadecimal Bit Devices, Individual and GroupedAssigning I/O Moving grouped bit devicesAssigning grouped bit devices Word Devices Interpreting Word DataFX Series Programmable Controllers Binary Coded Decimal value= Error Word Data Summary14.4 Two’s Compliment Inverted7 Additional1Floating Point And Scientific Notation Some useful constantsScientific Notation Floating Point Format FLT