Home
QnACPU,PROGRAMMING MANUAL(SFC)
Contents
1. 1 When CPU STOP RUN switching occurs SM322 is switched OFF or ON in accordance with the parameter setting OFF if an initial START is designated and ON if a resumptive start setting is designated 2 The previous active status is the status which was active when SM321 was switched OFF during SFC program execution or when a CPU reset or power OFF occurred 4 7 2 Block 0 START condition The block 0 START condition setting determines whether block 0 is auto matically started and activated when an SFC program START occurs SM321 OFF ON 1 Settings and corresponding operations An auto START ON or auto START OFF setting is designated for block 0 Operations which occur at the SFC program START and at the block END are shown below wn At SFC Program START _ At Block END Block 0 Auto START ON e Block 0 is automatically activated and is The initial step is automatically activated default executed from its initial step again at the block END Block 0 is activated by a START request Auto START OFF resulting from an SFC contro block START instruction or a block START step in the same manner as other blocks Block 0 is deactivated at the block END and waits for another START request 4 SFC PROGRAM CONFIGURATION Me c i ut IS EE I EEN 4 7 3 Output mode at block STOP The output mode at block STOP setting determines whether an output designated by OUT instruct
2. 1 _GENERAL DESCRIPTION a In cases where the same function can be executed by a number of methods the first control method which has been designated by the request output to the block or step in question will be the effec tive control method id b Functions controlled by a given control method can be canceled by another control method Example For block START OE S active block which 5 starte l B n m method can be ended forced end 1 by an SFC control d instruction RST BLm or by switching the SFC information reg ister s block START END bit OFF re same screen SFC saan operation output and transition condition ladder display features a zoom function which can split the screen 4 ways right left upper lower to simplify program cut and paste opera tions Moreover advanced program edit functions such as the SFC diagram or device search function etc make program creation and editing operations quick and EASY e Displays with commen tees understanding Comments can be entered at each step and transition condition item Up to 32 characters can be entered Display size is 8 characters x 3 lines 24 characters i ae Ready w gt 8 aiting f 29 Start N2 Mix B ji 2 D3 Wait ateSD4 Wait ste Net lt Ins gt Step Mix A EWL Led 9 An automatic scrolling functions enables quick identification of mechani cal system trouble spots Activ
3. 1 instruction Number of steps 2 occurs at parallel coupling per parallel coupling For serial transitions and selection Transition START instruction TRAN 5 TR Number of steps 2 1 per transition condition Transition TSET Si e Designates the transition transitions 1 per transition condition designation Number of steps 2 destination ste for parallel branching transitions the instruction P P number of steps is the same as the number of parallel couplings Step END SEND e Indicates the step amp nar ete instruction Number of steps 1 transition END P P 3 10 4 SFC PROGRAM CONFIGURATION URS AE 4 SFC PROGRAM CONFIGURATION The SFC program symbols contro instructions and information registers which comprise an SFC program are discussed in this section 1 As shown below an SFC program consists of an initial step transition conditions intermediate steps and an END step The data beginning from the initial step and ending at the END step is referred to as a block Initial step Transition Transition condition 1 condition Step 1 Step Transition Transition Block condition 2 condition Step 2 Step H 1 1 Ms END step 2 SFC program operation begins at the initial step and proceeds to each of the successive steps as each transition condition is satisfied This operation sequen
4. QnACPU M SAFETY CAUTIONS You must read these cautions before using the product In connection with the use of this product in addition to carefully reading both this manual and the related manuals indicated in this manual it is also essential to pay due attention to safety and handle the product correctly j The safety cautions given here apply to this product in isolation For information on the safety of the PC system as a whole refer to the CPU modute User s Manual These SAFETY CAUTIONS are classified into two grades DANGER and CAUTION DANGER Safety caution given when incorrect handling could result in hazardous situations involving the possibility of death or serious injury N CAUTION Safety caution given when incorrect handling could result in hazardous situations involving the possibility of moderate or light injury or damage to property Note that depending on the circumstances failing to follow a A CAUTION may also have very serious consequences Both of these classes of safety caution are very important and must be observed Store this manual carefully in a place where it is accessible for reference whenever necessary and forward a copy of the manua to the end user System Design Precautions e Safety circuits should be installed external to the programmable controller to ensure that the system as a whofe will continue to operate safely in the event of an external power supply malfunct
5. e Individual information 0 None Error information Error information codes classification classification code 1 Unit No 0 None 2 File name 3 Time setting value File name 4 Program error location Time actual count value Program error location Parameter No Annunciator F No CHK instruction Failure No e The error common information is stored When the SFC program is started data is stored as follows File name rror common Error common information information Extend name AE E T e por Jor Jor b0 SFC bt Step No transition pai Seen condition No b1 SFC step information SaQuance program present No for step and b2 SFC transition transition condition condition information present APRS 4 APPENDICES eee TREN Warn EAE a e e iiia iui 3 rd LRQ UO Ue 0 Description a Tee onor individual iniou malion Je stored ies sss There is no individual information for errors originating at SFC programs ANS Error meou cU information information Step Wansition watchdog timer corresponding to SM90 Step vansition watchdog timer setting corresponding to SM91 Step traneition watchdog timer setting corresponding to SM92 Step trartsition watchdog timer setting corresponding to SM93 Step transition watchdog timer se M ae corresponding to SM94 Step transit
6. Up to 32 steps 4 22 4 SFC PROGRAM CONFIGURATION 2 If another block is started by the parallel processing operation the START source block and START destination block will be executed si multaneously In the example below processing from step n 1 will be executed simultaneously with block 1 Block 0 Step n Transition condition b Step n Tananan peal tote When condition b is satisfied at step n execution processing will i proceed to step n 1 and block 1 will be started Blocks 0 and 1 will then be processed simultane ously Block 1 START 3 Up to 1280 steps total for all blocks can be processed simultane ously If the 1280 limit is exceeded an error will occur and the PC CPU operation will be stopped The maximum number of active steps per block is 256 4 Couplings must be provided when the parallel transition format is used Program creation is impossible without couplings Example Program without couplings NG example END step Jump transition see Section 4 3 4 Each column ends occurs without coupling atthe END step END step 5 As arule a waiting step must be created prior to the coupling However in cases such as the example below where each of the par allel transition columns consist of only 1 step program without a tran sition condition between the parallel transition branch and the coupling a waiting
7. See failure diagnosis oom ome wan cmexpatwn cargo mem fome ensomeer ww jw eememsum O O O woe srono semen mox mox m ewasmr 0 mo foes someon OOOO STEP S SFC step START N D SC SE ST R C c SFC transition START Use of labe P is also prohibited Program branch SFC dedicated instructions 1 1D ISC ISE IST IR TRAN TRAN S L O OA OC OCA A C CA CO COC TAND TAND S SFC coupling check o TSET TSET S Deere SEE transition Sa NE 4 SFC PROGRAM CONFIGURATION Ae 2 Sequence program for transition condition a Transition condition sequence Program expression format TOY no A transittorrcondition sequence program using the tadder expression format is shown below f TRAN lt TRAN is e dummy output b Sequenc amp program capacity A transition condition s sequence program capacity is as follows e Max f 4K sequence steps per transition condition e Max of 4K sequence steps per block c Instructioris used Instructions which can be used in a transition condition sequence program are listed below Operation START N O contact Serial connection N O contact Parallel connection N O contact Contacts Operation START N C contact Serial connection N C contact Parallel connection N C contact Leading edge pulse operation START Leading edge pulse seria
8. 2 Multiple blocks can be started simultaneously by using a parallel transi tion format see Section 4 3 3 at the block START request Steps in the simultaneously started blocks will be processed in parallel 3 A maximum of 1280 steps total for all blocks can be executed simulta neously A maximum of 256 steps including HOLD steps can be executed simultaneously in each block 1 A simultaneous START at a single sub block or at a sub block which has already been started is impossible If attempted a BLOCK EXE ERROR error will occur and the programmable controller CPU will be stopped 2 The execution status of each block can be checked at another block by using the block START END bit see Section 4 5 1 or the block execution status check instruction SFC control instruction see Section 4 4 3 3 The use of a block START END bit or block execution status check instruction interlock is recommended in the transition condition which precedes a block START request in order to verify that the block to be started is not currently being executed Dame 4 sectari Kees condition Block 1 START request When the block 1 Biock 1 status BLOCK START end bit is Mi active inactive is checked 4 SFC PROGRAM CONFIGURATION A SS DEES ES MELSEC QaA 4 2 10 Block END 1 A block END indicates the end of the processing sequence for a given block 2 After a block END execution is completed operation is
9. Max of 60k steps Max of 92k steps Max of 124k steps The SFC program can execute only 1 file To exegute an SFC program which is in the wait status switch the SFC program being scanned to the wait status then scan the program in question 3 SPECIFICATIONS 3 2 Device List Internal system Internal user Link direct NET 10 Devices which can be used for the SFC program s transition conditions and operation outputs are shown in table 3 2 below Table 3 2 Device List Argument input input Bk Argument Argument register Special relay er SMO to SM2047 Special Input inputrelay LO to ETT MM Latch ES FO to F2047 to F2047 Annunciator Fage triggered rol EE Link Linkrelay Data register VO to V2047 Boto BIFFF to BIFFF Variable DO to 12287 within a WotoWiFFF 387 of WO to WOto WIFFF FFF Link pere 28 75 K words Normal timer timer TO to T2047 Bit word Retentive timer STO to ST2047 to ST2047 Special link EE link E SO to 511 1 EELS 8192 points for all ae Hose ario to JO XIFFF EE to JO YIFFF JO BO to JENBO to JO BIFFF JCNSBO to JOISBIFF xum aeea JOWO to JCNWIFFF Leg to ewer to JECASW1FF i relay Link Hae Link Ze Link Link relay Link special relay Link register Link special register M Sub r routine with argument e Sub routine with argument 1
10. 6 SFC PROGRAM EXECUTION T e When TRANSFER setting is designated RR RENE NR TRUE The transition occurs immediately and the previous step is deactivated The activation is absorbed b Double START by SFC control instruction The instruction is ignored and processing of the START destination step continues as is S The instruction is executed in the same way as the NOP instruction 6 SFC PROGRAM EXECUTION P ihe ate E O DIA a S 6 4 2 Step END deactivate methods The methods for deactivating steps are described below 1 Steps can be ended deactivated by the methods shown below e The step is automatically deactivated by the system when the step s transition condition is satisfied Deactivated when condition is satisfied Condition TRAN e f a reset step is designated as the step attribute the reset deactivate step No must be specified END by SFC diagram symbol n S10 p Reset step No e Using an SFC control instruction a specified step is forcibly reset deactivated from an SFC program step operation output or from another sequence program Condition Condition H m is the block No n is the step No END by SFC control instruction RST Sn n is the step No e Basic SFC program operation e At steps where attributes are specified operation will occur according to the attribute e Convenient for resetting HOLD steps during SFC prog
11. 6 4 1 Step START activate mes 6 9 6 4 2 Step END deactivate methods 0 cece cee et eese 6 11 6 4 3 Changing an active step status 0 ccc cece teen ees 6 12 4 4 10 Active step change instruction GC 4 52 APPENDICES iiss sea ker AC pO UR SOCCER AURI A RC ER PR CC ee APP 1 APP 10 APPENDIX 1 SPECIAL RELAY AND SPECIAL REGISTER LIST APP 1 11 SM Special Relays 0 0 cere hh en APP 1 12 SD Special Registers APP A APPENDIX 2 MELSAP II AND MELSAP3 COMPARISON 0 0 c cece ene eee APP 6 1 GENERAL DESCRIPTION 1 GENERAL DESCRIPTION This manual discusses the specifications functions instructions and pro gramming procedures used to program the MELSEC Q2A Q2A S1 Q3A and Q4ACPU hereafter referred to as QGAACPU with an SFC program using the MELSAP3 function SFC is an abbreviation for Sequential Function Chart and represents a program format in which a sequence of control operations is split into a se ries of steps enabling a clear expression of the program execution se quence and execution conditions MELSAPS conforms to the IEC standard for SFC In this manual the se quential function chart is referred to as SFC program diagram Related Manuals QnACPU Guidebook Aimed at people using QnACPU for the first time Describes procedures for everything from creating programs and writing created programs to the CPU to debugging Also descri
12. Designated block break Max of 64 block designations Designated step break Max of 64 step designations Designated block continue 1 block designation Continue STEP RUN function Designated step continue 1 point designation at specified step Continue from puer REN step 1 point peste N at specified step Forced block execution block execution 1 block beckdesgnaion Forced 1 step execution for designated block 1 point designation at specified step Forced block end 1 block designation ytes per block 1k byte units Execution conditions Per scan or per designated time Step transition watchdog timer function Equipped with 10 timers 1 Creation of 1 separate SFC program for program execution management is possible see Section 5 1 3 Forced execution Step trace function memory card required 3 SPECIFICATIONS The relationship between the CPU memory s program capacity and the number of files is shown below MELSEC QnA ex Multiple program files possible no SFC programs Multiple program files possible 1 SFC program only Scan program WAIT program tt Multiple program files possible multiple SFC programs OK Muitiple program files possible no SFC pr grams program e Max total of 124 programs possible Registration is by parameter setting e The program capacity varies according to the CPU type as shown below Max of 28k steps
13. GENERAL DESCRIPTION A es eI i maT EEE ETAT SEE STE TIR OR PE DETERRENT CUBE MELSEC GnA 4 Creation of multiple initial steps is possible Multiple processes can easily be executed and combined Initial steps are linked using a selection coupling format When multiple initial steps SO to S3 are active the step where the transition condition t4 to t7 immediately prior to the selected coupling is satisfied becomes inactive and a transition to the next step occurs Moreover when the transition condition immediately prior to an active step is satisfied the next step is executed in accordance with the parameter settings e Wait Transition to the next step occurs after waiting for the next step to become inactive e Transfer Transition to the next step occurs even if the next step is active e Pause An error occurs if the next step is active Linked steps can also be changed at each initial step 1 GENERAL DESCRIPTION 5 Program design is easy due to a wealth of step attributes A variety of step attributes can becassigned to each step Used singly fora given control operation or inicombination these attributes greatly simplify program design procedures e Types of HOLD Steps and their operations a Coit HOLD step SO Xo f Transition condition satisfied Step which is active due t trensition oondition being e isfied When the transition condition is satist
14. constant expansion SFC or the other column only that device may be used Example If K H is indicated in the constant column only a decimal K or hexadecimal H constant may be used Real number constants E and character string constants may not be used The data type for the designated device is indicated here el Saree rere eee Indicates a bit data operation es BIN16 Indicates 16 bit binary value processing 1 word used e BIN32 Indicates 16 bit binary value processing 2 words used e Character string Indicates character string processing Variable number of words e Devicelndicates device name and first device processing Variable number of words The type of program which can be used with the instruction in question is indicated here The request destination for the instruction in question is indicated here 4 SFC PROGRAM CONFIGURATION 4 4 1 Step operation status check instructions LD LDI AND ANI OR ORI DC Sn only At expansion SFC and other columns m represents the block No and n represents the step transition condition No BLmiSn e mt is the block No n is the step No BLm Sn nun ry 2 4 BLm Sn se LA BLm Sn BLm Sn Function 1 Checks a specified step in a specified block to determine if the step is active or inactive 2 If the step in question is active the N O contact instructi
15. e If the block START step is a EJ or EJ step all initial steps will be come active at the block START e f the block START is designated by the SET BLm block START instruction SFC control instruction all initial steps will become ac tive at the block START e f a forced block START is designated by the SFC information regis ter s block START END bit all initial steps will become active at the block START e f one of the initial steps is designated by the SET BLm Sn SET Sn step control instruction SFC control instruction only the desig nated step will become active at the block START Transition processing for multiple active initial steps When a selection coupling has been designated for a block with multi ple active initial steps the steps immediately following the coupling will be activated when any one of the transition conditions immedi ately preceding the coupling is satisfied In the program example shown above step 8 S8 will be activated when any one of the t4 to t7 transition conditions is satisfied When another transition condition immediately preceding the coupling becomes satisfied after the post coupling step has been activated re activation processing will occur as a follow up function If another transition condition becomes satisfied while the post coupling step S8 in the above example is active processing will be according to the SFC parameter setting for the transition to ac
16. with transition check initial step e Max of 31 steps per block Reset initial step Dummy step Coil HOLD step Operation HOLD step without transition check Operation HOLD step with transition check Steps other than initial step Max of 512 steps per block including initial step Reset step Block START step with END check Block START step without END check 4 SFC PROGRAM CONFIGURATION Serial transition Selective branching Selective branching parallel branching Selection coupling Selection coupling parallel branching Parallel branching Transition Parallel coupling Parallel coupling parallel branching Parallel coupling selective branching Parallel coupling selective coupling peok eno eror eno OoOo eum 4 SFC PROGRAM CONFIGURATION Steps are the basic units which comprise a block and they represent the units in which the SFC program is executed 1 Each step consists of operation outputs A maximum of 512 steps per block can be designated total of 8192 steps for ail blocks 2 Step numbers are assigned to the steps either automatically or by user designation when the SFC program is created The step numbers are used for monitoring step processing and for designating a forced START or END by SFC control instruction 4 2 1 Step L1 without step attribute During processing of steps without attributes the next transi
17. 5 SFC PROGRAM PROCESSING SEQUENCE QR RR ERR HE EOE A 5 2 2 Block execution sequence 1 When a block becomes active the operation output programs at each step are executed in order beginning from the initial step 2 At SFC programs with multiple blocks block processing is executed in order beginning from the block with the lowest number block 0 5 block 1 block 2 3 If multiple steps are activated by a parallel transition in an SFC program the operation outputs of all the active steps will be processed in a single scan Example In the SFC program shown below steps 3 and 4 at block 0 and steps 4 and 5 at block 1 are activated simultaneously Block o Block 1 Step 3 of Step 4 of E Step 5 of Step 4 of block 0 NES block 0 block 1 block 1 executed executed executed executed Active steps within a single block are processed in order from left to right 5 SFC PROGRAM PROCESSING SEQUENCE 2 3 Step execution sequence The step operation output programs are executed at each scan while the SFC program START END special relay SM321 is ON 1 Execution sequence from program START to the transition to step 1 of the SFC program When the SFC program START END special relay SM321 is switched ON and a program START occurs the execution sequence from the initial step to the transition to step 1 occurs as shown below CPU RUN END processing END processing END processing SM
18. A jump transition is a jump to a specified step within the same block which occurs when the transition condition is satisfied e When condition br is satisfied at step n Step n execution step n operation output A operation output A is deactivated and processing proceeds Transition condition br to step mr m 1 There are no restrictions regarding the number of jump transitions within a single block 2 In the parallel transition format only jumps in the vertical direction are possible at each of the branches It is impossible to create programs with jumps to another vertical lad der of a branch or with jumps which leave a parallel branch Example Program with jump which leaves a parallel branch NG example Parallel transition 4 Jump transition Example Program with vertical direction jump transition within the branch to coupling range OK example The jump transition must occur within the branch to coupling range 4 SFC PROGRAM CONFIGURATION jaa gies MEI GE C LA 4 3 5 Transition processing with multiple initial steps Transition processing at blocks which contain multiple initial steps is dis cussed in this section Only the selection coupling format may be used at blocks with multiple initial steps 1 2 Active step at block START At blocks containing multiple initial steps the step s which becomes active at the block START depends on the START method used
19. E Readout instruction n is the step No m is the block No n is the step No I woves Oman L nore T oss gl wow G si O ono sem Function 1 Executes a batch readout of the operation statuses active inactive of steps in a specified block 2 The readout results are stored at the D device as shown below b15 b14 b13 b12 bi bp b9 b3 ejelelededeieleleledeedelele e Ze e gt Sn step 15 Sn sl 1 Step designated at Sn 3 If the steps in question do not exist in the SFC program they will remain OFF 4 SFC PROGRAM CONFIGURATION TUM E MELSEC nA Program Examples 1 The following progtam will read out Reps 0 to 32 iri block 3 when XO switches ON Gene a step within the current block Designating a step in another block xo aer asas zs b15 bid b13 b12 bi bin b9 b8 b7 bE b5 b4 b3 b2 bi bO 815 si4 s13 812 sit s10 s9 s8 SEET SM 331 s30 s29 s28 127 s26 325 s24 823 s22 821 820 s19 818 s17 316 Related Instructions a SFC control instructions e Block switching instruction BRSET See Section 4 4 11 e Step operation status check instruction Sn See Section 4 4 1 e Active step batch readout f instruction BMOV 05 See Section 4 4 5 4 SFC PROGRAM CONFIGURATION MELSEC QnA 4 4 5 Active step batch readout BMOV MELSECNET A0 Direct AM Programs Programe
20. END instructions SET RST Programe Vang nabuctons Using Instructions Dets SFC Program uie Type ISS Beie Condition Traneltion Condition At expansion SFC and other columns m represents the block No and n represents the step transition condition No n is the step No H m is the block No LH SET BLmiSn RST B BimiSn Function 1 a A specified step at a specified block is activated forcibly Operation at the block in question varies as follows depending on whether the block is active or inactive e When the specified block is inactive The specified block is activated when the SET instruction is exe cuted and processing begins from the specified step If an SFC information register block START END bit setting has been designated the bit device in question will switch ON at this time e When the specified block is active If the step is already active when the SET instruction is exe cuted the step will remain active and processing will continue with another step being designated as active Multiple step acti vation follow up function b When multiple initia steps exist an initial step selection START will occur when a given step is specified and activated c When designating a step located in a paralle branch all the paral lel steps should be activated An inactive parallel branch ladder at such a time will prevent the parallel coupling conditi
21. Executed again 5 When the SFC control block STOP instruction PAUSE BLm is exe cuted the block in question is stopped and the block STOP RESTART bit switches ON When the block RESTART instruction RSTART BLm is executed while the black is stopped the block in question is restarted and the block STOP RESTART bit switches OFF 1 Stopping of program processing by a block STOP RESTART bit being switched ON or by a block STOP instruction applies only to the specified block 2 Even if a block stop is executed for the START destination block the START source block will not be stopped 3 Even if a block stop is executed for the START source block the START destination block will not be stopped Related Instructions a SFC information register e Block STOP mode bit See Section 4 5 4 b SFC control instructions e Block STOP instruction PAUSE BLm amp block RESTART instruction RSTART BLm 0 eee eee See Section 4 4 7 4 6 4 SFC PROGRAM CONFIGURATION i ns MELSEC QnA 4 5 4 Block STOP mode bit The block STOP mode bit setting determines when the specified block is stopped after the block STOP RESTART bit switches ON or after a stop designation by the block STOP instruction PAUSE BLm 1 The stop timing for a block where a STOP request has occurred varies according to the ON OFF setting of the block STOP mode bit as shown below e The block is stopped immediat
22. GPPQ programming software package For details regarding the setting procedure refer to the GPPQ Operating Manual SFC 5 SEC PROGRAM PROCESSING SEQUENCE ae ee 3 Example of program execution management SFC programs SFC1 QPR SFO2 QPR and SFC3 QPR are assumed to be SFC program files and SQ QPR is assumed to be a program file for a program other than an SFC pragram Condition 1 so PSCAN SFC1 QPR Scanning of the zero return etc pre KE processing contro SFC program and the constant monitoring sequence program SCAN sa GPR is executed Condition 2 PoFF SFC1 QPR An SFC program WAIT status is estab t6 lished at the zero return END signal S4 Condition 3 uv wH When an SFC program SFC1 WAIT I status is established a selection transi INV inverse of previous operation result tion occurs If condition 3 product type etc Is ON Scanning of SFC program for automatic operation is executed POFF SFC2 QPR e AnSFC program WAIT status is estab lished when the automatic operation END condition is satisfied by a cycle STOP or emergency STOP etc Condition 4 Condition 4 H When condition 4 is satisfied normal ENO by cycle STOP a block END oc curs and SO is reactivated after the tran sition condition is satisfied Condition 5 t2 PCHK SFC2 opp TRAN When condition 5 is satisfied forced END by emergency STOP etc a selec fon transition t
23. START at a single block or at a block which has already been started is impossible _ If attempted a BLOCK EXE ERROR error will occur and the programmable controller CPU will be stopped 2 The execution status of each block can be checked at another block by using the block START END bit see Section 4 5 1 or the block execution status check instruction SFC control instruction see Section 4 4 3 8 The use of a block START END bit or block execution status check instruction interlock is recommended in the transition condition which precedes a block START request in order to verify that the block to be started is not currently being executed Example EE Eje ae aa condition Tran 7 Tran Block 1 START request When the block 1 Block 1 status BLOCK START end bitis M1 active inactive is checked 4 SFC PROGRAM CONFIGURATION a a GH NCS MEEOEGO GnA 4 2 9 Block START step without END check E A block START step without END check is the step to which processing proceeds when a specified block is started activated without waiting for the START destination block to be deactivated 1 Transition from the block START request source to the next step occurs when the transition condition which follows the block START step is satisfied This transition occurs without waiting for the START destina tion block execution to be completed Processing of the START destination sub block continues without inter ruption
24. This file Is for subroutines or interrupt programs etc 4 WAIT program waiting Started by program start instruction 1 The SFC program can execute only one of the scan execution files To start a WAIT program the SFC program where scanning Is currently in progress must first be designated as a WAIT program Refer to section 5 1 2 for details regarding the scan execution amp WAIT program switching procedure 2 The execution type settings for the program files are designated at the program setting item of the auxiliary parameter settings 5 SFC PROGRAM PROCESSING SEQUENCE MELSEC QnA 5 1 2 Execution type designation by instructions The execution by instruction function enables the use of instructions to change the execution type designated by the program setting parameter Details on execution type designation by instructions are given below 1 instructions and corresponding operations SFC PSTOP e Designates a WAIT status at the specified block beginning from the next scan e Designates END processing for all blocks of a specified SFC program from the next POFF scan with a WAIT status established at the 2nd scan following execution of the instruction e Designates scanning of a specified program beginning from the next scan PSCAN e f multiple programs are specified the execution sequence is determined by the program setting paramet
25. at device DO and with device Y10 switch ing ON when time up occurs Xo weg oo kso vio 4 SFC PROGRAM CONFIGURATION C ND cipes mnis tete ICO SNR ESPRIME mE reme genz iE SE C Qn A 45 SFC Information Registers The SFC information registers designated at each block are described in this section In cases where SFC information register functions are not required there is no need to designate the register settings when creating the SFC pro gram The absence of register settings will not affect SFC program opera tion The devices which can be used for each of the SFC information register types and functions are shown below SFC Information Registers Block START END bit Step transition bit Block STOP RESTART bit Block STOP mode bit Continuous transition bit Number of active steps register SFC information register settings are designated when entering the SFC diagram at the SWOIVD GPPQ GPP function software package 4 SFC PROGRAM CONFIGURATION 4 5 1 Block START END bit The block START END bit can be used as a confirmation device when a block is activated by a block START step or it can be used to execute a forced START or forced END from sequence program or by peripheral de vice test operation at a given block 1 The block START END bit can be used for purposes such as providing an interlock when confirming that the sub block in question is inactive when a sub block is started by a blo
26. block at the same time the START destination s block STOP RESTART bit must also be switched OFF 2 When a block is stopped by switching the block STOP RESTART bit ON the STOP timing will be as shown below Status ot Operation Description Output Mode Output Setting at rate Wiock BTOP Parameter pecial Active Step Other than HOLD Block STOP Relay Mode Eh P Un Active HOLD Step 8M325 OFF or no setting immediate stop e After the STOP request the coil output will be switched OFF the first time processing occurs at the specified block and a STOP will occur Coil output OFF e After the STOP request the coil OFF coil coil output output will be switched OFF e After the STOP request output HOLD OFF when the transition condition is the coil output will be eck tanen satisfied and a STOP will occur switched OFF the first STOP e If multiple steps are active the time processing occurs at STOP will occur at each of the cd on ba block and a steps in sequence as their will occur transition conditions are satisfied OFF or no setting immediate stop e After the STOP request a coil output HOLD status will be established the first time processing occurs at the specified block and a STOP will occur ON e After the STOP request the coil Coil output coil output output HOLD status will be e After the STOP request HOLD HOLD established when the transition a coil output HOLD status ON condition is sati
27. blocks at multiple steps the BRSET instruction must be executed at each of the steps e Error No 4621 occurs when the specified block does not exist 1 When X1 switches ON the following program switches the Sn or TRn block number to the block number stored at the DO data register Condition BRSET Do 2 When X2 switches ON the following program switches the Sn or TRn block number according to the constant at the Z1 index register X2 BRSET Kozi 4 SFC PROGRAM CONFIGURATION 44 12 Program operation status check instruction Programs Using Instructions SFC Program _ Internal Device o Sytem User MELSECNET 10 gt Si Exper sion meas Direct JEN e SE SECO Bimsn i BimTRA Transition Condition 7 At expansion SFC and th Sero condition N Function Operation Error a The MEM program switches Y10 ON if the ABC QPR p program is program Examples currently being executed PCHK ABC QPR Being Geteste Not being executed 4 SFC PROGRAM CONFIGURATION if j MELSEC QnA 4 4 13 Subroutine call instruction XCALL Programs taing iecit Using Programs taing iecit Deta pm Type Sequence Transition Zeg Program Condition es Transition Condition Device name Accordl ng to H specifie device provided to subroutine program as argument d devi
28. conditions EE EREMO 4 steps 2 3 6 7 3 SPECIFICATIONS Q 1100 TS MELSEC QnA 3 4 Calculating the SFC Program Capacity In order to express the SFC diagram using instructions the memory capacity shown below is required The method for calculating the SFC program capacity and the number of steps when the SFC diagram is expressed by SFC dedicated instructions is described in this section 1 Method for calculating the SFC program capacity av max created lock 0 cai block 1 zz block n SFC program capacity 2 e X block No 1 Number of blocks being used SFC fhe header capacity SFC program START SFCP and END SFCPEND instructions number of steps where SFC diagram Is i e operation output total for all steps Capacity of blocks 2 pisei by SFC dedicated instructions total number of transition conditions As shown below Block START BLOCK BLm and END BEND instructions Number of steps where SFC diagram is expressed by SFC dedi cated instructions gt e Step 0 88 3 sequence steps for step START STEP Sn and END SEND instruc tions Transition conditions gt a For serial transition or selective branching coupling 4 sequence steps for transition START instruction TRAN TRn and tran sition destination instruction TSET Sn b For parallel branching Total number of steps for the transition START instruction TRAN 3 TRn and transitio
29. functions as a normal step no step attributes When a reset stap is activated a specified step is deactivated reset 4 SFC PROGRAM CONFIGURATION POINT Only HOLD steps can be reset deactivated by a reset step Resets are impossible for activa HOLD steps where a HOLD status is not in effect and for steps nat designated as HOLD steps 4 SFC PROGRAM CONFIGURATION 4 2 8 Block START step with END check a A block START step with END check is the step to which processing proceeds when a specified block is started activated and the START destination block is deactivated 1 Multiple blocks can be started simultaneously by using a parallel transi tion format see Section 4 3 3 at the block START request Steps in the simultaneously started blocks will be processed in parallel 2 Theblock START request source is stopped at the block START request step until execution of the START destination block is completed The block START request source will then proceed to the next step 3 If a ladder exists at the transition condition which follows a block START step the step transition will occur according to the ladder s AND condition following the completion of the START request destination block operation 4 Amaximum of 1280 steps total for all blocks can be executed simultaneously A maximum of 256 steps including HOLD steps can be executed simultaneously in each block 1 A simultaneous
30. instructions instructions Only when transition condition is satisfied e Processing time for operation output instructions deat M td trip va vau bdo Total processing time for instructions used for operation outputs at all active steps e Processing time for transition condition instructions sd aster ae eae tatu ud d do ets Total processing time for instructions used for transition conditions at all active steps For details regarding the processing times for operation outputs and transition condition instructions refer to the QnA Program ming Manual Common Instructions b Method for calculating the system processing time System processing time SFC END processing time active block processing time x number of active blocks processing time for inactive blocks x number of inactive blocks processing time for nonexistent blocks x number of nonexistent blocks active step processing time x number of active steps processing time for active step transition conditions x number of active step transition conditions processing time for steps where transition conditions are satisfied x number of steps where transition conditions are satisfied e Number of active blocks Total number of active blocks e Number of inactive blocks Total number of inactive blocks e Number of nonexistent blocks Lie Sa pase A demi PIE ede d Total number of parameter designated blocks which have no programs
31. is OFF and is switched ON when the coil output is ON in accordance with the parameter setting The M325 special relay can also be switched ON and OFF by the user program without regard to the parameter setting c The STOP RESTART bit switches ON when the SFC control block STOP instruction PAUSE BLm is executed 2 RSTART a The block in question is restarted from the step where a STOP oc curred An operation HOLD status step with transition check or without transition check which has been stopped will be restarted with the operation HOLD status in effect A coil output HOLD step cannot be restarted after being stopped as it becomes deactivated at that time b Execution of PLS and P instructions after a block STOP has been canceled varies according to the ON HOLD or OFF all OFF status of the SM325 special relay ON operation output HOLD at block STOP OFF all OFF ON Not executed SM325 l OFF Executed again c If the block restart instruction RSTART BLm is executed while the block is stopped the block STOP RESTART bit switches OFF Operation Error e Error No 4621 occurs when the specified block does not exist Program Examples 1 Block 1 is stopped when X1 switches ON and is restarted when X2 switches ON xi Related Instructions a SFC information register e Block STOP RESTART bit See Section 4 5 3 4 47 4 SFC PROGRAM CONFIGURATION MELSEC QnA 4 4 8 Step START amp
32. is executed from its initial step e A specified block is forcibly ended Block STOP instruction PAUSE BLm e A specified block is temporarily stopped BLm Sn Sn Di e The temporary stop status at a specified Block restart nstruction RSTART block is canceled with operation resuming from the STOP step e A specified block is forcibly started activated independently and is executed from a specified step ET Step control instruction RS T T BLm Sn SCHG e The instruction execution step is deactivated and a specified step is activated e A specified transition condition at a specified D 22 SET SET BLm TRn block is forcibly satisfied RST TRn gd RST D Pn e A specified step at a specified block is forcibly deactivated Transition control instruction e The forced transition at a specified transition condition in a specified block is canceled BLmYTRA Block switching BRSET e Blocks subject to the 1 SFC contro instruction instruction are designated e When the instruction execution condition is ON the subroutine call is executed in a constant manner When switched OFF the subroutine call occurs only once at that time Subroutine call instruction XCALL APP 8 Program operation venu status check instruction Block START L With END check da T a Block START without END check Block END Block STOP Block res
33. is used to request a START at a step which is already active the request is ignored and processing continues as is 5 SFC PROGRAM PROCESSING SEQUENCE 5 SFC PROGRAM PROCESSING SEQUENCE The processing sequence for SFC programs is shown below initial program execution Resumptive start What is the SFC program START mode Initial START Auto START OFF What is the block 0 START condition Auto START ON Has block START request occurred Execution from initial step of block designated by START request Execution from initial step of bloc x o Has SM321 switched OFF SFC program execution END mr System starts automatically at CPU power ON or at STOP A RUN switching in order to switch SM321 ON If SM321 is switched OFF before SFC program scanning begins the SFC pro gram will not be executed until SM321 is switched ON An SFC program initia START or re sumptive start setting is designated at the SFC parameter setting When a resumptive start setting is designated the system switches SM322 ON If SM322 is switched OFF before SFC program scanning begins the initial START setting will be designated A block 0 auto START ON or auto START OFF setting is designated in the SFC parameter settings If auto START ON is designated block 0 is executed from its initial step If auto START OFF is designated operation begins from the
34. meet MELSEC QnA b if the BRSET instruction is executed at an SFC program block switching will be effective only for the step currently being exe cuted Even If the step in question is the same step the BRSET instruc tion must be executed at each block where the Sn and TRn instruc tions are used Moreover within a single step block switching will be effective from the point where the BRSET instruction is executed to that step s processing END point When processing is repeated at the next scan following the proc essing END for that step the block in question will be designated as the current block until the point when the BRSET instruction is executed again Repeated Sequence program Sequence program SFC program END O B END Block n Block n 1 END Execution program c o E 9 EI E a Sn TRn destination block Operation Error Program Examples executed executed Instruction executed Instruction executed Instruction Block specifi Block specified Block specified Block specified by instruction by instruction Current block by instruction Current block iy instruction 1 scan a The block No designated by the m at BLm Sn or BLm TRn will be ef fective regardless of the execution status ON OFF of the BRSET in struction When multiple steps are active at parallel branch etc only the step where the instruction was executed will be effective To designate
35. n 2 1 Up to 32 steps can be available for selection in the selection transition format Max of 32 steps 2 When two or more selection step transition conditions are satisfied simultaneously the left most condition will take precedence Example y transition conditions and d are satis A S fied simultaneously Transition Transition Transition Transition the step n 2 opera condition b condition c condition d condition er tion output will be exe pep cuted n 4 4 SFC PROGRAM CONFIGURATION sg aS MELSEC QnA 3 The following method of coupling can be omitted when the selection transition format is used Transition Transition condition br Step n 4 Step n4 5 Transition condition d condition er When transition condition b is sa tisfied at the step n operation out put processing will proceed in order through steps n1 n2 and n 3 When transition condi tion d is satisfied processing will jump to step n For details on jump transitions see Section 4 3 4 4 SFC PROGRAM CONFIGURATION ee MELGEC GnA 4 Selection transition operation flowchart Operation status Initial step operation output executed Transition ransitian condition tied condition h a eatis YES el Initial step operation output deactivated Transition i condition i Step 1 operation output executed Transition condition b
36. processing returns to the beginning of the block in question e Coil output A coil output OFF or HOLD status will be established depending on the output mode setting see Section 4 7 3 at the time of the block STOP designated in the SFC operation mode However an ON status will be maintained for coil outputs which were switched ON by the SET instruction 1 When the transition condition immediately prior to a given step is satisfied or if the step has been reactivated by a JUMP instruction the step transition will occur again when the transition condition is satisfied 2 Double STARTs do not apply to reactivated steps 4 SFC PROGRAM CONFIGURATION Ce Gig TP 4 2 6 Operation HOLD step with transition check An operation HOLD step with transition check is a step where operation output ladder processing continues even after a transition to the next step with the next step being reactivated when the transition condition is again satisfied 1 During normal SFC program operation the coil ON status switched ON by OUT instruction when transition condition is satisfied is automatically switched OFF before proceeding to the next step By designating an operation output step as an operation HOLD step with transition check that step will remain active even after a transition to the next step occurs processing of its operation output ladder will continue and a transition condition check will be executed If the trans
37. restarted by the methods shown below Biock BekNe O Restart Method eeler Seen KEN ane D e Processing automatically returns to the initial step and at the SFC parameter setting operation is repeated stream ane START or block 0 START condition is stream ane START or as auto START OFF at the SFC parameter setting At block 0 e A restart is executed when any of the following occurs 1 When another START request is received from another block block START step is activated 2 When the block START instruction SFC contro instruction is executed 3 When the block information register s block START END bit is forced ON At all other blocks other than block O z 4 SFC PROGRAM CONFIGURATION ur E E Ee RE T 43 Transition Condition AE A transition condition is the condition which must be satisfied in order for processing to proceed to the next step 4 3 1 Serial transition Serial transition is the transition format in which processing proceeds to the step immediately below the current step when the transition condition is satisfied e Step n operation output A e When transition condition b becomes satisfied at step n operation output A execution operation output Transition condition bi E A will be deactivated and processing will proceed to step n4 1 operation output Ten Step n 1 operation output B S op i tep 1 A maximum o
38. status active inactive or to execute a forced START or END etc They can be used in SFC programs for easier SFC program control The various SFC control instructions and their functions are shown in the table below LD AND OR S s Sn 1 eChecks a specified step in a LDI ANI ORI Am p SC status check ANI OR specified block to determine if the LD AND OR pi msn step is active or inactive LDI ANI ORI LD AND OR TR Checks a specified step in a LOI ANI ORI specified block to determine if the transition condition by transition K AND OR BLa TRa control instruction for that step Forced transition check instruction LDI ANI ORI was Satisfied forcibly or not Block operation status check LD AND OR Bim e Checks a specified block to instruction LDI ANI ORI determine if it is active or inactive MOV P K4Sn D W MOV P BLm K4Sn D Active steps in a specified block DMOV P K8Sn D areread to a specified device as Active steps batch readout instruction DMOV P BLmWB8Sn D bit information BMOV P K4Sn D Kn 1 BMOV P BLm K4Sn D Kn eA specified block is forcibly started Block START instruction SET BLm activated independently and is executed from its initial step e eA specified block is forcibly ended Block END instruction RST BLm deactivated e eA specified block is temporarily Block STOP instruction PAUSE BLm stopp
39. step is not required 4 SFC PROGRAM CONFIGURATION EP 6 Parallel transition operation flowchart Initial step Transition condition a Initia step operation output Transition condition Cer satisfied YES of Transition Transition Transition m SEN condition ve condition d condition zez Initial step operation output Waiting step Step 1 operation output i executed Transition condition f Transition condition Transition D satisfied condition g YES el Step 1 operation output deactivated Step 2 operation output executed Transition condition rer satisfied YES YES vi YES vi Step 2 operation output Step 3 operation output Step 4 operation output deactivated deactivated deactivated Waiting step executed Step 3 operation output executed Step 4 operation output odd Transition condition er satisfied Transition condition d satisfied Parallel processing Waiting step executed Waiting step executed TT All waiting steps executed YES Transition condition f satisfied YES Step 5 operation output executed i Transition condition g satisfied YES DI Step 5 operation output END step executed deactivated operation completed 1 For steps with attribute designations processing occurs in accordance with the attributes 4 SFC PROGRAM CONFIGURATION 4 3 4 Jump transition
40. step s operation output after the transition condition is satisfied It will also remain ON following the execution of multiple steps even if the transition condition is unsatisfied In these cases the transition bit will switch OFF when block execution occurs at the next scan Example Step transition bit M1 ege B aga z Ses 2 KEE a Other program executed Transition condition 1 satisfied Transition condition 2 unsatisfied 4 SFC PROGRAM CONFIGURATION anm TD smemmms We Sie SoA 4 Atactive parallel branch steps the transition bit will switch ON when any of the transition conditions are satisfied a N c bh a a E e ETIN FLEE e a 35327 n n S o o o e 2 Ka ae Ka Ki 2 E E 8 2 E 2 8 E 9 8 Other program executed b 2 s g gt 5 D 8 e 2 we c g 4 SFC PROGRAM CONFIGURATION 4 5 3 Block STOP RESTART bit The block STOP RESTART bit is used to temporarily stop processing of a given block due to a machine malfunction etc 1 When the designated block STOP RESTART bit is switched ON by the sequence program or peripheral device processing will be stopped at the current step of the block in question If a START status is in effect at another block the STOP will still occur but the START destination block will remain active and processing will continue To stop the START destination
41. the first time processing occurs at the specified block and a STOP will occur e After the STOP request the coil output will be switched OFF when the transition condition is satisfied and a STOP will occur e if multiple steps are active the STOP will occur at each of the steps in sequence as their transition conditions are satisfied OFF or no setting immediate stop e After the STOP request the coil output will be switched OFF the first time processing occurs at the specified block and a STOP will occur OFF or no setting immediate stop e After the STOP request a coll output HOLD status will be established the first time processing occurs at the specified block and a STOP will occur e After the STOP request the coil output HOLD status will be established when the transition condition is satisfied and a STOP will occur e After the STOP request a coil output HOLD status will be established the first time processing occurs at the specified block and a STOP will occur ON post transition STOP e if multiple steps are active the STOP will occur at each of the steps in sequence as their transition conditions are satisfied 4 SFC PROGRAM CONFIGURATION 1 The coil HOLD step becomes inactive the first time processing occurs at the block in question following the STOP request 2 During SFC program execution the M325 special relay is switched OFF when the coil output
42. the timer will be reset 2 There are a total of 10 watchdog timers in the SFC program The special relay and special register allocations for each watchdog timer are shown below Timer 1 Timer 2 city 3 Timer 4 Timer 5 Timer 6 Timer Timer 8 Timer Timer 10 EE rely register 3 The setting method at special registers SD90 SD99 is shown below EES b8b7 GER geess Setting 1 to 255 setting value x 1 sec Annunciator F ON when time over status occurs device No setting 0 to 255 4 The method for using a watchdog timer is shown below Time setting 10 x 1 sec 10 secs LMOVP HO10Aj S090 Annunciator F No F1 Step where time j monitoring occurs Soc Transition HO10A dition a condition a 10 sec F1 annunciator a As shown above the special relay switches ON at the operation output of the monitored step and the time count begins 4 SFC PROGRAM CONFIGURATION 5 6 b If transition condition a at the step in question is not satisfied within the designated time 10 secs after SM90 switches ON the F1 annunciator will switch ON However SFC program operation will continue c If transition condition a is satisfied within the designated time SM90 will switch OFF the time count will stop and the timer will be reset Even if the annunciator FO to F255 switches ON the annunciator s ON detection count and the annunciator numb
43. trace execution rate e tee progress and OFF when tracing is status completed or stopped _ change f S ae e Switches ON when a trigger condition is System Post trigger step trace ON Tiger bd en satisfied at any of the blocks where the status lt ngg step trace function is being executed change OFF Block with porcos eSwitches ON when trigger conditions System Post trigger step trace are satisfied at all blocks where the status SNC ees ali step trace function is being executed change Geen e Switches ON when step tracing is System OFF Tracy ris completed at all the specified blocks ON Trace and switches OFF when step tracing Get begins Step trace END ttag APP 3 APPENDICES The No of the diagnosis error is stored as 4 digit binary data e E t5 Diagnosis error No o caa for errors originating at an SFC program e When more than one error has occurred the error with the highest display priority is stored The clock data when an SDO update occurs is stored b15 b8 b7 bo Time of diagnosis Time of diagnosis SD1 Year 00 to 99 Month 1 to 12 error occurrence error occurrence SD2 Day 1 to 31 Hour 0 to 23 Each item is stored as BCD 2 digit data SD3 Minute 0 to 59 Second 0 to 59 e Code which identifies an error as information or individual information is stored BIN 8 bits BIN 8 bits DEM Common information codes
44. transition condition check occurs when the next step becomes active no step transition will occur when the transition conditions for the step in question are again satisfied The difference between an operation HOLD step without transition check and a coil HOLD step is that processing continues even after the step transition with the former and does not with the latter No subsequent H transition We err eer L 1 H i Step activated by previous transition condition being satisfied An operation HOLD step without transition check becomes inactive when any of the following occur e When the END step of the block in question is executed e When an SFC control instruction RST BLm designates a forced END at the block in question e When an SFC control instruction RST BLm Sn RSTSn designates a reset at the block in question e When a reset occurs at the device designated as the SFC informa tion register s block START END device e When a reset step for resetting the step in question becomes active e When the SFC START STOP command SM321 is switched OFF 4 9 4 SFC PROGRAM CONFIGURATION i MELSEC QnA 4 Block STOP processing If a block STOP request is designated by the SFC information register s STOP RESTART bit or by an SFC block STOP instruction processing will occur as follows e STOP status timing A STOP status is established after the block STOP request output occurs and
45. 3 SPECIFICATIONS e Number of active steps Total number of active steps in all blocks e Number of active step transition conditions n EE Total number of transition conditions for all active steps in all blocks e Number of steps where transition conditions are satisfied TEE Number of steps in all blocks where the transition conditions have been satisfied resulting in an operation output OFF 2 CPU models and corresponding system processing times SSES NC RNC N77 Leen Le Te Without a HOLD d step designation 7 8 pS 15 6 pS 20 8 pS With a HOLD step 4 At initial START 14 3 pS 28 5 pS 38 0 pS At resumptive START 97 5 pS 195 0 uS 260 0 pS HOLD steps include both coil HOLD steps and operation HOLD steps with or without transition checks Processing of steps where transition conditions are satisfied SFC END processing Example of SFC system processing time calculation Using the Q4ACPU as an example the processing time for the SFC system is calculated as shown below given the following conditions e Designated at initial START es Number of active blocks 30 active blocks at SFC program e Number of inactive blocks 70 inactive blocks at SFC program e Number of nonexistent blocks 50 number of blocks between 0 and the max created block No which have no SFC program e Number of active steps 60 active steps within active blocks e Active step transition cond
46. 3210N SM3210N SM3210N Initial step Initia step Step 1 operation operation operation Output output output executed executed executed SFC program Block 0 Transition condition Transition condition Transition condition unsatisfied unsatisfied unsatisfied e The status of the transition condition for a transition to the next step is checked at the completion of each step s operation output Condition unsatisfied The same step s operation output is exe cuted again at the next scan Condition satisfied All outputs of the executed step are switched OFF by that step s OUT instruc tion and the next step s operation output is executed at the next scan e When atransition condition is satisfied and SFC program processing proceeds to the next step the operation output of the previous step is deactivated The CPU only processes the operation output of the step which is currently active and the transition condition program for a transi tion to the next step e If a step attribute designates a step as a HOLD step that step will not be deactivated and processing will continue in accordance with the attribute e f the continuous transition bit at a give block is set to ON processing will proceed to the next step when the transition condition is satisfied without ending the SFC program at the end of each step s operation output CPU RUN END processing END processing SM3210N SM3210N Initial step ope
47. 34 s33 832 Related Instructions a SFC control instructions e Block switching instruction BRSET See Section 4 4 11 e Step operation status check instruction Sn See Section 4 4 1 e Active step batch readout instruction MOD DMOV See Section 4 4 4 4 SFC PROGRAM CONFIGURATION MELSEC QnA 4 4 6 Block START amp END instructions SET RST Programo Using instructione Using Programo Using instructione Data T SFC Program Ke Transition Condition e Transition Condition Device At expansion SFC and other columns m represents the block No and n represents the step transition condition No m is the block No I4 I Function 1 a A specified block is independently activated forcibly and is exe cuted from its initial step If multiple initial steps exist all the ini tial steps will become active If the SFC information register block START END bit setting has been designated the bit device in question will be switched ON Expansion SC BLmiSn Bum TRA b If the specified block is already active when this instruction is exe cuted the instruction will be ignored equivalent to the NOP in struction and processing will continue e a If the SFC information register block START END bit setting has been designated the bit device in question will be switched ON b If the specified block is inactive when this instruct
48. 5 HOLD step when step 10 is activated 4 SFC PROGRAM CONFIGURATION MELSEC GnA 4 4 9 Forced transition EXECUTE amp CANCEL instructions SET RST Programa Using meutone Using instructione meer Site Data T SFC Program odul cats Condition A Traneition Condition Device At expansion SFC and other columns m represents the block No and n represents the step transition condition No NUES z m is the block No H SET D BLm TAn RST D BLm TAn Function 1 a A specified transition condition in a specified block is forcibly satis fied and an unconditional transition is executed at the step which precedes the condition User designated Continuous transition preventer transition condition SM324 mi Ladder resulting from execution of SET instruction Mew ewe eee ee ee ee ee b After execution of the instruction the forced transition status re mains effective until a reset instruction is executed 2 a Cancels the forced transition setting designated by SET instruc tion at a transition condition and restores the transition condition ladder created by the user Operation Error e Error No 4631 occurs when the specified transition condition does not exist 4 SFC PROGRAM CONFIGURATION Ut Sat v nr mE x DE Net H uns i 3 Program Examples 1 When X1 switches ON tie following program executes a forced transi tion at trans
49. Block STOP timing amp coil output status when STOP occurs The STOP timing in response to a block STOP request and the coil output status during the STOP are as shown below Status of Operation Description Output Mode Output Setting Mode s Deiere at Parameter Special Active Step Other Block STOP Relay Mode Bit than HOLD Step Active HOLD Step SM325 OFF or no setting immediate stop e After the STOP request the coil output will be switched OFF the first time processing occurs at the specified block and a STOP will occur Coil output OFF coil output HOLD e After the STOP request the coil output will be switched OFF when the transition condition is satisfied and a STOP will occur OFF coi output OFF e After the STOP request the coil output will be Switched OFF the first time processing occurs at the specified block and a STOP will occur ON post transition STOP elf multiple steps are active the STOP will occur at each of the steps in sequence as their transition conditions are satisfied 6 6 6 SFC PROGRAM EXECUTION wp Uu deer phe o Status of Output Mode Output Setting Mode s at Parameter Special Block STOP Relay Status of Block STOP Mode Bit Active Step Other than HOLD Step Active HOLD Step OFF or no setting immediate stop e After
50. ITSUBISHI ELECTRIC CORPORATION HEAD OFFICE MITSUBISHI DENKI BLDG MARUNOUCHI TOKYO 100 TELEX 424532 CABLE MELCO TOKYO NAGOYA WORKS 1 14 YADA MINAMI 5 HIGASHI KU NAGOYA JAPAN PF i E When exported from Japan this manual does not require application to the Ministry of Intemational Trade and Industry for service transaction permission Specifications subject to change without notice Printed in Japan on recycled paper
51. PROGRAM CONFIGURATION e Wo e are 3 Pr cautions when tranghlor destination ts a parallel branch o mien a STOP setting is designated T eh Anerrorils activated if even 1 of the parallel branch s transition destination steps is active and CPU operation is stopped e When a WAIT setting is designated A WAIT status is established until all the parallel branch s transition destination steps become inactive The transition is then be executed and all the parallel branch s first steps become active When the WAIT status is established the previous step is deactivated d Transition condition satisfied All active e When a TRANSFER setting is designated The transition is executed if even 1 of the parallel branch s transition destination steps is active and the previous step is deactivated Transition destination steps which are inactive are not activated at this time If all the transition destination steps are Inactive transition processing occurs in the normal manner with all the destination steps being activated SUE so rcs ft b ATA A BEOS cui 4 SFC PROGRAM CONFIGURATION i MELSEC QRA e The operation mode at transition to active step double step START setting applies at transitions caused by satisfied transition conditions and at forced transitions caused by the SFC control transition con trol instruction SET TRn If the SFC control step control instruction SET Sn
52. Periodic execution block setting 0 ccc cece ee eens 4 74 4 7 5 Operation mode at double block START 4 75 4 7 6 Operation mode at transition to active step double step START 4 76 SFC PROGRAM PROCESSING SEQUENCE cecec cece ee cen eee 5 1 5 14 5 1 Overall Program Processing eee Vu eps dci o ee ee C a eee ee 5 2 5 1 1 Program processing sequence 6 cece e 5 2 5 1 2 Execution type designation by instructions eese 5 4 5 1 3 SFC program for program execution management 000 5 6 5 2 SFC Program Processing Sequence ccc cect eee 5 8 5 2 1 SFC program execution Cycle 5 8 5 2 2 Block execution sequence 0 cece eee teen ee nee 5 9 5 2 3 Step execution sequence ee eee eee e eee 5 10 5 2 4 Continuous transition ON OFF operation 0 0 0 0 cece eee eee 5 12 SFC PROGRAM EXECUTION ccc cece cece cece n enhn nn 6 1 6 12 61 SFC Program START and END 6 1 6 1 1 SFC program resumptive START procedure 0 ccc ec eee ee 6 2 62 Block START and END 3 cise a ee e dete Rh ER REPRE E 6 4 6 2 1 Block START methods 0 ccc ccc eh 6 4 6 2 2 Block END methods e See Kee dree gh X 3 RARIOR ACE C DECR aba dae 6 5 6 3 Block Temporary Stop amp Restart Methods 0 cece centre cece eee 6 6 6 3 1 Block STOP methods corro eO them el cays A E 6 6 6 3 2 Restarting a stopped back 6 8 6 4 Step START Activate and END Deactivate Methods 0 0 c ee eee 6 9
53. Programo Wing noructione Using instructions Data SFC Program HIE Type Block Transition Condition Se Transition Condition d At expansion SFC and other columns m represents the block No and n represents the step transition condition No Ee FEE m m is the block No lk ee grey PE Function 1 A check occurs to determine if the specified block is active 2 If the block in question is active the N O contact instruction switches the contact ON and the N C contact instruction switches the contact OFF 3 If the block in question does not exist in the SFC program it will re main OFF Program Example 1 The following program switches Y20 ON when block 3 is checked and found to be active oiii Related Instructions a SFC control instructions e Block START instruction SET BLm and block END instruction RST BLm See Section 4 4 6 b SFC diagram symbols e Block START step Ein Bin See Sections 4 2 8 and 4 2 9 C SFC information register e Block START END bit See Section 4 5 4 SFC PROGRAM CONFIGURATION MELSEC QnA 4 4 4 Active step batch readout instructions MOV DMOV Programe gangen Using Instructions meer Site Data Ge Program Condition Transition Condition CS RAD E be Cl Sn only At expansion SFC and other columns m represents the block No and nr represents the step transition condition No
54. SAP IlI AND MELSAP3 COMPARISON Compared to MELSAP I the improved MELSAP3 has additional functions which facilitate the use of SFC programs MELSAP I afd MELSAP3 are compared below MELSAP3 improvements and added functions a SFC program control by instructions Using SFC control instructions at a sequence program the SFC program status can be checked and blocks steps can be forcibly started and ended Expression of SFC program as a sequence program ladder list is possible SFC programs can be expressed as ladders or lists and step and transition condition programs timer T and counter C setting values etc can be revised at the Q6PU b c Additional step attributes MELSAP3 offers many more step attributes such as the operation HOLD step reset step block START step without END wait etc Moreover machine control by SFC program has been made eas ier by improvements such as the step follow up function activates multiple steps in a series within a single block and a contro func tion which allows transitions at block START requests without waiting for a block END status at the START destination block asynchronous control of the START source and destination blocks d Expanded memory capacity In addition to an increased number of steps and branches per block the capacity of step and transition condition programs has been increased to 4k sequence steps in order to make program ming easi
55. TART OFF inactive until a START A aquest occurs by one of the methods described in Section 6 2 1 Block 0 Blocks other than block O blocks 1 to 319 6 SFC PROGRAM EXECUTION 6 3 Btock Temporary Stop amp Restart Methods 6 3 1 Block STOP methods The temporary block STOP methods which can be used during SFC program execution are described below 1 Block STOP methods The methods for temporarily stopping a block during SFC program operation are shown below STOP Method Operation Description Remarks e Using an SFC control instruction a specified block is temporarily stopped from an SFC program step operation output or from another sequence program e Convenient for temporarily stopping operation at error detection etc in order to correct the error by manual operation Block STOP by SFC control instruction Condition The manual operation control programcan be placed atanother block which is forcibtyforcibly startedwhen the block STOP occurs m is the block No A specified block is temporarily stopped by e Convenient for confirming operation by step Block STOP by SFC forcing the block START END bit ON from control at debugging and test operations information register a program or a peripheral device because block processing can be stopped The block START END bit is designated at from a peripheral device without requiring a each block as an SFC information register program 2
56. TRnje m is the block No n is the transition condition No BLm TAn BLm TAn Bum TR fp C 5 4 BLm TRn 1 IM wm sm ELEME CC 2 4 BLm TRn BLmTRn Btm TAn BLMTAn BLm TRA Function 1 A check occurs to determine if a forced transition is designated for a specified transition condition in a specified block 2 Ifa forced transition is designated at the transition condition in question the N O contact instruction switches the contact ON and the N C contact instruction switches the contact OFF 3 To designate a step in the current block use TRn To designate a step in another block or to execute an instruction by the sequence program use BLm TRn 4 If the transition condition in question does not exist in the SFC program it will remain OFF 4 SFC PROGRAM CONFIGURATION MELSEC QnA 1 The following program switches Y20 ON when a forced transition is designated for transition condition 5 at block 3 Program Examples Designating a transition condition No within the current block TRS Designating a transition condition No in another block BL3 TRS H Related Instructions a SFC control instructions e Transition control instructions SET TRn SET BLm TRn RST TRn RST BLm TRn See Section 4 4 9 e Block switching instruction BRSET See Section 4 4 11 4 SFC PROGRAM CONFIGURATION 4 4 3 Block operation status check instruction BLm Usebie i
57. UP La BET Ys Transition M condition 3 Unclamp operation workpiece unloading operation unt Step 3 acces M 1 LC DST 24 X6 Unclamp confirmation Conveyor START v20 mat es m X7 Workpiece unloaded confirmation Transition ETT H condition 4 Process END END step Machining completed 1 GENERAL DESCRIPTION deas ee The SFC program performs a sequence of operations beginning from the initial step proceeding to each subsequent step as the transition condi tions are satisfied and ending at the END step 1 When the SFC program is started the initial step is executed first 2 Execution of the initial step continues until transition condition 1 is satisfied When this transition condition is satisfied execution of the initial step is stopped and processing proceeds to the step which follows the initial step Processing of the SFC program continues from step to step in this manner until the END step has been executed 1 GENERAL DESCRIPTION EE MELSEC QnA 12 SFC MELSAP3 Features 1 Easy to design and maintain systems Because control of the overall system and each station as well as the machines themselves corresponds on a one to one basis with the blocks and steps of the SFC program systems can be designed and maintained even by those with relatively little sequence program expe rience Moreover programs designed by other programmers using this format are much easie
58. activates step 5 and l activates step 6 4 SFC PROGRAM CONFIGURATION eu quU NT ee PS I E p 4 4 11 Block switching instruction BRSET Wege rengen instructione mem sie Site BEEN NN gti e SAG Program sais Baton Transition Condition um v 2M a At expansion SFC and other columns m represents the block No and n represents the step transition condition No I asser Function 1 Designates the destination block number for an SFC control instruction which specifies only a step Sm or transition condition TRm 2 Although BLm Sn or BLm TRn may be used as the instruction device when designating the destination block number only a constant K H may be designated at the m of BLm thereby fixing the designation destination When block switching is executed by this BRSET instruction a word device can be used for indirect designation index qualification etc 3 The effective operation range when block switching occurs by BRSET instruction varies according to the program being run at the time as shown below a If the BRSET instruction is executed at a sequence program block switching will be effective from the point where the instruction is executed to the END step At the next scan the block in question will be designated as block 0 default value until the point when the BRSET instruction is exe cuted again 4 SFC PROGRAM CONFIGURATION
59. al specifications will cause electric shock fire malfunction or damage to deterioration of the product Make sure that the module fixing projection on the base of the module is properly engaged in the module fixing hole in the base unit before mounting the module Failure to mount the module properly will result in malfunction or failure or in the module falling Extension cables should be securely connected to base unit and module connectors Check for loose connection after installation A poor connection could result in contact problems and erroneous inputs outputs Plug the memory cassette firmly into the memory cassette mounting connector Check for loose connection after installation A poor connection could result in erroneous operation Plug the memory firmly into the memory socket Check for loose connection after installation A poor connection could result in erroneous operation Cautions on Wiring e Switch off the external power supply before staring installation and wiring work Failure to do so could result in electrical shocks and equipment damage After installation and wiring is completed be sure to attach the terminal cover before switching the power ON and starting operation Failure to do so could result in electrical shocks Be sure to ground the FG and LG terminals carrying out at least class 3 grounding work with a ground exclusive to the PC Otherwise there will be a danger of electric shock an
60. all instruction Time check instruction TIMCHK S1 S2 D 1 The block designated by the block switching instruction BRSET becomes subject to the instruction The default setting is block O or all blocks see Section 4 4 11 2 Use is permitted only at steps with SFC programs An error will occur if used at steps with other sequence programs 4 SFC PROGRAM CONFIGURATION EE num g S d Beginning from Section 4 4 1 of this manual the following t table i isused in the explanations of us various instructions The tape contents a are explained below i T nm d MELSECNET Zu Ao Direct Na SFC Program Data Type eg Block Sep op ain H F JBIN32 HERIDA I Destination Source e Instruction code Ss dE Instruction code Destination Se Data destination following the operation Source Pitas ot eere Where data is stored prior to the operation 2 Usable devices are indicated at this area e Devices indicated by a circle mark O can be used with the instruc tion in question The device application classifications are shown below 4 SFC PROGRAM CONFIGURATION Internal System User Gi 4 5 MELSEC QnA NET 10 Direct Special JONG Function KSE sOw uDe Decimal hexadecimal sO sw real number DX constant character string constant e When a device name is indicated in the
61. ansition enabled Continuous transition disabled After transition Before transition Coil output OFF Coil output ON e Switches ON when the SFC program status Is normal with the parameter program settings designated eSwitches ON automatically when an SFC program is present elf switched OFF by another program file prior to SFC program execution the SFC program will not be executed e SFC program START STOP control is possible by ON OFF switching at the e The default value is the value designated at the parameter s SFC program START mode When OFF All execution statuses are cleared when the SFC program is stopped and a START occurs from the initial step of block 0 When ON A START occurs from the block and step which were being executed when the SFC program was stopped An ON settingis only valid when the parameter s SFC program START mode is set to resumptive START e When the transition conditions of contiguous steps are all satisfied this setting determines whether all those steps will be executed in a single scan When ON Continuous execution continuous transition enabled When OFF Steps are executed in a 1 step per scan format continuous transition disabled When the SFC information register s continuous transition bit setting is designated at each block those settings will take precedence e f the continuous transition status is set to ON this flag is ON
62. bes how to use the QnACPU most effectively Q2A S1 03A Q4ACPU User s Manual Describes the performance functions and handling of the Q2ACPU S1 Q3ACPU and Q4ACPU and the specifications and handling of memory cards and base units Purchased separately 18 66606 1B 66608 QnACPU Programming Manual Common Instructions Describes how to use sequence instructions basic instructions and application instruc tions Purchased separately 1B 66615 18 66625 QnACPU Programming Manual Special Function Describes the dedicated instructions for special function modules available when using the Q2ACPU S 1 Q3ACPU and Q4ACPU Purchased separately QnACPU Programming Manual AD57 Instructions Describes the dedicated instructions for controlling an AD57 S1 type CRT controller module available when using the Q2ACPU S1 Q3ACPU or Q4ACPU Purchased separately QnACPU Programming Manual PID Control Instructions Describes the dedicated instructions for PID control available when using the Q2ACPU S1 QSACPU or Q4ACPU Purchased separately MELSECNET 10 Network System for QnA Reference Manual Describes the general concept specifications and part names and settings for MEL SECNET 10 Purchased separately Type SWOIVD GPPQ GPP Function Operating Manual OFFLINE Describes the how to create programs and print out data when using SWOIVD GPPQ and th
63. ce T C F cannot be used At expansion SFC and other columns m represents the block No and ni represents the step transition condition No MELSECNET I xcx e eG Function 1 When the condition is satisfied the subroutine call designated at P is switched ON CALL The subroutine call is switched OFF FCALL when the condition switches from ON to OFF Xo H CALL P1 xio wel 0 9 a While is XO is ON the P1 subroutine is executed at every scan each time the step in question is executed b When X0 switches from ON to OFF the P1 subroutine is switched OFF once only 2 Because pointers cannot be used in SFC programs a common pointer must be called when the XCALL instruction is executed in these programs 3 Normal processing will be impossible if the subroutine program s argument type is different from the XCALL instruction s argument type 4 A maximum of 16 XCALL nestings including those for other CALLs are possible 4 SFC PROGRAM CONFIGURATION For details regarding the common pointer and the subroutine program s argument refar to the QnACPU Programming Manual Common Instructions Operation Error e ErrorNo 4210 occurs if the program for the speci fied pointer does not exist e Error No 4214 occurs tf an END FEND GOEND or STOP instruction is executed prior to the RET instruction e Error No 4212 occ
64. ce ends when the END step is reached a b c When the SFC program is started the initial step is executed first During initial step processing the next transition condition transi tion condition 1 in the above illustration is checked to determine whether or not it is satisfied Initial step processing continues until transition condition 1 is satisfied When transition condition 1 is satisfied initial step processing stops and processing of the next step step 1 in the above illustration begins During step 1 processing the next transition condition transition condition 2 in the above illustration is checked to determine whether or not it is satisfied When transition condition 2 is satisfied step 1 processing stops and processing of the next step step 2 in the above illustration begins Processing of the SFC program continues in this manner executing the steps in order until the END step is reached 4 SFC PROGRAM CONFIGURATION 41 List of SFC Diagram Symbols Initial step Dummy initial step Coil HOLD initial step When step Operation HOLD step without No is 0 transition check initial step Operation HOLD step with transition check initial step Reset initial step Initial step Dummy initial step Coil HOLD initia step When initial tep No is Operation HOLD step without s ae transition check initial step other than 9 Operation HOLD step
65. ch occurs when a START request is made for a block which is already active Operation mode at double block START can be designated for the PAUSE setting a block range SFC program Pause Wait Transfer Designates the operation which occurs when a transition follow up is executed to a step which is already active or when an attive step is started Operation mode at transition to active step dou ble step START astep range can be designated for the PAUSE or Wait setting 4 SFC PROGRAM CONFIGURATION S 4 7 4 SFC program START mode The SFC program START mode setting determines whether an SFC program START SM321 OFF ON is executed by an initial START or by a resumptive START from the preceding execution status 1 Settings and corresponding operations The SFC program START format can be designated as an initial START or a resumptive START As shown below the operation which occurs depends on the parameter and special relay SM322 setting combination Initial START initial START default ON OFF When auto START ON is designated for block 0 Block 0 is executed from its initial step Wh n auto START OFF is designated for block 0 The block started by the SFC control block START instruction is Resumptive START executed from its initial step Resumptive START A resumptive START is executed from the previous active status
66. cial Relays ON OFF Control e Switches ON when a diagnosis result error occurs OFF normal no error Also switches ON at an external oe ON abnormal error diagnosis error occurrence e Remains ON even when normal status is restored Diagnosis error Step transition watchdog timer START corresponds to SD90 Step transition watchdog timer START corresponds to SD91 Step transition watchdog timer START corresponds to SD92 Step transition watchdog timer START corresponds to SD93 Step transition watchdog timer OFF Watchdog timer Switched ON to begin the step transition START corresponds reset watchdog timer count to SD94 ON Watchdog timer Watchdog timer is reset when switched Step transition START OFF watchdog timer START corresponds to SD95 Step transition watchdog timer START corresponds to SD96 Step transition watchdog timer START corresponds to SD97 Step transition watchdog timer START corresponds to SD98 Step transition watchdog timer START corresponds to SD99 APP 1 APPENDICES SFC program presence absence SFC program START STOP SFC program START status All blocks continuous transition status Continuous transition disable flag Operation output at block STOP OFF SFC program absent SFC peogram present SFC program STOP SFC program START Initial START Resumptive START Continuous tr
67. ck START step Block 0 Block 5 0 T an O Block Es block active bit MO 0 E o 1 m ig ege 0 2 1 1 OFF A 2 2e LL 2 2 T 2 If the block in question is inactive and is forced ON by the block START END bit from a peripheral device test function that block can be started independently Moreover processing of that block can be forcibly ended by executing a forced OFF 3 When a forced OFF is executed by the block START END bit and the block in question becomes inactive processing will occur as follows e Execution of the block in question will stop together with all outputs from the step which was being executed Devices switched ON by the SET instruction will not switch OFF e f a START status exists at another block the STOP will still occur but the START destination block will remain active and processing will continue To clear the START destination block at the same time the START destination s block START END bit must also be switched OFF 4 Ablock which has been forcibly deactivated is restarted as shown below Relevant Block Restart Status When the START condition for block 0 is designated as auto Operation is restarted from the A initial step following END step START ON at the SFC processing parameter setting When the START condition for e block 0 is designated as auto The block is deactivated after e END step processing and ee a SFC processing is restarted from
68. cution conditions for the counter at step n are already ON when transition condition m is satisfied the counter s count will increase by 1 when step n becomes active H X10 is already ON at step n Example while step n 1 is active the Step n 1 counter s CO count will increase Transition by 1 when the transition to step condition TNI Kio occurs after transition condi Stpm J eH tion m is satisfied If a transition to the next step occurs before the counter is reset the counter s present value and the contact ON status if ON will be maintained even atter step n becomes inactive In order to reset the counter at another step an RST instruction etc will be required When the counter CO is reset at Example GE K10 step n 1 or subsequent step step cl LH the present value will be cleared and the contact will be switched Transition OFF condition m 5 Step mai D t F i d o a wn 4 i o 2 When a PLS or P instruction is used at a step s operation output the instruction will be executed when the step s status changes from inactive to active even though the execution conditi n contact is always ON The ladder shown above is actu Example See ally executed as shown below Because the step conditions con Step nl Jr Hiris YO tactis ON when the step is active and OFF when the step is inac tive the PLS or P instruction will be ex
69. d malfunctions Carry out wiring to the PC correctly checking the rated voltage and terminal arrangement of the product Using a power supply that does not conform to the rated voltage or carrying out wiring incorrectly will cause fire or failure Outputs from multiple power supply modules should not be connected in parallel Failure to do so could cause the power supply module to overheat resulting in a fire or module failure Tighten the terminal screws to the stipulated torque Loose screws will cause short circuits fire or malfunctions Make sure that no foreign matter such as chips or wiring offcuts gets inside the module It will cause fire failure or malfunction Connectors for external connections should be crimped pressure welded or soldered in the correct manner using the correct tools For details regarding crimping and pressure welding tools refer to the input output module user s manual A poor connection could cause shorts fire and erroneous operation Cautions on Startup and Maintenance Do not touch terminals while the power is ON This will cause malfunctions Make sure that the battery is connected properly Do not attempt to charge or disassemble the battery do not heat the battery or place it in a flame and do not short or solder the battery Incorrect handling of the battery can cause battery heat generation and ruptures which could result in fire or injury Switch the power off before cl
70. e execution blocks and steps as well as the execution of opera tion output transition condition ladders can be monitored by a peripheral device with automatic scrolling function This monitor function enables even those with little knowledge of se quence programs to easily identify trouble spots 1 GENERAL DESCRIPTION DD OMNINO E 00 Convenient trace function Blocks can be feet ar aced enabling the user to check the operation timing of multiple blocks Moreover the trace results display screen can be switched to display the trace result details for each block Active step Nos are disp SE from smaliest No for each block Block No where trace occurred Active step No display Dn Program editing is possible using athe oe programming unit Operation output and transition conditions programs can easily be re vised using the Q6PU The SFC diagram can be shown using either a list or ladder format The Q6PU unit uses a list format Program for program creation modification A operatione a 2 SYSTEM CONFIGURATION 2 mm MELSEC GnA SYSTEM CONFIGURATION 1 2 3 Applicable CPU models MELSAP3 SFC program can be run by the following CPU models e Q2ACPU e Q2ACPU S1 e Q3ACPU e Q4ACPU Peripheral devices for the SFC program SFC program creation editing and monitoring operations are conducted at the following peripheral devices Pe
71. e offline functions of SWOIVD GPPQ such as file maintenance Supplied with the product Type SWOIVD GPPQ GPP Function Operating Manual ONLINE Describes the online functions of SWOIVD GPPOQ including the methods for monitoring and debugging Supplied with the product Type SWOIVD GPPQ GPP Function Operating Manual SFC Describes the system configuration performance specifications functions system startup procedure SFC program editing method monitoring method printout method and error messages for MELSAP 3 Supplied with the product 1 GENERAL DESCRIPTION MELSEC QnA 11 Description of SFC Program The SFC program splits a sequence of machine operations into individual steps with the detailed control which occurs at each step being repre sented by ladders Machine operation Operation output and transition condition diagram for each step lowchart SFCdiag b SFCdiagram Process START Workpiece es apice Conveyor START START switch 1 operation unit Initial step Luc bag Y20 gt Palet detection Transition x2 condition 7777 H ml Tran H Pailet confirmation clamp operation 1 operation unit Pallet clamp step 1 Y21 Clamp confir mation Transition condition 2 Drill rotation Y22 MO MO Drill DOWN tf SET Y23 Machine s Drilling operation 1 operation unit Step 2 were X4 Drill DOWN endpoint operation sequence 253 ne K20 TO To Dril
72. eaning or re tightening terminal screws Carrying out this work while the power is ON will cause failure or malfunction of the module In order to ensure safe operation read the manual carefully to acquaint yourself with procedures for program changes forced outputs RUN STOP and PAUSE operations etc while operation is in progress Incorrect operation could result in machine failure and injury Do not disassemble or modify any module This will cause failure malfunction injuries or fire Switch the power OFF before mounting or removing the module Mounting or removing it with the power ON can cause failure or malfunction of the module When replacing fuses be sure to use the prescribed fuse A fuse of the wrong capacity could cause a fire Cautions on Disposal Ah CAUTION e Dispose of this product as industrial waste REVISIONS The manual number is given on the bottom left of the back cover Manual Number GENERAL DESCRIPTION cece eee c ccc r etree scene ese nnne 1 1 1 11 Li Description of SFC Program kiosk eee eto e RE Pe RR IRE E er I Rh he 1 2 1 2 SFC MELSAPS Features oot olds diee Ox RE eels tH RE Peewee aoe 1 4 SYSTEM CONFIGURATION cc cece cere cece ee hh hh hn 2 1 2 1 SPECIFICATIONS e 6 555 boii nin RYE RR VAAA TATE RR E e ee Aa 3 1 3 10 3 1 Performance Specifications Related to SFC Programs 0 cece eee eee 3 1 G2 Device USE co Sou Vos Eee tale aA E ae Pu Rd iare ae EA
73. ecuted when the step becomes active even though the execution condition contact is al Step ni ways ON L Step conditions When active ON contact When inactive OFF Always ON rris soh Leading edge Iti and trailing edge Ht PLS instructions are executed in the same manner as the PLS ZP instructions described above 4 SFC PROGRAM CONFIGURATION DEE EEN LSE Q QnA 4 2 2 Initial step n The initial step represents the beginning of a block Up to 32 initial steps per block can be designated Initial step processing occurs in the same manner as other steps 1 When multiple initial steps are used the step statuses active inactive are determined by the block START request as shown below START Method eStart by block START E step B e When an initial step is At SFC Program START Start by block START designated by a step SET SM321 instruction SET BLm START instruction SET BLm Sn Block No S D block START Block 0 All steps active All steps active Only designated step is active 2 Processing of initial steps with attributes occurs in the same manner as for other steps e Refer to section 4 3 5 for details regarding transition processing when multiple initial steps are used 4 2 3 Dummy step amp A dummy step is a waiting step etc which contains no operation output program 1 The next transition condition is constantly checked during execution of a dummy step and the op
74. ed e The temporary stop status at a specified block is canceled with RSTART Bem operation resuming trom the STOP step eA specified block is forcibly started SET Sn 1 activated independently and is SET BLm Sn executed from a specified step RST Sn t_ eA specified step at a specified RST BLm Sn block is forcibly deactivated e The instruction execution step is SCHG D 2 deactivated and a specified step is activated SET TRmn 1 A specified transition condition at a SET BLm TRn specified block is forcibly satisfied Transition control instruction e RST TRn 1 The forced transition at a specified transition condition in a specified RST BLm TRn block is canceled e Blocks subject to the 1 SFC Block switching Instruction BRSET S control instruction are designated Block restart instruction Step control instruction 4 31 4 SFC PROGRAM CONFIGURATION e When the instruction execution condition is ON the subroutine call is executed in a constant manner When it is switched OFF the subroutine call occurs only once at that time A check occurs to determine if a Program operation status checkin LD AND OR PCHK Program name specified program is being executed When the designated time period beginning from the point when a specified condition is satisfied elapses the designated output device is switched ON Subroutine c
75. ed in parallel are processed simultaneously when the relevant transition condi tion is satisfied Step rn operation output A Transition condition b Step n 1 operation output B Transition condition c Step n 2 operation output C Step n operation output A Transition condition br Coupling Waiting step Transition condition d Step n 2 operation output C Step n 3 operation output D Transition condition d Step n4 operation output E Step nai operation Goar B Transition condition c Waiting step e From step n processing will proceed simultaneously to steps n 1 and n 3 when transition condition b is satisfied Processing will proceed to step n 4 when transition condition c is satisfied and to step n 4 when transition condition d is satisfied When transition conditions b and rer are satisfied at step n and step n 1 execution steps n and n 1 will be deactivated and processing will proceed to the waiting steps Waiting steps are used to synchronize parallel processing operations Parallel processing steps always proceed to a waiting step When condition d is satisfied at the waiting steps processing will proceed to step n 2 Waiting steps are dummy steps which require no operation output ladder 1 Up to 32 steps can processed simultaneously with the parallel transi tion format
76. eed gel 3 3 3 3 Processing Time for SFC Program 0 eee cece teen ten eens 3 5 3 4 Calculating the SFC Program Capacity 3 9 SFC PROGRAM CONFIGURATION cccccecccccecneeseaserees 4 1 4 78 41 List of SFC Diagram Symbols 0 cece ee eee cece teen eens 4 2 EE 4 4 4 2 1 Step without step attribute 0 0 eee ec eee cette eet enees 4 4 422 Intia step O MEET 4 6 4 2 3 Dummy st pD Cd geleed iot HC UPPER UH EQ EX GRO 4 6 4 04 Coil HOLD Slap SC EE 4 7 4 2 5 Operation HOLD step without transition check SE 4 9 4 2 6 Operation HOLD step with transition check ST ER 4 11 ROT Beet Step Bussi revente cem dfe aad ac cated tween 4 12 4 28 Block START step with END check EI 4 14 4 2 9 Block START step without END check E 4 15 42 10 BIOK END EE EE 4 16 4 3 Transition Conditiol et ERE ae eh ae ORE Oe ete Rar RAL aed 4 17 431 Sonal transition ooo EIL AN EUER Cot e reb e CN Ks 4 17 4 3 2 Selection transition voc as vag NEEN EE EY EX FEX ee Re RE 4 19 43 3 Parallel transition ed ose ch eee e ke eee 4 22 43 4 Jump transition MUTET 4 25 4 3 5 Transition processing with multiple initial steps 4 26 3 De cups pa e TERN ee 4 2 44 Controlling SFC Programs by Instructions SFC Control Instructions 4 31 4 4 1 Step operation status check instructions LO LDI AND ANI OR ORI 4 35 4 4 2 Forced transition check instruction 0 0 0 eee cece eee eee eee 4 37 4 4 3 Block o
77. ely when the block STOP RESTART bit switches from OFF to ON or when a block STOP instruction is executed However if the Block STOP mode bit OFF block STOP RESTART bit is switched ON within the current block the STOP will occur when that block is processed at the next scan or when the instruction is executed e The block is stopped at the step transition which occurs when the transition condition for the current step active step is satisfied However the operation output will not Block STOP mode bit ON be executed for the step following the transition e When multiple steps are active in a paralle branch the STOP will occur sequentially at each of the steps as their transition conditions are satisfied a SFC information register e Block STOP RESTART bit See Section 4 5 3 b SFC control instruction e Block STOP instruction PAUSE BLm See Section 4 4 7 4 SFC PROGRAM CONFIGURATION ae ee ee a EE eee MELSEC QaA 4 5 5 Continuous transition bit The continuous transition bit setting determines whether the operation out put of the next step is to be executed within the same scan after a transi tion condition is satisfied 1 As shown below SFC program transition processing occurs according to the continuous transition bit setting ON OFF designated by the user e Continuous transition ON EE When the transition conditions at contiguous steps are satisfied all the steps with satisfied transition condi
78. en a resumptive START occurs following a PC power OFF or reset the SFC program s STOP position will be maintained HOLD but the statuses of the devices used at the operation outputs will not Therefore a latch setting must be designated for devices where a HOLD condition is required in addition to execution of a resumptive START 2 The special function module is initialized when a PC power OFF or reset occurs Initial programs for the special function module should be created at constantly active blocks or programs other than SFC programs 3 After making SFC program changes SFC diagram modifications such as step additions or deletions etc while a resumptive START setting is in effect switch to an initial START setting then back to the resumptive START setting in order to register the changes Failure to do so will result in a START executed from the pre change step number causing a mechanical system malfunc tion 4 If a CPU reset occurs during SFC program execution with a re sumptive START format an initial START status may be desig nated when the system is restarted due to the reset being interpreted as a resumption disabled condition 6 SFC PROGRAM EXECUTION S 6 2 Block START and END 6 2 1 Block START methods The block START methods during SFC program execution are described below As shown below there are several block START methods Choose the method which is most suitable f
79. er Designates low speed execution of a specified program beginning from the next scan e if multiple programs are specified the execution sequence is determined by the program setting parameter e The following conditions will result in an operation error e When the specified program does not exist error No 2410 e At execution of the PSCAN or PLOW instruction when scanning or low speed execution of the specified program is in progress error No 2411 e When an SFC program is designated by the PSCAN instruction while scanning is in progress at another SFC program error No 2412 e The SFC control PCHK instruction can be used to check whether or not the specified SFC program is currently being executed For details regarding the PCHK instruction refer to Section 4 4 12 2 Instruction format rel ee Character string or word device where character string is stored PSTOP POFF PSCAN PLOW 5 SFC PROGRAM PROCESSING SEQUENCE ECE A a a ATO I I NET WELBEO GnA 3 Processing time required to switch SFC program from WAIT status to scan status The processing time required to switch an SFC program from a WAIT status to a scan status is shown below Although the scanning time is extended by the amount of the processing time this will not result in a watchdog timer error detection Switching time uS number of created programs x 20 number i of created steps x 40 SFC program capacity
80. er Substantial block information The amount of block information has been increased permitting operations such as a cont nuous transition designation in 1 block units and a STOP timing selection immediate STOP or STOP when transition condition is satisfied for block STOP requests Furthermore the additional block information simplifies operation by permitting a block START and END to be executed from a sin gle device e f Increased processing speed reduces system processing time The SFC program s system processing time has been reduced resulting in reduced tact times through the efficient combination of the SFC program functions g Improved operability of SFC software package Troublesome menu switching operations have been eliminated by permitting SFC comments steps and transition condition pro grams to be created concurrently with SFC ladder creation Moreover the SFC diagram cut amp paste function and block unit registration utilization have been simplified For reference purposes comparisons of the major MELSAP II and MELSAPS functions are shown in the following pages APP 6 i CA perg APPENDICES S EGET NG IRE LEE EE IE TE ETE TE DC MD PC EE I CUR ER PV Aca o PAP dt UR Manger i 1 SFC Diagram Symbols Ru EES Sek Zei SEIL os cian NAME C s os sse co o s MELSAP3 Coil HOLD step Operation HOLD step without transition check Operation HOLD step with transition chec
81. er will not be stored at SD62 SD63 or SD64 to SD79 The same step transition watchdog timer can be used at more than one step provided that the steps are not concurrently active Example 4 5 Watchdog timer 1 5 As there is no chance that steps 5 and 6 will be concurrently ac tive the same watchdog timer 6 can be used at both steps 6 Watchdog timer 2 4 SFC PROGRAM CONFIGURATION 47 SFC Operation Mode Setting The SFC operation mode setting is used to designate SFC program START conditions or to designate the processing method at a double START Some of the settings are designated at the parameter file common for en tire system and others at the SFO program file The SFC operation mode setting items and the resulting operations are shown below tem Description Setting Range e Designates an initial START or i Steam Srsumpive START went oiana START inai START SFC program is started Block O START e Designates whether block 0 is to Auto START ON be started automatically Auto START OFF AWOSTART Output mode at Designates the coil output mode Coil output OFF block STOP at a block STOP OFF HOLD Designates the first block No of 0 to 319 the periodic execution blocks e Designates the time interval for No setting execution of the periodic execution blocks Pause Wait Setting File Parameter file Periodic execution block setting e Designates the operation whi
82. eration proceeds to the next step when the condition is satisfied 2 o is displayed if a ladder is created at a dummy step 4 6 4 SFC PROGRAM CONFIGURATION 4 2 4 Coil HOLD step SC vi x e s 5 A coil HOLD step is a step where the cail output status is maintained in the transition to the next step The coil output is switched ON by the OUT instruction when the transition condition is satisfied 1 During normal SFC program operation the coil ON status switched ON by OUT instruction when transition condition is satisfied is automatically switched OFF before proceeding to the next step By designating an operation output step as a coil HOLD step the coil ON status will remain in effect when proceeding to the next step CI 4 e At a designated coil HOLD step When designated as a coil HOLD step When not designated as a coil HOLD step Xo sc Hro 8 Am FA ON ON ON Transition condition satisfied Cranach DE e etc Zeg ON OFF At steps not designated as coil Y10 switched ON by OUT instruc HOLD steps Y10 switched tion will remain ON even when the ON by OUT instruction is auto transition condition is satisfied matically switched OFF when 2 3 the transition condition is satis fied No ladder processing occurs following a transition to the next step Therefore the coil output status will remain unchanged even if the input conditions are changed When a c
83. essing will be executed after those blocks have been processed 8 Ladder operation is executed for the step activated by the satisfied condition at the previous scan e END processing occurs following the execution of all program files designated at the program setting parameter as scan execution files For details regarding the processing sequence etc refer to the QnACPU User s Manual 5 SFC PROGRAM PROCESSING SEQUENCE MELSEC QnA n 1 2 Transition processing for continuous transition OFF setting The SFC program processing procedure for a continuous transition OFF setting is shown below 1 Active step n ladder operation 2 Transition condition satisfied unsatisfied check When transition condition When transition condition Is unsatistied is satistied 3 END processing 3 The active step n is deactivated and the coil where the OUT instruction is ON Is switched OFF if other blocks exist subsequent the block in question END processing will be executed after those blocks have been processed 4 END processing if other blocks exist subsequent the block in question END processing will be executed 4 Ladder processing for the same step n after those blocks have been processed as that at the previous scan 5 Ladder operation is executed for the step activated by the satisfied condition at the previous scan e END processing occurs following the execut
84. f 512 serial transition steps A O per block are possible representing 512 serial transitions However the number of lines is restricted according to the SFC display column setting as shown below When SFC display column When SFC display setting is 1 or 2 column setting is n Max of Max of 1536 lines 512 serial transitions Number 1 i U of lines 1 Number of columns max of 32 Examples of the permissible number of lines corresponding to a few SFC display column setting values are shown below The SFC dis Approx 3000 ccc o ApproxX 2U00 auan lay column setting value can be designated i realy within a 1 to 32 range 3 Number of lines s SFG display column setting value n SFC Display Col 1 2 umn setting Possible 4 SFC PROGRAM CONFIGURATION 2 Serial transition operation flowchart Initial step Transition condition a Step 1 Transition condition b Step 2 Transition condition c Step 3 Transition condition d END step 1 For steps with attribute designations processing occurs in accordance with the attributes Operation status Initial step operation output executed Transition condition a satisfled YES Hd Initial step operation output deactivated Step 1 operation output executed Transition condition br satisfied YES wi Step 1 operation output deactivated Step 2 operation output executed Transitio
85. g of the START destination block will be continued to the block END e By starting another block at a given step the START destina tion block can be controlled inde pendently and asynchronously with the START source block un til processing of the current block is completed 6 A given function can be controlled in a variety of ways according to the application in question Block functions such as START END temporary stop restart and forced activation and ending of specified steps can be controlled by SFC diagram symbols SFC control instructions or by SFC information registers e Control by SFC diagram symbols T Convenient for control of automatic operations with easy sequential control e Control by SFC instructions Sites Enables requests from program files other than the SFC and is convenient for error processing for example after emergency stops and interrupt control e Control by SFC information registers m Enables control of SFC peripheral devices and is convenient for partial operations such as debugging or trial runs Functions which can be controlled by these 3 methods are shown below Control Method SFC Control SFC Diagram SFC Information Registers with END wait Block START Block START END bit without END wait EECH ON Hsk END RST BLm Block START END bit OFF DESS BUSE BU Block STOP RESTART bit RSTART BLm Block STOP RESTART bit OFF Foiced step SET Sn actWaton SCHG Kn ST S
86. he transition is executed and the next step is activated Operation output processing is executed at the reactivated next step When the transition condi tion is satisfied transition oc curs and the step is deactivated Convenient for outputs where there is an interlock with the next operation for example where machining is started on comple tion of a repeated operation workpiece transport etc When a HOLD status becomes unnecessary for machine con trol or on selective branching to a manual ladder occurs after an error detection etc a reset re quest can be designated for the HOLD step deactivating the step in question e Types of block START steps and their operations a Block START step with END check B m m In the same manner as for a sub routine CALL RET a START source block transition will not occur until the end of the START destination block is reached Convenient for starting the same block several times or to use several blocks together etc A convenient way to return to the START source block and pro ceed to the next process block when a given process is com pleted in a processing line for example 1 GENERAL DESCRIPTION ENE b Block START st p Without END check B m m e Even if the START destination block is active a START source block transition will occur if the n transition conditions for the block START step are satisfied H Tran H At such times processin
87. his will eliminate the waiting time from the point when a transition condition is satisfied until the point when the transition destination step s operation output is executed 4 5 6 Number of active steps register The number of active steps value for a given block is stored at this regis ter 1 The number of active steps value for a given block is stored Specified device piscem Number of steps 2 The number of active steps value includes normal active steps coil HOLD steps operation HOLD steps with transition check and opera tion HOLD steps without transition check 4 SFC PROGRAM CONFIGURATION 46 Step Transition Watchdog Timer The step transition watchdog timer is a check function which monitors the time from the point when execution of a step begins until the point when transition to the next st p occurs to determine whether the transition oc curred within the preset time period If transition to the next Step fails to c ur within the designated time period a preset annunciator F switches ON 1 The preset time period and the annunciator F ON when time over status occurs device number are designated at special relays SD90 SD99 The step transition watchdog timer operation begins when these special relays switch ON at the operation outputs of the monitored steps If the SD90 SD99 special relays switch OFF while a time count is in progress the time count will be stopped and
88. ied the coil output status is maintained regardless of the ON OFF status of the interlock condition X0 Transition will not occur even if the transition condition is satis fied again Convenient for maintaining an output until the block in question is compieted hydraulic motor output pass confirmation signal etc b Operation HOLD step no transition check SE s Y10 gt d el E S au MAE ver D Step which is active due to transition condition being atistied Operation output processing continues even after a step tran sition occurs and coil output Y10 ON OFF switching occurs in accordance with the interlock condition X0 ON OFF status Transition will not occur if the transition condition is satisfied again Convenient for repeating the same operation cylinder ad vance retract etc while the relevant block is active 1 GENERAL DESCRIPTION c Operation HOLD step with transition check ST xo K v10 D PLS MO Mo HEt ma H a Transition executed Step which is active due the previous transition condition being satisfied e Reset step R 7 When the reset step is activated a designated step will become inactive Operation output processing continues even after a step tran sition occurs and coil output Y10 ON OFF switching occurs in accordance with the interlock condition X0 ON OFF status When the transition condition is again satisfied t
89. initial step of the block designated by another pro gram file s SFC control instruction START request 5 SFC PROGRAM PROCESSING SEQUENCE 5 1 Overall Program Processing The overall QnACPU program processing operation is described in this sec tion For more detailed information refer to the QnACPU User s Manual 5 1 1 Program processing sequence The QnACPU can store several programs in the program memory and manage them as files file execution can be designated for a specified file only or for multiple files simultaneously The overall operation format is shown below CPU RUN l Initial program i Sg Started only 4 2 when required ua i f Execution time monitoring Low speed program END END END CPU RUN processing processing processing 1 2 3 2 3 Initial scan 1 scan 1 scan e The longer of the surplus constant scanning time or the desig nated low speed program execution time is adopted for the low speed program 3 5 SFC PROGRAM PROCESSING SEQUENCE ma E Execution Type Description e 1 scan only is executed at power ON or at STOP RUN switching e The WAIT program is used from that point on 2 San See e File which is executed at every scan 9 7 e The execution time for this file is either the surplus den pend Seet constant scanning time or the preset low speed execution time Initial program initial execution
90. ion is to remain ON or be switched OFF when a temporary STOP octurs at a given block in response to the SFC informa tion register s STOP RESTART bit or the SFC control block STOP PAUSE Bim instruction 1 Settings and corresponding operations Either an output HOLD or an output forced OFF setting can be designated 5 the output mode when a block STOP occurs As shown betow the operation which occurs depends on the parameter and special relay SM325 setting combination Block stor eration OM325 Status pon Active Steps Other than Status Operation HOLD Steps Operation HOLD Steps OFF or no setting Operation output s coil output switches OFF at the STOP Coil output immediate instruction and operation stops OFF OFF STOP default RR e After the STOP instruction coil output ON OFF the operation output s coil Operation output s coil output ON itches OFF at the STOP post transition output switches OFF when STOP the transition condition is e and operation satisfied and operation stops ps3 OFF or no setting A coil output HOLD status is established at the STOP immediate instruction and operation stops Coil output or ON ON coil output HOLD ON eege patus i a A coll output HOLD status is poat h established when the eeneg OP instruction and operation transition condition Is stops satisfied and operation stops 1 The coil HOLD step becomes inactive the first ti
91. ion watchdog timer setting corresponding to SM95 Step transition watchdog timer setting corresponding to SM96 Step transition watchdog timer SD97 setting ee corresponding to SMS97 Step transition watchdog timer SD968 setting corresponding to SM98 Step transition watchdog timer setting corresponding to M99 E SD816 Statu s check Status heck e The block No where a status check at SFC program is are executed is stored execution block No execution block No Valid only when SM816 is ON SD817 Status check Status checi e The step No where a status check at SFC program is execution step No execution step No The step transition watchdog timer s setting value and the Er No which switches ON when a watchdog timer time over status occurs are designated bi5 to b8 b7 to bo Timer limit setting 1 to 255 secs designated in 1 sec units Er No setting Timer setting value and F No at time over The timer is started when any of these special registers switches ON if the next transition condition for the step in question is not satisfied within the designated time the specified annunciator F switches ON executed is stored Valid only when SM816 is ON APPS APPENDICES SI AY EL TEE MELOEC OnA APPENDICES 2 MEL
92. ion is executed nothing will change Operation Error e Error No 4621 occurs when the specified block does not exist Program Examples 1 When X1 switches ON the following program forcibly activates block 1 When X2 switches ON it ends and forcibly deactivates block 1 x1 4 SFC PROGRAM CONFIGURATION APG c wg ue ule Rp eg SC a MM MM ECCE ZR CE E E MM ene AA Er o ar Qe Gf a SFC diagram symbols _ Keesen e Block START step El B See Sections 4 2 8 and 4 2 9 b SFC information register e Block START END bit See Section 4 5 1 4 SFC PROGRAM CONFIGURATION 4 4 7 Block STOP amp RESTART instructions PAUSE RSTART Device i ee eee At expansion SFC and other columns m represents the block No and n represents the step transition condition No m is the block No H rA Function Output Mode Set ting at Pa rameter Block STOP Coil output OFF coil output HOLD Coil output HOLD 1 Status of Output Mode s Special Relay SM325 OFF coll output OFF ON coil output HOLD a Executes a temporary stop at the specified block b As shown below processing varies depending on when the stop occurs and on the coil output status setting designated by OUT instruction Operation Description Active Step Other than HOLD Step Status of Block STOP Mode Bit Active HOLD Step e After the STOP request the coil output will be switched OFF
93. ion of all program files designated at the program setting parameter as scan execution files For details regarding the processing sequence etc refer to the QnACPU User s Manual 5 14 6 SEC PROGRAM EXECUTION a re ee er ee ee l DONDE 6 SFC PROGRAM EXECUTION 61 SFC Program START And END The SFC program s START STOP special relay SM321 is automatically switched ON when CPU STOP RUN switching occurs and the SFC program is automatically started At other program files SFC program processing can be temporarily inter rupted and restarted by switching SM321 OFF and ON CPU RUN Resumptive START Initial START SFC program execution SFC program not executed Is another program designated at the execution file Was SM321 switched ON or OFF at another program file SFC program not executed 1 The processing which occurs when an SFC program is designated as a WAIT program by the POFF instruction is identical to that when SM321 is switched OFF 2 The processing which occurs when an SFC program scan execu tion status is designated by the PSCAN instruction is identical to that for a CPU RUN condition 6 SFC PROGRAM EXECUTION 6 1 1 SFC program resumptive START procedure The SFC program START format can be designated as initial START or resumptive START The resumptive START setting procedure as well as some precautions regarding the res
94. ion or a programmable controller failure Erroneous outputs and operation could result in an accident 1 The following circuitry should be installed outside the programmable controller interlock circuitry for the emergency stop circuit protective circuit and for reciprocal operations such as forward reverse etc and interlock circuitry for upper lower positioning limits etc to prevent machine damage 2 When the programmable controller detects an abnormal condition processing is stopped and all outputs are switched OFF This happens in the following cases e When the power supply module s over current or over voltage protection device is activated e When an error watchdog timer error etc is detected at the PC CPU by the self diagnosis function Some errors such as input output control errors cannot be detected by the PC CPU and there may be cases when all outputs are turned ON when such errors occur In order to ensure that the machine operates safely in such cases a failsafe circuit or mechanism should be provided outside the programmable controller Refer to the CPU module user s manual for an example of such a failsafe circuit 3 Outputs may become stuck at ON or OFF due to an output module relay or transistor failure An external circuit should therefore be provided to monitor output signals whose incorrect operation could cause serious accidents A circuit should be installed which permits the external power suppl
95. ition condition 1 of block 1 The forced transition setting is canceled when X2 switches ON Designating a transition condition No within the current block A Les xe Designating a transition condition No in another block RST BLUTR I 4 SFC PROGRAM CONFIGURATION MN Se MELSEC QnA 4 4 10 Active step change instruction SCHG meme Site Transition Condition Transition Conditien 21 MR CREER ES At expansion SFC and other columns m represents the block No and n represents the step transition condition No I 4 Function 1 The step where this instruction is executed is deactivated and a speci fied step within the same block is forcibly activated 2 If the destination step is already active the step where this instruction is executed will be deactivated and processing of the destination step will continue as is 3 The step where this instruction is executed is deactivated when proces sing proceeds to the transition condition status check following the completion of that step s program operation 4 This instruction can only be used at SFC program steps Operation Error Error No 4631 occurs when the specified destination step does not exist Error No 4001 occurs when this instruction is used at a sequence program other th n an SFC program error is activated on switching from STOP to RUN Program Examples 1 When X1 switches ON the following program de
96. ition condition is satisfied again a transition to the next step will occur with that step being activated while the current step remains active repeated operation 1 A pulse PLS format should be used for the transition condition If a pulse format is not used scan transition processing will occur each time a condition is satisfied 2 If a double START occurs due to the transition destination step being active when the transition condition is satisfied processing will be according to the parameter setting Refer to Section 4 7 6 for details regarding parameter settings and the processing for each setting 3 The difference between operation HOLD steps with and without transition checks is as follows At operation HOLD steps with transition checks the next step is activated when the transition condition is again satisfied At operation HOLD steps without transition checks the next step is not activated when the eue oer is again satisfied yio PLS MO MO Transition executed again Step activated by previous transition condition being satistied 4 SFC PROGRAM CONFIGURATION Cen ns MELSEC QnA 2 Anoperation HOLD step with transition check becomes inactive when any of the following occur e When the END step of the block in question is executed e When an SFC control instruction RST BLm designates a forced END at the block in question e When an SFC contro instruction RST BLm Sn RST Sn desig nate
97. itions 60 3 SPECIFICATIONS E e Steps with satisfied transition conditions 10 active steps no HOLD steps with satisfied transition conditions SFC system process time 14 3 20 3 x 30 4 0 x 70 2 1 x 50 3 2 x 60 7 4 x 60 7 8 x 10 1722 3 uS 1 72 ms In this case catculation using the equation shown above results in an SFC system processing time of 1 72 ms With the Q3ACPU given the same conditions the processing time would be 3 41 ms and with the Q2ACPU it would be 4 56 ms The scan time is the total of the following times SFC system processing time main sequence program processing time SFC active step transi tion condition ladder processing time and CPU END processing time The numbar of active steps the number of transition conditions and the number of steps with satisfied transition conditions varies according to the conditions shown below e When transition condition is unsatisfied e When transition condition is satisfied without continuous transition e When transition condition is satisfied with continuous transition The method for determining the number of the above items is illustrated in the SFC diagram below Step 6 Transition Transition condition 2 condition 5 Step 7 Transition Transition condition 3 condition 6 Transition Transition condition 4 condition 7 3 SPECIFICATIONS a When transition condition is not satisfied If steps 2 and 6 are both act
98. k Block START step l with END wait Block START step without END wait Coupling amp Branch A dummy step is required when couplings or branches are duplicated at a transition condition amp Coupling and branch duplications are possible at a transition condition APPENDICES 2 SFC Controf Instructions The SFC control instruction shown below are available at MELSAP3 MELSAP It has no SFC control instructions LD AND OR E LO AND OR toi ANI oni BLm So D g Sal Rn si o Checks a specified step in a specified block Forced transition check Rea to determine If the transition condition by instruction transition controt Instruction for that step Sep aN oni BLn TRn was satistied forcibly or not Block operation status LD AND OR Bim e Checks a specified block to determine if it Is check instruction 8 ANI oxi active or inactive MOV P K4Sn D ei MOV P BLmW4Sn D Active steps batch DMOV P K8Sn D readout instruction DMOV P BLm K8Sn D BMOV P K4Sn D Kn Step status active inactive check instruction e Executes a check to determine if a specified step at a specified block is active or inactive cc e Active steps in a specified block are read to a specified device as bit information BMOV P BLM K4Sn D Kn e A specified block is forcibly started Block START instruction SET BLm activated independently and
99. kregen instructione SFC Program Constant Expansion SESCH Sequence n Transition KH vs Program Condition Y BLmSn Transition Condition Sn only At expansion SFC and other columns m represents the block No and n represents the step transition condition No nr is the step No Number of readouts mr is the block No H anova TOTO H Hover icm TOTO Function 1 A batch readout designated number of words of step operation statu ses is executed at the specified block 2 The readout results are SR s jig Se MAN as phil below b15 ba b13 bI2 bil bp b9 b4 Fleleleldeleleledeleleledede e Se gt Se A AD cma tee Vs e lame E dE ee Rees dem em RE Te gt Sn step 15 Sn caup 1 Step designated at Sn Sn A x 16 15 i S 3 Ifthe steps in question do not exist in the SFC program they will remain OFF 4 SFC PROGRAM CONFIGURATION SEN ne MELSEGC QnA Program Examples 1 When XO switches ON the following program executes a 3 word read out beginning from DO of block 3 active step statuses Designating a step within the current block xo swovP kaso oo x3 Designating a step in another block xo amove eraso oo ks bi5 bid bi3 b12 b11 b10 b9 b8 b7 bE b5 b4 b3 b2 bt bO 15 id s13 812 vii s10 s9 s8 87 s6 s5 s4 83 82 si s0 s31 330 s29 s28 s27 s26 825 s24 823 s22 21 s20 819 s18 s17 s16 D2 347 M 45 844 s43 842 s4 s40 39 s38 837 s36 835 8
100. l connection Leading edge pulse parallel connection Contacts i Trailing edge pulse operation START Trailing edge pulse serial connection Trailing edge pulse parallel connection ANB Ladder block serial connection ORB Ladder block EE connection Coupling Operation results converted to a ee edge pulse step memory Operation results converted to trailing edge pulse step memory Operation results converted to leading edge pulse memory Operation results converted to trailing edge pulse memory 4 SFC PROGRAM CONFIGURATION Instruction Code Lol ANDLI oro LoO ANDI S1 S2 orO D lt gt gt gt lt lt BIN16 bit data comparison Loo ANDOD S1 S2 oro CN lt gt gt gt lt lt BINS2 bit data comparison Comparison operation Loe ANDED 81 S2 one O lt gt gt gt lt lt Floating decimal point data comparison LosO ANDS S1 S2 ops C lt gt gt gt a lt lt Character string data comparison Contacts LDPCHK Operation START N O contact ales Meda ANDPCHK Serial connection N O contact p ORPCHK Parallel connection N O contact status check 4 SFC PROGRAM CONFIGURATION EH 44 Controlling SFC Programs by Instructions SFC Control Instructions SFC control instructions can be used to check a block or step operation
101. ll be executed following execution of blocks designated for execution at each scan If the specified time interval is shorter than the scan time the peri odic execution blocks will be execut d at each scan in the same manner as the other blocks 4c The specified time interval countdown is executed in a continuous manner 4 SFC PROGRAM CONFIGURATION A 4 7 5 Operation mode at double block START This mode setting designates the operation mode which is to be effective when a block START request occurs by block START step B SI fora block which is already started 1 Settings and corresponding operations Either a PAUSE or WAIT setting can be designated The operations resulting from these settings are shown below a HENRI e A CPU operation error BLOCK EXE ERROR occurs A block range can be STOP and CPU operation is stopped designated for the STOP e All Y outputs switch OFF setting e CPU operation continues and a WAIT status is established when the transition condition is satisfied The WAIT status continues until the START destination block is deactivated e A step transition occurs when the START destination block is deactivated and that block is then reactivated WAIT default elf a transition WAIT occurs the previous step is deactivated the output is switched OFF and the operation output wIH not be executed HOLD ste p Condition with transition check oe Tran
102. lock is restarted by forcing the e Convenient for confirming operation by s block START END bit ON from a program control at d bugaifig EN dpud sd ud Restart by SFC or a peripheral device because block processing can be restarted information register The block START END bit is designated from a p ripheral device without requiring a at each block as an SFC information ro bd i d s register baie 2 Active step when restart occurs The step which is active when a block is restarted varies according to the status which existed when the STOP occurred as shown below Step Other than Operation HOLD Step Operation HOLD Step e Operation is restarted from the step which POE mode was being executed whan the STOP occurred e Because the STOP is due a satisfied W er mode transition condition operation is restarted from the post transition step Steps where an operation HOLD status with or without transition check was in effect when the STOP occurred retain their operation HOLD status when restarted Coil HOLD steps are inactive when a STOP occurs and are therefore not reactivated by a restart 6 SFC PROGRAM EXECUTION qd anoche te ap te z Su 6 4 Step START Activate and END Deactivate Methods Tm 4 1 Step START activate methods E The methods for activating steps are described below 1 Step START activate m thed Steps can be started activated by the methods shown below e The
103. me processing occurs at the block in question following the STOP request 2 When CPU STOP 5 RUN switching occurs the SM325 special relay is switched OFF when the coil output is OFF and is switched ON when the coil output is ON in accordance with the parameter setting The SM325 special relay can also be switched ON and OFF by the user program without regard to the parameter setting 4 SFC PROGRAM CONFIGURATION Ss WELSEC QnA 4 7 4 Periodic execution block setting The periodic execution block setting designates the execution of a given block at specified time intervals rather than at each scan 1 Setting items Designate the first block number and the time of execution for the periodic execution blocks When these settings are designated the first block and all subsequent blocks will become periodic execution blocks The execution time interval setting can be designated in 1 ms units within a 1 to 65535 ms range 2 Periodic execution block operation method Periodic execution block operation occurs as shown below mya a Execution interval Execution interval 1 Sequence programs executed at each scan 2 Blocks executed at each scan 3 END processing 4 Periodic execution blocks a Until the specified time interval elapses only the sequence pro grams and blocks designated for execution at each scan will be executed b When the specified time interval elapses the periodic execution blocks wi
104. mp BOWN e m MIO lt MTIB e repai 70 8 t Headstock RETRACT Machining Machining Carriage ADVANCE endpoint START END endpoint Carriage RETRACT endpoint tSo S S R 1 GENERAL DESCRIPTION Sh og appe Carriage ADVANCE endpoint Step were pe vao 5 Carriage ADVANCE TM Hi Tan J x3 Clamp DOWN St 6 E As shown in the SFC program at leit the steps require ep P I f lt Yai no operation completed interlock contact with the previous step With a conventional sequence program Clamp DOWN endpoint carriage FORWARD Y20 and clamp DOWN Y21 X4 interlock contacts would be required at the ladder used for the headstock ADVANCE NEE Hie tran H x Xx Headstock ADVANGE v20 Y21 xa X4 Headstock ADVANCE Step 7 dI EM vaa leren EM IM va gt Interlock contacts SFC program 3 Block and step configurations can easily be changed for new control applications A total of 320 blocks can be used in an SFC program with 512 steps in each block A total of 4k sequence steps can be created in each block of the ladder diagram programs for operation outputs and transition conditions Reduced tact times as well as easier debugging and trial run operations are possible by dividing the blocks and steps so as to obtain the optimum configuration for system of units used for machine operation 320 blocks Block 0 Block 1 Block 319 4k sequence steps per block for operation outputs and transition conditions por 1
105. n until the designated time up setting is reached even if a step transition occurs e Block STOP processing If a block STOP request is designated by the SFC information register s STOP RESTART bit or by an SFC block STOP instruction the step in question will become inactive with processing occurring as follows e Step becomes inactive after the block STOP request occurs and processing returns to the beginning of the block All coil outputs except those which were switched ON by the SET instruction will switch OFF 4 8 4 SFC PROGRAM CONFIGURATION f v Hames sn 4 2 5 Operation HOLD step without transition check SE An operation HOLD step without transition check is a step where operation output ladder processing continues even after a transition to the next step However transition processing will not be executed when the transition condition is satisfied again 1 2 3 During normal SFC program operation the coil ON status switched ON by OUT instruction when transition condition is satisfied is automatically switched OFF before proceeding to the next step By designating an operation output step as an operation HOLD step without transition check that step will remain active even after a transition to the next step occurs and processing of its operation output ladder will continue l Therefore the coil status will be changed if the input conditions are changed As no
106. n condition c satisfied YES ot Step 2 operation output deactivated Step 3 operation output executed Transition condition d satisfied Step 3 operation output deactivated END step executed operation l completed YES 1 4 SFC PROGRAM CONFIGURATION RPA P AEE MEL OEG QUA 4 3 2 Selection transition A selection transition is the transition format in which several steps are coupled in a parallel manner with processing occurring only at the step where the transition condition is satisfied first e From step nr processing will proceed to Step n either step n 1 or n 2 depending on operation output A which transition condition b or c e is satisfied first Transition condition b Transition condition rer e if both transition conditions are satisfied Branch Step n 1 Step n 2 simuitaneously the condition to the left operation output B operation output C will take precedence d poraj ope put C Step n will then be deactivated e Subsequent processing will proceed from step to step in the selected column until another parallel coupling selection occurs Step nr Step nai operation output A operation output 8D e When the transition condition br or rer Transition condition b Transition condition c at the executed branch is satisfied the Coupling executed step Al or B will be Step n 2 deactivated and processing will proceed operation output C to step
107. n destination instructions TSET Sn for the number of parallel branches in qu stion C For parallel coupling Total number of steps for the transition START instruction TRAN 3 TRn and the transition destination instructions TSET Sn and coupling check instruc tions TAND Sn for the number of parallel branchings In question 1 gt e Jump L block end Calculated as step 0 because it is included in the previous transition condition e Operation outputs for each step The capacity per step is as follows e Total number of sequence steps for all instructions For details regarding the number of sequence steps for each instruction refer to the QnA Programming Manual Common Instructions e Transition conditions The capacity per transition condition is as follows e Total number of sequence steps for all instructions For detalis regarding the number of sequence steps for each instruction refer to the QnA Programming Manual Common Instructions 3 SPECIFICATIONS Be MELSEC QnA 2 Number of steps required for expressing the SFC diagram as SFC dedicated instructions The following table shows the number of steps required for expressing the SFC diagram as SFC dedicated instructions CRT KS eee of steps 1 ounen block e Indicates the step START e Indicates the transition START DA varies according to the step attribute Coupling check TAND Si e Coupling completed check Number of parallel couplings
108. o S2 occurs after the tran sition condition Is satisfied S2 Scanning of the error processing SFC program is executed Condition 6 An SFC program WAIT status is estab lished when condition 6 is satisfied er ror processing END t3 PcHK etc opp TRAN When error processing is completed and the transition condition is satisfied a block END occurs and SO is reactivated The processing sequence when transition condition t4 is satisfied is the same as that shown above except for a different product type 5 7 5 SFC PROGRAM PROCESSING SEQUENCE M MELSEC QnA 5 2 SFC Program Processing Sequence 5 2 4 SFC program execution cycle The SFC program execution cycle is one time per scan while the SFC pro gram START STOP special relay SM321 is ON Example Under the conditions shown below the execution cycle would be as follows Condition 1 Program sequence 1 ABC sequence scan designated by 2 DEF SFC scan parameter setting 3 XYZ sequence lt low speed gt Condition 2 Parameter setting for low speed program time 20 ms Condition 3 Automatic START designated for SFC program ABC SFC END z ABC SFC END XYZ program execution processing program program execution processing program execution execution execution execution for 20 ms for 20 ms Refer to Section 6 1 for details regarding the SFC program START STOP procedure
109. oil ON status at coil HOLD step has been maintained to the next step the coil will be switched OFF at any of the following times When the END step of the block in question is executed When an SFC control instruction RST BLm designates a forced END at the block in question When an SFC control instruction RST BLm Sn RSTSn desig nates a reset at the block in question When a reset occurs at the device designated as the SFC informa tion register s block START END device When a reset step for resetting the step in question becomes active When the SFC START STOP command SM321 is switched OFF When the coil in question is reset by the program A SFC PROGRAM CONFIGURATION REENEN ENEE MELSEC QnA 4 Precautions when designating coil HOLD steps a PLS instruction When the transition condition is satisfied at the same scan where a PLS output condition is satisfied resutting in a PLS output the PLS contact will remain ON until the OFF condition described at item 3 above is satisfied b PLF instruction The PLF output occurs when the OFF condition described at item 3 above is satisfied c Counter If the counter coil is ON when the transition condition becomes satisfied counting will not occur even if input condition ON OFF switching is executed after the transition to the next step d Timer if the timer coil is ON when the transition condition becomes satis fied the timer will continue to ru
110. on from being satisfied d If a specified step is already active when this instruction is exe cuted the instruction will be ignored equivalent to the NOP in struction and processing will continue 4 SFC PROGRAM CONFIGURATION eter du ue eoo a ne asi maar nee mmn 2 Al A specified step at a spacified block is forcibly deactivated Coil HOLD and operation HOLD steps are subject to this instruction b When the number of active steps at the block in question reaches 0 due tQ the execution of this RST instruction block END proces sing will occur and the block will be deactivated H an SFC information register block START END bit setting has been designated the bit device in question will switch OFF at this time c If the RST instruction is executed at a step located in a parallel branch the parallel coupling condition will remain unsatisfied d If a specified step is already inactive when this instruction is exe cuted the instruction will be ignored equivalent to the NOP in struction Operation Error e Error No 4631 occurs when the specified step does not exist Program Examples 1 When X1 switches ON the following program will select and start step 2 of block 1 which contains multiple initial steps Program 1 so 1 2 Designating a step within the current block 3 S4 S5 D H Designating a step in another block S6 xi 4 SET BL1 S2 1 2 The following program deactivates step
111. on switches the contact ON and the N C contact instruction switches the contact OFF 3 To designate a step in the current block use SN To designate a step in another block or to execute an instruction by the sequence program use BLm Sn 4 If the step in question does not exist in the SFC program it will remain OFF 4 SFC PROGRAM CONFIGURATION MELSEC QnA Program Examples 1 The following program switches Y20 ON when the operation status of step 5 in block 3 is checked and found to be active Designating a step within the current block HE Designating a step in another block BL3 S5 2 The following program executes a step synchronously with another step of a parallel branch S5 S6 10 20 Interlock HH L MK eH 20 Related Instructions a SFC control instructions e Block switching instruction BRSET See Section 4 4 11 e Step control instruction SCHG See Section 4 4 10 e Active step batch readout instruction MOV P DMOV P BMOV P See Section 4 4 4 4 SFC PROGRAM CONFIGURATION 4 4 2 Forced transition check instruction Programe temp Using instructions meme Site SFC Program P Deta k ote pan Condition Transition Condition Device name At expansion SFC and other columns m represents the block No and n represents the step transition condition No LTAn nj n is the transition condition No BLm
112. or ali blocks max of 256 steps per block including HOLD steps Number of operation Max of 4k steps per output sequence steps Max of 255 sequence steps block no limit per step Number of transition Max ol k steps pe condition sequence Max of 255 sequence steps Block no KE Ber ten steps li Step transition watchdog timer function Function exists 8 timers Oden 5 System Processing Times for CPU Types NEEEM ac T A3UCPU A4UCPU eegen mos wo oem ore Number of SFC steps Max of 255 steps per block Number of concurrently active steps Max of 1024 steps total for ali blocks max of 22 steps per block AnNCPU F A1SCPU Processing of step with satisfied transition condition SFC END processing APP 10 IMPORTANT Design the uid Aa duh of a ES to gt prov e an externa protective or Sea inter peng eireuit dos dA PCs d E fecun eS mec Ln INE LU RM e Me M INC e Acer ta ies Ge AIL s tz and sagan shown in this manual are intended 1 ori i dn aid to Eos the text not to guarantee operation Mitsubishi Electric will accept no responsibility for actual use ot the Product based on these illustrati f Owing to the very geai variety in pos icati i if Im satisfy yourself as to its suitability for your specific application s ad QNA P SFC E S M
113. or the purpose at hand START Method Operation Description Remake O Auto START ON At SFC program START Auto START OFF Block START by SFC diagram symbol Block START by SFC control instructi n Block START by SFC information register e When the SFC program is started block O is automatically started and is executed from its initial step e A START request is designated from another sequence program for a specified block The specified block is then started and executed from its initial step e Another block is started by the block START steps E3 Bl at each of the SFC program blocks c 1 START occurs 1 t t Using an SFC control instruction a specified black is forcibly started from an SFC program step operation output or from another sequence program 1 When specified block is executed from its initial step Condition BLm m is the block No 2 When specified block is executed from a specified step d m is the block No n is the step o Condition e A specified block is started by forcing the block START END bit ON from a program or a peripheral device The block START END bit is designated at each block as an SFC information register e Convenient when block 0 is used as a control block pre processing block or a constant monitoring block e Convenient when the started block is to be variable product type etc when the SFC prog
114. peration status check instruction BLM 0 cece ee eee 4 39 4 4 4 Active step batch readout instructions MOV DMOV 00 4 40 4 4 5 Active step batch readout DMON cc cece cece e eene 4 42 4 4 6 Block START amp END instructions SET RST 0 ec eee ee 4 44 4 4 7 Block STOP amp RESTART instructions PAUSE RSTART 4 46 4 4 8 Step START amp END instructions SET RST 0 2 eee eee 4 48 4 49 Forced transition EXECUTE A CANCEL instructions SET RST 4 50 4 4 11 Block switching instruction BRSET 0 00 000 c cece eee eee 4 8 4 4 12 Program operation status check instruction bets ok ase rre riva b O5 4 4 43 Subroutine call instruction XCALL 0 cee ccc e 4 56 4 4 14 Time check instruction TIMCHK naneuaesaana aoa ae ca we eee 4 58 4 5 SFC Information Registers 00 ccc eee e cee e eee ROSEO Bee 4 59 4 5 1 Block START END bt Win Eee LUN EE 4 60 45 2 Step transition 4 62 4 5 3 Block STOP RESTART be 4 64 45 4 Block STOP modebit eiiis hene 4 66 4 5 5 Continuous transition bg SE EE 4 67 4 5 6 Number of active steps regeiert 4 68 4 6 Step Transition Watchdog Timer 0 0 eee nne 4 69 4 7 SFC Operation Mode Setting e 4 71 4 71 SFC program START mode icis yer Rr Er rx RS wales AEN 4 72 4 7 2 Block 0 START condition 0 0000 cease waded Doda condis 4 72 4 7 3 Output mode at block STOP 4 73 4 74
115. point 4 words e Direct processing at DX Direct processing at DY eT and ST by parameter setting e Contact and coil by bit e Contact and coil by bit e Exclusively for SFC program e Present at each link unit Special unit e Present at each installed Index register index register Wed zoezis 3 SPECIFICATIONS MELSEC QnA When block switching is 0 to R32767 ig File register File register ZRO to ZR1042431 ere geck SFC transition Exclusively for SFC program oe No BueER to UFF K 2147483648 to K2147483647 Hexadecimal constant Classification HO to HFFFFFFFF Constants EH number EH E 1 17549 38 to E 3 40282 38 EE a EE constant ABC123 etc 3 SPECIFICATIONS ae RE 3 Processing Time for SFC Program The time required to process the SFC program is discussed below 1 Method for calculating the SFC program processing time The processing time for the SFC program comprises the processing time for operation outputs and transition condition instructions and the sys tem processing time SFC program Operation output transition condition e System processing processing time instructions processing time time a Processing time for operation output amp transition condition instruc tions Operation output transition Processing time Processing time condition instructions for operation output X2 for transition condition processing time
116. r satisfied Transition condition f Transition condition g Transition condition d YES Transition condition j Transition condition e satislied vi Step 1 operation output deactivated Step 2 operation output executed l ransition condition c satisfied vi Step 1 operation output deactivated Step 4 operation output executed Transition condition F satisfied YES ed Step 4 operation output deactivated Step 5 operation output executed Transition condition g satisfied Transition condition h satisfied Step 1 operation output deactivated Step 6 operation output BEE Transition condition i satisfied YES el Step 2 operation output deactivated Step 3 operation output executed Step 6 operation output deactivated Transition condition d satisfied YES vi Step 5 operation output deactivated YES vi ed Step 3 operation output deactivat Step 7 operation output executed Transition condition j satisfied YES et Step 7 operation output deactivated END step executed operation completed 1 For steps with attribute designations processing occurs in accordance with the attributes 4 SFC PROGRAM CONFIGURATION SE ee MEL BE CHA 4 3 3 Parallel transition Parallel transition is the transition format in which several steps link
117. r to decode than sequence programs Station 1 Station 2 Station 3 contro unit centro unit control unit Step transition control unit for overal process Transter machine Overall system SFC program Uae EEN Step transition oontrol Station 1 Station 2 Station 3 unit for overall process vnit controt unit control unit block 0 block 1 block 2 block 3 Transter machine START START START START ree initial step P E initial step fers initial step f initial step H t i H D 1 H Station 1 START Pellet Pallet clamp i CT Pallet clamp t 3 block 1 START step 1 step 1 t step 1 a 4 t pow H i 1 S Station 2 START Drilling i Tapping 1 Workpiece unloading S block 2 START step 2 step 2 step 2 L 1 Station 3 START M Pallet unclamp r Palet unciamp 1 Pallet unclamp i block 3 START step 3 step 3 D step 3 WS H N U ND 1 U t c eNO ZE L END step END step END step E ET 4 H t 4 Lem om we ee rm mm mm ee i 2 Requires no complex interlock circuitry Interlock circuits are used only inthe operation output programs for each step Because interiocks between steps are not required it is not necessary to consider interlocks with regard to the overall system Clamp SOLI SoL2 LS U Clamp UP endpoint SE Cia
118. ram execution when a machine operation condition is satisfied or when a parallel branch transition to an error processing step occurs e The specified reset step must be located in the same block e Step resets at other blocks are also possible e if all the block s steps are deactivated by the reset processing of that block will be ended 6 SFC PROGRAM EXECUTION 6 4 3 Changing an active step status The method for deactivating an active step and activating a specified step is shown below ERR e Active SFC program steps instruction execution steps are deactivated and a forced START is executed for a specified e Convenient when jump destination varies according to the condition e The change destination step must be Change by SFC Condition located in the current block gon metrpeuan C H SCHG Kn e Indirect designation DO K4MO etc of the i change destination step is also possible e If multiple instructions exist in a single step the change destination executed in Active step Specified ste i i deactivated Seeche H the same scan will be effective APPENDICES APPENDICES APPENDIGES 1 SPECIAL RELAY AND SPECIAL REGISTER LIST The special relays and special registers SR can be used in SFC pro grams are shown below For information regarding other special releys and special registers not used at SFC program refer to the QnACPU Programming Manual Com mon Instructions 1 1 SM Spe
119. ram is started e sequence program other than the SFC program must be designated at the program setting parameter e Convenient for automatic operations etc where the sequence control is clearly defined There are 2 types of block START The START source step remains active until the START destination block is ended The START source transition occurs without waiting for the START destination block to be ended SFC diagram symbol Bm Convenient when starting an error resetting block when error detection occurs and for executing interruption processing e Convenient for debugging and test operations in 1 block units because the block can be started from a peripheral device without requiring a program 6 SFC PROGRAM EXECUTION Pie ME er tee 6 2 2 Block END methods The methods for ending block operations are described below _ As shown below there are several block END methads Choose the method which is most suitable for the purpose at hand mam ommon me e Block proc is ended and the block is deactivated when the block s END step is executed Block END by SFC diagram symboi i END step Using an SFC control instruction a specified block is forcibly ended and deactivated from an SFC program step operation output or from another sequence program Block END by SFC Condition control instruction H ser Bim m is the block No Block processing is also ended
120. ration output Initial step operation Step 1 operation executed output executed output executed SFC program Block 0 Transition condition Transition condition Transition condition unsatisfied unsatisfied unsatisfied 5 SFC PROGRAM PROCESSING SEQUENCE The continuous transition ON setting is recommended for faster tact times and step transitions A continuous transition ON setting eliminates the waiting time from the point when a transition condition is satisfied until the point when the operation output for the transition destination step is executed For further details see Section 5 2 4 5 11 5 SFC PROGRAM PROCESSING SEQUENCE j MELSEC QnA 5 2 4 Continuous transition ON OFF operation SFC program transition processing can occur with or without a continuous transition depending on whether the continuous transition bit device desig nated by the SFC information register is set to ON or OFF by the user e Continuous transition ON SUID ui epu Ses When the transition conditions for contiguous steps are all satisfied all these steps will be executed in a single scan e Continuous transition OFF 1 step is executed at each scan When multiple steps in a parallel branch are active the entire parallel branch is executed Example Sample program and corresponding processing Block n SM400 e With continuous transition ON setting H When
121. ripheral Device Software Model Name Package Name For details regarding the system IBM PC AT SWOIVD GPPO configuration and environment settings etc refer to the GPPQ Operating Manual OFFLINE Memory card The memory card shown below is required for SFC trace operations Q1 MEN AAA Memory type Memory size For details regarding the memory card refer to the QnACPU Users Manual 3 SPECIFICATIONS A NEN LRP RT TAL M amp LSRC QnA 3 SPECIFICATIONS The performance specifications for SFC programs are described in this section 3 1 Performance Specifications Related to SFC Programs Performance specifications related to SFC programs are shown in table 3 1 below Table 3 1 Performance Specifications Related To SFC Programs Max 28k Max 60k Max 92k Max 124k mae of files 1 file number of scannable files D RI Number of blocks of blocks Max of 320 blocks 0 to 319 Max of 8192 steps for ali blocks Number of SFC steps 512 steps per block SFC program Number of concurrently active Max of 1280 steps for all blocks steps 256 steps per block including HOLD steps Number of operation output Max of 4k steps per block sequence steps no per step restrictions Number of transition conditions Max of 4k steps per block sequence steps no per transition condition restrictions All blocks break Batch break setting for all blocks Break
122. s a reset at the block in question e When a reset occurs at the device designated as the SFC informa tion register s block START END device e When a reset step for resetting the step in question becomes active e When the SFC START STOP command SM321 is switched OFF 3 Block STOP processing If a block STOP request is designated by the SFC information register s STOP RESTART bit or by an SFC block STOP instruction processing will occur as follows e STOP status timing A STOP status s established after the block STOP request output occurs and processing returns to the beginning of the block in question e Coil output A coil output OFF or HOLD status will be established depending on the output mode setting see Section 4 7 3 at the time of the block STOP designated in the SFC operation mode However an ON status will be maintained for coil outputs which were switched ON by the SET instruction 4 27 Resetstep R A reset step is a step which designates a forced deactivation of another specified step operation output 1 When the reset step is activated a specified step within that block will be reset deactivated If 999 is designated as the step to be reset all coil HOLD operation HOLD without transition check and operation HOLD with transition check steps within that block will be reset 2 In addition to designating the step to be reset 1 step or all HOLD steps a reset step possesses the same
123. sfied and a will be established the post transition STOP will occur first time processing ti he specified e If multiple steps are active the occurs att i STOP will occur at each of the block and a STOP will steps in sequence as their occur transition conditions are satisfied 4 SFC PROGRAM CONFIGURATION pg M 2 1 The coil HOLD step becomes inactive the first time processing occurs at the block in question following the STOP request 2 During SFC program execution the M325 special relay is switched OFF when the oft output is OFF and is switched ON when the coil output is ON in accordance with the parameter setting The M325 special relay can also be switched ON and OFF by the user program without regard to the parameter setting 3 Processing of the block is restarted from the step where the STOP occurred when the block STOP RESTART bit is switched OFF at the sequence program or peripheral device An operation HOLD status step with transition check or without tran sition check which has been stopped will be restarted with the operation HOLD status in effect A coil output HOLD step cannot be restarted after being stopped as it is deactivated at that time 4 Execution of PLS and 3P instructions after a block STOP has been canceled varies according to the ON HOLD or OFF all OFF status of the SM325 special relay ON operation output HOLD at block STOP OFF all OFF ON Not executed SM325 OFF
124. sition to step in active block P When a START request for a block which is already started is executed by the SFC control block START instruction SET BLm or by the SFC information register s block START END bit being switched ON the START request will be ignored and processing of the SFC program will continue as is 4 75 4 SFC PROGRAM CONFIGURATION MELSEC OnA 4 7 6 Operation mode at transition to active step double step START This mode setting designates the operation mode which is to be effective when a follow up function such as an operation HOLD step with transition check is used to execute a transition to a step which is already active 1 Settings and corresponding operations A PAUSE WAIT or TRANSFER setting can be designated The operations resulting from these settings are shown below e A CPU operation error BLOCK EXE ERROR occurs and CPU operation is stopped es All Y outputs switch OFF e CPU operation continues and a WAIT status is established when the transition condition is satisfied The WAIT status continues until the START destination step is deactivated e A step range can be designated for the STOP setting PAUSE eA step range can be designated for the WAIT e If a transition WAIT occurs the previous step is setting deactivated the output is switched OFF and the operation outpu
125. step is automatically started activated when the preceding transition condition is satistied Step START by SFC Condition diagram symbol d I 8 TRANH EE START occurs when transition condition is satisfied e Basic SFC program operation e Using an SFC control Instruction a specified step is forcibly started from an SFC program step operation output or from another sequence program H Jumps to other blocks are possible Condition l e if the block where the specified destination pte a fide E SET i Sn step is located is inactive a forced block START will occur n is the step No e When multiple initial steps exist a selection Condition START will occur m is the block No n is the step No 2 Operation at double step START When a double step START occurs for a step which is already active operation varies according to the START method as shown below a Double START by SFC diagram symbol Operation varies according to the transition to active step block parameter setting for the block in question e When PAUSE setting is designated duis atc bck a e MR AA RR RA A CPU operation error occurs and CPU operation is stopped e When WAIT setting is designated Qu a eut cate ok es The previous step is deactivated and a WAIT status is established The transition occurs when the transition destination step becomes inactive Transition destination step is reactivated
126. t will not be executed e CPU operation continues the transition occurs and the previous step is deactivated and absorbed by the transition destination step E Active step Condition satisfied TRANSFER default Active step Condition satisfied 2 Transition to HOLD step by double START The following table shows the transition procedure for transitions to coil HOLD steps operation HOLD steps with transition check and opera tion HOLD steps without transition check which occur when the double START condition is satisfied These transitions occur without regard to the settings described at item 1 above e The TRANSFER setting applies to all operations regardless of the setting e At coil HOLD steps aasi The operation output is restarted and a transition condition check begins e At operation HOLD steps without transition check ids A transition condition check begins e At operation HOLD steps with transition check M Operation continues as is es Following the double START execution of all subsequent steps where transition conditions are satisfied will occur according to the step attributes PAUSE WAIT TRANSFER Active step Transition condition satisfied Coil HOLD step or operation output step without transition check Active Transition condition is checked No transition condition check 4 SFC
127. tart STOP cancel Step START change Active step forced transition Forced transition i cancel STOP timing at block STOP request E RE Function eA check occurs to determine if a specified Program is being executed When the designated time period beginning from Time check instruction TIMCHK 1 2 D the point when a specified condition is satisfied glapses the designated output device is JL Switched ON siu 8 Block Step EH en H By Block ios By SEC Controll Information Instruction Block eseu START END bit SET BLm Sn ON j UBleck c POR RE E STARTIEND bit Hi icis Li ORE Block STOP RESTART PAUSE BLm Ke bit ON L Block E EE STOP RESTART _ RSTART BLm bit OFF riche PR AEE noe No register at biock erop lr EF s only SCHG Sn SET TRn J SET BLMTRn RST pn RST BLm n Spe by block STOP mode bit d b immediate itimediate STOP or STOP re STOP m nee after transition m 2E condition is satisfied APPENDICES 4 SFC Program Specifications Max 58K bytes A3N A3A A3U A4U Max 124K bytes Capacity main program only Q4ACPU Number of blocks Max 256 blocks Max 320 blocks Max of 8192 steps total for all blocks max of 512 steps per block SFC program Number otbranchos Maxotaa y an Max of 1280 steps totai f
128. the P 9 initial step when another START Blocks 1 to 319 request occurs for that block Block 0 4 SFC PROGRAM CONFIGURATION Ee ee oe ee Related Instructions a SFC control instructions e Block START instruction SET BLm block END instruction AST U See Section 4 4 6 b SFC diagram symbols e Block START step Bn Bn See Sections 4 2 8 S and 4 2 9 4 SFC PROGRAM CONFIGURATION Sg EE nA 4 5 2 Step transition bit The step transition bit performs a check to determine if the transition condi tion for the current step has been satisfied 1 After the operation output at each step is completed the step transition bit automatically switches ON when the transition condition for transi tion to the next step is satisfied 2 Atransition bit which is ON will automatically switch OFF when processing of the block in question occurs again Example Step transition bit M1 ON TT M1 OFF te nna e f o e Ei o o NO 3 E LG S 2 aS 29 az a2 g ag ZS 2 oS Ki os 5 o e S 2 o 9 o e EI oe as og 8 os o6 z o ZS o 3 P S t c z c e Block n o S x s e S m P 5 E S EP 5 amp 2 P g a o a 6 a o 8 D c co o amp E 5 Fi 5 c i c o o o 5 o S o o c o eg v 2 L3 c EI S e 2 ke c ke c T pe w ben H m 3 If a continuous transition is designated continuous transition bit ON the transition bit will remain ON during the next
129. the STOP request a coil output HOLD status will be established the first time processing eccurs at the specified block and a STOP wii occur e After the STOP request the coil Coil output in outu output HOLD status will be e After the STOP request a HOLD Co P established when the transition coil output HOLD status HOLD OM condition is satisfied and a STOP will be established the post transition will occur first time processing STOP occurs at the spacified block and a STOP will occur e if multiple steps are active the STOP will occur at each of the steps in sequence as their transition conditions are satisfied e The coil HOLD step becomes inactive the first time processing oc curs at the block in question following the STOP request 6 SFC PROGRAM EXECUTION EE 6 3 2 Restarting a stopped block The methods for restarting a block which has been temporarily stepped during SFC program processing are described below 1 Restarting block processing The methods for restarting a block which has been temporarily stopped are shown below e Processing of the specified block is restarted by an SFC control instruction at a step operation output or sequence program outside the stopped block Restart by SFC e Convenient for returning to automatic i operation when the manual control END control instruction Condition signal is output at the temporary STOP m is the block No e A specified b
130. the block becomes active all steps will be executed in a single scan Block END processing then occurs and the block is deactivated SM400 CTran e With continuous transition OFF setting When the block becomes active step execution occurs in a 1 step per scan format Block END processing occurs at the 3rd scan and the block is SM400 deactivated Hiran 5 SFC PROGRAM PROCESSING SEQUENCE E w w G amp S 1 Transition processing for continuous transition ON setting The SFC program processing procedure tor a continuous transition ON setting is shown below 1 Active step n ladder operation HQH xo 2 Transition condition satisfied unsatistied check Hia n 1 When transition condition When transition condition H Y11 is unsatisfied is satisfled 3 END processing 3 The actve step n is deactivated and the coil where the OUT Instruction is ON is switched OFF if other blocks exist subsequent the block in question END processing wii be executed after those blocks have been processed 4 Step ni is activated and its ladder operation occurs 4 Ladder processing for the same step n as that at the previous scan 5 Transition condition satisfied unsatisfied check 6 Subsequent processing is executed in a continuous manner up to a step with an unsatisfied transition condition 7 END processing If other blocks exist subsequent the block In question END proc
131. tion condition is constantly monitored with transition to the next step occurring when the condition is satisfied 1 The operation output status of each step n varies after a transition to the next step n 1 depending on the instruction used e When the OUT instruction is used excluding OUT C After a transition to the next step n 1 step n becomes inactive resulting in an automatic output OFF in accordance with the OUT instruction The same processing occurs for timers with the present value be ing cleared and the contact switched OFF When transition condition m be Example xi comes satisfied at the step n sten zm l v operation output where YO is ON Transition in accordance with the OUT in condition m struction YO is automatically Step n 1 switched OFF e When a SET Basic or Application instruction is used Even though step n becomes inactive after a transition to the next step n 1 the ON status or present value is held If switched OFF an RST instruction etc will be required to exe cute another step Example When transition condition m be X2 comes satisfied at the step n Step m j H operation output where YO is ON Transition by SET instruction the YO ON condition om status will be maintained even af Step nei ter the transition to step n 1 4 SFC PROGRAM CONFIGURATION BUS del aad v n Ee When the OUT C J instruction is used If the exe
132. tions will be executed at once within a single scan e Continuous transition OFF ande ede Ua Steps are executed in a 1 step per scan format Example Sample program processing Block n e Continuous transition ON S When the block is activated all steps are proc essed within the same scan The block is then FE Cl deactivated at the block END SM400 e Continuous transition OFF Hi Cian When the block is activated steps are proc essed in a 1 step per scan format The block SM400 END step is processed at the 3rd scan and the m Cran block is deactivated 2 A continuous transition can be designated for individual blocks by the continuous transition bit ON OFF setting or for all blocks using the batch setting special relay As shown below the continuous transition operation ON OFF varies according to the continuous transition bit and special relay SM323 setting combination dy cn a EE ER Bit SFC Program Operation Operation occurs without Ld Continuous transition bit OFF continuous tranehion No continuous transition bit setting Continuous transition bit ON e No continuous transition bit setting e Continuous transition bit OFF Operation occurs with continuous transition Operation occurs without continuous transition 4 SFC PROGRAM CONFIGURATION MELSEC QnA To shorten tact time a continuous transition ON status is recommended in order to speed up the step transitions T
133. tive step double START operation mode see Section 4 7 3 The settings are pause wait transfer with step transition 4 SFC PROGRAM CONFIGURATION MS ne 4 3 6 Precautions when creating sequence programs for operation outputs steps and transition conditions The points to consider when creating operation cutput step and transition condition sequence programs are described below 1 Sequence program for operation outputs steps a Step sequence program expression format A step sequence program using the ladder expression format is shown below Output Condition can be omitted instruction only at the first ladder block instruction The lack of a sequence program at a given step will not result in an error In such cases no processing will occur until the transition condition immediately following the step in question is satistied b Sequence program capacity A step s sequence program capacity is as follows e Max of 4K sequence steps per step e Max of 4K sequence steps per block 4 27 4 SFC PROGRAM CONFIGURATION bees c Instructions used All instructions except for those shown below may be used Prohibited Instruction List Instruction ein eem Master control lou CJ P Leef Condition Condition jump o scs scJ PO Delay jump Lu o JMP PC Unconditional jump ms mem mem ae se MINNIE NER epp Leon Jump to END une TI aranana er er O peeso manoa E8188 wes ea 9 emoa
134. umptive START format are described below 1 Resumptive START setting procedure An SFC program resumptive START format can be designated at the SFC program START mode item of the SFC parameter setting 2 Block operation status resulting from SFC program START mode setting The block operation statuses which correspond to the SFC program START mode settings SFC parameter setting are shown below SFC Program START Mode SM322 Status Operation Status Setting Initial START e Initial START default ON OFF e When auto START ON is designated for block o t seats Block O is executed from its initial step OFF e When auto START OFF is designated for block 0 O orFF In The block started by the SFC control block START instruction is Resumptive executed from its initial step START e Resumptive START A resumptive START is executed from the previous active status 2 1 When CPU STOP RUN switching occurs SM322 is switched OFF or ON in accordance with the parameter setting OFF if an initial START is designated and ON if a resumptive start setting is designated 2 The block O auto START ON OFF setting is designated at block 0 START condition item of the SFC parameter settings 8 The previous active status is the status which was active when SM321 was switched OFF during SFC program execution or when a CPU reset or power OFF occurred 6 2 6 SFC PROGRAM EXECUTION A EE 1 Wh
135. until the continuous transition occurs and switches OFF when a 1 step transition is completed A continuous transition for the step in question can be prevented by designating an AND condition for SM324 e Designates the operation output which occurs when the block is stopped When ON The coil output ON OFF status at the step being executed when the block is stopped is maintained HOLD When OFF All coil outputs are switched OFF Operation outputs which occur in response to the SET instruction are maintained HOLD without regard to the SM325 ON OFF status APP 2 System inttial value System initial value User System initial value User System for instruction execution System initial value User APPENDICES AU CEA We 7 ON OFF e Switches ON when a status check is Status check SFC OFF Disabled completed atan SFC program E information ON lend l When ewitched ON information is stored at D816 and SD817 System status change OFF Noi ready e Switches ON when a ready status is Step trace ready etatus ON Ready established after step trace registration e Designates the step trace STARTYSTOP status When ON Step trace function is started Step trace START ON ag When OFF re trace function is pped If switched OFF during a trace execution the trace operation is stopped YER m ON when step trace execution is in System fac
136. urs if the RET instruction is exe cuted prior to the XCALL instruc tion l e Error No 4213 occurs if the number of nestings ex ceeds 16 4 SFC PROGRAM CONFIGURATION MELSEC QnA Programo Akne Deng instructions Other SFC Program P udis id Transition Condition Bum TRA id Transition Lei 4 4 14 Time check instruction TIMCHK At expansion SFC and other columns m represents the block No and n represents the step transition condition No I mex 9 8 16 Function 1 Measuresthe condition device ON time and switches a specified device ON when the condition device remains ON longer than the designated time setting 2 The following devices are used for this instruction Condition I Device switched ON at time up Device where measurement set value is stored Device where measured present value is stored Measurement execution condition 3 When the measurement execution condition switches ON the device switched ON by the measured present value and the time up status switches the monitor execution condition OFF Or if the transition condition is satisfied the status is held When the present value is cleared to 0 or the device which was ON switches OFF the measure ment execution condition will either switch ON again or the program will be reset Program Examples 1 The following is a program where the X0 ON time setting is 5 seconds with the present value stored
137. ve but transition conditions 2 and 5 are not satisfied Number of active steps 2 steps 2 amp 6 Transition conditions 2 transition conditions 2 amp 5 Number of steps with satisfied transition conditions b When transition conditions are satisfied e f steps 2 and 6 are active transition conditions 2 and 5 are satisfied and transition conditions 3 and 6 are not satisfied With continuous transition Number of active steps 2 steps 2 amp 6 Number of transition conditions rr 2 transition conditions 2 amp 5 Number of steps with satisfied transition conditions with continuous transition ee dd tte eade at 2 steps 2 amp 6 Number of active steps 4 steps 2 3 6 7 Number of transition conditions shisha iad xe As esr Sages 4 transition conditions 2 3 5 6 Number of steps with satisfied transition conditions Seen AT NR erede aye Soe ved V 2 steps 2 amp 6 e f steps 2 and 6 are active and transition conditions 2 3 6 7 are all satisfied without continuous transition Number of active steps 2 steps 2 amp 6 Number of transition conditions EE 2 transition conditions 2 amp 5 Number of steps with satisfied transition conditions with continuous transition PEE 2 steps 2 amp 6 Number of active steps 6 steps 2 to 4 amp 6 to 8 Number of transition conditions TE 6 transition conditions 2 to 4 amp 5 to 7 Number of steps with satisfied transition
138. when the RST BLm Sn instruction is used to deactivate all steps at a specified block A specified block is ended by forcing the block START END bit OFF from a program or a peripheral device The block START END bit Is designated at each block as an SFC information register Block START by SFC information register e Convenient for cycle stops at automatic operations etc Multiple END steps are possible within a single block Convenient for executing a forced STOP at emergency stops etc without regard to the operation status e Convenient for debugging and test operations because block processing can be ended from a peripheral device without requiring a program 1 A forced end to block processing is possible using a method which is different from that used to start the block Example 1 A block started by an SFC diagram symbol B amp can be ended by an SFC control instruction RST BLm 2 A block started by an SFC control instruction SET BLm can be ended by forcing the SFC information register s block START END bit OFF 2 After block END processing is completed the block can be restarted as shown below After block processing is When the block O START ended processing is condition is designated as k a started automatically from auto START ON the initial step When the block 0 START e After block processing is condition is designated as ended the block remains auto S
139. x 2 Example Number of created programs 30 Number of created steps 1200 SFC program capacity 20K sequence steps 30 x 20 1200 x 40 20K x 2 89560 uS 89 56 ms e No system processing time is required when switching from a scan status to a WAIT status 5 SFC PROGRAM PROCESSING SEQUENCE Sn Ae ee A 5 1 3 SFC program for program execution management This SFC program can be used to manage the program execution se quence when multiple program file switching is required Unlike scan execution SFC programs this program execution management SFC program can consist of only 1 file with 1 block 1 Program execution management SFC program creation procedure a Number of files and blocks Only 1 file with 1 block is possible when created as a scan execution program b Usable instructions Except for block START step B amp symbols all SFC diagram sym bols steps and sequence instructions for transition conditions used at normal SFC programs may be used e A BLOCK EXE ERROR error No 4621 will occur if the block START step B amp symbols are used 2 Execution procedure The program is started automatically when registered as a scan execu tion file After block END processing the initial step is reactivated and processing is repeated e The setting which determines whether a program is a program execution management SFC program or a normal SFC program is designated with the SWOIVD
140. y to be switched ON only after the programmable controller power has been switched ON Accidents caused by erroneous outputs and motion could result if the external power supply is switched ON first When a data link communication error occurs the status shown below will be established at the faulty station In order to ensure that the system operates safely at such times an interlock circuit should be provided in the sequence program using the communication status information Erroneous outputs and operation could result in an accident 1 The data link data which existed prior to the error will be held 2 All outputs will be switched OFF at MELSECNET Il B 10 remote UO stations 3 At the MELSECNET MINI S3 remote UO stations all outputs will be switched OFF or output statuses will be held depending on the E C mode setting For details on procedures for checking faulty stations and for operation statuses when such errors occur refer to the appropriate data link manual System Design Precautions e Do not bundle control lines or communication wires together with main circuit or power lines or lay them close to these lines As a guide separate the lines by a distance of at least 100 mm otherwise malfunctions may occur due to noise Cautions on Mounting Use the PC in an environment that conforms to the general specifications in the manual Using the PC in environments outside the ranges stated in the gener
Download Pdf Manuals
Related Search
Related Contents
Brilliance-DMX Decoder specification (Wide Low Voltage) 和泉市立青少年の家・槇尾山森林浴コース(PDF Bryant Furnace NAHA003WK.01 User's Manual User Manual 大韓民国電波法に適合しました。 2004 300M Owner`s Manual - Dealer e 取扱説明書ダウンロード LB61 - Manuale d`uso Manual de Instrucciones Copyright © All rights reserved.
Failed to retrieve file