Home

SV13/22Programming Manual (Motion SFC

image

Contents

1. 5 OPERATION CONTROL PROGRAMS FIFS 5 13 5 Same data block transfer FMOV FMOV D S n Number of basic steps 6 Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit i 16 bit 32 bit i Calculation a p R floating Coasting g floating i conditional conditional integer integer i integer integer type j expression 4 point timer point expression expression type type L type F type K H K H L type K o fom o o o ome o o os so Tl I Tl I O Usable Note 1 Refer to the Section 1 2 5 for the correspondence version of the Motion CPU and the software Setting data Setting data Data type of result Transfer destination device starting No Device No which transfer data or data to be S transferred are stored Number of words to be transferred Functions 1 The data specified with S or contents of device are transferred a part for n words of data to the device specified with D 2 The devices that may be set at D S and n are shown below Setting data f Note 4 Note 3 Note 3 E The Lo Lo cannot be specified indirectly Note 2 Specify a multiple of 16 as the device number of bit data Note 3 PX PY cannot be set Note 4 Sp
2. lt PLC CPU gt lt Motion CPU gt i PLC program i Motion SFC program Mechanical system program EDIE Drive module i i i gt Transfer _ d Virtual servomotor i sP Sros L i Transmission module j i ie gt H Start request Specification of starting M2044 on virtual mode instruction of program No i i the Motion i i _ Servo program SFC program i i K100 virtual 1 VF hai ae a eee anneal ek oe Axis 1 SE E Note 1 The Motion SFC program can also be started i D C5 automatically by parameter setting Combined D 0 PLS s END eas Peay Sav tegen ener Output module oS eee Positioning control parameters System settings Fixed parameters Servo parameters Parameter blocks Limit switch output data Home position return data is not used since home position return cannot be performed in virtual mode 3 Y 3 Y Home position return is executed in real mode e JOG operation in virtual mode is controlled using the JOG operation data set by drive module parameters Servo amplifier Servo amplifier 4 4 y Servomotor Servomotor 2 STRUCTURE OF THE MOTION CPU PROGRAM MEMO 3 MOTION DEDICATED PLC INSTRUCTION 3 MOTION DEDICATED PLC INSTRUCTION 3 1 Motion Dedicated PLC Instruction 1 The Motion dedicated PLC instruction which can be executed toward the Motion CPU which installed a SV13 SV22 operating system software for the Motion SFC is shown below S P SFCS
3. Selective coupling IFEm Selective branch IFBm 1 Parallel coupling PAEm Parallel branch PABm 1 JMP IFEm IFEm PABm PATI CALL Fn JMP PAEm PAT2 CALL Fn JMP PAEm PAEm JMP PAEm PAEm IFBm IFT1 SFT Gn JMP IFEm IFT2 SFT Gn JMP IFEm IFEm JMP IFEm IFEm IFBm 1 IFT1 SFT Gn JMP IFEm 1 IFT2 SFT Gr JMP IFEm 1 IFEm 1 JMP PAEm PAEm PABm 1 PATI CALL Fn JMP PAEm 1 PAT2 CALL Fn JMP PAEm 1 PAEm 1 e The selective coupling point and parallel branch point can be the same Note that in the Motion SFC chart this type is displayed in order of a selective coupling a parallel branch as shown on the left In this case a pointer Pn cannot be set between the selective coupling point IFEm and the parallel branch point PABm The parallel coupling point and selective branch point can be the same Note that in the Motion SFC chart this type is displayed in order of a parallel coupling a selective branch as shown on the left Execution waits at the parallel coupling point and shifts to the selective branch In this case a pointer Pn cannot be set between the parallel coupling point PAEm and the selective branch point IFBm The selective coupling point and selective branch point can be the same Note that in the Motion SFC
4. APP 19 APPENDICES g No 150 Programming operation Programming operation gt G150 II OFF to ON detection of PX3 G151 G152 Did you turn on PX4 Did you finish a programming operation PX4 Imode PX3 turns on MO in on when M1 last time PX2 PX1 Icondition of PX3 is off RST MO Edge OFF to ON SET MO PX3 M1 detection of the bit Condition was stored in M1 last time device PX3 lof PX3 Condition was RST M1 memorized in M1 SET M1 PX3 last time and OFF When MO is ON OFF to ON of PX3 is to ON of PX3 was detected it transition to the next steps detected MO F150 END 0L 1000000 1 axis positioning address K150 Real Ilset 1 INC 1 2L 2000000 2 axes positioning address Axis 1 1000000 PLS Iiset Speed 500000 PLS s 4L 500000 Positioning speed Positioning address the indirect designation of the speed K151 Real G153 1 INC 2 it waits 1000 ms after the motion control Axis 1 OPLS Icompletion TIME K1000 Axis 2 2PLS Speed 4PLS s K152 Reall 1 INC 1 Axis 2 2000000 PLS Speed 1000000 PLS s G154 Did you turned on 1 axis and 2 axis lin position M2402 M2422 G155 F151 re NOP Waits for the motion control 0L 0L 1 axis positioning address sign i linversion nasa 2L 2L 2 axes positioning address sign linversion D4 4L 4L 2 Pos
5. Errors The abnormal completion in the case shown below and the error code is stored in the device specified with the complete status storing device D2 Complete status Note Error factor Corrective action Error code H 4C00 The specified device cannot be used in the Motion CPU Or it is outside the device range The instruction for the Multiple CPU system which did not be correspond with operating system software of the Motion CPU was executed 4C03 The servo program No to execute is outside the range Confirm a program 0 to 4095 and correct it to a gcoa si Axis No set by SVST instruction is injustice correct PLC There are 33 or more instruction requests to the program Motion CPU from the PLC CPU in S P SFCS S P SVST S P CHGA S P GINT sum table simultaneously and the Motion CPU cannot process them 4C09 CPU No of the instruction cause is injustice Note 0000H Normal 3 MOTION DEDICATED PLC INSTRUCTION The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO 2110 The CPU No to be set by First I O No of the target CPU 16 is specified AT The self CPU is by First I O No of the target CPU 16 is specified Confirm a program 2117 The CPU except the Motion CPU by First I O No of and correct it to a the target CPU 16 is specified correct PLC The instruction be composed of devices except program 4004
6. G170 Did you release a stop Did a thing during servo ON and PX5 turn off 1 axis and 2 axes M2415 M2435 PX5 When servo ON and the outside input signal PX5 for the stop are OFF 1 axis 2 axis stop command are turned off and 1 axis 2 axis continue motion control by turning off an internal relay M100 for the stop F170 F171 It is made to turn on 1 axis 2 axis stop IIA stop is being released stop status The stop is being turned on status command and motion control is made RST M3200 1 axis stop command OFF SET M100 Stop ON to stop by turning on an internal relay RST M3220 2 axes stop command OFF RST M100 Stop OFF SET M3200 1 axis stop command ON SET M3220 2 axes stop command ON M100 for the stop too when either axis turns off servo or when PX5 turns it on APP 30 APPENDICES c No 150 Programming operation Programming operation G151 Did you turn on PX4 and turn loff a stop PX4 M100 K150 Real 1 ABS 2 Axis 1 0 PLS Axis 2 0 PLS Speed 500000 PLS s a G200 Did 1 axis and 2 axes execute Xv WAIT transition which wants to stop substitutes The internal relay M100 for the stop turns off for the AND status The motion control step executed absolute positioning to application with it when to start again after it stops on the way Ipositioning completion M2401 M2
7. 3 9 Interrupt Instruction to The Other CPU S P GINT PLC instruction S P GINT Usable devices Internal devices p MELSECNET 10 Special index System User File direct JO O function Constant register module regeer K H gis A i Bit Word specified device Bit Word ZO UO GO ct oe ee ee en ee ee eee eee ee al a a ee re O Usable A Usable partly Note Setting data n1 to D2 Index qualification possible Oo S oe 2 gz N Instruction Condition Start command SP GINT _4 SP GINT Start command S GINT S GINT Setting data Setting data Data type First I O No of the target CPU 16 n1 Value to specify actually is the following CPU No 1 3EOH CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H 16 bit Interrupt instruction No 0 to 15 binary Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration Note 1 16 bit binary Controls This instruction generates the interrupt to the Motion CPU by PLC program when the execution instruction of S P GINT is started OFF ON The Motion CPU executes the active program operation program status processing of the Motion SFC program set by PLC interruption of the event task at the interrupt generation from the PLC CPU 1 This instruction is always effective regardless of the state of real mode virtual mode mode switching when t
8. 10 4 10 USER FILES 2 When the operation control transition program editor screen Convert is used Online change of the operation control transition program during edit is executed by selecting the Convert key Online change is possible to the operation control transition program during execution A program that the online change was made is executed from the next scan Operation Control Program Transition Program Editor F100 comand C D lt Convert Key ET Y100 X0 1100 oK Cancel Word device description Device description Device Non designated range kaze 64bit integer floating point QIRDI integer ws i a even n even Dataregister Dn DaL DoF f Oto 8191 Linkregister Wn WaL WnF Oto 1FFF Operations for which made the online change to the operation control transition program during execution in the following conditions are shown below Be careful to execute the online change in the following conditions e Online change of the FSn e After completion of online change operation control program is the FSn repeats the operation executed during FSn control program that the online execution in the state of change was made until the waiting for the completion of completion of condition for Gn condition for Gn e Online change of the Gn e After completion of online change program is executed in the the Gn does not transit to the next sta
9. Program examples 1 Program which converts the data of DOL into a signed 64 bit floating point value and substitutes the result to 0F 0F FLOAT DOL 3 2 1 D1 DO e 2 ea Go HFFFFFFFF 5 OPERATION CONTROL PROGRAMS FIFS 5 7 6 Unsigned 64 bit floating point value conversion UFLOAT UFLOAT S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting 16 bit veo floating aona ak conditional conditional integer integer integer integer type expression i int expression expression type type L type K H K H L poin P P type F type K PNG ee o o l a aa H H O Usable Setting data Setting data Data type of result Data which will be converted into unsigned 64 bit S f 64 bit floating point type floating point value Functions 1 The data specified with S is converted into an unsigned 64 bit floating point value 2 If S is a 64 bit floating point type its value is returned unchanged with no conversion processing performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which converts the data of DOL into an unsigned 64 bit floating point value and substitutes the result to 0F 0F UFLOAT DOL 3 2 1 0 D1 DO K4294967295 0
10. _ K iL HFFFFFFFF Unsigned value is K4294967295 5 OPERATION CONTROL PROGRAMS FIFS 5 8 Bit Device Statuses 5 8 1 ON Normally open contact None S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison data Bit device AB Plt Sebit floating Coasting ap oit Sepil floating Calculation conditional conditional integer integer oint finer integer integer type point expression expression expression type type L vae 4 type KH KHD Lod o dl d l d d l d d d d O Usable Setting data Setting data Data type of result Bit device used in bit conditional expression Logical type true false Functions 1 True is returned when the bit device specified with S in a bit conditional expression is ON 1 or false is returned when that bit device is OFF 0 Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which sets M100 when either of MO and XO is ON 1 MO False cue MO CO Fas Moo lt X0 1 True 5 OPERATION CONTROL PROGRAMS FIFS 5 8 2 OFF Normally closed contact Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting 16 bit s 32 bit floating ACHA m conditional conditional integer integer i integer
11. 2 Set the clock data and clock data read request M9028 in the user program 8 MOTION DEVICES b Servo monitor devices 8064 to 8191 Information about servo amplifier type motor current and motor speed for each axis is stored the servo monitor devices The details of the storage data are shown below Axis f No Device No Signal name 8064 to 8067 8068 to 8071 Signal name PE 8072 to 8075 Note 1 Signal description Refresh cycle 8076 to 8079 8080 to 8083 Oe Onid 6 8084 to 8087 __ 256 MR J3 B Servo amplifier 8088 to 8091 257 MR J3 B Fully closed When the servo amplifier power on a 8092 to 8095 loop control Monitor o 8096 to 8099 258 MR J3 B Linear devise 8100 to 8103 0 11 Operation cycle 1 7 ms or less Operation cycle 8104 to 8107 Motor speed x 0 1 r min Operation cycle 3 5 ms or more 3 5 ms 8108 to 8111 3 8112 to 8115 Note 1 The value that the lowest servo monitor device No was added 0 1 on each axis is shown 8 MOTION DEVICES 8 2 Coasting Timer FT Motion device Coasting timer FT Number of points Specification 1 point FT Data size 32 bit point 2147483648 to 2147483647 Latch No latch Cleared to zero at power on or reset a count rise is continued from now on Usable tasks Normal event NMI Access Read only enabled Timer specifications 888s timer Current value
12. The selective coupling point can be the same as the coupling point of a parallel coupling for selective branch parallel branch Note that in the Motion SFC chart this type is displayed in order of a parallel coupling a selective coupling as shown on the left In this case a pointer Pn cannot be set between the parallel coupling point PAEm and the selective coupling point IFEm After a parallel branch a selective branch can be performed The parallel coupling point can be the same as the coupling point of a selective coupling for parallel branch selective branch Note that in the Motion SFC chart this type is displayed in order of a selective coupling a parallel coupling as shown on the left In this case a pointer Pn cannot be set between the selective coupling point IFEm and the parallel coupling point PAEm 4 MOTION SFC PROGRAMS representation Selective branch Selective branch Selective coupling Selective coupling Parallel branch Parallel branch Parallel coupling Parallel coupling CALL Kn IFBm IFT1 SFT Gn IFBm 1 IFT1 SFT Gr JMP IFEm 1 IFT2 SFT Gn JMP IFEm 1 IFEm 1 JMP IFEm IFT2 SFT Gn
13. e c if e G G e I F F F F F F F PT lined 124 05 176 00 Q172HCPU us Note Varies greatly with the started or cleared program Long processing time may cause a Motion CPU WDT error or servo fault Especially for the Motion SFC programs run by event NMI tasks take care so that the processing time will not be too long APP 8 APPENDICES APPENDIX 2 Sample Program APPENDIX 2 1 Program example to execute the Multiple CPU dedicated instruction continuously This is the program example which publishes the instruction continuously toward the same Motion CPU in the Multiple dedicated instruction toward the Motion CPU When an instruction cannot be accepted even if it is executed it becomes No operation The following is program example which repeats reading data for 10 points from DO of the Motion CPU installing the CPU No 2 to since D100 of the PLC CPU and the data for 10 points from D200 of the Motion CPU to since D300 of the PLC CPU by turns continuously during X0 is ON Make a circuit to execute the next S P DDRD instruction after the device which it is made to turn on by the instruction completion of the S P DDRD instruction execute 1 scan turns it on lt Example gt SM400 K10 D251 X0 M2 X0 M1 Ni MO M10 m H3E1 D50 Do D100 M10 M50 M50 M10 cms oer RST mo RST M50 M1 M pP DDRO H3E1 D250 D200
14. is decimal When target is the CPU No 2 address O wm 7 lowest rank bit 30H 48 toward executing instruction ETE U3E1 G48 0 from CPU No 1 The lowest rank bit 31H 49 toward executing instruction 31H 49 U3E1 G49 0 from CPU No 2 The lowest rank bit 32H 50 toward executing instruction 32H 50 U3E1 G50 0 from CPU No 3 The lowest rank bit 33H 51 toward executing instruction 33H 51 U3E1 G51 0 from CPU No 4 b To self CPU high speed interrupt accept flag from CPUn turn ON OFF at the executing instruction when the Multiple CPU dedicated instructions are executed to the same CPU from one PLC CPU Therefore when each instruction is executed only once at approval the executing condition it is necessary to take an interlock by internal relay M10 and so on besides To self CPU high speed interrupt accept flag from CPUn 2 Execution of the Motion dedicated PLC instruction a Motion dedicated PLC instruction can be executed with fixed cycle execute type PLC and interrupt PLC However as for a complete device the program turned on according to fixed cycle executed type PLC and program type scan or low speed executed interrupt PLC is different b One Motion CPU can be accepted max 32 instructions simultaneously from multiple other CPUs Except S P GINT instruction If 33 instructions or more are executed Motion CPU returns the complete status 4C08 error As Motion CPU can be accepted up to 32 instructions
15. 1 The data specified with S1 and the data specified with S2 are compared and the result is true if they are not equal 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before comparison is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which compares whether 0 and DO are unequal or not 0 DO 0 I True lt q po 2 5 OPERATION CONTROL PROGRAMS FIFS 5 11 3 Less than lt S1 lt S2 Number of basic steps Usable data Usable Data Setting 64 bit i 64 bit Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer 5 i integer integer type 5 expression 2 point expression expression type type L type K H K H L type K ae el a a a l a aaa aE an an ae ol a O Usable Setting data Setting data Data type of result S1 ee S2 Data which will be compared Logical type true false Functions 1 The result is true if the data specified with S1 is less than the data specified with S2 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before comparison is performed Errors 1 An operation error will occur if e S1 or S
16. 4 MOTION SFC PROGRAMS Instructions Always pair a transition with a motion control step one for one If the step following WAITON WAITOFF is not a motion control step the Motion SFC program error 16102 will occur and the Motion SFC program running will stop at the error detection An error will not occur if the jump destination immediately after WAITON WAIT OFF is a motion control step Left below A pointer may exist immediately after WAITON WAITOFF Right below ON MO Gn fa Kn Kn If the servo program specified with a motion control step could not be started due to a major minor error the Motion SFC program continues running and execution shifts to the next independently of the WAITON WAITOFF bit device status To stop the Motion SFC program at error detection provide an error detection condition at the next transition transition condition The following instructions can be used in the motion control step used combining the WAITON WAITOFF Linear interpolation control circular interpolation control helical interpolation speed switching control position follow up control constant speed control and high speed oscillation 2 Combination with operation control step Operations At an operation control step both Shift and WAIT perform the same operation and after Gi Cor executing of the operation control program Fn transits to the next step by formation of transition
17. 5 9 3 Device output DOUT DOUT D S Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit f Calculation a 7 i R floating Coasting n floating i conditional conditional integer integer 5 i integer integer type j expression point expression expression type L type K H O Usable Note 1 PX and special relay cannot be used at D Note 2 Range including M2000 to M2127 cannot be used at D Setting data sai data Data type of result Output destination bit data Batch bit ee Output source data Functions 1 The data specified with S is output to the bit data specified with D 2 Specify a multiple of 16 as the device No of the bit data specified with D 3 If the type of S is a 16 bit integer type 16 points of the S data starting at the least significant bit are output in order to the bit devices headed by the one specified with D 4 If the type of S is a 32 bit integer type 32 points of the S data starting at the least significant bit are output in order to the bit devices headed by the one specified with D Errors 1 An operation error will occur if e D or S is an indirectly specified device and its device No is outside the range e D is an indirectly specified device and its device No is not a multiple of 16 Program examples 1 Program which
18. CALL Fr JMP IFEm IFEm SFT Gn CALL Kn PABm PAT1 SFT Gn PABm 1 PAT1 CALL Fr JMP PAEm 1 PAT2 CALL Fn JMP PAEm 1 PAEm 1 JMP PAEm PAT2 CALL Fn CALL Kn JMP PAEm PAEm SFT Gn After a selective branch a selective branch can be performed The two selective coupling points for selective branch selective branch can be the same Note that in the Motion SFC chart this type is displayed in order of a selective coupling gt a selective coupling as shown on the left In this case a pointer Pn cannot be set between the selective coupling point IFEm 1 and the selective coupling point IFEm After a parallel branch a parallel branch can be performed A parallel branch can be nested up to four levels The two parallel coupling points for parallel branch parallel branch can be the same Note that in the Motion SFC chart this type is displayed in order of a parallel coupling a parallel coupling as shown on the left In this case a pointer Pn cannot be set between the parallel coupling point PAEm 1 and the parallel coupling point PAEm 4 MOTION SFC PROGRAMS representation Selective coupling IFEm Parallel branch Parallel coupling PAEm Selective branch
19. ID0000 to D0639 640 words D000 to CPU No 1 of the Qn H CPU BMOV W100 DO K640 ISpecial devices D9000 to D9015 16 words 1D640 to CPU No 1 of the Qn H CPU W380 D9000 W381 D9005 W382 D9008 W384L D9010L W386L D9012L W388L D9014L Special registers D9182 to D9197 I 16 words ID656 to CPU No 1 of the Qn H CPU W38AL D9182L W38CL D9184L W38EL D9186L W390L D9188L W392L D9190L W394L D9192L W396L D9194L W398L D9196L 1 Each axis status M2400 to M3039 for 32 axes transferred to WO to 2 Common devices M2000 to M2064 transferred to W28 to 3 Special relay M9000 to M9015 transferred to W2C to Automatic refresh of the between Multiple CPU and WO to of Q173HCPU CPU No 2 sets it up to have refresh by M2400 to of Qn H CPU CPU No 1 therefore the condition of Q173HCPU CPU No 2 can be grasped with Qn H CPU of the CPU No 1 by monitoring the following device Devices of QnHCPU Correspond with devices CPU No 1 of Q173HCPU CPU No 2 M2400 to M3039 M2400 to M3039 M3040 to M3103 M2000 to M2064 M3104 to M3119 M9000 to M9015 Note Refresh does data for 32 axes by this sample example number of refresh points is made a necessary minimum corresponding to the system for processing time shortening 1 Each monitor devices DO to D639 for 32 axes transferred to W100 to 2 Special register D9000 to D9015 transferred to W380 to 3 Speci
20. e gt e gt o gt o gt e gt e gt e gt Q o Q wo ow 9 9 Q wo wo Q Q Q Q Q wo wo wo wo wo N N N gt O O O O N O a A wo N o gt a A wo N execution error illegal 11 5 11 ERROR CODE LISTS Table 11 5 Operation control transition execution errors 16300 to 16599 continued Error factor Bit device output OUT execution error Error code e The device No which indirectly specifies D is illegal Signed 16 bit integer value conversion SHORT execution error Unsigned 16 bit integer value conversion USHORT execution error The S data is outside the signed 16 bit integer value range The S data is outside the unsigned 16 bit integer value range Signed 32 bit integer value conversion LONG execution error Unsigned 32 bit integer value conversion ULONG execution error Tangent TAN execution error The S data is outside the signed 32 bit integer value range The S data is outside the unsigned 32 bit integer value range e S is 90 180 n n is an integer Arcsine ASIN execution error e S is outside the range of 1 0 to 1 0 e S is a negative number Any digit of S has a value other than 0 to 9 Arccosine ACOS execution error Square root SQRT execu BCD BIN conversion BIN execution error BIN BCD conversion BCD execution error ion error The S value is outside the range where BI
21. 1 OVERVIEW Generic term Abbreviation f i Abbreviation for MELSECNET H module Ethernet module CC Link module Intelligent function module i a Serial communication module Note 1 Q172EX can be used in SV22 Note 2 SSCNET Servo System Controller NETwork Note 3 Teaching unit can be used in SV13 For information about the each module design method for program and parameter refer to the following manuals relevant to each module Reference Manual Motion CPU module Motion unit Q173HCPU Q172HCPU User s Manual PLC CPU peripheral devices for PLC program design I O f Manual relevant to each module modules and intelligent function module Operation method for MT Developer Help of each software e Multiple CPU system configuration e Performance specification Q173HCPU Q172HCPU Motion controller Design method for common parameter Programming Manual COMMON e Auxiliary and applied functions common SV13 SV22 e Design method for positioning control program in the real mode Q173HCPU Q172HCPU Motion controller SV13 SV22 e Design method for positioning control Programming Manual REAL MODE parameter SV22 e Design method for mechanical system Q173HCPU Q172HCPU Motion controller SV13 SV22 Virtual mode program Programming Manual VIRTUAL MODE 1 OVERVIEW 1 2 Features The Motion CPU and Motion SFC program have the following features 1 2 1 Features of Motion SFC programs 1 Since a prog
22. 4 1 2 3 Operation control transition Control specifications cccececceeecceeeceeeeeeeeeeeeeeeeeeeeeeeeeeeteaeeeseetaees 1 6 1 2 4 Differences Between Q173HCPU Q172HCPU and Q173CPU N Q172CPU N neee 1 10 1 2 5 Restrictions by the Version v cccccceccessedecceesceeaceeaedeaeeuaedneduaeduaeduaedeaedbaedeaesbaedbaeduae ia i ia 1 11 1 2 6 Positioning dedicated devices special relays special registers eeceeeeeeeeeeeeeeeeecneeeereeeeeateeas 1 12 2 STRUCTURE OF THE MOTION CPU PROGRAM 2 1to2 4 2 1 Motion Control in SV13 SV22 Real Mode ceceeeceeeceeeeeeeeeeeeeeeeeeeeeeaeeeaeesaeeeaeeeaeeeseeeaeesaeesaeesaeeeaeenteeaeeeas 2 2 2 2 Motion Control in SV22 Virtual Mode 0 0 ceeeecceeceeeeeeeeeeeeeceeeeaeesaeesaeeeaeeseesaeeseeseeseesieesieesieesieeieesieeeeee 2 3 3 MOTION DEDICATED PLC INSTRUCTION 3 1 to 3 48 3 1 Motion Dedicated PLC IMStruction arenie 3 1 3 1 1 Restriction item of the Motion dedicated PLC instruction oo eeeeeeeeeeeeeeeeeeeeeeeeeeeeneeeeeeeeeeeeas 3 1 3 2 Motion SFC Start Request from The PLC CPU to The Motion CPU S P SFGS PLGsinstruction S P SECS ae re rae apts dee aa a E Re ENARE eara E e 3 8 3 3 Servo Program Start Request from The PLC CPU to The Motion CPU S P SVST PLC instruction S P SVST oo ccc a aa a eta a a a aata 3 11 3 4 Current Value Change Instruction from The PLC CPU to The Motion CPU S P CHGA PLC instruction S P CHGA Jasireta iaae aaa aaaea aaa aani 3 16 3 5 S
23. 50 o8oo oss1 wo wa iro a ac Pe nos fot ft 3 Automatic refresh setting 2 Send range for each CPU CPU side device 4 4 levice CPU CPU share memory G Dev starting W100 Se Point sin end sian End tert o tt No2 640 0832 ons wio wae Eies E a E a p E T noa T S S T 4 Automatic refresh setting 3 Send range for each CPU CPU side device CPU CPU share memory G Dev starting o Point stin end sian Eni onaf S ee a ee ee ee ee ee wos FS j S d S S 5 Automatic refresh setting 4 Send range for each CPU CPU side device CPU CPU share memory G Dev starting o Pont stn Ena stt end D E a a Cee EEE ee ee Cna J T T T T noa T S S S APP 22 This device area is set up in M2400 with the Qn H CPU No 1 The bit device for monitor is transferred to WO to by Q173HCPU side This device area is set up in DO with the Qn H CPU No 1 The ward device for monitor is transferred to W100 to by the Motion SFC program on the Q173HCPU side This setting area is used for the use except for the positioning device for the monitor APPENDICES 6 System setting Setting items Operation cycle setting Operation mode M2000 is turned on with switch Stop to Run Emergency shout down input 7 Latch range setting jintemalrelay S om CCT T Link relay Annunciator jAnnunciator D T
24. COMMON for system settings 2 Setting of the current value to change S2 usable range 2147483648 to 2147483647 Start accept flag System area The complete status of the start accept flag is stored in the address of the start accept flag in the shared CPU memory Shared CPU memory address Description is decimal address The start accept flag is stored by the 1 to 32 axis each bit As for a bit s actually being set Q173HCPU J1 to J32 Q172HCPU J1 to J8 OFF Start accept flag usable 204H 516 ON Start accept flag disable 205H 517 b15 204H 516 address J16 205H 517 address J32 Errors The abnormal completion in the case shown below and the error code is stored in the device specified with the complete status storing device D2 Complete status Note Error factor Corrective action Error code H 4c00 The specified device cannot be used in the Motion CPU Or it is outside the device range The instruction for the Multiple CPU system which did not be correspond with operating system software of the Motion CPU was executed Confirm a program 4C05 Axis No set by CHGA instruction is injustice and correct it to a There are 33 or more instruction requests to the correct PLC Motion CPU from the PLC CPU in S P SFCS program S P SVST S P CHGA S P GINT sum table simultaneously and the Motion CPU cannot process them 4C09 CPU No of the instruction cause is injus
25. D300 M20 M51 M51 M20 RST Te M10 M11 Read the data from DO to D100 ead the data from o ER M11 ay Read the data from DO to D100 M20 M21 Read the data from D200 to D300 1 M21 Read the data from D200 to D300 APP 9 APPENDICES There is the following restriction in the case as an example 1 The Multiple CPU instruction of Motion CPU cannot be used Interrupt program fixed cycle executive type program and low speed executive type program When it is used an instruction may not operate by the timing APP 10 APPENDICES APPENDIX 2 2 The program example to execute plural Multiple CPU instruction by the instructions of one time This is the program example which executes to the Multiple same Motion CPU at high speed by one instruction In this case you must take an interlock with To self CPU high speed interrupt accept flag from CPU When an instruction cannot be accepted even if it is executed it becomes No operation The program which read the data for 10 points from DO of the Motion CPU installing the CPU No 2 to since D100 of the PLC CPU the data for 10 points from D200 of the Motion CPU to since D300 of the PLC CPU and the data for 10 points from D400 of the Motion CPU to since D500 of the PLC CPU by starting of X0 is shown as an example 1 At this time number of multiple CPU dedicated execute instructions at one command should no exceed the maximum acceptable number of instructions Refer to
26. During execution of an event or NMI task the execution of the normal task is suspended Note that since the normal task allows the event task disable instruction DI to be described in an operation control step the event task can be disabled in the area enclosed by the event task disable instruction DI and event task enable instruction El 9 MOTION SFC PARAMETER be e SSS 2 Event task operation Operations An event task executes the Motion SFC program at occurrence of an event There are the following events a Fixed cycle The Motion SFC program is executed periodically in any of 0 88ms 1 77ms 3 55ms 7 11ms and 14 2ms cycles b External interrupt 16 points of l0 to 115 Among 16 points of the QI60 16 point interrupt module loaded in the motion slot the Motion SFC program is run when the input set for an event task turns on c PLC interrupt The Motion SFC program is executed when the S P GINT instruction is executed in the PLC program lt Example 1 gt Program 1 Program name areata F2 12 L_F4 js SFCS PLC program fs ee 3 55ms l l Event task END operation End lt 1 gt lt 2 gt lt 3 END operation Continue ____ __1 lt 2 __ lt _ 3 1 2 l Do not execute a Execute the number of When END operation is set as program before the consecutive transition for continuation continuation event task startin
27. JMP IFEm IFT2 SFT Gn CALL Fr JMP IFEm IFEm CALL Fn CALL Kn PABm PAT1 CALL Fn SFT Gn JMP PAEm PAT2 CALL Fr SFT Gn JMP PAEm PAEm CALL Fn CALL Fn JMP Pn CALL Fn Pn CALL Kn The route which transition condition enables first is executed after executing the step or transition preceding a branch Selective branch destinations should always be started by transitions all of which must be Shift or WAIT Using Shift and WAIT together will cause a parallel branch After the route branched by a selective branch has been processed execution shifts to a coupling point A coupling may be preceded and followed by either a step or a transition Multiple routes steps connected in parallel are executed simultaneously Each parallel branch destination may be started by either a step or transition Execution waits at the coupling point for executions of the routes branched by a parallel branch to be completed and shifts to the next when executions of all routes are completed A coupling may be preceded and followed by either a step or a transition When this coupling is preceded by an FS step scans are executed during waiting After waiting is complete scans are not executed 1 Normal jump e After the step or transition preceding this jump transition is executed execution shifts to the pointer Pn specified within its own program e The jump destination may either be a step or
28. M9028 is turned on so that clock data 2 Reading of the clock data may be set to the error history When the forced stop input assigned to PXO is on all axes turn on and Fordedsi p motion control is executed When the forced stop input turn off servo amplifier is made to forced stop and motion control is suspended and actual output PY turn off Motion control is executed according to the condition of PX and PX2 in each following mode e PX2 OFF PX1 OFF JOG mode e PX2 OFF PX1 ON Manual pulse generator mode e PX2 On PX1 OFF Home position return mode Motion control PX2 On PX1 On Programming operation mode The following JOG operation is executed when each signal of PX3 to PX6 is turned on e PX3 1 axis JOG forward rotation JOG mode e PX4 1 axis JOG reverse rotation e PX5 2 axes JOG forward rotation PX6 2 axes JOG reverse rotation Manual pulse generator mode manual pulse generator P1 e Manual pulse generator operation of 2 axes is executed with the manual pulse generator P1 The following home position return is executed Home position return mode e When PX3 is on the home position return of 1 axis is executed e When PX 4 is on the home position return of 2 axes is executed The following program operation is executed When PX3 detects OFF to ON axis No 1 locates and 1000 ms standing by after the location of axis No 2 is executed p e When PX4 turn on axis No 1 2 locates of the linear cont
29. cannot be used in the first character of the Motion SFC program name 3 2 lt gt cannot be used in Motion SFC program name 4 MOTION SFC PROGRAMS 4 5 Steps 4 5 1 Motion control step Symbol Starts the servo program Kn Motion control step Kn Specified range KO to K4095 Operations 1 Turns on the start accept flag of the axis specified with the specified servo program Kn n 0 to 4095 runnnig 2 Starts the specified servo program Kn n 0 to 4095 Completion of transition condition Start accept flag M200n v IZ Errors 1 When the specified servo program Kn does not exist the Motion SFC program error 16200 will occur and stops to execute the Motion SFC program at the error detection Instructions 1 When the current value change is executed in the Motion SFC program running specify the CHGA instruction in the servo program and call it at the motion control step 2 If the servo program has stopped due to a major minor error which occurred at or during a start of the servo program specified with the motion control step the Motion SFC program continues executing When the Motion SFC program is stopped at error detection provide an error detection condition at the transition transition condition 4 MOTION SFC PROGRAMS 4 5 2 Operation control step Operations Errors Instructions Operation tS Executes the operatio
30. integer type expression int expression expression type type L type K H KH L PO e i type F type K Londo J O Usable Setting data Setting data Data type of result Bit device used in bit conditional expression Logical type true false Functions 1 True is returned when the bit device specified with S in a bit conditional expression is OFF 0 or false is returned when that bit device is ON 1 Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which resets M100 when MO is OFF 0 RST M100 MO M100 o Mo 0 Tue 5 OPERATION CONTROL PROGRAMS FIFS 5 9 Bit Device Controls 5 9 1 Device set SET SET D S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device 16 bit Seu floating Coasting ipl ae floating epics S conditional conditional integer integer point Umer integer integer type expression point expression expression type type L type F type K H K H L type K ee ee ee ee ee ee ee ee eee ee es ee Lo o l 9 9 Usable Note 1 PX is write disabled and cannot be used at D Note 2 M2001 to M2032 cannot be used at D Setting data Setting data Descrip
31. it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is a negative number or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which finds the square root of DOF and substitutes the result to 0F 0F SQRT DOF 3 2 D2 D1 DO 1 0 D3 a Se a a 5 OPERATION CONTROL PROGRAMS FIFS 5 6 8 Natural logarithm LN LN S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting ae bit f 32 bit floating ACHA as conditional conditional integer integer integer integer type expression i int expression expression type type L type K H K H L poin R P type F type K fe NG ee o o a a o H H O Usable Setting data Setting data Data type of result Data on which natural logarithm operation will be S peroneal Floating point type Functions 1 The base e natural logarithm of the data specified with S is found 2 Only a positive number may be specified with S Operation cannot be performed with a negative number 3 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is 0 or a negative number or e S is an indirectly spec
32. processing performed Errors 1 An operation error will occur if e The S data is outside the range 0 to 65535 or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which converts the data of DOL into an unsigned 16 bit integer value and substitutes the result to 0 0 USHORT DOL D1 DO 0 K 5536 K6o o0L HEA60 HO000EA60 Unsigned value is K60000 5 OPERATION CONTROL PROGRAMS FIFS 5 7 3 Signed 32 bit integer value conversion LONG LONG S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati tata Bit device Js Re ae floating Coasting 18 bit Sra floating acuaton Conditional conditional integer integer 5 integer integer type 5 expression i point expression expression type type L type K H K H L type F type K Lond dad aoad aoad aoa dn aoa daoa dodod uda O Usable Setting data Setting data Data type of result Data which will be converted into signed 32 bit integer value Functions 1 The data specified with S is converted into a signed 32 bit integer value 2 The data range of S is 2147483648 to 2147483647 3 When S is a 64 bit floating point type its fractional portion is rounded down before conversion is made 4 If S is a 32 bit integer type its value is returned unchanged with no conversion processing per
33. stopped axis No specified with S1 is changed into the current value specified S2 This instruction is always effective regardless of the state of real mode virtual mode mode switching when the operating system software of Motion CPU is V22 S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P CHGA instruction When the Motion dedicated PLC instruction is started continuously It is necessary to take an interlock by the to self CPU high speed interrupt accept flag from CPUn When the servo program is executed also at the motion control step Kn in the Motion CPU it is necessary to take an interlock by user program because there is no flag which can distinguish the axis starting in the PLC CPU Start accept flag M2001 to M2032 of the motion devices is used as the interlock condition in the Motion CPU It is necessary to take an interlock by the start accept flag of the shared CPU memory so that multiple instructions may not be executed toward the same axis of the same Motion CPU No The current change value is also possible when the servo program which execute the CHGA instruction toward an axis is executed in the S P SVST instruction 3 MOTION DEDICATED PLC INSTRUCTION Operation Setting range PLC program S P CHGA instruction To self CPU high speed interrupt accept flag from CPUn OFF Start accept flag
34. transition e When a jump takes place from an FS step toa transition scans are executed during waiting for the completion of transition condition of the jump destination 2 Coupling jump e When a jump to the other route within a parallel branch takes place after the parallel branch a coupling jump takes place and execution waits at the jump destination 4 MOTION SFC PROGRAMS Combining the basic type branches couplings provides the following application types which are defined as in the basic types Name Motion SFC chart symbol Hist Function representation Selective branch Parallel branch Parallel coupling Selective coupling FEm Parallel branch Selective branch Selective coupling Parallel coupling CALL Kn IFBm IFT1 SFT Gn PABm PAT1 CALL Fn JMP PAEm PAT2 CALL Fn JMP PAEm PAEm JMP IFEm IFT2 SFT Gr CALL Fn JMP IFEm IFEm SFT Gn SFT Gn PABm PATI CALL Fn IFBm IFT1 SFT Gn CALL Fn JMP IFEm IFT2 SFT Gn CALL Fn JMP IFEm IFEm JMP PAEm PAT2 CALL Fn CALL Kn JMP PAEm PAEm SFT Gn After a selective branch a parallel branch can be performed
35. usable devices 4100 Since 0 to 3DFH 3E4H is specified by First I O No of the target CPU 16 is specified Note 0000H Normal Program example Program which requests to start the servo program No 10 toward axis No 1 and No 2 of the Motion CPU No 4 from the PLC CPU No 1 To self CPU Start accept flag Start accept flag high speed of the axis No 1 of the axis No 2 interrupt accept CPU No 4 CPU No 4 flag from CPU U3E3 U3E3 U3E3 G516 0 G516 1 M100 48 2 wee m SP SVST H3E3 J1J2 _K10_ mo Do M100 MO M1 V Normal complete program M1 tH J aa Abnormal complete program 3 MOTION DEDICATED PLC INSTRUCTION 3 4 Current Value Change Instruction from The PLC CPU to The Motion CPU S P CHGA PLC instruction S P CHGA Usable devices Internal devices F MELSECNET 10 Special Bit Indirectly 7 Index System User File _ direct JO O function Constant digit specified register Other register module K H Bit Word specified device Bit Word Unco ZO ado ES a a a ta Note Setting da len o fo fo fT Fe a a ee Ee RS a SC a CC a reae a E ee ee O Usable A Usable partly Note Setting data except S1 Index qualification possible Instruction Condition Start request sP cHGA f SRICHGA Start request S CHGA CHGA Setting data Setting da
36. 10 4 5 2 Operation control stepi accec eine dahl de a a de wilde in a ada a a e adaa ai a daia 4 11 4 5 3 Subroutine call start Step ecccccecccescceseeeeceeeeeeeeeeeaeeeeaeeeseaeeseaeeseaeescaeeesaaeesaeeseaesecaeescaeeeseeeessaeessaees 4 12 4 5 A Clear Step A A gener neielon ee nie E re duve aie tieenernieelneediens 4 14 4 6 Transits rnai ats wale atten k ei enn ae wee walk als weiss 4 15 4 7 JumMp PONCE 2 E E E E raha Wena O alsin E ahah eat E 4 17 AB END icc coheed lecheccesatisted a a ia heticeiabel laghal obiaetbel iad hedicetabel laghad obicediewsted a 4 17 4 9 Branches COupliNGS a c42a caieee ate aul eee See eee eee eee 4 18 4 9 1 Series transition emia heen A A oe ol RA ei ee i ad 4 18 4 9 2 Selective branch selective COUPIING ccccececcceeeeceeeeeeeeceeceneeeeaeeccaeeecaeeesaeeseaeessaeeesieeeseeteaeeseaees 4 19 4 9 3 Parallel branch parallel COUPIING cccccceeeceeeeeeeeeeeeeeceeeeaeetaeeeeaeeeeaeeeceaeeseaeseaeeeeeeeeteaeteneeseaees 4 20 410 Y N Transitions cc E A EEE TE E ok ea anand hea heen hanes 4 22 4 11 Motion SFC Comments ccccccccccssssccesssseccessssesecsseeeccssseeeessnsessssaeeesseseeeessussecesaaaeessaasecesaeeeesssaaeess 4 26 5 1 Operation Control Programs ccsccececceeeeeeeeeeeeeeeeeeaeeeeaceeceaeeceaeeseaeescaeeesaceeseaeeseaeeesaeesceeesieeseeeeseaeessaees 5 1 5 2 Device DeSscriptions lt 2tie inne Adie ik eA de A ek te ed nd ea 5 7 5 3 Constant Descr
37. 2 S P CHGT instruction To self CPU high speed interrupt accept flag from CPUn Torque limit value change Instruction start accept complete device D1 0 State display device D1 1 at the instruction start accept completion f Instruction accept gt completion at the Motion CPU side Setting range 1 Setting of the axis to execute the torque limit value change The axis to execute the torque limit change set as S1 sets J axis No ina character sequence 81 usabie range Q173HCPU 1 to 32 Q172HCPU The number of axes which can set are only 1 axis The axis No set in the system setting is used as the axis No to start Refer to the Q173HCPU Q172HCPU Motion controller Programming Manual COMMON for system settings 3 35 3 MOTION DEDICATED PLC INSTRUCTION 2 Setting of the torque limit value to change S2 usable range 1 to 1000 Errors The abnormal completion in the case shown below and the error code is stored in the device specified with the complete status storing device D2 Complete status Note Error factor Corrective action Error code H The specified device cannot be used in the Motion CPU Or it is outside the device range The instruction for the Multiple CPU system which did Confirm a program 4Cc00 4C01 not be correspond with operating system software of and correct it to a the Motion CPU was executed correct PLC 4C07 Axis No se
38. 5 40 5 7 3 Signed 32 bit integer value Conversion LONG cecceceeceeeceeeeeeeeeseeeteeeseeeseeeseneseeeeeaeseneteneeeneeaes 5 41 5 7 4 Unsigned 32 bit integer value Conversion ULONG wu ecceeceeeeeneeeeeeeeeeeeeeaeeeaeeeaeeeaeeeaeeeaeeeaeesas 5 42 5 7 5 Signed 64 bit floating point value conversion FLOAT eceses tees tee eeee teeter teeeeae tee teeteneeaeeaes 5 43 5 7 6 Unsigned 64 bit floating point value conversion UFLOAT eect eee tee teste tee tee seeeete 5 44 5 8 Bit Device Statuses iu 2 iia dedi Aline ie A Ale nde no dead eet idee 5 45 5 8 1 ON Normally open contact NOME ce eeceeceeeeeeeeeteeeeeeeeeeeeeeeseeseeeseaeseeeseeeseeeseeeseeeseaeseneteateaeeaaes 5 45 5 8 2 OFF Normally closed Contact lerure na a E A 5 46 5 9 Bit Device CONTO oia e E E EA ie ee a R 5 47 Se IBE E E aere E ET T T E E E E E E E E E E E E E E E 5 47 5 9 2 Device reset i RS T nnnnarioranio ti Ni T E T A 5 49 5 93 Device output DOUT a a a e a a r aa teed fete ete iset 5 51 5 9 4 Device input i DIN aeiia nane aa ae aaa aaa aa aeaea iaado riaan 5 52 5 9 5 Bit device output lt OQU Ti suran aeea haai e a eaaa a eat a eaa ae 5 53 9 10 Logical Operations muera A A N 5 54 5 10 1 Logical acknowledgement None eceeceeceseeeeeeeteeeteeeseeeseeeseeesanesneseeesaeseeseeeseneseaeeeneseneeaneeaes 5 54 5 10 2 Logical negation Diar an e an a a aa TAA ERAT EAA EEE aa E E aA 5 55 510 3 Logical AND Torteoniini etaa i AEE
39. 7 PLC interrupt Execute with interrupt instruction S P GINT from PLC CPU Execute when input ON is set among interrupt module QI60 NMI task 16 points 1 OVERVIEW 1 2 3 Operation control transition control specifications Expression 1 Table of the operation control transition control specifications Specifications Remark Returns a numeric result Calculation expression Bit conditional expression Expressions for calculating indirectly specified data using constants and word devices Returns a true or false result Expression for judging ON or OFF of bit device D100 1 SIN D100 etc MO MO M1 MO M1 M2 IM3 M4 etc Conditional C i expression Seay Expressions for comparing indirectly specified data and calculation D100 100 eeng RS expressions using constants and word devices D10 lt D102 D10 etc expression The input X output Y are written with the actual input PX actual output PY Device Symbol Accessibility Usable tasks Description Normal Event NMI example Input module X X100 It does the layput of the I O numbers of PX PY by a set up of as system In the operation control program transition program automatically represented as PX PY according to the system setting information non loaded Input range Input modul nput module PX loaded range Bee O Output module non loaded Output range Output module PY PY1E0 loaded range Drm Interna
40. Change n so that the block transfer range BMOV execution D to D n 1 is outside the device range is within the device range error e n is O or a negative number e Change n to a positive number e S is a bit device and the device number is not e When S or D is a bit device set the a multiple of 16 device number to be multiple of 16 D is a bit device and the device number is not When S or D is a bit device do not set a multiple of 16 PXIPY PX PY is set in S to S n 1 e PX PY is set in D to D n 1 The device No which indirectly specifies S is Correct the program so that the device No Time to wait TIME illegal which indirectly specifies S is proper execution error The S data is outside the range 0 to e Correct the program so that the S data is 2147483647 within the range of 0 to 2147483647 D to D n 1 is outside the device range e n is O or a negative number e S is a bit device and the device number is not e Change n so that the block transfer range is within the device range e When S or D is a bit device set the t The block processing on device number to be multiple of 16 executing is stopped and the When S or D is a bit device do not set next block is executed PXIPY Same data block transfer FMOV execution error a multiple of 16 D is a bit device and the device number is no a multiple of 16 e PX PY is s
41. Data type of result Data type of S S Data whose bits will be inverted Integer type 1 The bit inverted value of the data specified with S is found Functions Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which finds the bit inverted value of 0 and substitutes the value to DO DO 0 oo OTT 0 PONTE 5 OPERATION CONTROL PROGRAMS FIFS 5 5 2 Bit logical AND amp S1 8 S2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit f Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer integer integer type int expression Sxpression expression type type L type K H K H L eon BISERE EAE AEA E seal l o lol l olol ol dl o l O Usable Setting data Data type of S1 or S2 which is greater Integer type Functions 1 The bit by bit logical product of the data specified with S1 and the data specified with S2 is found 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed At this time note that signed data is converted Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is
42. E E T E a E tnkregster dowo S d d Latch 1 It is possible to clear using the latch clear Latch 2 Clearing using the latch clear is disabled c PLC module setting Type of the Number of Occupation I O response Base Slot No module points device time 000 00F cPUbaseunit 1 10mg Output 010 01F_ cPUbaseunit 2 Parameter setting of the Qn H CPU No 1 PC parameter item Qn H parameter Description Ht Number of pU_ _2medules__ Operation mode The error operating mode in the CPU stop Out of group input settings Out of group ee A The output condition outside the group is not taken ee Refresh setting Setting No 1 CPU side device Repu Ned J a N E a M2400 M3199 Setting No 2 CPU side device First device M2400 Start END ii bo Start END CPU No 1 OOS CPU No 2 D639 APPENDICES APPENDIX 2 4 Continuation execution example at the subroutine re start by the Motion SFC program 1 Explanation of the operation This is the program example which execute continuously from the motion control step which stopped on the way when it re started after stopping the subroutine program with the clear step during the motion control is running The servo is turned on by the forced stop release and the positioning control of the 2 axes liner interpolation is executed when PX4 is ON in this program One cycle operation is completed after confirmation that PX4 became OFF When the forced
43. F n read error Indirectly specified 32 bit batch annunciator F n read error e2 e2 e2 e2 e2 e2 e2 Oo 0 Oo 0 Oo a a N N N N N gt gt A wo N oO o 11 10 11 ERROR CODE LISTS 11 3 Motion SFC Parameter Errors Motion SFC parameters are checked by SW6RN GSVEP Table 11 6 PLC ready flag M2000 OFF ON errors 17000 to 17009 Error factor Error code Error Processing Name Description Normal task i el i e The normal task s consecutive transition count on consecutive The initial value of 3 is used of the Motion SFC program started by the normal task is outside the range 1 to 30 Corrective Action transition count for control error Event task The set number of consecutive transitions of Turn PLC ready flag M2000 OFF make consecutive the Motion SFC program started by the event correction to set the value within the range transition count error task is outside the range 1 to 10 and write it to the CPU The initial value of 1 is used for control NMI task The set number of consecutive transitions of consecutive the Motion SFC program started by the NMI transition count error task is outside the range 1 to 10 Table 11 7 SFC Program start errors 17010 to 17019 Name Description Error code Error Processing Corrective Action Executed task Among the normal event and NMI tasks more setting is illegal than one or none of them has been se
44. FT is incremented by 1 per 888ys 9 MOTION SFC PARAMETER 9 MOTION SFC PARAMETER Two different Motion SFC parameters are available task parameters designed to control the tasks normal task event task NMI task and program parameters to be set per Motion SFC program Their details are shown below 9 1 Task Definitions When to execute the Motion SFC program processing can be set only once in the program parameter per program Roughly classified there are the following three different tasks Task type Contents Normal task Executes in motion main cycle free time 1 Executes in fixed cycle 0 88ms 1 77ms 3 55ms 7 11ms 14 2ms 2 Executes when the input set to the event task factor among external Event task gt interrupts 16 points of QI60 turns on 3 Executes by an interrupt from the PLC CPU Executes when the input set to the NMI task factor among external interrupts 16 points of QI60 turns on 9 MOTION SFC PARAMETER 9 2 Number of Consecutive Transitions and Task Operation 9 2 1 Number of consecutive transitions With execution of active step judgment of next transition condition transition processing performed when condition enables transition of active step defined as a single basic operation of the Motion SFC program execution control in the execution cycle of the corresponding task this operation is performed for the number of active steps to terminate processing
45. M2799 M2480 M2800 to Axis 5 status to Axis 21 status M2499 M2819 M2500 M2820 to Axis 6 status to Axis 22 status M2519 M2839 M2520 M2840 to Axis 7 status to Axis 23 status M2539 M2859 M2540 M2860 to Axis 8 status to Axis 24 status M2559 M2879 M2560 M2880 to Axis 9 status to Axis 25 status M2579 M2899 M2580 M2900 to Axis 10 status to Axis 26 status M2599 M2919 M2600 M2920 to Axis 11 status to Axis 27 status M2619 M2939 M2620 M2940 to Axis 12 status to Axis 28 status M2639 M2959 M2640 M2960 to Axis 13 status to Axis 29 status M2659 M2979 M2660 M2980 to Axis 14 status to Axis 30 status M2679 M2999 M2680 M3000 to Axis 15 status to Axis 31 status M2699 M3019 M2700 M3020 to Axis 16 status to Axis 32 status M2719 M3039 1 14 1 OVERVIEW Detailes of each axis M2402 20n Zero pass signal External signals M2416 20n Torque limiting signal M2418 20n Virtual moge continuation operation disable warning signal SV22 Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 0 to 31 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 Device area of 9 axes or more is unusable in the Q172HCPU 1 15 1 OVERVIEW 2 Table of the axis command signals SV13 SV22 Device No M3200 to M3219 M3220 to M3239 M3240 to M3259 M3260 to M3279 M3280 to M3299 M3300 to M3319 M3320 to M3339 M3340 to M3359 M3360 to M3379 M3380 t
46. N N O Command speed constant speed Number of indirect words x N Absolute 1 axis positioning Incremental 1 axis positioning Absolute 2 axes linear Description 7 Instruction fstton snaa Gives the servo instructions usable in servo programs Processing Gives the processing outlines of the servo instructions a Indicates positioning data which can be set in servo instructions 1 O Item which must be set Data which cannot execute the servo instruction unless it sets 2 A Item which is set when required Data which will be controlled by the default value unless it sets b Allows direct or indirect designation except axis No 1 Direct designation Set with numerical value 2 Indirect designation Set with word device D W e Servo program execution is controlled using the preset word device contents Each setting item may either be 1 or 2 word data e For 2 word data set the first device No c Number of steps As there are more setting items there are more number of instruction steps The number of steps is displayed when a 3 4 a a e servo program is created The instruction O item comprise the minimum steps and one A item increases the number of steps by 1 Items common to the servo instructions Items set in circula
47. NMI task 3 55ms fixed cycle even task with a program to run by the NMI task and the normal task like a chart 1 The 3 55ms fixed cycle event task is executed at intervals of 3 55ms Normal task execute program 2 The NMI task is executed with the highest priority when an NMI interrupt is input and 3 The normal task is executed at free time as shown above Points One Motion SFC program can be executed partially by another task by setting the area to be executed by another task as a subroutine and setting a subroutine running task as another task lt Example gt No 0 Main Motion SFC program Normal task No 1 Subroutine Event task 3 55ms cycle A normal task may be hardly executed when a NMI task an event task are executed in many 9 MOTION SFC PARAMETER 9 4 Task Parameters Setting item Initial value Remark Number of Normal task i These parameters are imported when PLC ready flag M2000 turns off to on and used for control consecutive Normal task 1 to 30 transitions common Set whether the event task or NMI task is thereafter When setting changing the values Interrupt setting used for external Event task of these parameters turns the interruptinputs PLC ready flag M2000 off l0 to 115 1 Number of consecutive transitions Description With execution of active step judgment of next transition condition transition processing
48. O Module Type Building Block User s Manual This manual explains the specifications of the I O modules connector connector terminal block SH 080042 conversion modules and others 13JL99 Optional 3 Servo amplifier Manual Name Manual Number Model Code MR J3 OB Servo amplifier Instruction Manual This manual explains the I O signals parts names parameters start up procedure and others for SH 030051 MR J3 OB Servo amplifier 1CW202 Optional Fully Closed Loop Control MR J3 LIB RJ006 Servo amplifier Instruction Manual This manual explains the I O signals parts names parameters start up procedure and others for Fully SH 030056 Closed Loop Control MR J3 KJB RJ006 Servo amplifier 1CW304 Optional 1 OVERVIEW 1 OVERVIEW 1 1 Overview This programming manual describes the Motion SFC program and Multiple CPU system of the operating system software packages SW6RN SV13QD SW6RN V22QD for Motion CPU module Q173HCPU Q172HCPU In this manual the following abbreviations are used Generic term Abbreviation Q173HCPU Q172HCPU or Q173HCPU Q172HCPU Q173HCPU T Q172HCPU T Motion CPU module Motion CPU module Q172LX Servo external signals interface module Q172LX Q172EX Q173PX or Note 1 Q172EX S2 S3 Serial absolute synchronous encoder interface module Motion module Q173PX S1 Manual pulse generator interface module MR J3 OB Servo amplifier model MR J3 O
49. PCPU ready flag M9074 is OFF a minor error J 00 occurs and a current value change is not made If the cam shaft within one revolution current value change is executed in the real mode a servo program setting error Note 903 or 905 occurs and the current value change is not made 903 when the current value change servo program is set to within the virtual mode program No range or 905 when it is set to within the real mode program No range If a current value change is made during mode changing a servo program setting error Note 907 real virtual changing or 908 virtual real changing occurs and the current value change is not made Note Refer to the Q173HCPU Q172HCPU Motion controller SV13 SV22 Programming Manual REAL MODE Q173HCPU Q172HCPU Motion controller SV22 Programming Manual VIRTUAL MODE for minor error major error and servo program setting error Note 7 MOTION CONTROL PROGRAMS 7 5 Programming Instructions 7 5 1 Cancel start When a cancel start has been set in the setting items of the servo program which was started at the motion control step of the Motion SFC program the cancel of the running servo program is valid but the servo program specified to start after a cancel is ignored without being started The following example shows the Motion SFC program which exercises control equivalent to a cancel start Selective branch KO Ee Dis an al js ac Providing tran
50. Program cccceccesceeseeseeeeeeeeeeeeeeeieeceesaeesaeeeaeeeaeesaeeeaeesaeesaeesaeeeaeeeeeeaeeeas 9 16 9 6 1 Automatic starts ails ie Aen caus Aen ung cunaetiacadeige undead daa 9 16 9 6 2 Start from the Motion SFC program ceccceceeceseceseceeeeeeeeeseeeseeeeeeeseeeceeseeeseeeseeeseeeseeeseaeseeeseaseaeeaes 9 16 9 6 3 Start from PLC PLC instruction S P SFCS oo ec eeeeeeeeeeneeeeeeeneeeeeeaeeeaeseaeeeaeeeaeeeaeeeaeeeaeeeaeeeas 9 16 9 7 How to End The Motion SFC Program cecceeccsecesseeeeeeseeeeeeeeeeeeeeeeeaeesaeeeaeeeaeeeaeeeaeesaeesaeeeeesaeeneeeaeeeas 9 16 9 8 How to Change from One Motion SFC Program to Another 02 0 eeceeeeeeeeeeeeeeeneeeeeeeaeeeeeeaeeseeeeeeaeeas 9 17 9 9 How to Manage The Executing Program cecceeceeeceeeeeeneeeeeeeeeeeeeeaeeeaeesaeeeaeeeaeesaeeeaeesaeesaeeeaeeeaeeeaeeatenas 9 17 9 10 Operation Performed at CPU Power Off or ReSet cc cccecceeeeeeeeeeeeeeeeeeeeeeeneeseaeeseaeeeeeeesineeeeneeeas 9 17 9 11 Operation Performed when CPU is Switched from RUN STOP c cceeeeeeeeeeeeeeeeeeeeeeeeeeeeseetseeees 9 17 9 12 Operation Performed when PLC Ready Flag M2000 Turns OFF ON cecceeeeeeeeeeeeeeeeteeenteeatens 9 18 9 13 Operation at The Error OCCUITCNCE cecccceecceeeceeeeeeeeeeeeeeaeeecaeeeeeneecaeeseaeeecaeeesaneeseaeeseaeeesieenieeesineetans 9 18 10 USER FILES 10 1to 10 8 VOR TiVO OCts 2x 22izceazckadekateedccuadensdebadcebecaadensdeh EES 10 1 10 2 Us
51. S2 Specified torque limit value Functions 1 The torque limit value of the axis specified with S1 is changed to the torque limit value axis specified with S2 2 Inthe real mode any axis that has completed a servo startup can be changed in torque limit value any time independently of the status starting stopping servo ON or servo OFF 3 The axis No that may be set at S1 is within the following range Q172HCPU Q173HCPU 1 to 32 4 The torque limit value that may be set at S2 is within the range 1 to 1000 5 The torque limit value specified here and the one specified in the servo program have the following relationships At a normal start the torque limit value is given to the servo of the start axis according to P torque set in the servo program or the torque limit value of the specified parameter block For an interpolation start the torque limit value is given to the number of axes to be interpolated Executing the CHGT instruction gives the preset torque limit value to only the specified axis Thereafter the torque limit value given to the servo at a servo program start or JOG start is made valid only when it is lower than the torque limit value specified in CHGT This torque limit value clamp processing is performed per axis 5 70 5 OPERATION CONTROL PROGRAMS During start a If the following torque limit value has been set it will not be changed to higher than the torque limit v
52. Setting data Data type of result COS value data on which COS arccosine S S Floating point type operation will be performed Functions 1 COS al arccosine operation is performed on the COS value data specified with S to find an angle 2 The COS value specified with S must be within the range 1 0 to 1 0 3 The operation result is in an angle degree unit 4 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is outside the range 1 0 to 1 0 or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which performs the COS 1 arccosine operation of DOF and substitutes the result to 0F 0F ACOS DOF 3 2 D2 D1 DO 1 0 D3 Se e eS eS 5 OPERATION CONTROL PROGRAMS FIFS 5 6 6 Arctangent ATAN ATAN S Number of basic steps Usable data Usable Data Bit device 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit DF Calculation a ne floating Coasting floating conditional conditional i i expression r integer integer type ae P expression expression Setting data integer integer ai imer type type L ia type K H K H L O Usable Setting data Setting data Data type of result TAN value data on which TAN arctangent S ee Floating point type operation wi
53. Signal direction Refresh Device No Signal name Status Command cycle on Motion SFC error history Seventh error information in past 8 errors 64 points Signal name Oldest error information Sixth error information in past Error Motion SFC program No Error type Fifth error information in past Error program No Error block No Fourth error information in past Motion SFC list Line No Axis No At error occur Error code Third error information in past Year te Month Day Error occurrence Hour Minute Second Second error information in past time First error information in past Latest error information 11 2 11 ERROR CODE LISTS Table 11 2 Motion SFC program start errors 16000 to 16099 Error factor Error code At a start by S P SFCS instruction PLC ready flag M2000 or PCPU ready flag M9074 is OFF At a start by S P SFCS instruction the range of 0 to 255 is specified in the Motion SFC program No At a Motion SFC program start by S P SFCS instruction the specified Motion SFC program does not exist At a Motion SFC program start by S P SFCS instruction the same Motion SFC program PLC ready OFF SFCS Motion SFC program No error SFCS None Motion SFC program SFCS Double start error starts S P GINT instruction was executed with PLC ready flag M2
54. The SFC program is started by executing the S P SFCS in the PLC program Refer to Chapter 3 MOTION DEDICATED PLC INSTRUCTION for details 9 7 How to End The Motion SFC Program Operations 1 The Motion SFC program is ended by executing END set in itself 2 The Motion SFC program is stopped by turning off the PLC ready flag M2000 3 The program can be ended by the clear step Refer to Section 4 5 4 Clear step for details of the clear step Point 1 Multiple ENDs can be set in one Motion SFC program 9 MOTION SFC PARAMETER 9 8 How to Change from One Motion SFC Program to Another Use a subroutine start to stop the Motion SFC program running and switch it to another Motion SFC program Motion SFC program changing example using subroutine start i aT Ea MAIN SUB eee C END 9 9 How to Manage The Executing Program There are no specific information that indicates which the Motion SFC program is executing Use a user program Motion SFC program PLC program to control the executing program 9 10 Operation Performed at CPU Power Off or Reset When the CPU is powered off or reset operation is performed Motion SFC programs run are shown below 1 When the CPU is powered off or reset operation is performed Motion SFC programs stop to execute 2 At CPU power off or key reset the contents of the motion registers 0 to 7999 are held Initialize them in the Motion SFC programs as requi
55. Unit us OF FIX 4F 11 30 FIX Round down D800F FIX D804F 13 20 O0F FUP 4F 11 70 FUP Round up D800F FUP D804F 13 05 0 BIN 1 8 40 D800 BIN D801 a O BCD BIN conversion 0L BIN 2L 10 60 D800L BIN D802L 10 60 0 BCD 1 12 80 D800 BCD D801 14 25 0L BCD 2L 18 10 D800L BCD D802L 27 05 0 SHORT 2L Converted into 16 bit integer type O SHORT 4F 11 35 signed D800 SHORT D802L 10 60 D800 SHORT D804F 11 85 0 USHORT 2L Converted into 16 bit integer type O USHORT 4F 11 95 USHORT unsigned D800 USHORT D802L 11 40 D800 USHORT D804F 13 90 OL LONG 2 Converted into 32 bit integer type OL LONG 4F 12 45 signed D800L LONG D802 D800L LONG D804F 13 80 0L ULONG 2 7 95 Converted into 32 bit integer type OL ULONG 4F 12 45 unsigned D800L ULONG D802 10 10 D800L ULONG D804F 13 95 ei hace hth ity HORSRLORTO egarcec as oe calaand IHOF FLOAT AL converted into 64 bit floating point ea D800F FLOAT D804 D800F FLOAT D804L 11 75 BIN BCD conversion UFLOAT OF UFLOAT 4 Regarded as unsigned 0F UFLOAT 4L UFLOAT data and converted D800F UFLOAT D804 g90 O into 64 bit floating point type D800F UFLOAT D804L 10 75 SET M1000 MO 10 40 ON normally open contact SET M1000 X100 10 35 Daat SET M1000 PXO 18 10 Bit device status z SET M1000 MO 11 55 OFF normally closed contact SET M1000 X100 12 00 SET M1000 PXO 16 70 SET M1000 Device set SET Y100 De
56. WAIT Y N transition programs 4 MOTION SFC PROGRAMS 3 Instructions for the Motion SFC charts Any Motion SFC chart that will be meaningless to or conflict with the definition of Y N transitions will result in an error at the time of editing or Motion SFC chart conversion Their patterns and instructions will be given below a When Shift Y N or WAIT Y N is connected as a selective branch or parallel branch Error e Shift Y N used as selective branch WAIT Y N used as selective branch x L x e Shift Y N and WAIT Y N used as e Shift or WAIT Y N used with other parallel branch step transition as parallel branch or selective branch Ls x Lx b When a coupling precedes Shift Y N or WAIT Y N Provide coupling branch continuation in between e Direct coupling with Shift Y N or WAIT e Provide coupling branch continuation in Y N is not allowed between Co Co O gt LIL _ 4 MOTION SFC PROGRAMS c The following patterns may be set End END from Shift Y N or WAIT Y N Jump from Shift Y N or WAIT Y N o O Le END e Continuation from Shift Y N or WAIT Y N to Shift Y N or WAIT Y N selective branch selective branch END When there are two or more connection lines from Y N side of Shift Y N or WAIT Y N selective branch continues to sel
57. a RE A A E N 5 56 Di 10 4 HOGICAlL OR sss sete E ore soit sade R a den E A E I R fade 5 57 5 11 Comparison Operations cccccccccceeeceeeeeeeeeeeeeeeeeeeaceeceaeeseaeeccaeeecaeeesaaeeseaeeseaeeseaeessaeeeseaeeseaeeseaeeesaneetaas 5 58 ae A Ma IH e BE ho ae reper ery verre or E pr rere eee eee EEE E E EEEE EAE EREE reer errr eer eee errr creer errr e 5 58 Loy MLPA 1 10 UF gt BL C6 E rene a en EE ye er py ere ere ene ere ere ep or ee rere reper a al 5 59 5311 3 Less than lt i tisckctie chet cien let ee eet occa ceet idee ede ecca nce adit ede acai eee aden ede aa dea det ada eee ave ia 5 60 5 11 4 Less than or equal tO lt ooo eeeccececceeeneeeeeeeeeeeeecaceeeeneeseaeeceaeeseaeeecaaeeseneeseaeescaeeesieeeseaeessaeseieessiseess 5 61 5 11 5 More thant gt w ctevin nde ceded AA 5 62 5 1 16 More than or equalto s Sas ie cle eee cee ete ee eee ed ee dee Ce eh e 5 63 5 12 Motion Dedicated Functions CHGV CHGT ececceesceeeeeeeeeeeeeeeeeaeeeaeeeaeeeaeeeaeeeaeeeaeeeaeecaeeeaeeeaseareeaeeeas 5 64 5 12 14 Speed change request CHGV vic sic cosn ate ae tee a aeadek ad ee eaten a he hese ah hate Teena 5 64 5 12 2 Torque limit value change request CHGT cccccceceeeceeeeceeeeeeeceeseaeeeeaeeseeeeesceeseaeeseeeesieeesieees 5 70 5 13 Other INStructions vistas elie ete cette cbeadenceelideneed a aa i e a a aaa a iE aA 5 72 5 13 1 Event task enable El on ecceeceeeceeeceeseeeeneeeeeeeeeeaeeeaeeeaeedaeeeaeeeaneeaeedaeeeaeee
58. a subroutine call to make it stop when this program is suspended by the clear step of No 20 Main too Condition of Subroutine call program PX1 PX2 PX2 PX1 No Program name OFF OFF 120 JOG OFF ON 130 Manual pulse generator ON OFF 140 Home position return ON ON 150 Programming operation APP 17 APPENDICES d No 120 JOG JOG F120 I1 axis JOG operation speed A00000PLS s D640L K100000 2 axes JOG operation speed IA00000PLS s D642L K100000 G120 y When each signal of PX3 to PX6 is turned on off which the I1 axis forward rotation JOG start correspondences JOG command device is SET RST IISET RST It makes forward rotation JOG start of the same axis and a SET M3202 PX3 1M3203 reverse rotation JOG start from making turned on at the same RST M3202 PX3 time 1 axis reverse rotation JOG start Signal name Correspond with JOG command device HSET RST PX3 M3202 1 axis forward rotation JOG SET M3203 PX4 M3202 PX4 M3203 1 axis reverse rotation JOG RST M3203 PX4 PX5 M3222 2 axis forward rotation JOG 2 axis forward rotation JOG start PX6 M3223 2 axis reverse rotation JOG HSETIRST gt SET M3222 PX5 M3223 Note The ON OFF distinction of each signal can be RST M3222 PX5 described with Y N transition But processing time can 2 axes reverse rotation JOG start ISET RST be shortened more the number of steps
59. abnormal completion 16 bit D2 Device to store the complete status binary Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration Note 2 n shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 1 to 32 Q172HCPU Axis No 1 to No 8 n 1 to 8 3 MOTION DEDICATED PLC INSTRUCTION Controls 1 This instruction is dedicated instruction toward the Motion CPU in the Multiple CPU system Errors occurs when it was executed toward the CPU except the Motion CPU 2 The speed change is executed of the axis specified with S1 during positioning or JOG operating 3 S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P CHGV instruction When the Motion dedicated PLC instruction is started continuously It is necessary to take an interlock by the to self CPU high speed interrupt accept flag from CPUn 4 When the speed change is executed also at the operation control step Fn FSn in the Motion CPU it is necessary to take an interlock by user program because there is no flag which can distinguish the speed changing in the PLC CPU Speed changing flag M2061 to M2092 of the motion devices is used as the interlock condition in the Motion CPU 5 Itis necessary to take an interlock by the speed changing flag of the shared CPU memory so that multiple instructions may not be executed toward t
60. as an end e The following operation example assumes that the END operation is continued Program parameters e Automatically started e Execute task event 3 55ms e Number of consecutive transitions 2 e End operation continued Program name 1 After starting M2000 program is 4 Program is executed in 3 55ms executed at 3 55ms intervals cycle fourth time first time after event task enable 2 Program is executed in 5 Program is executed in 3 55ms cycle second time 3 55ms cycle fifth time 3 Program is executed in 6 Program is executed in 3 55ms cycle third time 3 55ms cycle sixth time 9 MOTION SFC PARAMETER 9 6 How to Start The Motion SFC Program The Motion SFC program is executed during PLC ready flag M2000 is on The Motion SFC program may be started by any of the following three methods 1 Automatic start 2 Start from the Motion SFC program 3 Start from the PLC Set the starting method in the program parameter for every Motion SFC program Refer to Section 9 5 Program Parameters for parameter setting 9 6 1 Automatic start Operations An automatic start is made by turning PLC ready flag M2000 on 9 6 2 Start from the Motion SFC program Operations A start is made by executing a subroutine call start step in the SFC program Refer to Chapter 4 MOTION SFC PROGRAMS for details of the subroutine call start step 9 6 3 Start from PLC PLC instruction S P SFCS
61. below 1 block 0 D0 D1 D2 5 Substitution expression four arithmetic operations WO0 F SIN 10F Substitution expression standard function CHGV K2 K10 Motion dedicated function 1 program SET M100 M0 X0 Bit device control SET RST M10 X0 Bit device control RST DIN DO X0 Bit device control DIN Comment 5 OPERATION CONTROL PROGRAMS 2 Priorities of ope rators and functions Operators and functions have the following priorities Using parentheses High allows an operation sequence to be specified freely Item Operator Function Calculation within parentheses Standard function SIN COS etc Type conversion USHORT LONG etc Bit inversion logical negation sign inversion Multiplication division remainder Addition subtraction Bit left shift lt lt bit right shift gt gt Comparison operators Less than lt less than or equal to lt more than gt more than or equal to gt Comparison operators Equal to not equal to Bit logical AND amp Bit exclusive OR Bit logical OR Logical AND Logical OR Substitution 5 OPERATION CONTROL PROGRAMS 3 Structure of instruction Many of the instructions usable in operation control programs can be divided into instruction and data parts The instruction and data parts are used for the following purposes e Instr
62. chart this type is displayed in order of a selective coupling a selective branch as shown on the left In this case a pointer Pn cannot be set between the selective coupling point IFEm and the selective branch point IFBm 1 The parallel coupling point and parallel branch point can be the same Note that in the Motion SFC chart this type is displayed in order of a parallel coupling a parallel branch as shown on the left Execution waits at the parallel coupling point and shifts to the parallel branch In this case a pointer Pn cannot be set between the parallel coupling point PAEm and the parallel branch point PABm 1 4 MOTION SFC PROGRAMS 4 4 Motion SFC Program Name Set the Motion SFC program name to the Motion SFC program No 0 to No 255 individually Make this setting in the Motion SFC program management window on the Motion SFC program edit screen Set the Motion SFC program name within 16 characters Specify this Motion SFC program name for a subroutine call start step GSUB and clear step CLR Motion SFC programs correspond to No 0 to No 255 and saved in a one program for one file format The preset Motion SFC program name is used as the file name of the Motion SFC Program file for user file management Refer to Chapter 10 USER FILES for details 1 Itis can be set the Motion SFC program to any of No 0 to No 255 There are no specific programs which have special roles 2
63. complete For the continuation from P20 100 30 Continuation point 30 F191 For the continuation from P30 G156 Did you turn on PX4 IPX4 F193 100 0 Continuation point 0 0 is set on 100 Continuation point and it jumps in PO APP 27 APPENDICES APPENDIX 2 5 Continuation execution example after the stop by the Motion SFC program 1 The explanation of the operation The program example that the Motion SFC program is stopped by external input signal ON for the forced stop from the input module and it is executed continuously by external signal OFF for the stop is shown below The servo is turned on by the forced stop release and the positioning control of the 2 axes liner interpolation is executed when PX4 is ON in this program One cycle operation is completed after confirmation that PX4 became OFF When PX5 turns ON during the positioning operating the positioning operation is stopped by the stop instruction and it is resumed from the interrupted positioning operation at turning PX5 on The transition to the next step is not executed during PX5 is ON in the WAIT transition When the forced stop is executed during the positioning operating the positioning operation is interrupted and the servomotor is stopped It is resumed from the interrupted positioning operation when the forced stop was released next Continuation execution of the stop and stop after is execut
64. condition Gn Fn Fn 3 Combination with subroutine call start step Refer to Section 4 5 3 Subroutine call start step 4 MOTION SFC PROGRAMS 4 7 Jump Pointer Jump Pointer Operations Setting a jump will cause a jump to the specified pointer Pn of the self program You can set pointers at steps transitions branch points and coupling points You can set pointers Pn at PO to P16383 in one program e Instructions You cannot make a jump setting which will exit from within parallel branch parallel coupling Connect directly Bad example 1 given below You cannot make a jump setting from outside parallel branch parallel coupling to within parallel branch parallel coupling Bad example 2 given below You cannot make a setting where a label and a jump will continue Bad example 3 given below e at example 9 ail CIFIC Ss T Pn Pn See fie ae 4 8 END Operations Ends a program In this case of an event task or NMI task operation changes with end operation setting of the program parameter Refer to Section 9 5 Program Parameters for details e Making a subroutine call will return to the call source Motion SFC program Instructions e END may be set a multiple number of times in one program END cannot be set between a parallel branch and a parallel coupling e The output is held after t
65. conditional integer integer j integer integer type 5 expression point expression expression type type L type K H K H L type K mee ee ee ek ate alee ee nO Ss ee ee eee ee ee ee ee ee ee O Usable Setting data Setting data Data type of result S1 Augend data Data type of S1 or S2 S2 Addend data which is greater Functions 1 The data specified with S2 is added to the data specified with S1 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which substitutes the result of adding K123 and 0 to WO WO K123 0 123 wo 579 qt I 0 456 2 Program which substitutes the result of adding 0F and 10 to DOL DOL 0F 10 3 2 1 0 R 12345 789 DOL 12468 p a c A E 0 The 64 bit floating point type data are used for addition and the result is converted into the 32 bit integer type and then substituted 5 12 5 OPERATION CONTROL PROGRAMS FIFS 5 4 3 Subtraction S1 S2 Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit Calculation aA p gt floating Coasting i fl
66. example Program example 2 g When the Motion dedicated function of the operation control step Fn FSn and Motion control program Kn in Motion CPU Since there is no flag which can be distinguished on instruction execution in the PLC CPU it is necessary to taken an interlock by user program Program example 3 lt Program example 1 gt Program which executes multiple instructions to the same shaft of the Motion CPU of same CPU No To self CPU high Start accept Start accept speed interrupt flag of the Axis 1 flag of the Axis 2 accept flag from CPU No 2 CPU No 2 CPU1 U3E1 G516 0 U3E1 G516 1 mo U3E1 G48 0 R 2 Aa V KO gt o gt SP SVST H3E1 J1J2 K100 M10 DO To self CPU high Start accept speed interrupt flag of the Axis 1 accept flag from CPU No 2 CPU No 1 U3E1 G516 0 M2 U3E1 G48 0 SP CHGA H3E1 J1 Ko m3 D2 I To self CPU high speed interrupt accept flag from CPU No 1 M6 U3E1 G48 0 SP CHGT H3E1 K250 M7 D _ RST _ m6 _ 3 MOTION DEDICATED PLC INSTRUCTION lt Program example 2 gt Program which executes directly multiple Motion dedicated PLC instructions because one contact point turns on M1001 To self CPU high speed interrupt Start accept _ accept flag from flag of the Axis 1 To self CPU hig speed interrupt Start accept _ accept flag from flag of the Axis 2 CPU1 CPU No 2 M23 U3E1 G48 0 U3E1 G51
67. flag is OFF RST M2052 P2 Manual pulse generator lenable flag is OFF _ 1 2 axis Manual pulse generator enable flag turned off at the time of the JOG mode completion not to continue a manual pulse generator operation after it moves to other mode of the safety END APP 18 APPENDICES f No 140 Home position return Home position return request gt G140 G141 G142 PX3 1 axis home position return I PX4 2 axes home position return Did you finish home position return Icompletion 1 axis in position signal 1 Icompletion 2 axes in position signal 2 request mode laxis start accept laxis start accept PX2 IPX1 PX4 IM2430 M2422 IM2002 PX3 IM2410 M2402 IM2001 K140 Real K141 Real 1 ZERO 1 ZERO Axis 1 Axis 2 When PX3 is ON the home position return request of 1 axis is executed When PX4 is ON the home position return request of 2 axes is executed At this time in position signal ON and start accept OFF confirmed and home position return request program is started Note This program is the structure which does not have WAIT that it waits for the completion of the home position return in the next of the motion control step because it possible a thing during K140 practice and K141 are started You must take the initial start of each axis to interlock condition to prevent the double start of K140 and K141
68. for event task and PLC interrupt However multiple fixed cycles cannot be set toward one Motion SFC program Example Interrupt setting Inputs for event task 16 I7 18 19 110 111 112 113 114 and 115 Motion SFC program No 10 event Fixed cycle 3 55ms Motion SFC program No 20 event Fixed cycle 1 77ms external interrupt 16 Motion SFC program No 30 event External interrupts I7 115 PLC CPU interrupt When the NMI task is set multiple interrupt inputs among the external interrupts for NMI task can be set Example Interrupt setting Inputs for NMI task 10 11 12 13 14 15 Motion SFC program No 10 NMI I0 Motion SFC program No 20 NMI 11 12 Motion SFC program No 30 NMI I5 Errors This program parameter is imported when the PLC ready flag M2000 turns off to on and is checked at starting of the Motion SFC program automatic start start from PLC or subroutine start When the value is illegal either of the following Motion SFC errors is set and the initial value is controlled Error cause Name Execute task setting is illegal Contents Multiple events among the normal event and NMI tasks are set or one is not set Executed task setting is illegal event Two or more fixed cycles of the event task have been set Error processing The initial value normal task is controlled Corrective action Turn PLC ready flag M
69. four arithmetic operations W0 F SIN 10F Substitution expression standard function CHGV K2 K10 Motion dedicated function 1 program SET M100 M0 X0 Bit device control SET RST M10 D100 gt K10 Bit device control RST DIN DO X0 Bit device control DIN DO gt K100 Standby until transition condition enables v Transition condition Comment 6 TRANSITION PROGRAMS What can be set as a transition condition in the last block are bit conditional expressions comparison conditional expressions and device set SET device reset RST which return logical data values true false In the case of device set SET device reset RST whether the bit or comparison conditional expression specified at S is true or false is a transition condition and when the transition condition enables device set reset is executed and execution shifts to the next step Transition condition description examples are given below Classification Description example Bit conditional expression IMO X10 M100 Comparison conditional expression DO gt K100 D100L K20L Device set SET SET YO M100 Device reset RST RST M10 D0 K100 1 A transition program differs from an operation control program in that a transition condition is set in the last block Other settings are the same as those of the operation control program 2 When setting device set SET device reset RST in the last block as a transition condition the bit or comparis
70. is set when required Controls Control using CHGA instruction 1 Executing the CHGA instruction changes the current value in the following procedure a The start accept flag M2001 to M2008 M2001 to M2032 corresponding to the specified axis is turned on b The current value of the specified axis is changed to the specified address c Start accept flag is turned off at completion of the current value change 2 The current value of the specified axis is changed in the real mode 3 The current value of the specified virtual servo motor shaft is changed in the virtual mode 4 The used axis No can be set within the following range Q172HCPU Q173HCPU Axis 1 to 8 Axis 1 to 32 5 The address which made the current value change by CHGA instruction is valid on the power supply turning on 7 MOTION CONTROL PROGRAMS Program example A program which made the current value change control in the real mode is described as the following conditions 1 System configuration The current value change control of axis 2 is executed Q02H Q173H Q172 QX10 CPU CPU EX l 3 AMP AMP AMP AMP Axis 5 Axis 6 Axis 7 Axis D 2 The current value change control conditions a The current value change control conditions are shown below Item Setting Servo program No 10 Control axis No 2 Current value change address 50 3 Operation timing CHGA instruct
71. its device No is outside the range Program examples 1 Program which sets M100 when MO and XO are both 1 vo 1 M100 x True x 7 5 OPERATION CONTROL PROGRAMS FIFS 5 10 4 Logical OR S1 S2 Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit f Calculation a i i R floating Coasting n floating i conditional conditional integer integer i integer integer type j expression y point expression expression type type L type K H K H L type K m a de no Be ae ae ee eee ee o el ee O Usable Setting data Setting data Data type of result Data which will be ORed Logical type true false Functions 1 The data specified with S1 and the data specified with S2 are ORed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which sets M100 when either of MO and X0 is 1 SET M100 MO XO vo 0 M100 _ _ True x0 1 5 OPERATION CONTROL PROGRAMS FIFS 5 11 Comparison Operations 5 11 1 Equal to S1 S2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device 16 bit Seu floating Coasting aoe seni floating a e a conditional conditional i i i i e
72. linear interpolation peer fed pitch ese fafofofofafa 3 axes linear interpolation eee ee ieee fafofofofafa VF Speed control I forward pee rotation start vp l Speed control I reverse VR 7 J rotation start Fixed pitch feed WE Speed control T forward J rotation start rap Speed control T reverse WR rotation start ADE Speed position control VPF J forward rotation start eet HESE Speed position control restart Speed switching control start Speed switching control end ed control end oa Soon baa speed switching nes Reverse Forward rotation ro Speed position Restart Speed switching control 7 MOTION CONTROL PROGRAMS Positioning data Starting angle Amplitude Frequency Reference axis No Control unit Speed limit value Acceleration time Deceleration time Torque limit value at stop input interpolation S curve ratio Repeat condition Program No Command speed WAIT ON OFF deceleration time Fixed position stop Number of steps Rapid stop deceleration time Deceleration processing FIN acceleration deceleration Fixed position stop acceleration amp 5 5 lt aD f o E o 2 Fa 6 x 12 1 1 a 1B Must be set A Set if required 1 Only reference axis speed specification 2 B indicates a bit device 7 MOTION CONTROL PROGRAMS Table 7 2 Servo Ins
73. n 0 to 31 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 Device area of 9 axes or more is unusable in the Q172HCPU 1 33 1 OVERVIEW MEMO 1 OVERVIEW 2 Table of the control change registers SV13 SV22 D640 Axis 1 JOG speed D672 Axis 17 JOG speed D642 Axis 2 JOG speed D674 Axis 18 JOG speed D644 Axis 3 JOG speed D676 Axis 19 JOG speed D646 Axis 4 JOG speed D678 Axis 20 JOG speed D648 Axis 5 JOG speed D680 Axis 21 JOG speed D650 Axis 6 JOG speed D682 Axis 22 JOG speed D652 Axis 7 JOG speed D684 Axis 23 JOG speed D654 Axis 8 JOG speed D686 Axis 24 JOG speed D656 Axis 9 JOG speed D688 Axis 25 JOG speed D658 Axis 10 JOG speed D690 Axis 26 JOG speed D660 Axis 11 JOG speed D692 Axis 27 JOG speed D662 Axis 12 JOG speed D694 Axis 28 JOG speed D664 Axis 13 JOG speed D696 Axis 29 JOG speed D666 Axis 14 JOG speed D698 Axis 30 JOG speed D668 Axis 15 JOG speed D700 Axis 31 JOG speed D670 Axis 16 JOG speed D702 Axis 32 JOG speed setting register setting register 1 35 1 OVERVIEW 3 Table of the virtual servomotor axis monitor devices SV22 only D800 D960 to Axis 1 monitor device to Axis 17 monitor device D809 D969 D810 D970 to Axis 2 monitor device to Axis 18 monitor device D819 D979 D820 D980 to Axis 3 monitor device to Axis 19 monitor device D829 D989 D830 D990 to Axis 4 monitor device to Axis 20 monitor device D839 D999 D840 D1000 to Axis 5 monitor device to Axis 21 monitor device D849 D1009 D8
74. not place fingers or hands in the clearance when opening or closing any opening Periodically replace consumable parts such as batteries according to the instruction manual Do not touch the lead sections such as ICs or the connector contacts Do not place the Motion controller or servo amplifier on metal that may cause a power leakage or wood plastic or vinyl that may cause static electricity buildup Do not perform a megger test insulation resistance measurement during inspection When replacing the Motion controller or servo amplifier always set the new module settings correctly When the Motion controller or absolute value motor has been replaced carry out a home position return operation using one of the following methods otherwise position displacement could occur 1 After writing the servo data to the Motion controller using programming software switch on the power again then perform a home position return operation 2 Using the backup function of the programming software load the data backed up before replacement After maintenance and inspections are completed confirm that the position detection of the absolute position detector function is correct Do not short circuit charge overheat incinerate or disassemble the batteries The electrolytic capacitor will generate gas during a fault so do not place your face near the Motion controller or servo amplifier The electrolytic capacitor and fan will deter
75. number of acceptable instructions changes according to number of CPUs included Motion CPU Calculation expression is shown below Number of maximum acceptable instructions per one Motion CPU 32 Number of allCPUs 2 Number of instructions c Local devices and file registers as program are written to device by END processing Do not use the devices below e Each instruction complete device e D1 of S P DDRD instruction The first device of the self CPU which stored the reading data 3 MOTION DEDICATED PLC INSTRUCTION d Use a flag in the shared CPU memory which correspond with each instruction not to execute multiple instructions to the same shaft of the Motion CPU of same CPU No for the interlock condition Program example 1 e S P SFCS S P SVST S P CHGA S P CHGVS P CHGT S P DDWR S P DDRD instructions cannot be executed simultaneously Therefore it is necessary to take an interlock by to self CPU high speed interrupt accept flag from CPUn One PLC CPU can be executed max 32 Motion dedicated PLC instructions simultaneously using to self CPU high speed interrupt accept flag from CPUn Except S P GINT instruction If 33 instructions or more are executed the PLC CPU returns the OPERATION ERROR 4107 f When multiple Motion dedicated PLC instructions are directly executed because one contact point turns on an instruction may not be executed In this case create a program with reference to program
76. occur if e The S data is outside the range 0 to 4294967295 or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which converts the data of DO into an unsigned 32 bit integer value and substitutes the result to 0L 0L ULONG DO 1 0 K65535L lt 4 D0 HOOOOFFFF HFFFF Unsigned value is K65535 5 OPERATION CONTROL PROGRAMS FIFS 5 7 5 Signed 64 bit floating point value conversion FLOAT FLOAT S Number of basic steps Usable data Usable Data Worddevice Constant Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting 16 bit f 32 bit floating ACHA as conditional conditional integer integer i integer integer type expression int expression expression type type L type K H KH L Pon e i type F type K Lond dad aoad aoa d aoa d aoa daoa d ee O Usable Setting data Setting data Data type of result Data which will be converted into signed 64 bit S 64 bit floating point type floating point value Functions 1 The data specified with S is converted into a signed 64 bit floating point value 2 If S is a 64 bit floating point type its value is returned unchanged with no conversion processing performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range
77. of DO and substitutes the result to 0F 0F SIN DO 3 1 0 2 0 70710678118655 lt _ D0 5 OPERATION CONTROL PROGRAMS FIFS 5 6 2 Cosine COS COS S Number of basic steps Usable data Usable Data Bit device Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit OF Calculation pe i floating Coasting 3 floating conditional conditional integer integer i integer integer type expression i aes timer ene expression expression type type L type K H K H L O Usable data Setting data Setting data Data type of result Angle data on which COS cosine operation will F J S Floating point type be performed Functions 1 COS cosine operation is performed on the data specified with S 2 The data specified with S is in an angle degree unit 3 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which performs the COS operation of DO and substitutes the result to 0F 0F COS D0 3 2 RE ee vf wo 5 OPERATION CONTROL PROGRAMS FIFS 5 6 3 Tangent TAN TAN S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8
78. only when it is set with external battery use by system setting Ra a S S ius E o 2 e Turn on when the voltage of the external battery reduces to less than specified value Remains on if normal status OFF Normal is restored ON _ Battery low e Synchronizes with BAT LED Check the voltage of the external battery only when it is set with external battery use by system setting 8 Sett di i OFF No error Turn on when error is found as a result of self diagnosis ee eta ee ON _ Error Remains on if normal status is restored OFF No error e Turn on when error is found as a result of diagnosis 0 Diagnostic error f ON _ Error Remains on if normal status is restored Lae a resent Write clock data stored in D9025 to D9028 to the clock sed q R element when M9025 has changed from off to on OFF N 6 Clock data error ON mia e Turn on by clock data D9025 to D9028 error S Request OFF Ignored e Read clock data from D9025 to D9028 in BCD when 28 Clock dat d t U ON _ Read request M9028 is on O M9036 Always ON oe on without regard to position of RUN STOP switch ON OFF ON Turn off without regard to position of RUN STOP switch Processing M9037 Always OFF urn off without regard to position o switc OFF on OFF ON Error reset A release of the error is executed e Turn on when a watchdog timer error is detected by the Motion CPU self diagnosi
79. or create the non created Motion SFC program Double start should be managed on the user side Provide the user s starting signal as an interlocks in the transition condition Start after the completion of online change Table 11 3 Motion SFC interpreter detection errors 16100 to 16199 Error Processing Corrective Action Error factor Error code a e The code exists but is grammatically 16100 erroneous 16101 e Though not within branch coupling a label jump code within selective branch coupling or a label jump code within parallel branch coupling exists e Selective branch destinations are all headed 16102 16103 16104 Motion SFC code error 16105 Jump code error 1 ein ema nora list code error in jump destination information 16106 Jump code error 2 ein ema Gode label information error in jump destination information 16107 Jump code error 3 Internal code label No error in jump S 16108 16109 Motion SFC program error grammatical error permitted to a pointer Pn or jump Pn A parallel branch is followed by an END step without a parallel coupling An impossible code is used The internal code is corrupted by other than SFT or WAIT transitions WAITON WAITOFF is not followed by a motion control step However this is destination information Jump code error 4 ein sma gode label adaress error in jump destination information Jump destination error e The specifie
80. outputs the data of DO to YO YF DOUT YO DO 5 OPERATION CONTROL PROGRAMS FIFS 5 9 4 Device input DIN DIN D S Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit Calculation a p gt floating Coasting floating conditional conditional integer integer 5 i integer integer type j expression 4 at expression expression type L type K H SS e a e a O Usable Setting data Setting data Data type of result Input destination data Data type of D BE Input source bit data Integer type Functions 1 The bit data specified with S is input to the data specified with D 2 Specify a multiple of 16 as the device No of the bit data specified with S 3 If the type of D is a 16 bit integer type 16 points of the D data starting at the least significant bit are input in order to the bit devices headed by the one specified with S 4 Ifthe type of D is a 32 bit integer type 32 points of the D data starting at the least significant bit are input in order to the bit devices headed by the one specified with S Errors 1 An operation error will occur if e D or S is an indirectly specified device and its device No is outside the range e S is an indirectly specified device and its device No is not a multiple of 16 Program examples 1 Program w
81. outside the range Program examples 1 Program which ANDs 0 and 1 and substitutes the result to DO DO 0 amp 1 7 o Poron 0 i 3 1 Porerenneproeno 5 OPERATION CONTROL PROGRAMS FIFS 5 5 3 Bit logical OR S1 1 S2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison data Bit device 16 bit aa floating Coasting ete Seat floating Calculation snditional conditional integer integer 5 i integer integer type expression x point expression expression type type L type K H K H L type K BISERE EAE AEA E seal l o lol l olol ol dl o l O Usable Setting data Data type of result Data type of S1 or S2 Data which will be ORed bit by bit which is greater Integer type Functions 1 The bit by bit logical add of the data specified with S1 and the data specified with S2 is found 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed At this time note that signed data is converted Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which ORs 0 and 1 and substitutes the result to DO DO 01 1 o poreon DO pooo noonoo em 5 OPERATION CONTROL PROGRAMS FIFS 5 5 4 Bit exclusive logical
82. performed when condition enables transition of active step defined as a single basic operation of the Motion SFC program execution control in the execution cycle of the corresponding task this operation is performed for the number of active steps to terminate processing once And the same operation is processed continuously in the next cycle In this case the transition destination step is executed in the next cycle when the transition condition enables Consecutive transition control indicates that transition destination steps are executed one after another in the same one execution cycle when their transition conditions have enabled single basic operation is performed consecutively In this case the number of consecutive transitions can be set Controls in common to the Motion SFC programs executed by normal tasks Set the number of consecutive transitions to the Motion SFC programs executed by event and NMI tasks for every program Errors These parameters are imported and checked when the PLC ready flag M2000 turns off to on When the value that was set is outside the setting range the following Motion SFC error is set and the initial value is used to control Error code Error cause Error processing Corrective action Note Contents The normal task s Normal task consecutive transition ER Turn PLC ready flag M2000 The initial value consecutive count of the Motion SFC off make correction to set the
83. sets C cam axis No in a character sequence _ St usabie range Q173HCPU 1 to 32 Q172HCPU 1 to 8 The number of axes which can set are only 1 axis The axis No set in the system setting is used as the axis No to start Refer to the Q173HCPU Q172HCPU Motion controller Programming Manual COMMON for system settings 2 Setting of the current value to change S2 usable range 2147483648 to 2147483647 Cam axis within one revolution current value changing flag System area The complete status of the cam axis within one revolution current value changing flag is stored in the address of the cam axis within one revolution current value changing flag in the shared CPU memory Shared CPU memory address is decimal Description address The cam axis within one revolution current value changing flag is stored by the 1 to 32 axis each bit As for a bit s actually being set Q173HCPU C1 to C32 Q172HCPU C1 to C8 20CH 524 OFF Start accept usable 20DH 525 ON Start accept disable 20CH 524 address 20DH 525 address 3 MOTION DEDICATED PLC INSTRUCTION Errors The abnormal completion in the case shown below and the error code is stored in the device specified with the complete status storing device D2 Complete status Note Error factor Corrective action Error code H The specified device cannot be used in the Motion CPU Or it is outside the device range The in
84. shown below Setting Servo program No 10 Synchronous encoder No 1 Indirect designation using D1500 D11501 Current value change address 3 Operation timing CHGA E instruction Synchronous encoder shaft current value changing flag Current value change completion 4 Servo program lt K10 gt T CHGA E Synchronous encoder shaft current value Axis 1 D1500 change control gi e Synchronous encoder No 1 Curent value change address Indirect designation using D1500 D1501 7 MOTION CONTROL PROGRAMS 1 Synchronous encoder current value changing instructions e The current value change of the synchronous encoder is executed if operation is being performed in the virtual mode during pulse input from the synchronous encoder If the current value is changed the feed current value of the synchronous encoder continues from the new value The current value change of the synchronous encoder does not affect the current value of the output module Set the current value change program of the synchronous encoder shaft program within the virtual mode program No range set in program mode assignment When PLC ready flag M2000 or PCPU ready flag M9074 is OFF a minor error N 100 occurs and a current value change is not made If a synchronous encoder current value change is executed in the real mode a servo program setting error oe 903 or 905 occurs an
85. turned on and servo on of 1 axis and 2 axes is confirmed when a forced stop is released No 160 Re start continuation is stopped at the time of the forced stop and actual output PY is turned off 1 This program jumps corresponding to the value of the continuation point 100 of the following 2 1 to 9 moo Jump destination Following 2 1 Following 2 3 30 2 The following motion control is executed 1 This program stands by until PX4 is turned on Restant Normal Netaiad 2 10 is set on continuation point 100 continuation 3 1 axis 2 axes are located in 0 0 in the linear control absolute 2 axes positioning 4 Positioning completion signal on of 1 axis 2 axes is confirmed and 20 is set on the continuation point 100 5 In position on of 1 axis and 2 axes is confirmed 6 1 axis 2 axes are located in 1000000 2000000 in the linear control absolute 2 axes positioning 7 Positioning completion signal on of 1 axis 2 axes is confirmed and 30 is set on the continuation point 100 8 This program stands by until PX4 is turned off 9 0 is set on continuation point 100 APP 25 APPENDICES a No 20 Main F20 SET M9028 Clock data read request on 100 0 Continuation point 0 G20 M9076 Did you release a forced listop F110 SET M2042 All axis servo ON command IION G105 M2415 M2435 Did a thing during serv
86. 000 Gnch min 0 001 to 2147483 647 deg min In case of speed 10x multiplier device Invalid 0 01 to 21474836 47 deg min In case of speed 10x multiplier device Valid At a7 a0 inrer 4 a 94 an aone ar 7 AN Operations for which made the online change to the servo program in the following conditions during execution are shown below Be careful to execute the online change in the following conditions e Online change of the servo program Kn at the WAITON or after WAITOFF is executed in the state of waiting for the completion of condition for WAITON WAITOFF e Online change of the servo program Kn after Gn is executed in the state of waiting for the completion of condition for Gn 10 6 e After completion of condition for WAITON WAITOFF the servo program before the online change is started e The servo program that the online change was made is executed at the next servo program start e After completion of condition for Gn the servo program that online change was made is executed 10 USER FILES 10 3 2 Transfer of program The outline operations to transfer the program from SW6RN GSVOP to the program memory of Motion CPU are described 1 Program writing by the Communication menu Transfer a After transfer programs are stored in the program memory of Motion CPU stuffing to the front for every kind Motion CPU Personal comp
87. 000 or PCPU ready flag M9074 is OFF PLC ready OFF GINT At a Motion SFC program start by automatic start setting or GSUB the specified Motion SFC program does not exist None Motion SFC program At a Motion SFC program start by automatic start setting or GSUB the same Motion SFC program is already starting Double start error e The Motion SFC program which is rewriting the Motion SFC chart by online change was started Online change Error Processing The specified Motion SFC program does not start The active step of Motion SFC program executed by PLC interrupt is not processed Interrupt instruction No is set in the error Motion SFC program No The specified Motion SFC program does not start When it started by GSUB the start source Motion SFC also stop to execute The specified Motion SFC program does not start Corrective Action Provide ON of the PLC ready flag M2000 and PCPU ready flag M9074 as start interlocks Check the Motion SFC program No and correct a PLC program Check the Motion SFC program No and correct a PLC program or create the non created Motion SFC program Double start should be managed on the user side Provide the user s starting signal as a start interlock in the PLC program Provide ON of PLC ready flag M2000 and PCPU ready flag M9074 as S P GINT execution interlocks Check the Motion SFC program No and correct a program
88. 075 M2043 SV22 oa JOG e simultaneous start M3076 e M3077 Manual pulse generator 1 enable flag M3078 Manual pulse generator 2 enable flag M3079 Manual pulse generator 3 enable flag Motion SFC error history clear request M3080 g te Unusable 55 points Command signal Main cycle Note 1 The device of a remarks column turns ON by OFF to ON of the above device and the device of a remarks column turns OFF by ON to OFF of the above device The state of a device is not in agreement when the device of a remarks column is turned on directly In addition when the request from a data register and the request from the above device are performed simultaneously the request from the above device becomes effective Note 2 It can also be ordered the device of a remark column Note 3 M3080 does not turn off automatically Turn it off as an user side 12 Table of the special relay allocated devices Command signal SV13 SV22 Remark Refresh cycle Fetch cycle Signal direction Note 1 Note 2 M3136 Clock data set request Command M3137 Clock data read request Main cycle signal ee Unusable 61 points Note 1 The device of a remarks column turns ON by OFF to ON of the above device and the device of a remarks column turns OFF by ON to OFF of the above device The state of a device is not in agreement when the device of a remarks column is turned on directly Note 2 It can also be ordered the device of a
89. 10 axes 0 44ms 1 to 3 axes 1 77ms 11 to 20 axes 0 88ms 4 to 8 axes Operation cycle 3 55ms 21 to 32 axes default 0 88ms 1 to 5 axes 1 77ms 6 to 14 axes 0 88ms 1 to 4 axes 3 55ms 15 to 28 axes 1 77ms 5 to 8 axes 7 11ms 29 to 32 axes Linear interpolation Up to 4 axes Circular interpolation 2 axes Interpolation functions vie 2 Helical interpolation 3 axes PTP Point to Point control Speed control Speed position control Fixed pitch feed Control modes Constant speed control Position follow up control Speed control with fixed position stop Speed switching control High speed oscillation control Synchronous control SV22 Acceleration Automatic trapezoidal acceleration deceleration deceleration control S curve acceleration deceleration Compensation Backlash compensation Electronic gear Phase compensation SV22 Programming language Motion SFC Dedicated instruction Mechanical support language SV22 Servo program capacity 14k steps Number of positioning 3200 points points Positioning data can be designated indirectly Programming tool IBM PC AT Peripheral I F USB SSCNET Teaching operation s faci None Provided SV13 use None Provided SV13 use unction a Proximity dog type 2 types Count type 3 types Data set type 2 types Dog cradle type Home position return ee f elise Stopper type 2 types Limit switch combined type uncti Home position return re try function provided home position sh
90. 1420 to Axis 3 monitor device to Axis 19 monitor device D1269 D1429 D1270 D1430 to Axis 4 monitor device to Axis 20 monitor device D1279 D1439 D1280 D1440 to Axis 5 monitor device to Axis 21 monitor device D1289 D1449 D1290 D1450 to Axis 6 monitor device to Axis 22 monitor device D1299 D1459 D1300 D1460 to Axis 7 monitor device to Axis 23 monitor device D1309 D1469 D1310 D1470 to Axis 8 monitor device to Axis 24 monitor device D1319 D1479 D1320 D1480 to Axis 9 monitor device to Axis 25 monitor device D1329 D1489 D1330 D1490 to Axis 10 monitor device to Axis 26 monitor device D1339 D1499 D1340 D1500 to Axis 11 monitor device to Axis 27 monitor device D1349 D1509 D1350 D1510 to Axis 12 monitor device to Axis 28 monitor device D1359 D1519 D1360 D1520 to Axis 13 monitor device to Axis 29 monitor device D1369 D1529 D1370 D1530 to Axis 14 monitor device to Axis 30 monitor device D1379 D1539 D1380 D1540 to Axis 15 monitor device to Axis 31 monitor device D1389 D1549 D1390 D1550 to Axis 16 monitor device to Axis 32 monitor device D1399 D1559 1 40 1 OVERVIEW e Detailes of each axis D1240 10n D1241 10n Execute cam No D1242 10n Execute stroke amount D1243 10n D1244 10n urZ Current value within 1 cam shaft revolution D1245 10n D1246 10n D1247 10n Unusable D1248 10n D1249 10n Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU A
91. 2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which compares whether 0 is less than DO or not 0 lt DO m lt True lt po 20 5 OPERATION CONTROL PROGRAMS FIFS 5 11 4 Less than or equal to lt S1 lt S2 Number of basic steps Usable data Usable Data Setting 64 bit i 64 bit Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer 5 i integer integer type 5 expression 2 point expression expression type type L type K H K H L type K ae eT a a a l o lololol olo lolol ee O Usable Setting data Setting data Data type of result S1 ee S2 Data which will be compared Logical type true false Functions 1 The result is true if the data specified with S1 is less than or equal to the data specified with S2 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before comparison is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which compares whether 0 is less than or equal to DO or not 0 lt DO 0 lt True lt po 2 5 OPERATION CONTROL PROGRAMS FIFS 5 11 5 More than gt S1 gt S2 Number of b
92. 2 enable flag request D757 Manual pulse generator 3 enable flag request Command p758__ Unusable device D75 PCPU ready complete flag status Monitor 0 OFF 1 ON device D760 Unusable to 7 30 points D789 D790 Real mode axis information register Monitor D791 SV22 device D792 Unusable to 8 points D799 Note 1 The range of axis No 1 to 8 is valid in the Q172HCPU Note 2 Device area of 9 axes or more is unusable in the Q172HCPU 1 42 1 OVERVIEW 2 Special relays Special relays are internal relays whose applications are fixed in the Motion CPU For this reason they cannot be used in the same way as the normal internal relays by the Motion SFC programs However they can be turned ON OFF as needed in order to control the Motion CPU The headings in the table that follows have the following meanings Explanation No e Indicates the device No of the special relay Name e Indicates the name of the special relay Indicates the nature of the special relay e Indicates detailed information about the nature of the special relay Indicates whether the relay is set by the system or user and if it is set by system when setting is performed lt Set by gt S Set by system Motion CPU U Set by user Motion SFC program or test operation using a peripheral device S U Set by both system Motion CPU and user Set by lt When se
93. 2000 off make correction to set the value of within the range and write it to the CPU Note 0000H normal 9 MOTION SFC PARAMETER Since the execute task can be set for every Motion SFC program No multiple programs need not be written for single control machine operation to divide execution timing based processing s For example it can be achieved easily by subroutine starting the areas to be run in fixed cycle and to be run by external interrupt partially in the Motion SFC program run by the normal task 3 Number of consecutive transitions Description Set the number of consecutive transitions to program executed by the event or NMI task for every program Refer to Section 9 4 Task Parameters for number of consecutive transitions Errors This program parameter is imported when the PLC ready flag M2000 turns off to on and is checked at starting of the Motion SFC program automatic start start from PLC or subroutine start When the value is illegal either of the following Motion SFC errors is set and the initial value is controlled Error code Error cause Error processing Corrective action Note Contents The number of consecutive Event task N transitions of the consecutive f 7 Motion SFC program transition count started by the event task is outside the Turn PLC ready flag M2000 off range 1 to 10 The initial value make correction to set the value error The number of of 1 i
94. 24 DOs SINC Pol Nok eek eee aie eee re ee ee ee ee ee we ee eee 5 24 56 2 COSING S O O Daa acts eteshs cee add satel seeeedst e a a a e a aa a a aE 5 25 SOS Tangent TAN aaa a I E A E E E E O died tien 5 26 5 6 4 Arcsine ASIN E E iad eich cade E E cadet E E E T E T 5 27 5 6 5 Arccosine ACOS ec fa secigtie a a ceases oe ac gon A a a A deal 5 28 9 6 6 Arctangent ATAN sc ctie eh eh tian ented ae tia a a a ei 5 29 5 6 7 Sq ar root SQR P eea ated didi a aa din slid en aaaea a tie edad eed 5 30 9 6 3 Natural logarithimr LN keisrina EEEE EEA EEEE AA 5 31 5 6 9 Exponential operation EXP ccccccecesceeenceeeeeeeeceeeeneeeeaeeseaeeecaeeesaneeseaeeseaeeseeeesenesseaeeseresseessieeees 5 32 5 6 10 Absolute valle A B O Bin eel ee enti Bae a eE Ra 5 33 5 6 1 FH ROUNG Off RAN D EE E Avene et oat S aut Ani eko tains ated atte eh tA rene het 5 34 56 12 ROUNG GOWM T A a a a a eadectaneigeedh calectanbigicsdh oafseties a eaa 5 35 5 6 13 Round up A U S E EE ET PT E E E E E E E E E E 5 36 5 6 14 BCD BIN conversion BIN ece Ra REA AAAA EA RANEA RARA 5 37 5 6 15 BIN BCD conversion BOD peer e E A OA KE E RA 5 38 57 Type Conversions ii nccniiec Aine Ald Aide All del alee all de ade ll de il ded te 5 39 5 7 1 Signed 16 bit integer value conversion SHORT e eee eee ce eee te tee eeee tastes seeeeae tae taeseeenaeeas 5 39 5 7 2 Unsigned 16 bit integer value conversion USHORT eccecceeceeceeeeeeeeeseeeeeeeeeeseeeseeeeeaeeeneeeneeaes
95. 3 status M4139 M4459 M4140 M4460 to Axis 8 status to Axis 24 status M4159 M4479 M4160 M4480 to Axis 9 status to Axis 25 status M4179 M4499 M4180 M4500 to Axis 10 status to Axis 26 status M4199 M4519 M4200 M4520 to Axis 11 status to Axis 27 status M4219 M4539 M4220 M4540 to Axis 12 status to Axis 28 status M4239 M4559 M4240 M4560 to Axis 13 status to Axis 29 status M4259 M4579 M4260 M4580 to Axis 14 status to Axis 30 status M4279 M4599 M4280 M4600 to Axis 15 status to Axis 31 status M4299 M4619 M4300 M4620 to Axis 16 status to Axis 32 status M4319 M4639 1 18 1 OVERVIEW e Detailes of each axis Unusable Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 0 to 31 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 The unused axis areas in the mechanical system program can be used as an user device 1 19 1 OVERVIEW 4 Table of the virtual servomotor axis command signals SV22 only Device No M4800 to M4819 M4820 to M4839 M4840 to M4859 M4860 to M4879 M4880 to M4899 M4900 to M4919 M4920 to M4939 M4940 to M4959 M4960 to M4979 M4980 to M4999 M5000 to M5019 M5020 to M5039 M5040 to M5059 M5060 to M5079 M5080 to M5099 M5100 to M5119 Signal name Axis 1 command signal Axis 2 command signal Axis 3 command signal Axis 4 command signal Axis 5 command signal Axis 6 command sig
96. 32 axes 32 axes Operation Control loop monitor Control loop monitor cycle status status M2303 32 axes 32 axes M2304 to M2319 Unusable Unusable 16 points 16 points 1 27 Status signal Note 2 3 Status signal Note 2 3 Status signal Note 2 3 Status signal Note 2 3 Remark Note 4 1 OVERVIEW Explanation of the request register D a coe e oer Note 1 Handling of D704 to D708 and D755 to D757 register Because cannot be turn ON OFF for every bit from the PLC CPU the above bit devices are assigned to D register and each bit device becomes on with the lowest rank bit 0 1 of each register and each bit device becomes off with 1 gt 0 Use it when the above functions are requested from the PLC CPU using the S P DDRD and S P DDWR instruction Refer to 3 MOTION DEDICATED PLC INSTRUCTION for S P DDRD and S P DDWR instruction Note 2 Device area of 9 axes or more is unusable in the Q172HCPU Note 3 The range of axis No 1 to 8 is valid in the Q172HCPU Note 4 It can also be ordered the device of a remark column Note 5 M3080 does not turn off automatically Turn it off as an user side Note 6 It is unusable in the SV22 real mode The data executed later becomes effective when the same device is executed simultaneously in the Motion SFC program and PLC program 1 28 1 OVERVIEW 10 Table of the special relay allocated devi
97. 421 as G154 Did you turn on 1 axis and 2 axes lin position signal M2402 M2422 F150 0L 1000000 1 axis positioning laddress set 2L 2000000 2 axes positioning laddress set 4L 500000 Positioning speed set K151 Real 1 ABS 2 Axis 1 OPLS Axis 2 2PLS Speed 4PLS s G200 Did 1 axis and 2 axes execute The motion control step executed absolute positioning to application with it when to start again after it stops on the way G202 1M100 Did you t urn off a stop P10 Ipositioning completion M2401 M2421 G156 Did you turn on PX4 and turn loff a stop IPX4 IM100 This program substitutes The internal relay M100 for the stop turns off into the AND status in WAIT transition which wants it to stop G202 1M100 Did you t APP 31 urn off a stop P20 This program is judged whether it was stopped by using the location complete signal during the location on the way This program is made to execute the motion control step of again after internal relay M100 of the stop waits to turn it off when positioning completion is not turned on after the motion control is executed This program is judged whether it was stopped by using the location complete signal during the location on the way It is made to execute the motion control step of again after internal relay M100 of the stop waits t
98. 5 6 10 Absolute value ABS ABS S Number of basic steps Usable data Usable Data Bit device Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit f Calculation on i d R floating Coasting g floating i conditional conditional integer integer integer integer type expression point expression expression data type type L type K H K H L type K O Usable Setting data Setting data Data type of result Data on which absolute value conversion will be S Data type of S performed 1 The absolute value of the data specified with S is found Functions Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which finds the absolute value of DOF and substitutes the result to 0F 0F ABS DOF 3 2 D1 DO EOR a ae 32 5 OPERATION CONTROL PROGRAMS FIFS 5 6 11 Round off RND RND S Number of basic steps Usable data Usable Data Bit device Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit i 16 bit 32 bit i Calculation ii p i R floating Coasting g floating conditional conditional integer integer integer integer type 5 expression a ae timer kann expression expression type type L type K H K H L O Usable data Setting data Setting data Data type of result S Data whos
99. 5 to 132VAC 170 to 264VAC Input frequency 50 60Hz 5 Tolerable momentary 20ms or less power failure 7 Corrective actions for errors A CAUTION If an error occurs in the self diagnosis of the Motion controller or servo amplifier confirm the check details according to the instruction manual and restore the operation if a dangerous state is predicted in case of a power failure or product failure use a servomotor with electromagnetic brakes or install a brake mechanism externally Use a double circuit construction so that the electromagnetic brake operation circuit can be operated by emergency stop signals set externally Shut off with the Shut off with servo ON signal OFF emergency stop alarm magnetic brake signal signal EMG Servomotor a EMG o Electro magnetic brakes A CAUTION If an error occurs remove the cause secure the safety and then resume operation after alarm release The unit may suddenly resume operation after a power failure is restored so do not go near the machine Design the machine so that personal safety can be ensured even if the machine restarts suddenly 8 Maintenance inspection and part replacement CAUTION Perform the daily and periodic inspections according to the instruction manual Perform maintenance and inspection after backing up the program and parameters for the Motion controller and servo amplifier Do
100. 50 D1010 to Axis 6 monitor device to Axis 22 monitor device D859 D1019 D860 D1020 to Axis 7 monitor device to Axis 23 monitor device D869 D1029 D870 D1030 to Axis 8 monitor device to Axis 24 monitor device D879 D1039 D880 D1040 to Axis 9 monitor device to Axis 25 monitor device D889 D1049 D890 D1050 to Axis 10 monitor device to Axis 26 monitor device D899 D1059 D900 D1060 to Axis 11 monitor device to Axis 27 monitor device D909 D1069 D910 D1070 to Axis 12 monitor device to Axis 28 monitor device D919 D1079 D920 D1080 to Axis 13 monitor device to Axis 29 monitor device D929 D1089 D930 D1090 to Axis 14 monitor device to Axis 30 monitor device D939 D1099 D940 D1100 to Axis 15 monitor device to Axis 31 monitor device D949 D1109 D950 D1110 to Axis 16 monitor device to Axis 32 monitor device D959 D1119 1 36 1 OVERVIEW e Detailes of each axis D800 10n Feed current value D801 10n D802 10n D803 10n Major error code D804 10n Execute program No D805 10n M code D806 10n Current value after virtual servomotor axis main D807 10n shaft s differential gear D808 10n Error search output axis No D809 10n Data set pointer for constant speed control Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 0 to 31 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 The unused axis areas in the mechanica
101. 53 Auxiliary input sid M5554 Output axis 18 Main shaft side M5555 Auxiliary input sid M5556 Output axis 19 Main shat side M5557 Auxiliary input sid M5558 Main shaft sid Output axis 20 ans a sce 3 M5559 Auxiliary input sid M5560 Output axis 21 Main shaft side M5561 Auxiliary input sid M5562 Main shaft sid Output axis 22 els M5563 Auxiliary input sid M5564 X Main shaft side Output axis 23 M5565 Auxiliary input sid M5566 Main shaft sid Output axis 24 Ansan sice M5567 Auxiliary input sid M5568 f Main shaft side Output axis 25 EE 7 M5569 Auxiliary input sid a M5570 x Main shaft side Output axis 26 M5571 Auxiliary input sid M5572 Output axis 27 Main shaft side M5573 Auxiliary input sid M5574 7 Main shaft side Output axis 28 M5575 Auxiliary input sid M5576 Output axis 29 Main shaft side M5577 Auxiliary input sid M5578 Main shaft sid Output axis 30 a Se M5579 Auxiliary input sid M5580 k Main shaft side Output axis 31 M5581 Auxiliary input sid M5582 Main shaft sid Output axis 32 E M5583 Auxiliary input sid Note 1 The range of axis No 1 to 8 is valid in the Q172HCPU Note 2 Device area of 9 axes or more is unusable in the Q172HCPU Note 3 The unused axis areas in the mechanical system program can be used as an user device 1 25 1 OVERVIEW 9 Table of the common devices SV13 SV22 owls SV22 Refresh Signal Remark Command M2000 PLC ready flag M2000 PLC ready flag foe atus St
102. 6 1 M21 U3E1 G48 0 U3E1 G516 0 m K h j To self CPU high speed interrupt Start accept flag of the Axis 4 accept flag from CPU No 2 CPU1 i M25 U3E1 G48 0 Y3E1 G516 3 E Y SP SVST H3E1 K106 M34 D24 To self CPU high speed interrupt a pr os accept flag from CPU ices CPU1 M27 U3E1 G48 0 VSE NGS16 4 i V SP SVST H3E1 K107 M36 D26 3 MOTION DEDICATED PLC INSTRUCTION lt Program example 3 gt Program which executes the Motion dedicated function of the operation control step Fn FSn and the motion control program Kn PLC CPU side To self CPU high speed interrupt accept flag from CPU1 M30 een Og a M31 D301 Note SP DDRD H3E1 D300 K4M0 K4M400 M31 M32 M31 To self CPU high Eaa hei peed interrupt Start t accept flag from a accepi flag of the Axis 2 SFC CPU No 2 U3E1 G48 0 U3E1 G516 1 M34 M401 D A a SP SVST H3E1 J1 K104 Interlock condition on axis starting Note 4 points worth of the data from MO of the CPU No 2 are stored after M400 by S P DDRD instruction e Motion CPU side Start program F200 SET M1 Axis 1 positioning start K104 Real 1 INC 1 Axis 1 10000000 PLS Speed 1000000 PLS s F201 RST M1 Axis 1 positioning end Completion Access from the PLC CPU is processed before the communication processing of the Motion CPU Therefore if the Moti
103. 8 monitor device to Axis 24 monitor device D479 D480 Axis 9 monitor device to Axis 25 monitor device D499 D500 Axis 10 monitor device to Axis 26 monitor device D519 D520 Axis 11 monitor device to Axis 27 monitor device D539 D540 Axis 12 monitor device to Axis 28 monitor device D559 D560 Axis 13 monitor device to Axis 29 monitor device D579 D580 Axis 14 monitor device to Axis 30 monitor device D599 D600 Axis 15 monitor device to Axis 31 monitor device D619 D620 Axis 16 monitor device to Axis 32 monitor device D639 1 32 1 OVERVIEW Detailes of each axis V13 SV22 Real mode SV22 Virtual mode Signal derection DO 20n Feed current value roller cycle Feed current value D1 20n speed D2 20n Real current value Real current value D3 20n D4 20n AAN gs Deviation counter value Deviation counter value D5 20n D6 20n D7 20n D8 20n ee Monitor device Home position return re travel D9 20n Hold value D10 20n Travel value after proximity dog D11 20n D12 20n Execute program No D13 20n e E E D14 20n Torque limit value Torque limit value Data set pointer for constant D15 20n speed control D16 20n Command Travel value change register D17 20n device D18 20n i 4 Real current value at stop input Hold Monitor device D19 20n Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32
104. 83648 to 2147483647 2000000000 W100L etc 32 bit integer type unsigned 0 to 4294967295 Ga pit gating point type IEEE format 1 23 10F etc double precision real number type Decimal constant The above data type symbol L or decimal point provided at the end K 100 HOFEL etc indicates the data type The constant without the data type is regarded Ce iat Hexadecimal as the applicable minimum type K may be omitted constant Binary operation a e Bit operation p e O i Standard function Type conversion e Bit device status 63 in total Bit device control Logical operation Comparison operation a 6e O Of Motion dedicated function Input response Direct read control at instruction execution Output response Direct write control at instruction execution 1 OVERVIEW 2 Table of the operation control transition instruction Usable step YIN Pee transition s Section of Classification Basic steps oe F FS G conditional reference expression Binary operation Subtraction emsa ce he ee Y Bit inversion complement Bit operation l Btoscaon fensa Pl oP oT Tsss BitexcusveoR Cissy S 4 fl of J 554 Foto 555 lt lt Bitietshit enea olo ss6 sign Signinversion complement of2 o fol 557 set cos cosine Csi 2 fl Of OT KY 5 2 TAN Tangent Cia SCE 2 fl OP J 68 ASIN arsine Css S 2 fT of OT J 56a acos Arcosin
105. B AMP or Servo amplifier General name for Servo amplifier model MR J3 OB QCPU PLC CPU or PLC CPU module Qn H CPU Multiple CPU system or Motion system Abbreviation for Multiple PLC system of the Q series CPU Abbreviation for CPU No n n 1 to 4 of the CPU module for the Multiple CPU n system Programming software package General name for MT Developer and GX Developer Operating system software General name for SWORN SVOQD SWE6RN SV13Q0 Operating system software for automatic machinery use Motion SFC SW6RN SV22Q0 Abbreviation for Integrated start up support software package MT Developer i MT Developer Version OOK or later Abbreviation for MELSEC PLC programming software package GX Developer GX Developer Version 6 or later Manual pulse generator or MR HDP01 Abbreviation for Manual pulse generator MR HDP01 Serial absolute synchronous encoder yee p Abbreviation for Serial absolute synchronous encoder Q170ENC or Q170ENC Tot High speed synchronous network between Motion controller and servo amplifier PCF SSCNE SSCNET Note 2 High Speed serial communication between Motion controller and servo amplifier General name for system using the servomotor and servo amplifier for Absolute position system wa absolute position B Battery holder unit Q170HBATC General name for Q170HBATC and Q6BAT Teaching Unit or Note 3 A31TU D301 A31TU DNUO Teaching unit A31TU D3KO A31TU DNKO
106. CHGA C instruction 1 Executing the CHGA C instruction changes the within one revolution current value of the specified cam shaft to the address 2 The cam shaft may be starting 3 The used axis No can be set within the following range Q172HCPU Q173HCPU Axis 1 to 8 Axis 1 to 32 4 The address which made the current value change by the CHGA C instruction is valid after also the power supply turned off 7 MOTION CONTROL PROGRAMS Program example A program which made the current value change control of the cam shaft within one revolution current value change is described as the following conditions 1 Current value change control conditions a The current value change control conditions are shown below Item Setting Servo program No Output axis No Current value change address 2 Servo program lt K10 gt CHGA C Cam shaft within one revolution Axis 2 0 current value change control e Output axis No cee 2 Current value change address 0 1 Cam shaft within one revolution current value changing instructions If a new within one revolution current value is outside the range 0 to one revolution pulse count 1 a minor error Note 6120 occurs and current value change is not Set the current value change program the cam shaft within one revolution within the virtual mode program No range set in program mode assignment When PLC ready flag M2000 or
107. CPU high speed interrupt accept flag from CPUn OFF Motion SFC program Motion SFC execution Instruction start accept complete device i D1 0 1 ON Abnormal completion only State display device D1 1 at the instruction start OFF accept completion Instruction accept gt completion at the Motion CPU side 3 MOTION DEDICATED PLC INSTRUCTION Errors The abnormal completion in the case shown below and the error code is stored in the device specified with the complete status storing device D2 Complete status Note Corrective Error factor Error code H action 4C00 The specified device cannot be used in the Motion CPU Or it is outside the device range The instruction for the Multiple CPU system which did not be correspond with operating system software of the Motion Confirm a CPU was executed program and The Motion SFC program No to start is outside the range 0 to 255 There are 33 or more instruction requests to the Motion CPU from the PLC CPU in S P SFCS S P SVST S P CHGA S P GINT sum table simultaneously and the Motion CPU cannot process them 4C09 CPU No of the instruction cause is injustice Note 0000H Normal correct it toa correct PLC program The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO action The CPU No to be set by First I O No of the target CPU 16 is Specified s
108. Changes for the Better MITSUBISHI ELECTRIC MOTION CONTROLLERS wee MOTION CONTROLLER Qseries SV13 SV22 Motion SFC Programming Manual SAFETY PRECAUTIONS Read these precautions before using When using this equipment thoroughly read this manual and the associated manuals introduced in this manual Also pay careful attention to safety and handle the module properly These precautions apply only to this equipment Refer to the Q173HCPU Q172HCPU Users manual for a description of the Motion controller safety precautions These SAFETY PRECAUTIONS classify the safety precautions into two categories DANGER and CAUTION g N Pa N 1 l Indicates that incorrect handling may cause hazardous conditions i D DANGER resulting in death or severe injury l l i CAUTION Indicates that incorrect handling may cause hazardous conditions I resulting in medium or slight personal injury or physical damage Depending on circumstances procedures indicated by CAUTION may also be linked to serious results In any case it is important to follow the directions for usage Store this manual in a safe place so that you can take it out and read it whenever necessary Always forward it to the end user For Safe Operations 1 Prevention of electric shocks lt DANGER Never open the front case or terminal covers while the power is ON or the unit is running as this may lead to elect
109. Chapter 3 of one Motion CPU When an maximum acceptable number of instructions is 32 the program which made not to execute the multiple dedicated instructions when number of the Multiple CPU dedicated execute instructions exceeds 32 is shown as an example 2 lt Example 1 gt SM400 K10 K10 XO PLS To self CPU high speed interrupt accept flag from CPU 1 Mo U3E1 G48 0 EP DDRO H3E1 D50 Do D100 m10 oe To self CPU high speed interrupt accept flag from CPU 1 M1 U3E1 G48 J l 0 RST M1 5 z N To self CPU high speed interrupt accept flag from CI M2 U3E1 G48 0 M10 M11 Read the data from DO to D100 and normality complete processing M11 Read the data from DO to D100 and abnormality complete processing M20 M21 Read the data from D200 to D300 and normality complete processing M21 Read the data from D200 to D300 and abnormality complete processing M30 M31 Read the data from D400 to D500 and normality complete processing M31 Read the data from D400 to D500 and abnormality complete processing APP 11 APPENDICES lt Example 2 gt SM400 aw SM400 M10 1 M20 mu M30 j XO To self CPU high speed interrupt accept flag from CPU 1 MO U3E1 G48 0 Vt BP DDRD H3E1 D50 Do D100 m10 D100 a z H Ig SJE O N To self CPU high speed interru
110. DICATED PLC INSTRUCTION The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO 2110 The CPU No to be set by First I O No of the target CPU 16 is specified The self CPU by First I O No of the target CPU 16 2114 is specified 217 The CPU except the Motion CPU by First I O No of the target CPU 16 is specified 4002 Specified instruction is wrong Confirm a program and correct it to a EA The instruction is composed of devices except usable Correct PLC devices program 4100 Since 0 to 3DFH 3E4H is specified by First I O No of the target CPU 16 is specified Number of the writing data is except 1 to 16 Number of writing data exceeds range of the storage device of the written data Note 0000H Normal Program example lt Example 1 gt lt Example 2 gt Program which stores 10 points worth of the data from DO of the CPU Program stores 10 points worth of the data from DO of the CPU No 2 since D100 of self CPU CPU No 1 when XO is turned on since D100 of self CPU CPU No 1 during turn on X0 SM400 SM400 K10 D51 X0 X0 M10 HET D50 Do D100 mo y HE1 D50 DO D100 MO M1 l Normal complete processing m MO M10 Abnormal complete processing RST vo M10 M11 Normal complete processing M11 Abnormal complete processing 3 45 3 MOTION DEDICATED PLC INSTRUCTION
111. G operation speed of 1 axis and 2 axes is set 2 1 axis JOG forward command is turned on when PX3 is on and the reverse command is turned on when PX4 is on 3 2 axes JOG forward command is turned on when PX5 is on 20 JOG Normal Not start and the reverse command is turned on when PX6 is on 4 The above 2 3 are repeated during PX2 PX1 is off when except for it the JOG forward and reverse command of 1 axis and 2 axes are turned off and the program is ended e 1 pulse input magnification of the 1 axis and 2 axes is set up e 1 axis is controlled with P1 and set up to control 2 axes with P2 and Manual pulse generator enable flag of P1 P2 is turned Manual pulse 1 Normal Not start generator When except for PX2 OFF PX1 ON Manual pulse generator mode Manual pulse generator enable flag of P1 P2 is turned off and a program is ended APP 14 All axes servo on e The call of the subroutine of the following program is executed by the condition of PX1 PX2 1 PX2 OFF PX1 OFF No 120 JOG 2 PX2 OFF PX1 ON No 130 Manual pulse generator Motion control 20 1 1 30 APPENDICES Motion SFC program list Continued _ Number of No Program name Task i Contents of processing K140 The home position return of 1 axis is started when PX3 is on K141 The home position return of 2 axes is started Home position Normal Not start when PX 4 is on return e PX2 ON PX1 The progr
112. G190 100 0 Is a continuation point 0 E r G191 G192 100 20 Is a continuation point 20 Ce Fa G193 100 30 Is a continuation 100 10 Is a continuation Ipoint 30 point 10 G151 Did you turn on PX4 PX4 F189 100 10 Continuation point 10 P10 K150 Real 1 ABS 2 Axis 1 OPLS Axis 2 OPLS Speed 500000 PLS s G195 Did you turn on 1 axis and 2 axes positioning completion M2401 M2421 F190 100 20 Continuation point 20 P20 G154 Did you turn on 1 axis and 2 axes in position signal M2402 M2422 F150 0L 1000000 1 axis positioning laddress set 2L 2000000 2 axes positioning laddress set 4L 500000 Positioning speed set yva HY The process is started corresponding to the value of 100 continuation point from each point of PO to P30 For the continuation from P10 The motion control step K151 Real executed absolute posi 1 ABS 2 tioning to application when Axis 1 0 PLS to start again after it stops Axis 2 2 PLS on the way Speed 4 PLS s This program is judged by using the positioning completion signal whether it was stopped during the positioning on the way When it stops on the way a switchover is stopped in this program clear step G195 Did you turn on 1 axis and 2 axes positioning completion M2401 M2421 stop
113. K ae eT a a a l o lololol olo lolol ee O Usable Setting data Setting data Data type of result S1 T Data which will be compared Logical type true false Functions 1 The result is true if the data specified with S1 is greater than or equal to the data specified with S2 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before comparison is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which compares whether 0 is greater than or equal to DO or not 0 gt DO 0 True q gt oa 5 OPERATION CONTROL PROGRAMS FIFS 5 12 Motion Dedicated Functions CHGV CHGT 5 12 1 Speed change request CHGV CHGV S1 S2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison data bi bi bi bi Calculati pi H Bit device ips 32 bit floating Coasting hg bit FADI floating S A conditional conditional integer integer type expression integer integer point timer point expression expression type type L type F type K H K H L type K pst o sz o o o o 9 Usable Setting data Setting data Data type of result z SS lt given S2 Specified speed Fun
114. LC CPU in d S P SFCS S P SVST S P CHGA S P GINT sum table simultaneously and the an i Motion CPU cannot process them correct it e When using the S P DDRD S P DDWR instruction toa There are 33 or more instruction requests to the Motion CPU from the PLC CPU in correct S P DDRD S P DDWR sum table simultaneously and the Motion CPU cannot PLC process them program 4Co9 CPU No of the instruction cause is injustice ACOA Data error The instruction which cannot be decoded in the Motion CPU was specified 4C80 4C81 4C83 4C84 program H W error of the target CPU Number over of execute instructions of the target CPU There are 33 or more instruction requests to the Motion CPU from the PLC CPU in S P SFCS S P SVST S P CHGA S P SHGV S P CHGT S P DDRD and S P DDWD sum table simultaneously and the Motion CPU cannot process them 4C90 4 Self CPU operation data area used by Motion dedicated instruction 30H to 33H The complete status of the to self CPU high speed interrupt accept flag from CPUn is stored in the following address Shared CPU memory address 30H 48 Description To self CPU high speed interrupt accept flag from CPU1 To self CPU high speed interrupt accept flag from CPU2 To self CPU high speed interrupt accept flag from CPU3 To self CPU high speed interrupt accept flag from CPU4 This area is used to check whether to self CPU high speed interrupt accept flag from CPUn can be acc
115. Minor error 305 If the absolute value of a negative new speed is higher than the speed specified with the servo program during constant speed control return control is exercised at the speed specified in the program speed clamp control for a speed change during constant speed control At this time an error will not occur 5 OPERATION CONTROL PROGRAMS Program examples 1 Program which changes the positioning speed of axis 2 CHGV K2 K10 2 Return program which changes the positioning speed of axis 1 to a negative value CHGV K1 K 1000 The following operation will be performed when a return request is made in constant speed control Servo program CPSTART2 Axis 1 Axis 2 Speed 1000 P1 a Axis 1 10000 Axis2 0 i p2 ABS 2 i Axis 2 10000 i ABS 2 l Axis 1 20000 Starting point Axis 2 10000 CPEND P3 Stat request SVST Start accept M2001 n CHGV 1000 7000 Speed change request New speed Return operation to point Waiting at Pa Combined speed Command in position OFF Speed change 0 i accepting flag ee er If a speed change to a negative speed is made during execution of positioning to P2 as shown above the axis returns to P1 along the program specified locus and waits at P1 5 OPERATION CONTROL PROGRAMS 1 A speed change may be invalid if it is made from when a servo program start request is made until the positioning start completion s
116. Motion SFC program Section 4 in this manual Motion control in SV13 SV22 real mode Q173HCPU Q172HCPU Motion controller Servo program SV13 SV22 Programming Manual REAL MODE Motion control in SV22 virtual mode Q173HCPU Q172HCPU Motion controller SV22 Mechanical system program Programming Manual VIRTUAL MODE 2 STRUCTURE OF THE MOTION CPU PROGRAM 2 1 Motion Control in SV13 SV22 Real Mode 1 System with servomotor is controlled directly using the servo program in SV13 SV22 real mode 2 Setting of the positioning parameter and creation of the servo program Motion SFC program are required 3 The procedure of positioning control is shown below 1 Motion SFC program is requested to start using the S P SFCS instruction of the PLC program Motion SFC program can also be started automatically by parameter setting t 2 Execute the positioning control using the specified the Motion SFC program Output to the servo amplifier 3 The servomotor is controlled Program structure in SV13 SV22 real mode lt PLC CPU gt lt Motion CPU gt PLC program i Motion SFC program s C Transier H i T SP SFCS we Ko G100 M2049 servo ON received Servo amplifier Start request Specification of starting i the Motion i i K10 real H SFC program i i 1 INC 2 E i Axis 1 10000 PLS i i Axis 2 20000 PLS i 3 Servomotor x The Motion SFC p
117. N data can be converted into BCD data e S is 0 or a negative number Natural logarithm LN execution error 16338 16380 16381 16382 16383 16398 16399 16400 16402 16403 16404 16405 11 6 The block processing on executing is stopped and the next block is executed The block processing in execution is stopped and the next block is executed Error Processing Corrective Action Correct the program so that the device No which indirectly specifies D is proper Correct the program so that the S data is within the signed 16 bit integer value range Correct the program so that the S data is within the unsigned 16 bit integer value range Correct the program so that the S data is within the signed 32 bit integer value range Correc 90 180 n n is an integer Correc the program so tha he signed 32 bit inte the program so tha the S data is ger value range S is not the program so tha range of 1 0 to 1 0 S is within the Correct the program so that S is a positive number Correct the program so that each digit of S is 0 to 9 Correct the program so that the S value is within the range Correct the program so that S is a positive numbe r 11 ERROR CODE LISTS Table 11 5 Operation control transition execution errors 16300 to 16599 continued Error code Write device data to shared CPU memory of the self CPU MULTW exec
118. N DEDICATED PLC INSTRUCTION Operation First S P DDRD Second S P DDRD instruction accept instruction accept To self CPU high speed interrupt accept flag from CPUn Instruction accept destination OFF buffer memory f I f i I i I f f S P DDRD instruction OFF l First T i I ON First S P DDRD instruction complete device N State display device at the first S P DDRD instruction completion I i i i i i i i i i i i Abnormal completion j 1 i L S P DDRD instruction Second Second S P DDRD instruction complete device State display device at the second OFF S P DDRD instruction completion First S P DDRD Second S P DDRD instruction completion instruction completion with response with response Errors The abnormal completion in the case shown below and the error code is stored in the control data S1 0 Complete status Complete status Error code H Error factor Corrective action 4C00 The specified device cannot be used in the Motion CPU Or it is outside the device range Confirm a There are 33 or more instruction requests to the Motion program and CPU from the PLC CPU in S P DDRD S P DDWR correct it to a sum table simultaneously and the Motion CPU cannot correct PLC process them program 4C09 CPU No of the instruction cause is injustice Note 0000H Normal 3 MOTION DE
119. O X0 X10 D100 W0 W100 YO gt M100 ABS 1 Axis1 D100 Speed 10000 1X0 4 MOTION SFC PROGRAMS 4 2 Motion SFC Chart Symbol List Parts as Motion SFC program components are shown below The operation sequence or transition control is expressed with connecting these parts by directed lines in the Motion SFC program Symbol y Classification Name List Representation Function Code size byte Indicates an entry of program as a program name Program name Specify this program name at a subroutine call Only one program name for one program Indicates an end exit of program When a subroutine call was carried out returns to the END call source program Multiple program names or no symbols for one program 0 8 Motion control Kn step CALL Kn Starts a servo program Kn KO to K4095 8 Fn 8 8 Program start end Once execution type operation control step Execute once the operation control program Fn FO to CALL Fn F4095 Repeats an operation control program FSn FSO to CALL FSn z 7 FS4095 until the next transition condition enables When the next of GSUB is WAIT performs subroutine call and transits control to the specified program Control returns to the call source program at END execution GSUB program name When the next of GSUB is except WAIT performs subroutine start and starts the specified program and transits to the ne
120. OPERATION CONTROL PROGRAMS FIFS 5 13 4 Block transfer BMOV BMOV D S n Number of basic steps 6 Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit Calculation a p floating Coasting i floating conditional conditional integer integer 5 integer integer type j expression 4 point expression expression type L type K H Oe A e e eaga e ee a a E a E O Usable Note 1 Refer to the Section 1 2 5 for the correspondence version of the Motion CPU and the software Setting data O D Transfer destination device starting No Transfer source device starting No n Number of words to be transferred Functions 1 The contents for n words from device specified with S are batch transferred to the n words from device specified with D 2 Data can be transferred if the devices of the transfer source and destination overlap Data are transferred from devices starting with the one at S for transfer of data from devices of larger numbers to those of smaller numbers or starting with the one at S n 1 for transfer of data from devices of smaller numbers to those of larger numbers 3 Specifying Nn cam No at D or S enables batch transfer of cam data In the Motion controller the cam data of same cam No must already have been registered The number of transferred words specified with n should match th
121. OR S1 S2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit s Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer 5 i integer integer type expression x point expression expression type type L type K H K H L type K BISERE EAE AEA E seal l o lol l olol ol dl o l O Usable Setting data Data type of S1 or S2 which is greater Integer type Functions 1 The bit by bit exclusive logical add of the data specified with S1 and the data specified with S2 is found 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed At this time note that signed data is converted Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which EXCLUSIVE ORs 0 and 1 and substitutes the result to DO bO ccce o bonoen bO 1 ooooooanaaua 5 OPERATION CONTROL PROGRAMS FIFS 5 5 5 Bit right shift gt gt S1 gt gt S2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer 5 i integer integer t
122. PU J1 to J32 Q172HCPU J1 to J8 OFF Start accept usable 206H 518 ON Start accept disable 207H 519 b15 206H 518 address b1 bO J2 J1 J17 207H 519 address 3 MOTION DEDICATED PLC INSTRUCTION Errors The abnormal completion in the case shown below and the error code is stored in the device specified with the complete status storing device D2 Complete status Note Error factor Corrective action Error code H The specified device cannot be used in the Motion CPU Or it is outside the device range Confirm a program The instruction for the Multiple CPU system which did not be correspond with operating system software of and correct it to a the Motion CPU was executed correct PLC 4C06 Axis No set by CHGV instruction is injustice RRISIN 4C09 CPU No of the instruction cause is injustice Note 0000H Normal The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO 2110 The CPU No to be set by First I O No of the target CPU 16 is specified Sita The self CPU by First I O No of the target CPU 16 is specified Confirm a program 217 The CPU except the Motion CPU by First I O No of and correct it to a the target CPU 16 is specified correct PLC ER program The instruction is composed of devices except usable devices 4004 4100 Since 0 to 3DFH 3E4H by First I O No of the target CP
123. Phase compensation function function Indirect setting of home position Se setting with word devices D W 0 Only direct setting by programming software return data Motion CPU 0 001 to 2147483 647 degree min fixed SSCNET When the speed control 10 X multiplier setting for degree axis is valid 0 01 to 21474836 47 degree min When the speed control 10 lt multiplier setting for degree axis is invalid 0 001 to 2147483 647 degree min Fetch of external signal input Q172LX General input of servo amplifier Note 2 Q172LX Optional data monitor function 3 points axis Specified device D W Ne es ll When the speed change is executed after When the speed change is executed after positioning automatic decerelation start or during positioning automatic decerelation start or during decerelation by the JOG start command signal decerelation by the JOG start command signal M3202 20n M3203 20n OFF since the M3202 20n M3203 20n OFF a minor error speed change request is ignored a minor error 303 304 will occur 303 304 will not occur Servo OFF is executed for all servo amplifier Servo OFF is executed for only servo amplifier connected behind servo amplifier with which the with which the control power supply was turned control power supply was turned OFF OFF Internal rechargeable battery Internal rechargeable battery Set the external battery Q6BAT if continuous Set the external battery A6BAT MR BAT if power
124. RVIEW M921 M921 z z z z N N is a a o N D o oO N ms N N N N N N ENS pN pS D pS iN N a a P a Manual pulse generator axis setting error flag TEST mode request error flag Servo program setting error flag ON Table 2 1 Special relay list continued No Name Meaning Details Stiby Remark When set At least one D714 to D719 setting is abnormal All D714 to D719 settings are normal Abnormal Normal Abnormal Normal This flag indicates whether the setting designated at the manual pulse generator axis setting register D714 to D719 is normal or abnormal When this relay turns on the error content is stored at the manual pulse generator axis setting error register D9185 to D9187 Turn on if the TEST mode is not established in response to a TEST mode request from a peripheral device When this relay turns on the error content is stored at the TEST mode request error register D9182 to D9183 e This flag status indicates whether the positioning data of the servo program K specified with the Motion SFC program is normal or abnormal and if error is detected this flag turns S Occur an error S Occur an error S Occur an error on The content of a servo program setting error is stored at D9189 and D9190 CPU No 1 MULTR OFF to ON Turn on when the data read from CPU No 1 is performed c
125. Reverse rotation JOG start comannd command M3204 20n Complete signal OFF command Complete signal OFF command Speed position switching enable Speed position switching enable M3205 20n command comannd M3206 20n Unusable Unusable M3207 20n__ Error reset command M3208 20n External stop input disable at start External stop input disable at start M3209 20n command command M3210 20n Unusable Unusable M3211 20n Feed current value update request Feed current value update request M3212 20n command command Address clutch reference setting command M3213 20n Cam reference position setting M3214 20n command M3216 20n Gain changing command Gain changing command Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 0 to 31 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 Device area of 9 axes or more is unusable in the Q172HCPU Unusable 1 17 1 OVERVIEW 3 Table of the virtual servomotor axis statuses SV22 only M4000 M4320 to Axis 1 status to Axis 17 status M4019 M4339 M4020 M4340 to Axis 2 status to Axis 18 status M4039 M4359 M4040 M4360 to Axis 3 status to Axis 19 status M4059 M4379 M4060 M4380 to Axis 4 status to Axis 20 status M4079 M4399 M4080 M4400 to Axis 5 status to Axis 21 status M4099 M4419 M4100 M4420 to Axis 6 status to Axis 22 status M4119 M4439 M4120 M4440 to Axis 7 status to Axis 2
126. S 10 3 1 Operating method for The Online Change Select the Online change OFF ON of Motion SFC program with the program editor screen Convert menu Online change setting of SW6RN GSVOP There are following three methods for the online change of Motion SFC program e When the program editor screen SFC diagram write is used Online change of the Motion SFC program e When the operation control transition program editor screen Convert is used Online change of the operation control transition program editor screen e When the servo program editor screen Store is used Online change of the servo program 1 When the program editor screen SFC diagram write is used Online change of the Motion SFC program during edit is executed by selecting the SFC diagram write key Online change is possible to the Motion SFC program during stop If the online change is made to the program during execution an alarm message indicates Execution stop state of the Motion SFC program can be checked with the program batch monitor If the start request is made to the program during online change the Motion SFC start error error code16007 online change will occur and the program does not start e SFC Diagram Write Key pief Communication lalx geal Sl o ealss e ze ere Soto D a ees Communication Transfer Online Change orr Password Set TEL data
127. S instruction At occurrence of a valid event after execution of the number of consecutive transitions of the corresponding program S P SFCS instruction the program is run from the initial first step in accordance with the number of consecutive transitions of the corresponding program Start control e When subroutine started At occurrence of a valid event after execution of GSUB the program is executed from the first step in accordance with the number of consecutive transitions of the corresponding program e When subroutine called The program is executed immediately from the first step After that the program is executed continuously by the number of consecutive transitions of the corresponding program at occurrence of a valid event The subroutine called program is controlled in accordance with the executed task and number of consecutive transitions of the call source program END control END As specified for END operation 9 MOTION SFC PARAMETER e Program run by NMI task When automatically started When not automatically started At occurrence of a valid event after starting of the The program is started by the Motion SFC start instruction PLC ready flag M2000 the program is executed S P SFCS from the PLC or by a subroutine call start from the initial first step in accordance with the number of consecutive transitions of the corresponding program GSUB made fro
128. SFCS consecutive transitions of the normal task instruction the program is executed from the initial first step in accordance with the number of consecutive transitions of Start control the normal task e When subroutine started In the next main cycle after execution of GSUB the program is executed from the first step in accordance with the number of consecutive transitions of the normal task e When subroutine called The program is executed in the same cycle from the first step After that the program is executed continuously by the number of consecutive transitions of the normal task in the motion main cycle The settings of executed task and number of consecutive transitions of the subroutine called program are invalid It is controlled as the normal task Ends the self program Again the program is started by the Motion SFC start instruction S P SFCS from the PLC or by a subroutine call start GSUB made from the Motion SFC program END control END e Program run by event task When automatically started When not automatically started At occurrence of a valid event after starting of the The program is started by the Motion SFC start instruction PLC ready flag M2000 the program is executed S P SFCS from the PLC or by a subroutine call start from the initial first step in accordance with the GSUB made from within the Motion SFC program e When started by the S P SFC
129. Start request of the Motion SFC program Program No may be specified S P SVST Start request of the specified servo program S P CHGA Current value change request of the specified axis S P CHGT Torque control value change request of the specified axis S P DDWR Write from the PLC CPU to the Motion CPU S P DDRD Read from the devices of the Motion CPU S P GINT Execute request of an event task of Motion SFC program Note As for the details of each instruction it explains after the next section 3 1 1 Restriction item of the Motion dedicated PLC instruction 1 To self CPU high speed interrupt accept flag from CPUn Common precautions of the Motion dedicated PLC instruction as shown below a To self CPU high speed interrupt accept flag from CPUn is shown in the following table To self CPU high speed interrupt accept flag from CPUn is No operation even if the instruction is executed when it is cannot be accepted When the Motion dedicated PLC instruction is accepted in the Motion CPU to self CPU high speed interrupt accept flag from CPUn of the self CPU Motion CPU shared CPU memory cannot be accepted and processing toward the instruction for requirement When processing is completed and it becomes the condition that it has an instruction accepted to self CPU high speed interrupt accept flag from CPUn can be accepted 3 MOTION DEDICATED PLC INSTRUCTION Shared CPU memory address Example of the reading Description
130. U 16 is specified Note 0000H Normal Program example Program which changes the positioning speed of the axis No 1 of the Motion CPU CPU No 4 from PLC CPU CPU No 1 to 1000 To self CPU Speed changing flag high speed of the axis No 1 interrupt accept CPU No 4 flag from CPU U3E3 U3E3 G518 0 M100 G48 0 t M 18 cHe Vv H3E3 s1 1000 mo Do MO M1 S Normal complete program Abnormal complete program 3 MOTION DEDICATED PLC INSTRUCTION 3 6 Torque Limit Value Change Request Instruction from The PLC CPU to The Motion CPU S P CHGT PLC instruction S P CHGT wa Usable devices Internal devices MELSECNET 10 Special Bit Indirectly Index ror User File direct JO O function Constant digit KH Other Setting data Note specified ee et register specified device ieee ZO Ed eae 2 2 ewe ae ee fr 2 ose Cu eee fee ff i a ae a a ee O Usable A Usable partly Note Setting data except S1 Index qualification possible Instruction Condition Start request SP CHGT _ Start request S CHGT Setting data Setting data Data type First I O No of the target CPU 16 n1 Value to specify actually is the following CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H S4 Axis No Jn Note 2 to execute the torque limit va
131. U Motion controller Programming Manual COMMON for system settings 2 Setting of the current value to change S2 usable range 2147483648 to 2147483647 Synchronous encoder current value changing flag System area The complete status of the synchronous encoder current value changing flag is stored in the address of the synchronous encoder current value changing flag in the shared CPU memory Shared CPU memory address Description is decimal address The synchronous encoder current value changing flag is stored by the 1 to 16 axis each bit As for a bit s actually being set Q173HCPU E1 to E12 Q172HCPU E1 to E8 208H 520 OFF Start accept usable ON Start accept disable 208H 520 address E16 Errors The abnormal completion in the case shown below and the error code is stored in the device specified with the complete status storing device D2 Complete status Note Error factor Corrective action Error code H 4C00 The specified device cannot be used in the Motion CPU Or it is outside the device range The instruction for the Multiple CPU system which did not be correspond with operating system software of the Motion CPU was executed Confirm a program 4C05 Axis No set by CHGA instruction is injustice and correct it to a There are 33 or more instruction requests to the correct PLC Motion CPU from the PLC CPU in S P SFCS program S P SVST S P CHGA S P GINT sum table simult
132. U No 4 3E3H 16 bit n2 Motion SFC program No to start binary Complete devices Note 1 16 bit binary D1 0 Device which make turn on for one scan at accept completion of instruction D1 1 Device which make turn on for one scan at accept abnormal completion of instruction D1 0 also turns on at the abnormal completion 16 bit D2 Device to store the complete status binary Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration 1 This instruction is dedicated instruction toward the Motion CPU in the Multiple CPU system Errors occurs when it was executed toward the CPU except the Motion CPU 3 MOTION DEDICATED PLC INSTRUCTION 2 Request to start the Motion SFC program of the program No specified with n2 The Motion SFC program can start any task setting of the normal task event task and NMI task 3 This instruction is always effective regardless of the state of real mode virtual mode mode switching when the operating system software of Motion CPU is SV22 4 S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P SFCS instruction When the Motion dedicated PLC instruction is started continuously it is necessary to execute the next instruction after the complete device of executing instruction turns on Operation PLC program S P SFCS instruction To self
133. U U3E3 U3E3 G524 0 G48 0 J SP CHGA H3E3 c1 K10 mo Do E Normal complete program M 1 uuu Abnormal complete program 3 MOTION DEDICATED PLC INSTRUCTION 3 5 Speed Change Instruction from The PLC CPU to The Motion CPU S P CHGV PLC instruction S P CHGV Usable devices Internal devices y MELSECNET 10 Special Sa File Bit Indirectly eataa Enc Index Sbhsta t i System Use digit specified ree nee register Other register specified device Setting data Note O Usable A Usable partly Note Setting data except S1 Index qualification possible Instruction Condition Start request SP CHGV sP cHov _4 Start request S CHGV S CHGV Setting data Setting data Data type First I O No of the target CPU 16 n1 Value to specify actually is the following CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H Axis No Jn N to execute the speed change Character S0 Q173HCPU J1 to J32 Q172HCPU J1 to J8 sequence 16 bit S2 Setting of the current value to change bi l inary Note 1 16 bit binary Complete devices D1 0 Device which make turn on for one scan at accept completion of instruction D1 1 Device which make turn on for one scan at accept abnormal completion of instruction D1 0 also turns on at the
134. Y N are the same as those enciea between Shift and WAIT Completion Y of condition A YIN transition is designed to describe the following two route selective branch program easily lt Y N transition is not used gt GO and G1 programs should be different only in acknowledgement negation of the conditional expressions Example 1 Example 2 G 0 G 0 G1 MO Bokt00 So H100 lt Y N transition is used gt Set the GO program shown in above Example 1 or Example 2 as a GO program The Motion SFC program list codes after conversion are the ft Oe same as in the conventional description different only in the Motion SFC chart representation Therefore automatic search for free G number automatic generation of program which conditional expression part is logically negated is performed during program editing to occupy two G programs Using Program editor to delete a Y N transition does not delete the automatically generated G program G1 below Use Program use list to delete that program 4 MOTION SFC PROGRAMS SSS SSS SS SSeS 1 Automatic free G number search feature a When not set to automatic numbering Searches for a free number forward starting with the set G number 1 at the Shift Y N or WAIT Y N symbol When no free numbers are found afte
135. a stop input signal PX5 from the input unit is off the treatment of the following 2 is executed and 1 axis and 2 axes executed the following 3 during servo on in the case of the one except for it 170 Stop Normal Not start 2 1 axis and 2 axes stop command are turned off and an internal relay M100 for the stop is turned off 3 1 axis and 2 axes stop command are turned on and an internal relay M100 for the stop is turned on 1 The following motion control is executed 1 This program stands by until PX4 is turned on 2 1 axis and 2 axes are located in 0 0 in the linear interpolation control absolute 2 axes positioning 3 Positioning completion signal on of 1 axis and 2 axes are confirmed 4 In position on of 1 axis and 2 axes are confirmed Progra 5 1 axis and 2 axes are located in 1000000 2000000 in the linear operation Normal Not start control absolute 2 axes positioning 6 Positioning completion signal on of 1 axis and 2 axes are confirmed 7 This program stands by until PX4 is turned off 2 When a positioning completion signal of the above 1 3 and 6 is off it waits to turn off and When a positioning was suspended on the way execute the motion control step 1 2 or 5 again 3 Until an internal relay M100 for the stop turns it on it does not move to the next step of the above 1 1 and 7 APP 29 APPENDICES a No 20 Main F20 SET M9028 Clock data read request on
136. al register D9182 to M9197 transferred to W38A to Automatic refresh of the between Multiple CPU and W100 to of Q173HCPU CPU No 2 sets it up to have refresh by DO to of Qn H CPU CPU No 1 therefore the condition of Q173HCPU CPU No 2 can be grasped with Qn H CPU of the CPU No 1 by monitoring the following device Devices of QNHCPU CPU No 1 D0000 to D0639 D0640 to D0655 D0656 to D0671 Correspond with devices of Q173HCPU CPU No 2 D0000 to D0630 D9000 to D9015 D9182 to D9197 Note Refresh does data for 32 axes by this sample example number of refresh points is made a necessary minimum corresponding to the system for processing time shortening APP 16 APPENDICES b No 20 Main F20 SET M9028 Clock data read request ON G20 M9076 Did you dur listop S ing the forced Motion control Main When a forced stop is released a subroutine starts No 110 Motion control Because the next step is a shift it becomes a subroutine start and the next step is executed at the same time with subroutine practice too G21 lIforced stop M9076 Did you release the CLR Fi Motion control F25 DOUT PY10 H0000 16points OFF HIPY10 to PY1F J No 110 Motion control is made to stop at the time of the forced stop and The program that a subroutine ca
137. alue specified in the CHGT instruction Torque limit value at a midway point in constant speed control or speed switching control Torque limit value at the point of switching to position control in speed position changing control Torque limit value in speed control b The CHGT instruction accepts a torque limit value which is higher than the torque limit value set in the servo program or parameter block 6 The torque limit value changed by CHGT instruction is effective only during power supply is on Errors 1 An operation error will occur and a torque limit value change will not be made if e The specified axis No at S1 is outside the range or e S2 is an indirectly specified device and its device No is outside the range 2 A minor error will occur and a torque limit value change will not be made if e The torque limit value specified with S2 is outside the range 1 to 1000 Minor error 311 or e The CHGT instruction is executed for any axis that has not yet been started Minor error 312 Program examples 1 Program which changes the torque limit value of axis 2 CHGT K2 K10 1 CHGT instruction is invalid ignored during the virtual mode When changing the torque limit value during operation in the virtual mode set the torque limit value setting device in the output module parameter of the mechanical system program 2 There will be a delay of time equivalent to an operation cycle at the maximu
138. am 2 running is stopped at the point of error detection 4 12 4 MOTION SFC PROGRAMS Instructions There are no restrictions on the depth of subroutine call start nesting For a subroutine start the start source Motion SFC program continues processing if the start destination Motion SFC program stops due to an error For a subroutine call the call source Motion SFC program stops running as soon as the call destination Motion SFC program stops due to an error 4 MOTION SFC PROGRAMS 4 5 4 Clear step Operations Errors Instructions 2 3 4 5 Stops the Motion SFC program of the specified CLR Clear step Program name program name Stops the specified Motion SFC program running The clear specified Motion SFC program will not start automatically after stopped if it has been set to start automatically The specified program may be its self program If the specified program is being subroutine called the subroutine program called is also stopped Shown below MAIN SUB If the program has been subroutine called as shown on the left fire When the call source program MAIN is cleared Even if the subroutine SUB is running both the call source program MAIN and subroutine SUB stop running No j When the subroutine SUB is running the subroutine SUB WAIT END stops running and execution to the call source
139. am is ended when they become to except for off Home position return mode When PX3 detects OFF to ON after positioning of 1 axis standing by for 1000 ms and positioning of 2 axes is executed e When PX4 turn on after positioning of linear interpolation in Programming position check is executed positioning of axis No 1 2 linear f Normal Not start l SR kai operation interpolation is executed at a double speed in the opposition direction and it stand by until PX4 turned off e PX2 ON PX1 The program is fended when they become to except for ON Programming operation mode APP 15 APPENDICES a No 0 Positioning device Positioning device FO Each axis status M2400 to M3039 I 40 words IM2400 to CPU No 1 of the Qn H CPU DIN WOOL M2400 DIN WO2L M2432 DIN WO4L M2464 DIN WO6L M2496 DIN WO8L M2528 DIN WOAL M2560 DIN WOCL M2592 DIN WOEL M2624 DIN W10L M2656 DIN W12L M2688 DIN W14L M2720 DIN W16L M2752 DIN W18L M2784 DIN W1AL M2816 DIN W1CL M2848 DIN W1EL M2880 DIN W20L M2912 DIN W22L M2944 DIN W24L M2976 DIN W26L M3008 Common devices M2000 to M2063 4 words 1M3040 to CPU No 1 of the Qn H CPU DIN W28L M2000 DIN W2AL M2032 Special relays M9000 to M9015 1 word 1M3104 to CPU No 1 of the Qn H CPU DIN W2C M9000 lISpecial relays M9064 to M9079 1 word 1M3110 to CPU No 1 of the Qn H CPU DIN W2D M9064 F1 Each axis monitor devices
140. aneously and the Motion CPU cannot process them 4Cc09 CPU No of the instruction cause is injustice Note 0000H Normal 3 MOTION DEDICATED PLC INSTRUCTION The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO 2110 The CPU No to be set by First I O No of the target CPU 16 is specified AT The self CPU by First I O No of the target CPU 16 is specified Confirm a program 2117 The CPU except the Motion CPU by First I O No of and correct it to a the target CPU 16 is specified correct PLC The instruction is composed of devices except usable program 4004 devices 4100 Since 0 to 3DFH 3E4H by First I O No of the target CPU 16 is specified Note 0000H Normal Program example Program which changes the current value of the axis No 1 of the Motion CPU CPU No 4 from PLC CPU CPU No 1 to 10 To self CPU Current value changing high speed flag of the axis No 1 interrupt accept CPU No 4 flag from CPU U3E3 U3E3 G516 0 mioo 6482 m y 88 cHG a 33 E1 k10 mo Do ST M100 Normal complete program Abnormal complete program i 3 MOTION DEDICATED PLC INSTRUCTION When an axis No Cn was specified with S1 Controls 1 7 This instruction is dedicated instruction toward the Motion CPU in the Multiple CPU system Errors occurs when it was executed toward the CPU except th
141. ar File DiSt ictieesedi te ced naeeeitai dined iad an hide field dena eiaua lena dual 10 2 10 3 Online Change in The Motion SFC Program ccceccecceeeeeeeeeeeeeeeeeneeeeeeaeeeaeeeaeeeeeeaeeeaeeeaeeeaeeeaeesatens 10 3 10 3 1 Operating method for The Online Change cecccecseceseeeseeeeeeteeeseeeseeeseeeseeeseeeseeeeeeeseneeeneeeaeeeas 10 4 10 3 2 Transfer of program erreren eee ee ei ee ee eee et ele ene ee ee eet 10 7 11 ERROR CODE LISTS 11 1to 11 12 11 1 Reading Procedure for Error Codeso rerainan a A a AA NA 11 1 11 2 Motion SFC Emor Code l Ehe eee a e E E EEE E EE 11 2 Tko Moton SFC Parameter EMO Sururu enra Ta e A A T 11 11 APPENDICES APP 1 to APP 31 APPENDIX 1 Processing TIMES naaraana ea aenar a aaan aa raa o aka ana Aa aSa aaa Eana ARATA R aaa a ar APP 1 APPENDIX 1 1 Processing time of operation control Transition instruction eeeeeeeeeeeeeeeeeeeee APP 1 APPENDIX 2 Sample Program aeaaaee A A OR anne APP 9 APPENDIX 2 1 Program example to execute the Multiple CPU dedicated instruction continuously APP 9 APPENDIX 2 2 The program example to execute plural Multiple CPU instruction by the instructions of ea E A EE TAE EEIE EE A E E E TA EA E E E OE EE APP 11 APPENDIX 2 3 Motion control example by Motion SFC program APPENDIX 2 4 Continuation execution example at the subroutine re start by the Motion SFC program About Manuals The following manuals are related to this product Referring to this list pleas
142. art accept flag Start accept flag Operation signal to to to to j dle g 32 points 32 points yi Note 2 3 Personal computer link Personal computer link Operation Status M2034 Rear M2034 ae ignal communication error flag communication error flag YES signa Motion SFC error history clear Motion SFC error history clear Command request flag Note 5 request flag Note 5 signal M2036 M2036 Unusable Unusable 3 points 3 points M2038 M2038 H H Immedi Status M2039 Motion SFC error detection flag M2039 Motion SFC error detection flag i D M2035 M2035 t e d Speed switching point specified Speed switcing point specified i flag flag 7 Operation Status M2041 System setting error flag M2041 System setting error flag cycle signa Operation M2042 All axes servo ON command M2042 All axes servo ON command cycle Real virtual mode switching At Vinual M2043 mode request Real virtual mode switching M2044 Unusable M2044 status At virtual transition 4 point PE poe Real virtual mode switching error mode M2045 M2045 tansion Status detection flag signal M2046 M2046 Out of sync warning R 3 Operation M2047 Motion slot fault detection flag M2047 Motion slot fault detection flag cycle C d JOG operation simultaneous start JOG operation simultaneous start eT M2048 M2048 Signa command command Note 1 M2049 All axes servo ON accept flag M2049 All axes servo ON accept flag Operation Status cycle signal M2050 Start bu
143. arted by either a step or a transition p G0 K2 K3 F1 G1 G2 G3 TS G255 Max number of parallel branches 255 After operation completion of preceding step steps K2 to F10 connected in parallel are executed when the completion of condition set at transition GO Thereafter routes are executed simultaneously up to parallel coupling point Shift or WAIT can be set to a transition preceding a parallel branch WAITON and WAITOFF cannot be set 2 Parallel coupling A parallel branch must be coupled by a parallel coupling A jump setting to another branch route can be made within parallel branch parallel coupling In this case a jump destination is a midway parallel coupling point coupling jump You cannot set a jump to exit from within parallel branch parallel coupling PAB1 K4 F10 Ss ON M100 wo wo F11 G12 K100 PAE1 F12 A a Parallel branch point Coupling jump After the servo program K3 has completed stopping execution waits until the completion of condition set at transition G3 and servo program K4 completes starting On completion of waiting execution transits to the next lower part Parallel coupling point 4 MOTION SFC PROGRAMS The number of parallel branches need not match that of couplings at a para
144. asic steps Usable data Usable Data Setting 64 bit i 64 bit Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer 5 i integer integer type 5 expression 2 point expression expression type type L type K H K H L type K ae eT a a a l o lololol olo lolol ee O Usable Setting data Setting data Data type of result S1 T Data which will be compared Logical type true false Functions 1 The result is true if the data specified with S1 is greater than the data specified with S2 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before comparison is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which compares whether 0 is greater than DO or not 0 gt DO 0 gt True lt po 2 5 OPERATION CONTROL PROGRAMS FIFS 5 11 6 More than or equal to gt S1 gt S2 Number of basic steps Usable data Usable Data Setting 64 bit i 64 bit Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer 5 i integer integer type 5 expression 2 point expression expression type type L type K H K H L type
145. axis Current value change Current value change 1 ON Instruction start accept complete device D1 0 State display device D1 1 at the instruction start l l ON Abnormal completion only OFF accept completion Instruction accept gt completion at the Motion CPU side 1 The start accept status of each axis can be confirmed with the start accept flag in the shared CPU memory of target CPU 2 S P CHGA instruction accepting and normal abnormal completion can be confirmed with the complete device D1 or status display device D2 at the completion a Complete device It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing b Status display device at the completion It is turned on off according to the status of the instruction completion e Normal completion OFF e Abnormal completion It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing 1 Setting of axis to execute the current value change The starting axis set as S1 sets J Axis No in a character sequence __ _St usable range Q173HCPU 1 to 32 Q172HCPU 3 MOTION DEDICATED PLC INSTRUCTION The number of axes which can set are only 1 axis The axis No set in the system setting is used as the axis No to start Refer to the Q173HCPU Q172HCPU Motion controller Programming Manual
146. bit 32 bit floating Coasting ae bit f 32 bit floating ACHA as conditional conditional integer integer i integer integer type expression int expression expression type type L type K H KH L Pon e i type F type K Lond dad aoad aoa d aoa d aoa daoa d ee O Usable Setting data Setting data Data type of result Angle data on which TAN tangent operation will F J S Floating point type be performed Functions 1 TAN tangent operation is performed on the data specified with S 2 The data specified with S is in an angle degree unit 3 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range or e S is 90 180 n n is an integer Program examples 1 Program which performs the TAN operation of DO and substitutes the result to 0F 3 0 2 1 0 57735026918963 4 DO 5 OPERATION CONTROL PROGRAMS FIFS 5 6 4 Arcsine ASIN ASIN S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting ae bit f 32 bit floating ACHA as conditional conditional integer integer i integer integer type expression int expression expression type type L type K H KH L Pon
147. can which the instruction completed and turned off by the next END processing b Status display device at the completion It is turned on off according to the status of the instruction completion e Normal completion OFF e Abnormal completion It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing SM390 turns on when the target CPU specified with n1 complete to accept SM390 turns off when the target CPU specified with n1 cannot be write correctly by the reset status or error factor 5000 to 5999 3 MOTION DEDICATED PLC INSTRUCTION Operation First S P DDWR Second S P DDWR instruction accept instruction accept To self CPU high speed interrupt accept flag from CPUn Instruction accept destination buffer memory S P DDWR instruction First First S P DDWR instruction complete device ON Abnormal completion State display device at the first S P DDWR instruction i i completion S P DDWR instruction Second Second S P DDWR instruction complete device 1 i State display device at the second OFF S P DDWR instruction i i 1 i i ii i completion OFF Normal completion i i First S P DDWR Second S P DDWR instruction completion instruction completion with response with response Errors The abnormal completion in the case shown below and the error code is store
148. central point specified helical interpolation CW Incremental central point specified helical ING interpolation CCW Auxiliary point specified Radius specified Helical interpolation control Central point specified 7 MOTION CONTROL PROGRAMS Positioning data Starting angle Amplitude Frequency Reference axis No Control unit Speed limit value Acceleration time Deceleration time Torque limit value at stop input interpolation S curve ratio Repeat condition Program No Command speed WAIT ON OFF deceleration time Fixed position stop Number of steps Deceleration processing FIN acceleration deceleration Rapid stop deceleration time Fixed position stop acceleration amp 5 5 lt aD f o E o 2 Fa Ke x 2 1 1 a 1B 10 to 27 10 to 27 Must be set A Set if required 1 Only reference axis speed specification 2 B indicates a bit device 7 MOTION CONTROL PROGRAMS Table 7 2 Servo Instruction List continued Positioning data no 2 Dwell time Instruction symbol Auxiliary point Central point Processing Command spee Torque limit value Parameter block No Address travel value Positioning control Virtual enable eel emi Rom Rew Reva koks on on ea Bea Number of steps ssm lee fat peee fafo LL 2 axes
149. ces Status SV13 SV22 Refresh cycle Fetch cycle _ Signal direction M2320 Fuse blown detection M2321 AC DC DOWN detection M2322 Battery low Error M2323 Battery low latch OgCuITeEnCS M2324 Self diagnostic error M2326 Always ON Main M2327 Always OFF operation M2328 Clock data error Error M2329 PCPU WDT error flag Occurrence M2330 PCPU READY complete flag At request M2331 Test mode ON flag Operation Status signal M2332 External forced stop input flag cycle Manual pulse generator axis setting M2333 M9077 error flag Error M2334 TEST mode request error flag occurrence M9078 M2335 Servo program setting error flag M9079 M2336 CPU No 1 reset flag M9240 M9241 ccoa o O _ crue WTR ey M2345 CPU No 1 MULTR complete flag M2346 CPU No 2 MULTR complete flag At instruction Status signal M2347 CPU No 3 MULTR complete flag completion M2348 CPU No 4 MULTR complete flag Unusable 51 points Note The same status as a remark column is output M9242 M9243 M9244 M9245 M9246 1 29 1 OVERVIEW 11 Table of the common devices Command signal SV13 SV22 i APEERE Remark Device No Signal name Refresh cycle Fetch cycle Signal direction Note 1 Note 2 M3072 PLC ready flag Main cycle e m roe eee 4 switching point specified flag atstat start M2040 mora Al axes servo ON command axes servo ON command ma e M2042 Real virtual mode change request oa virtual mode M3
150. changed if the device value is changed during a wait state 2 The TIME instruction is equivalent to a conditional expression and therefore may be set on only the last line of a transition G program 3 When the transition program Gn of the same number having the TIME instruction setting is used in multiple Motion SFC programs avoid running them at the same time If they are run simultaneously the waiting time in the program run first will be illegal 4 Another transition program Gn can executed a time of instruction by multiple Motion SFC program simultaneously Multi active step less than 256 5 While time by TIME instruction waits the wait time can not be stopped 6 When using the TIME instruction a verification error may occur even when the Motion SFC program of SW6RN GSVLIP is equal to the Motion CPU if a verification of Motion SFC program is executed 5 OPERATION CONTROL PROGRAMS FIFS 5 14 Comment Statement Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 7 16 bit 32 bit Of Calculation pa floating Coasting floating conditional conditional i i expression 4 integer integer integer integer type point P expression expression type type L type K H K H L type K O Usable Setting data There are no setting data Functions 1 A character string from after to a block
151. code area overflow Refer to Section 1 2 2 1 b Motion SFC Performance Specifications for the code area sizes 2 You cannot use in comment statements 4 MOTION SFC PROGRAMS MEMO 28 5 OPERATION CONTROL PROGRAMS 5 OPERATION CONTROL PROGRAMS Refer to Section 11 2 Motion SFC Error Code List for error codes of the operation error Refer to the Q173HCPU Q172HCPU Motion controller SV13 SV22 Programming Manual REAL MODE and Q173HCPU Q172HCPU Motion controller SV22 Programming Manual VIRTUAL MODE for minor errors of the operation error 5 1 Operation Control Programs 1 Operation control programs a Substitution operation expressions motion dedicated functions and bit device control commands can be set in operation control program Multiple blocks in one operation control program can be set gt oa a c There are no restrictions on the number of blocks that may be set in one operation control program However one program is within 64k bytes d The maximum number of characters in one block is 128 e Transition conditions cannot be set Transition conditions can be set only in transition programs f The bit conditional expression that logical data value true or false is returned in an operation control program a comparison conditional expression can be set up only as a source S of device set SET or device reset RST An operation control program example is shown
152. code e Error code stored in D9193 when error type is 8 16000 and later Refer to Chapter 11 ERROR CODE LISTS i e 1 when error type is 9 or 10 Error code stored in D9184 when error type is 11 Error code stored in D9196 when error type is 12 Year month Day The clock data at error occurrence D9025 D9026 D9027 are set hour BCD code year in its lower 2 digits Minute second 8 MOTION DEVICES 2 Motion SFC error detection flag M2039 Refresh cycle Scan time The Motion SFC error detection flag M2039 turns on when any of the errors detected by the Motion CPU occurs At error occurrence data are set to the error devices in the following procedure a Set the error code to each axis or error devices b Turns on the error detection signal of each axis or error c Set the error information to the above Motion SFC error history devices 8000 to 8063 d Turns on the Motion SFC error detection flag M2039 In the user program reset the Motion SFC error detection flag M2039 after reading the error history at the Motion SFC error detection flag M2039 After that Motion SFC error detection flag M2039 turns on again at occurrence of a new error 1 Resetting the Motion SFC error detection flag M2039 will not reset clear to zero the Motion SFC error history devices 8000 to 8063 After power on they always controls the error history continuously
153. completion of transition Shift Y N Sn N condition after operating execution If not the Completion Y IFT2 BL of condition SFT Gn completion of transition condition transits to the right connected step When just before is subroutine call or starting step transits to the next step by the completion of transition condition without waiting for the operating of subroutine completion If not formation of transition condition transits to the right connected step IFBm JMP IFEm JMP IFEm IFEm 4 MOTION SFC PROGRAMS Symbol Classification Name List representation Function Code size byte When just before is the motion control step waits for the motion operating completion and then transits to the next step by formation of transition condition Gn IFBm GO to G4095 If not completion of transition condition IFT1 transits to the right connected step ce WAIT Gn When just before is the operation control step transits fe completion to the next step by the completion of transition Traneltion WAEN of condition JMP IFEm condition after operating execution If not the iti Gn N IFT2 completion of transition condition transits to the right Completion Y of condition WAIT Gn connected step Same operation as Shift JMP IFEm When just before is subroutine call or starting step IFEm waits for the operating completion of subroutine and then transits to the next step by t
154. ctions 1 A speed change is made in the following procedure a The speed changing flag M2061 to M2092 correspond to the axis specified with S1 is turned ON b The speed of the axis specified with S1 is changed to the speed specified with S2 c The speed changing flag is turned OFF 2 The axis No that may be set at S1 is within the following range Q172HCPU Q173HCPU 1t032 For interpolation control set any one of the interpolation axes When linear interpolation control is exercised a speed change varies as described below with the positioning speed designation method set in the servo program Positioning speed designation Operation method S Speed change is made so that the combined speed Combined speed designation a becomes the speed specified with S2 7 Speed change is made so that the longest axis Longest axis designation speed becomes the speed specified with S2 N Speed change is made so that the reference axis Reference axis speed designation speed becomes the speed specified with S2 5 OPERATION CONTROL PROGRAMS 3 Operation varies with the sign of the specified speed set at S2 Sign of specified speed Speed change a u Temporary stop 4 The specified speed that may be set at S2 is within the following range a Real mode 3 Speed change Oto x 10 Oto x108 Oto F 3 p 0 to PLS s request 600000000 mm min 600000000 inch min 2147483647 atid 40000000 3 Re
155. ctions 1 The execution of an event task is disabled 2 If an external interrupt or PLC interrupt occurs after execution of the DI instruction the corresponding event task is executed once at the execution of the El instruction If two or more external interrupts or PLC interrupts occur during DI the corresponding event task is executed only once at the execution of the El instruction 3 During DI a fixed cycle event task is not executed 4 The execution of an NMI task cannot be disabled 5 The DI status is established at power on or when a reset is made with the RESET L CLR switch Errors 1 An operation error will occur if This instruction is used with other than a normal task Program examples 1 Program which disables the execution of an event task 5 OPERATION CONTROL PROGRAMS FIFS 5 13 3 No operation NOP NOP Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit Of Calculation pe floating Coasting floating conditional conditional d i i expression 4 integer integer integer integer type point P expression expression type type L type K H K H L type K O Usable Setting data There are no setting data Functions 1 This is a no operation instruction and does not affect the preceding operations Errors 1 There are no operation errors for no operation NOP 5
156. d o114 The self CPU by First I O No of the target CPU 16 is specified bag Sie The CPU except the Motion CPU by First O No of 00 a the target CPU 16 is specified program and Pre Since 0 to 3DFH 3E4H is specified by First I O No of Correct it to a the target CPU 16 is specified correct PLC There are 33 or more instruction requests to the Motion program 4C08 CPU from the PLC CPU in S P SFCS S P SVST S P CHGA S P GINT sum table simultaneously and the Motion CPU cannot process them Note 0000H Normal 3 MOTION DEDICATED PLC INSTRUCTION Program example Program which generates the interrupt toward the Motion CPU No 4 xo SP GINT H3E3 SM391 j Normal complete program SM391 Mi The program which generates interruption again 4 MOTION SFC PROGRAMS 4 MOTION SFC PROGRAMS Refer to Chapter 11 ERROR CODE LISTS for details of Motion SFC program error 4 1 Motion SFC Program Configuration The Motion SFC Program is constituted by the combination of start steps transitions end and others are shows below Operation stat eee v Positioning ready FO y Positioning ready check Go Vv Positioning KO execution v Positioning complete G1 check ae Operation END end The above Motion SFC program to be started performs the following operations 1 The step FO is activated and the operation specified wit
157. d in the control data S1 0 Complete status Complete status N E de H Error factor Corrective action rror code 4C00 The specified device cannot be used with the Motion CPU Or it is outside the device range Confirm a There are 33 or more instruction requests to the Motion program and CPU from the PLC CPU in S P DDRD S P DDWR correct it to a sum table simultaneously and the Motion CPU cannot correct PLC process them program 4Cc09 CPU No of the instruction cause is injustice Note 0000H Normal 3 MOTION DEDICATED PLC INSTRUCTION The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO 2110 The CPU No to be set by First I O No of the target CPU 16 is specified The self CPU by First I O No of the target CPU 16 2114 is specified 117 The CPU except the Motion CPU by First I O No of the target CPU 16 is specified 4002 Specified instruction is wrong Confirm a program and correct it to a EA The instruction is composed of devices except usable Correct PLC devices program 4100 Since 0 to 3DFH 3E4H is specified by First I O No of the target CPU 16 is specified Number of the writing data is except 1 to 16 Number of writing data exceeds range of the storage device of the written data Note 0000H Normal Program example lt Exampl
158. d pointer does not exist at the jump destination 11 3 Stop to execute the applicable Motion SFC program No For the subroutine called program the call source program also stops to execute The Motion SFC program code is corrupted Turn PLC ready flag M2000 OFF and write the Motion SFC program again Or replace the external battery if it passed over a life 11 ERROR CODE LISTS Table 11 3 Motion SFC interpreter detection errors 16100 to 16199 continued Error factor 5 The self program was called started by 1110 SSVB Seng emor GSUB GSUB cannot call its own or main program Th i lled started b Correct the Motion SFC program 16111 GSUB setting error 2 5 a program Was Secu oie con ee Corrective Action Error code Error Processing Stop to execute the The nesting of parallel branch is up to four J ra Parallel branch Nesting of parallel branches within a parallel applicable Motion SFC levels nesting excess branch route exceeded four levels program No Subroutine the branch destination processing For the subroutine called and correct the program Aniattcracl wasimade to execute a astic eee a ie ee Motion control steps cannot be executed in 16113 Executed task error p Progro aa aa the Motion SFC programs executed by the control step K with an event or NMI task execute event and NMI tasks Simultaneously F Number of simultaneously active steps is The number of sim
159. d the current value change is not made 903 when the current value change servo program is set to within the virtual mode program No range or 905 when it is set to within the real mode program No range If a current value change is made during mode changing a servo program setting error Nete 907 real virtual changing or 908 virtual real changing occurs and the current value change is not made Note Refer to the Q173HCPU Q172HCPU Motion controller SV13 SV22 Programming Manual REAL MODE Q173HCPU Q172HCPU Motion controller SV22 Programming Manual VIRTUAL MODE for minor error major error and servo program setting error 7 MOTION CONTROL PROGRAMS 7 4 Cam Shaft Within One Revolution Current Value Change Control SV22 only The current value of the specified cam shaft within one revolution is changed in the virtual mode Items set on peripheral device Speed Parameter block Others change at stop input interpolation Dwell time Control unit Servo Positioning Number of instruction method Control axes Parameter block No Address travel Command speed Torque limit value Auxiliary point Central point Speed limit value Acceleration time Deceleration time Rapid stop deceleration time Torque limit value Deceleration processing S curve ratio FIN acceleration deceleration Item which must be set A Item which is set when required Controls Control using
160. data are read from the address specified with S2 of the buffer memory in the intelligent function module special function module controlled by the self CPU specified with S1 and are stored since the device specified with S2 S1 Intelligent function module special function module D Device memory Read the data gp buffer memory aes gon es EN H0000 H0000 2 First I O No of the module set by system setting is specified by D1 Power supply No OOH No 10H No 20H D1 sets 20H by the system setting when a TO instruction is executed in the D A conversion module Q64DA 5 OPERATION CONTROL PROGRAMS 3 The word devices that may be set at D S1 S2 and n are shown below Hoe e Note 1 The device No cannot be specified indirectly Note 2 Specify a multiple of 16 as the device number of bit data Note 3 Special relays M9000 to M9255 and dedicated devices M2000 to M2399 cannot be set Note 4 PX and PY cannot be set 4 Adjust an executive task the number of transfer word referring to the operation processing time so that this instruction may not obstruct the execution of the motion operation because processing time becomes long in argument to the Number of words n to be read 5 The following analogue modules can be used as the control module of Motion CPU Q62DA e Q64AD Q64DA Q68ADV e Q68DAV e Q68ADI e Q68DAl Errors 1 An operat
161. data specified with S is converted into BIN data 2 If S is a 16 bit integer type the data range is 0 to 9999 3 If S is a 32 bit integer type the data range is 0 to 99999999 Errors 1 An operation error will occur if e A value other than 0 to 9 is in any digit of S or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which converts the BCD data of DO into BIN data and substitutes the result to 0 0 BIN DO BIN 9999 BCD 9999 y y y y Thousands Hundreds Tens Units 5 OPERATION CONTROL PROGRAMS FIFS 5 6 15 BIN BCD conversion BCD BCD S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device is Re a floating Coasting a bit Saa floating acuaton Conditional conditional integer integer integer integer type i expression 3 point expression expression type type L type K H K H L type F type K Pos dad o aoad aoada daoa O Usable Setting data Setting data Data type of result Data type of S S BIN data which will be converted into BCD data Integer type Functions 1 The BIN data specified with S is converted into BCD data 2 If S is a 16 bit integer type the data range is 0 to 9999 3 If S is a 32 bit integer type the data range is 0 to 99999999 Errors 1 An operation er
162. device n read error Corrective Action e The indirectly specified device No is outside the range Indirectly specified 32 bit motion device n L d AL read error e The indirectly specified device No is outside Indirectly specified the range or an odd number 64 bit motion device n F read error Indirectly specified 16 bit data register D n read error e The indirectly specified device No is outside the range Indirectly specified 32 bit data register D n L read error e The indirectly specified device No is outside the range or an odd number Indirectly specified 64 bit data register D n F read error Indirectly specified 16 bit link register W n read error e The indirectly specified device No is outside the range The block processing in Indirectly specified execution is stopped and the 32 bit link register next block is executed W n L read error Correct the program so that the indirectly specified device No is proper e The indirectly specified device No is outside Indirectly specified the range or an odd number 64 bit link register W n F read error Indirectly specified input relay X n read error Indirectly specified output relay Y n read error Indirectly specified internal latch relay M n L n read error e The indirectly specified device No is outside the range Indirectly specified link relay B n read error Annuncia
163. device specified with S2 of the self CPU are stored to since the word device specified with D1 of the target CPU n1 in the Multiple CPU system Figure specification of the bit device is possible for S2 and D1 However figure specification is 4 figures and a start bit device number is only the multiple of 16 It becomes INSTRCT CODE ERROR 4004 when other values are specified If the target CPU is not instruction acceptable condition even if the S P DDWR instruction is executed it may not be processed In this case it is necessary to execute the S P DDWR instruction again S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P DDWR instruction It can be confirmed by data in the shared CPU memory of the target CPU Motion CPU whether the instruction is acceptable or not When the Motion dedicated PLC instruction is started continuously it is must be design to execute next instruction after executing instruction complete device on The target CPU device range check is not executed with self CPU at the S P DDWR instruction execution but it checks by the target CPU side and it becomes abnormal completion at the device range over S P DDWR instruction accepting and normal abnormal completion can be confirmed with the complete device D1 or status display device D2 at the completion a Complete device It is turned on by the END processing of s
164. during the forced stop emergency stop servo OFF or power supply OFF use dynamic brakes Make sure that the system considers the coasting amount even when using dynamic brakes In systems where perpendicular shaft dropping may be a problem during the forced stop emergency stop servo OFF or power supply OFF use both dynamic brakes and electromagnetic brakes The dynamic brakes must be used only on errors that cause the forced stop emergency stop or servo OFF These brakes must not be used for normal braking A CAUTION The brakes electromagnetic brakes assembled into the servomotor are for holding applications and must not be used for normal braking The system must have a mechanical allowance so that the machine itself can stop even if the stroke limits switch is passed through at the max speed Use wires and cables that have a wire diameter heat resistance and bending resistance compatible with the system Use wires and cables within the length of the range described in the instruction manual The ratings and characteristics of the parts other than Motion controller servo amplifier and servomotor used in a system must be compatible with the Motion controller servo amplifier and servomotor Install a cover on the shaft so that the rotary parts of the servomotor are not touched during operation There may be some cases where holding by the electromagnetic brakes is not possible due to the life or mecha
165. e Extreme adjustments and changes may lead to unstable operation so never make them When using the absolute position system function on starting up and when the Motion controller or absolute value motor has been replaced always perform a home position return 6 Usage methods A CAUTION Immediately turn OFF the power if smoke abnormal sounds or odors are emitted from the Motion controller servo amplifier or servomotor Always execute a test operation before starting actual operations after the program or parameters have been changed or after maintenance and inspection The units must be disassembled and repaired by a qualified technician Do not make any modifications to the unit Keep the effect or electromagnetic obstacles to a minimum by installing a noise filter or by using wire shields etc Electromagnetic obstacles may affect the electronic devices used near the Motion controller or servo amplifier When using the CE Mark compliant equipment refer to the EMC Installation Guidelines data number IB NA 67339 for the Motion controllers and refer to the corresponding EMC guideline information for the servo amplifiers inverters and other equipment Use the units with the following conditions Q61P A1 Q61P A2 Q61P Q62P Q63P Q64P 100 to 120VAC a 200 to 240VAC Be 100 to 240VAC oa 24VDC ie 100 to 120VAC ne Input power 200 to 240VAC on 85 to 132VAC 170 to 264VAC 85 to 264VAC 15 6 to 31 2VDC 8
166. e Acceleration time Deceleration time Torque limit value at stop input interpolation S curve ratio Repeat condition Program No Command speed WAIT ON OFF deceleration time Fixed position stop Number of steps Deceleration processing FIN acceleration deceleration Rapid stop deceleration time Fixed position stop acceleration amp 5 5 lt aD f o E o 2 Fa Ke x PEEELEREEE EEE e Eee ett Lee eM Mf lla TR Must be set A Set if required 1 Only reference axis speed specification 2 B indicates a bit device 7 MOTION CONTROL PROGRAMS 7 2 Servomotor Virtual Servomotor Shaft Current Value Change The current value of the specified axis is changed in the real mode The current value of the specified virtual servomotor shaft is changed in the virtual mode Items set on peripheral device Parameter block Others at stop input Allowable error range for circular interpolation Control unit S curve ratio Dwell time Speed limit value Servo Positioning Number of instruction method Control axes Parameter block No Address travel Command speed Torque limit value Auxiliary point Central point Acceleration time Deceleration time Rapid stop deceleration time Torque limit value Deceleration processing FIN acceleration deceleration exon atsowe Pt fofol EET TT EEE EE pisa Item which must be set A ltem which
167. e Motion CPU The cam axis within one revolution current value specified with S1 is changed into the current value specified S2 at the virtual mode This instruction is always effective regardless of the state of real mode virtual mode mode switching when the operating system software of Motion CPU is V22 S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P CHGA instruction When the Motion dedicated PLC instruction is started continuously It is necessary to take an interlock by the to self CPU high speed interrupt accept flag from CPUn When the servo program is executed also at the motion control step Kn in the Motion CPU it is necessary to take an interlock by user program because there is no flag which can distinguish the axis starting in the PLC CPU It is necessary to take an interlock by the cam axis within one revolution current value changing flag of the shared CPU memory so that multiple instructions may not be executed toward the same cam axis of the same Motion CPU No The current change value is also possible when the servo program which execute the CHGA instruction toward the cam axis is executed in the S P SVST instruction 3 MOTION DEDICATED PLC INSTRUCTION Operation PLC program S P CHGA instruction accept flag from CPUn Start accept flag i i i i f I i To self CPU high speed interrup
168. e 1 gt lt Example 2 gt Program which stores 10 points worth of the data from DO of the self Program which stores 10 points worth of the data from DO of the CPU CPU No 1 since D100 of CPU No 2 when X0 is turned on self CPU CPU No 1 since D100 of CPU No 2 during turn on XO SM400 SM400 K10 K10 D51 X0 XO M10 FSET D50 Do D100 y H3E1 D50 Do D100 mi0 M10 M11 Normal complete processing SET w MO M10 Abnormal complete processing RST M10 M11 Normal complete processing M11 Abnormal complete processing 3 MOTION DEDICATED PLC INSTRUCTION 3 8 Read from The Devices of The Motion CPU S P DDRD PLC instruction S P DDRD _ Usable devices Internal devices MELSECNET 10 Special Bit Indirectly Index System User File na direct JO function register Word digit specified register module Setting data specified O Usable A Usable partly Note Setting data n1 to D2 Index qualification possible Instruction Condition Start request SP DDRD _4 SE BDRD Start request S DDRD S DDRD Setting data Setting data Data type First I O No of the target CPU 16 n1 Value to specify actually is the following CPU No 1 3EOH CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H S1 First device of the self CPU in which control data is stored S2 First device of the target CPU in which reading data is
169. e fractional portion will be rounded off Data type of S Functions 1 The rounded off fractional portion value of the data specified with S is found 2 If S is a negative number the absolute value of S is found and its fractional portion is rounded off and signed 3 If S is an integer type its value is returned unchanged with no conversion processing performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which finds the rounded off fractional portion value of DOF and substitutes the result to 0F 0F RND DOF 3 D1 DO ee 2 Program which finds the rounded off fractional portion value of D4F and substitutes the result to 0F when D4F is a negative number 0F RND D4F 3 2 D5 D4 nee Ce om o T a er 5 OPERATION CONTROL PROGRAMS FIFS 5 6 12 Round down FIX FIX S Number of basic steps Usable data Usable Data Bit device Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit OF Calculation pe floating Coasting t floating conditional conditional integer integer i integer integer type expression i aes timer ene expression expression type type L type K H K H L O Usable data Setting data Setting data Data type of result S Data whose fractional portion will be rounded down Data typ
170. e i type F type K Lond dad aoad aoa d aoa d aoa daoa d ee O Usable Setting data Setting data Data type of result SIN value data on which SIN arcsine operation S Floating point type will be performed Functions 1 SIN f arcsine operation is performed on the SIN value data specified with S to find an angle 2 The SIN value specified with S must be within the range 1 0 to 1 0 3 The operation result is in an angle degree unit 4 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is outside the range 1 0 to 1 0 or e S is an indirectly specified device and its device number is outside the range Program examples 1 Program which performs the SIN a arcsine operation of DO and substitutes the result to 0F 0F ASIN DO 3 2 1 0 C a E 5 OPERATION CONTROL PROGRAMS FIFS 5 6 5 Arccosine ACOS ACOS S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting ae bit f 32 bit floating ACHA as conditional conditional integer integer integer integer type expression i int expression expression type type L type K H K H L poin R P type F type K Lond dad aoad aoa d aoa d aoa daoa d ee O Usable Setting data
171. e jeooo 2 fT Of J 865 o ses om Rem 567 see seo 56 10 RND Roundo Roo O s5en 5612 5613 5614 56 15 SHORT S 5 5 S ls ESE me Ny Een Ben ae ee EIRA ALA NRTA th epl N Standard function BIN BCD conversion BCD S SHORT Convert into 16 bit integer type signed SHORT USHORT Convert into 16 bit integer type unsigned USHORT iti igned LONG Convert into 32 bit integer type signed LONG Tor Convert into 32 bit integer type signed Type conversion ULONG Convert into 32 bit integer type unsigned ULONG S FLOAT Regard as signed data and convert into 64 FLOAT S 2 bit floating point type UFLOAT Regard as unsigned data and convert into UFLOAT S 2 64 bit floating point type ON normally open contact S Bit device status OFF normally closed contact 2 o 3 olof SET Device set SET D conditional Pea i 5 expression o Bit device control BST Porter RST D conditional me expression DN Deviceinpt F NS _ 4 fofo coe Sie ae all fofo 2ER expression O o o o Kewl eal o eal Kea rio eal EA CESE HEA 1 O Q Q 7 7 9 9 1 OVERVIEW Table of the operation control transition instruction continued Usable Usable step YIN t ition s Sect
172. e of S Functions 1 The largest integer not greater than the data specified with S is found 2 If the S value is positive the absolute value will be smaller and if it is negative the absolute value will be greater 3 If S is an integer type its value is returned unchanged with no conversion processing performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which finds the rounded down fractional portion value of DOF and substitutes the result to 0F 0F FIX DOF 3 a D1 DO i a E 2 Program which finds the rounded down fractional portion value of D4F and substitutes the result to 0F when D4F is a negative number 0F FIX D4F 3 2 D5 D4 34 0 t A 54 5 OPERATION CONTROL PROGRAMS FIFS 5 6 13 Round up FUP FUP S Number of basic steps Usable data Usable Data Bit device Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit OF Calculation pe i floating Coasting 3 floating conditional conditional integer integer i integer integer type expression i aes timer ene expression expression type type L type K H K H L O Usable data Setting data Setting data Data type of result Data whose fractional portion will be rounded up Data type of S Functions 1 The smallest integer
173. e request the necessary manuals Related Manuals 1 Motion controller Model Code Q173HCPU Q172HCPU Motion controller User s Manual This manual explains specifications of the Motion CPU modules Q172LX Servo external signal interface module Q172EX Serial absolute synchronous encoder interface module Q173PX Manual pulse IB 0300110 generator interface module Teaching units Power supply modules Servo amplifiers SSCNETII cables 1XB910 synchronous encoder cables and others Optional Q173HCPU Q172HCPU Motion controller Programming Manual COMMON This manual explains the Multiple CPU system configuration performance specifications common 1B 0300111 parameters auxiliary applied functions and others 1XB911 Optional Q173HCPU Q172HCPU Motion controller SV13 SV22 Programming Manual REAL MODE maori This manual explains the servo parameters positioning instructions device list error list and others 1XB913 Optional Q173HCPU Q172HCPU Motion controller SV22 Programming Manual VIRTUAL MODE This manual describes the dedicated instructions use to the synchronous control by virtual main shaft mechanical system program create mechanical module axes This manual explains the servo parameters positioning instructions device list error list and others Optional Q173HCPU Q172HCPU Motion controller SV43 Programming Manual This manual describes the dedicated instructions to execute the positioning control by Motion progra
174. e resolution of the specified cam No At cam data write The cam data storage area is rewritten e Transfer of data to the cam data area is also executed during cam operation Be careful not to perform write while operation is being performed with the same cam No At cam data read The cam data storage area is rewritten e The cam data in the currently set status are read 5 75 5 OPERATION CONTROL PROGRAMS 4 The word devices that may be set at D S and n are shown below 2 Note Cam No Word devices Note 2 Bit devices Note 2 Note 3 am Setting data specification O O O O O w lololol l l l l Note 1 Nn indicates the cam No Note 2 The device No cannot be specified indirectly Note 3 Specify a multiple of 16 as the device number of bit data Note 4 PX PY cannot be set Note 5 Special relays M9000 to M9255 and dedicated devices M2000 to M2399 cannot be set Note DOUT cannot output the PX special relays M2000 to M9255 and dedicted devices M2000 to M2127 5 The cam No that may be set as Nn is within the following range Q173HPU Q172HCPU 1 to 64 101 to 164 201 to 264 301 to 364 Errors 1 An operation error will occur if The cam data of cam No specified with D or S are not yet registered to the Motion controller e The resolution of cam No specified with D or S differs from the number of transferred words specified w
175. e shown below Dm Decimal representation Hexadecimal representation K 32768 to K32767 H0000 to HFFFF b 32 bit integer type data The 32 bit integer type data is 32 bit integer value data Word devices are used in increments of 2 points specified device No specified device No 1 Data ranges are shown below Decimal representation Hexadecimal representation Data range K 2147483648L to K2147483647L HO0000000L to HFFFFFFFFL c 64 bit floating point type data The 64 bit floating point type data is IEEE formatted 64 bit floating point value data Word devices are used in increments of 4 points specified device No specified device No 1 specified device No 2 specified device No 3 1 The internal bit locations are shown below 3 2 1 Specified device number 0 b51 to bO 52 bits Decimal field b62 to b52 11 bits Bias exponent field b63 1 bit Sign bit field 2 The represented value is shown below The bias value is H3FF Sign bit fie ias exponent field bias value 1 SPP g 4 0 4 decimal field 2 09S 90079 fedHbias value 5 OPERATION CONTROL PROGRAMS 3 Data ranges are shown below Sa Decimal representation Hexadecimal representation H0000000000000000 K 1 79E 308 to K 2 23E 308 H0010000000000000 to H7FE1CCF385EBC89F H8000000000000000 H8010000000000000 to HFFE1CCF385EBC89F K2 23E 308 to K1 79E 308 4 Around off error may be p
176. e space Program No 100 Program No 5 Program No 6 Program No 100 Program No 6 _ Program No 5 Program No 2 c In the case of b arrange to stuff to the front the invalid programs Operation procedures to stuff to the front are shown below 1 Select the program editor screen Option menu Sort of SW6RN GSVLP In this case the invalid programs in the personal computer arranges by SW6RN GSVLP 2 Execute the program writing with the Communication menu Transfer in the stop state of Motion CPU Motion CPU Personal computer Programming software Program memory Program No 0 Program No 0 2 Write the Motion program by Transfer Key Program No 2 Program No 2 Program No 5 Program No 5 Program No 6 Program No 6 Program No 100 Program No 100 1 Select Sort Key Free area 10 8 11 ERROR CODE LISTS 11 ERROR CODE LISTS When an error occurs while the Motion CPU is running the error information is stored 11 in the error history devices 8000 to 8063 special relay M and special register D 11 1 Reading Procedure for Error Codes When an error occurs while the Motion SFC program is operating the error code and error message can be read by the SW6RN GSVLP The procedure for reading error codes by the SW6RN GSVOP is shown below Start the SW6RN GSVLP Con
177. e synchronous encoder current value change flag is stored by the 1 to 16 axis each bit As for a bit s actually being set Q173HCPU E1 to E12 Q172HCPU E1 to E8 OFF Start accept usable ON Start accept disable b15 208H 520 address E16 The cam axis within one revolution current value changing flag is stored by the 1 to 32 axis each bit As for a bit s actually being set Q173HCPU C1 to C32 Q172HCPU C1 to C8 OFF Start accept usable ON Start accept disable b15 b1 bO C17 Note 1 It can be used in SV22 20CH 524 address 20DH 525 address 3 MOTION DEDICATED PLC INSTRUCTION 3 2 Motion SFC Start Request from The PLC CPU to The Motion CPU S P SFCS PLC instruction S P SFCS Usable devices Internal devices MELSECNET 10 Special Bit Indirectly Index System User File a i direct JO O function f Constant Other a Note Setting dat digit specified register register f module specified device O Usable A Usable partly Note Setting data n1 to D2 Index qualification possible Instruction Condition Start request SP SFCS spP sFcs _ Start request S SFCS S SFCS Setting data Setting data Data type First I O No of the target CPU 16 n1 Value to specify actually is the following CPU No 2 3E1H CPU No 3 3E2H CP
178. ecial relays M9000 to M9255 and dedicated devices M2000 to M2399 cannot be set Errors 1 An operation error will occur if e D to D n 1 is outside the device range e n is O or a negative number i PX PY is set in D to D n 1 wordidevice When n specified is a 5 OPERATION CONTROL PROGRAMS 2 When conversion is made in program editing of the SW6RN GSVLEPP an error will occur if e D to D n 1 is outside the device range e S is outside the device range e n is 0 or a negative number When n specified is a PX PY is set in S constant e PX PY is set in D to D n 1 e S is a bit device and the device number is not a multiple of 16 e D is a bit device and the device number is not a multiple of 16 Program examples 1 Program which sets 3456H to all data for 100 words from 10 FMOV 10 H3456 K100 10 11 Transfer t H3456 109 2 Program which sets a content of D4000 to all data for 50 words from WO FMOV W0 D4000 K50 Transfer 4 D4000 1234 3 Program which sets 8000H to all data for 4 words from MO FMOV MO H8000 K4 M15 MO 1 0 0 0 0 00 0lo oo oloi o0 0 M31 M16 1000000000000000 Transfer 215 bO M47 S M32 _ 100000000 1000000000000000 M63 M48 1000000000000000 E oO Oo oO oO oO oO 5 OPERATION CONTROL PROGRAMS F FS 5 13 6 Write device data to shared CPU memory of the sel
179. ective branch or parallel branch O p J 4 MOTION SFC PROGRAMS G SSS EEE lt j 4 11 Motion SFC Comments A comment can be set to each symbol of the step transition in the motion SFC chart Comments are shown in the Motion SFC chart by changing the display mode to Comment display on the Motion SFC program edit screen Since the Motion SFC comments are stored into the CPU code area performing read from PC displays the Motion SFC chart with comments Classification cation Symbol Comment Setting Program name START Comment setting cannot be made Motion control step Program start end Once execution type operation control step Scan execution type operation control step Subroutine call start Program name step I CLR SY Clear step Program name Shift Up to 80 characters preread transition Displayed in 20 characters x4 lines WAIT WAITON Transition WAITOFF Shift Y N WAIT Y N Displayed in 16 characters x4 lines Pointer Pointer 4 MOTION SFC PROGRAMS 1 Motion SFC comments are stored into the CPU code area The CPU code area stores the Motion SFC chart codes operation control F FS program codes transition G program codes and Motion SFC comments Be careful not to set too many comments to avoid
180. ed by this program example by the following processing a While PX5 turns it on it is made to turn on a stop command M3200 20n and an internal relay M100 for the stop b While PX5 turns it off it is made to turn off a stop command M3200 20n and an internal relay M100 for the stop c A motion control step does absolute position to cope with it when it is resumed after it stops on the way of the positioning d A positioning completion signal M2401 20n is used for the decision whether it is stopped during the positioning on the way e The motion control step is resumed after it waits to turn it off when it was stepped during positioning f The internal relay M100 for the stop turn off is substituted for the WAIT transition condition that you must stop APP 28 APPENDICES 2 Contents of processing SFC program SFC program list Program Automatic i No Task Contents of processing name ie e This program starts automatically at the time of RUN of Q173HCPU and it is always executed e Watch data is taken out and clock data read request M9028 is turned on e The initials condition of the internal relay M100 for the stop is turned on 20 Main Normal Start i e The subroutine starts No 170 Stop The subroutine starts No 150 Programming operation When an forced stop is released all axes servo are turned on e Turns off actual output PY at the time of the forced stop 1 When
181. eeeeaeeceeeneeeeeneeeseeeeneeaees 5 72 5 13 2 Event task disable Di eea ae a A AE weeds teppei eee eaese 5 73 STS No Operation NOP ymsan aa a a a a alia te a a aR 5 74 5 13 4 Block transfer BMOW sarret aari a A AOE R AEE ae hae A A 5 75 5 13 5 Same data block transfer FMOV cecceeceeeeeeeeeeeeeeeeeeeeseeseeeseeseeseeseaeseeeseeeseeeseeeseaeseaeeeateaeeeaes 5 78 5 13 6 Write device data to shared CPU memory MULTW 0 eceeeceeeeeeeeeneeeeeeeeeeeeaeeeaeeeeeeaeeeaeeas 5 80 5 13 7 Read device data from shared CPU memory of the other CPU MULTR cecceeeeeeereeeeeees 5 83 5 13 8 Write device data to intelligent function module special function module TO 5 86 5 13 9 Read device data from intelligent function module special function module FROM 00 5 89 9 13 10 Time to wait TIME s asic hnadiva ahead aia ndawiiendie sed Sas hives 5 92 5 14 Comment Statement Mesire iare renina na aaa nA r aani Na ASAA ANE NEEE EAT NEERA aR Pa ITARA 5 94 6 TRANSITION PROGRAMS 6 1 to 6 2 6 1 Transition Programs 24 week cee e ea E a E A nd pec A ned adie 6 1 7 MOTION CONTROL PROGRAMS 7 1 to 7 22 ETSEN Instruction lists 2 ceskciet ie ea dite iid ae he i ete 7 1 7 2 Servomotor Virtual Servomotor Shaft Current Value Change cecceeceeeceeeeeeeeeeeeeneeeaeeeeeeeeeaeeeeeeaeesas 7 14 7 3 Synchronous Encoder Shaft Current Value Change Control SV22 OMly cceeeeeeneeeeeeeteeteeeereenteees 7 17 7 4 Cam Shaft Within One Revolu
182. emoved from the base unit The error of the MULTI CPU DOWN error code 7000 occurs in the other CPU e Turn off at reset release of the CPU No 3 Turn on during reset of the CPU No 3 It also contains when a CPU is removed from the base unit The error of the MULTI CPU DOWN error code 7000 occurs in the other CPU e Turn off at reset release of the CPU No 4 Turn on during reset of the CPU No 4 It also contains when a S Change status CPU is removed from the base unit The error of the MULTI CPU DOWN error code 7000 occurs in the other CPU Turn off when the CPU No 1 is normal I continuation error e Turn on during stop error of the CPU No 1 Note 1 Turn off when the CPU No 2 is normal I continuation error e Turn on during stop error of the CPU No 2 Note 1 Turn off when the CPU No 3 is normal I continuation error e Turn on during stop error of the CPU No 3 Note 1 Turn off when the CPU No 4 is normal I continuation error e Turn on during stop error of contains at contains at contains at contains at he CPU No 4 Note 1 Note 1 The CPU No 1 is reset after the factor of the stop error is removed to cancel a stop error Resetting is cancelled 1 OVERVIEW 3 Special registers Special registers are internal registers whose applications are fixed in the Motion CPU For this reason it is not possible to use these registers in Motion SFC programs
183. en PLC ready flag M2000 turns off Motion SFC programs stops to execute and the PCPU ready flag M9074 turns off Since actual outputs PY has whole point turn off When the PLC ready flag M2000 turns off Motion SFC programs stop but actual outputs PY in the Motion SFC programs do not turn off 9 13 Operation at The Error Occurrence Outputs are held if Motion SFC programs stop due to error occurrence To turn off outputs at error occurrence executes the following Motion SFC program ERROR Processing for the Motion FC B Processing for i oe the Motion SFC program AO Whether error occurred in corrspondence Motion SFC program or not is judged by error detection flag M2039 and 8056 latest error Motion SFC program No Outputs which must be turned OFF are turned OFF Motion SFC error detection flag M2039 is turned OFF 10 USER FILES 10 USER FILES A user file list and directory structure are shown below 10 1 Projects User files are managed on a project basis When you set a project name a project name folder is created as indicated on the next page and under that sub folders Sfc Glist Gcode Flist Fcode classified by file types are created Also under the Sfc sub folders initial files of the project file project name prj and an editing folder temp are created e Set the project name on the project management screen e The project name is restricted to 230 characte
184. end is a comment Errors 1 There are no operation errors for comment Program examples 1 Example which has commented a substitution program DO D1 Substitutes the DO value 16 bit integer data to D1 6 TRANSITION PROGRAMS 6 TRANSITION PROGRAMS 6 1 Transition Programs 1 Transition programs a Substitution operation expressions motion dedicated functions bit device control commands and transition conditions can be set in transition programs b Multiple blocks can be set in one transition program c There are no restrictions on the number of blocks that may be set in a single transition program Note that one program is within 64k bytes d The maximum number of characters in one block is 128 e Transition condition must be set in the last block of a transition program Transition program is repeated until the transition condition enables and when the transition condition has enabled it shifts to the next step Transition condition can be set only in the last block f As a special transition program a program which only no operation NOP is set in one block can be created This program is used when you want to proceed to the next step on completion of a servo program run and there are no special conditions to be set as interlocks Refer to Section 4 9 Branches Couplings for details A transition program example is shown below 1 block 0 D0 D1 D2 5 Substitution expression _ I
185. epted or not 31H 49 0 To self CPU high speed interrupt accept flag from CPUn accept usable 1 To self CPU high speed interrupt accept flag from CPUn accept disable 32H 50 33H 51 3 MOTION DEDICATED PLC INSTRUCTION Shared CPU memory address 204H 516 205H 517 206H 518 207H 519 208H 520 20CH 524 20DH 525 5 System area used by Motion dedicated instruction 204H to 20DH The complete status of the each flag is stored in the following address Start accept flag Axis1 to 16 Start accept flag Axis17 to 32 Speed changing flag Axis1 to 16 Speed changing flag Axis17 to 32 Synchronous encoder current value changing flag Axis1 to 12 Cam axis within one revolution current value changing flag Axis1 to 16 Cam axis within one revolution current value changing flag Axis17 to 32 Nee Description The start accept flag is stored by the 1 to 32 axis each bit As for a bit s actually being set Q173HCPU J1 to J32 Q172HCPU J1 to J8 OFF Start accept flag usable ON Start accept flag disable b15 J16 204H 516 address 205H 517 address J32 The speed changing flag is stored by the 1 to 32 axis each bit As for a bit s actually being set Q173HCPU J1 to J32 Q172HCPU J1 to J8 OFF Start accept usable ON Start accept disable b15 J16 206H 518 address 207H 519 address J32 Th
186. equest CHGT K1 0L CHGT K1 D800L Event task enable Event task disable C Write device data to shared CPU P memory of the self CPU MULTW H800 D800 0 K100 MO 39 95 MULTW H800 D800 K100 MO 44 55 MULTW H800 0 K256 MO 66 05 MULTW H800 D800 K256 MO 77 85 APP 5 APPENDICES Processing time of operation instructions Continued ed Q173HCPU Q172HCPU Classifications Symbol Instruction Operation expression Unit us u MULTR 0 H3E0 H800 K1 34 10 MULTR D800 H3E0 H800 K1 34 35 MULTR H800 0 K10 MO 40 15 Read device data from shared MULTR 0 H3E0 H800 K10 41 35 CPU memory of the other CPU MULTR D800 H3E0 H800 K10 126 15 MULTR 0 H3E0 H800 K100 128 40 MULTR 0 H3E0 H800 K256 260 50 MULTR D800 H3E0 H800 K256 261 85 TO HO HO 0 K1 25 95 TO H0 H0 D800 K1 26 50 TO HO HO 0 K10 32 60 Write device data to intelligent f TO HO HO D800 K10 34 30 function module special function TO HO HO 0 K100 108 35 module TO HO HO D800 K100 118 70 TO HO HO 0 K256 229 50 TO HO HO D800 K256 257 00 FROM 0 HO HO K1 26 50 FROM D800 HO HO K1 29 55 FROM 0 HO HO K10 33 45 Read device data from intelligent FROM D800 HO HO K10 34 00 function module special function FROM 0 HO HO K100 116 95 module FROM D800 HO HO K100 113 95 FROM 0 HO HO K256 240 70 FROM D800 HO HO K256 244 30 TIME K1 Time to wait TIME 0 TIME D800 APP 6 APPENDICES 2 Transition conditional expressions Processing time of transition conditio
187. ese parameters A duplication setting is possible turn PLC ready flag M2000 The same event can be shared among multiple off Motion SFC programs When you have set the NMI task further set the interrupt input which will be enabled 1 External interrupt make selection from those set to NMI task Multiple interrupt can be set from among 10 11 12 13 14 15 16 I7 18 19 110 111 112 113 114 and 115 Number of 1 to 10 consecutive Set the number of consecutive transitions toward the transitions program set to the event or NMI task End continue END Set the operation mode of the END step toward the operation program set to the event or NMI task The settings of END operation are invalid for the subroutine called program END operation is controlled as end 9 MOTION SFC PARAMETER 1 Start setting Description The following control is changed by automatically started or not setting e Program run by normal task When automatically started When not automatically started In the main cycle after the PLC ready flag M2000 The program is started by the Motion SFC start instruction turns off to on the program is executed from the S P SFCS from the PLC or by a subroutine call start initial first step in accordance with the number of GSUB made from the Motion SFC program e When started by the S P SFCS instruction In the main cycle after execution of the S P
188. ession type type L type K H K H L type K type F eS TE a EGR aS CA S o l l o ee O Usable Setting data substituted Data type of D Functions 1 The data value specified with S is substituted to the specified word device at D 2 When S and D differ in data type the data at S is converted into the data type of D and the resultant data is substituted When D is a 16 or 32 bit integer type and S is a 64 bit floating point type the fraction part of S is discarded Errors 1 An operation error will occur if The data at S is outside the data type range of D or e D or S is an indirectly specified device and its device No is outside the range Program examples 1 Program which substitutes the DO value to 0 0 DO 0 of 5 OPERATION CONTROL PROGRAMS 2 Program which substitutes K123456 789 to DOL DOL K123456 789 D1 DO 123456 D 123456 789 The 64 bit floating point type is converted into the 32 bit integer type and the result is substituted 3 Program which substitutes the result of adding K123 and 0 to WO WO K123 0 123 wo PEE i 0 5 OPERATION CONTROL PROGRAMS FIFS 5 4 2 Addition S1 S2 Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit f Calculation oi i i floating Coasting g floating conditional
189. et in S e PX PY is set in D to D n 1 Speed change request CHGV execution error Ci t th that th ified axi Torque limit value The specified axis No is outside the range Tene Peg a Set He SRE cue ats No is within the range change request CHGT execution error The S data is outside the range of the data e Correct the program so that the S data is Assignment type of D within the range of the data type of D execution error The device No which indirectly specifies D is Correct the program so that the device No illegal which indirectly specifies D is proper Operation execution error The divisor is 0 Correct the program so that the divisor is Remainder other than 0 execution error Device set SET execution error Device reset RST execu ion error The device No which indirectly specifies D is e Correct ane program so that the device No Device set SET which indirectly specifies D is proper illegal execution error CEAI rae ots Correct the program to set a write enabled D is a device which is write disabled s Device reset RST device at D execution error Device output DOUT execution Device input DIN The device No which indirectly specifies D is Correct the program so that the device No which indirectly specifies D is proper ass e gt e gt e gt e gt e gt e gt e gt e gt
190. expression of singleprogram for operation control transition program 2 1 Total number of basic steps in 1 block Number of 32 bit constants 1 block x 1 Number of 64 bit constants 1 block x 3 x Number of blocks steps 1 step 2 bytes 1 OVERVIEW 1 2 4 Differences Between Q173HCPU Q172HCPU and Q173CPU N Q172CPU N 1 Differences between Q173HCPU Q172HCPU and Q173CPU N Q172CPU N Q173HCPU Q172HCPU Q173CPU N Q172CPU N Number of control axes Operation cycle Default It can be set up by parameters Up to 32 axes 0 44ms 1to 3 axes 0 88ms 4 to 10 axes 1 77ms 11 to 20 axes 3 55ms 21 to 32 axes 0 88ms 1 to 5 axes 1 77ms 6 to 14 axes 3 55ms 15 to 28 axes 7 11ms 29 to 32 axes Up to 8 axes 0 44ms 1 to 3 axes 0 88ms 4to 8 axes 0 88ms 1 to 5 axes 1 77ms 6 to 8 axes Up to 32 axes 0 88ms 1 to 8 axes 1 77ms 9 to 16 axes 3 55ms 17 to 32 axes 0 88ms 1to 4 axes 1 77ms 5 to 12 axes 3 55ms 13 to 24 axes 7 11ms 25 to 32 axes Up to 8 axes 0 88ms 1 to 8 axes 0 88ms 1 to 4 axes 1 77ms 5to 8 axes Code total 543 kbyte Code total 287 kbyte Motion SFC program capacity Text total 484 kbyte Text total 224 kbyte Peripheral devices I F USB SSCNET USB RS 232 SSCNET See Q173HCPU 2 systems Q173CPU N 4 systems Note 1 Servo amplifier I F Optical Q172HCPU 1 system Q172CPU N 1 system communication Fixed position stop function with ee control Phase
191. f CPU MULTW MULTW D S n D1 Number of basic steps 8 Usable data Usable Data Bit device 64 bit 64 bit Bit Comparison 16 bit 32 bit 7 16 bit 32 bit DF Calculation pe floating Coasting floating conditional conditional l i i expression i integer integer point finer integer integer type i P expression expression type type L type F type K H K H L o lol o o ome o ee eT Pim eee pot d o eee O Usable Note 1 Refer to the Section 1 2 5 for the correspondence version of the Motion CPU and the software Setting data Setting data Setting data Data type of result The shared CPU memory address of self CPU of the writing destination device 8300H to FFFH First device No which writing data are stored ow Number of words to be written 1 to 256 D1 Self CPU device is made to turn on e the writing e 1 A part for n words of data since the device specified with S of the self CPU module are written to since the shared CPU memory address specified with D of the self CPU module After writing completion of the device data the complete bit device specified with D1 turns on Functions Shared CPU memory address Shared CPU OH Self CPU operation This area memory of the 3 data area cannot be self CPU Write the data Device memory 200H System area used at H0000 of a part for u
192. false Normally it is used in the conditional expression of a transition program In an operation control program the logical data is used in a bit conditional expression set to device set SET or device reset RST Example 1 SET MO X10 Logical data Bit data R Example 2 RST M5 X10 M100 Logical data Bit data R Example 3 transition program DO K100 j Logical data 5 OPERATION CONTROL PROGRAMS 5 2 Device Descriptions Word and bit device descriptions are shown below 1 Word device descriptions Device descriptions 16 bit pads orl Device No n specifying ranges integer type floating point type integer type f n is even No n is even No Data register O om ow toto Link register Wn WnL Wn F 0 to 1FFF Special register Dn DnL DnF 9000 to 9255 0 to 8191 Motion device Motion SFC dedicated devices 8000 to 8191 Coasting timer a a For differentiation the 32 bit floating point type is ended by L and the 64 bit floating point type by F F for the link register b For the 32 bit integer type and 64 bit floating point type specify the device number with an even number It cannot be set as an odd number c The coasting timer FT is incremented per 888 us The coasting timer is a 32 bit integer type 2 Bit device descriptions O OS Device description Device No n specifyied ranges Input relay Xn PXn 0 to 1FFF Out
193. ffer full M2050 Start buffer full Manual pulse generator 1 enable Manual pulse generator 1 enable M2051 M2051 flag flag Manual pul tor 2 enabl Manual pul tor 2 enabl Sara anual pulse generator 2 enable anual pulse generator 2 enable i M2052 PEER M2052 we Rae signal flag flag Note 1 Manual pulse generator 3 enable flag At start M2040 M2040 M2043 Manual pulse generator 3 enable flag M2053 M2053 1 26 1 OVERVIEW Table of the common devices SV13 SV22 continued SV13 SV22 Refresh Signal Operation Fa Status M2054 Operation cycle over flag M2054 Operation cycle over flag cycle signal M2055 M2055 Unusable Unusable 2080 6 points 6 points vosi asst ee lm te pera ion to to 32 to to 32 cycle m2002 avis a2 0429 m2002 avis a2 C2 M2093 a 01 ree CEES encoder Unusable to current value changing Operation 35 points flag cycle M2112 Axis 12 12 axes M2113 to 15 points M2127 M2127 Ai M2128 Automatic decelerating M2128 Automatic decelerating to flag to flag M2159 32 axes M2159 32 axes Main shaft M2160 ea Output side axis 1 ila Speed changing flag Unusable 8 points Unusable pare gt e Operation kew er input eyel an Clutch status eo e shaft Note 6 Unusable E M224 80 points axis 32 eoe input a M2239 Speed change 0 Speed change 0 accepting flag accepting flag
194. formed Errors 1 An operation error will occur if e The S data is outside the range 2147483648 to 2147483647 or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which converts the data of DO into a signed 32 bit integer value and substitutes the result to 0L 0L LONG DO0 1 0 K 1L q D0 HFFFFFFFF HFFFF 5 OPERATION CONTROL PROGRAMS FIFS 5 7 4 Unsigned 32 bit integer value conversion ULONG ULONG S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison oe on bi bi Calculati data Bit device 16 bit Saoi floating Coasting 16bit A floating appa conditional conditional d i i expression 4 h integer integer integer integer type point P expression expression type type L type K H K H L type F type K Lond d aoad aoad aoa d aoa d ee aoa d ee ee ee ee O Usable Setting data Setting data Data type of result Data which will be converted into unsigned 32 bit integer value Functions 1 The data specified with S is converted into an unsigned 32 bit integer value 2 The data range of S is 0 to 4294967295 3 When S is a 64 bit floating point type its fractional portion is rounded down before conversion is made 4 If S is a 32 bit integer type its value is returned unchanged with no conversion processing performed Errors 1 An operation error will
195. g every event occurrence operation is executed Note When making it When stopping it is make to always execute execute CLR by other programs set as automatic starting 9 MOTION SFC PARAMETER lt Example 2 gt Program name E a PLC program EI DI status by other programs sens 2 0 5 2 _____ Event processing by external interrupt Starting of the SINT l event task is accepted Cn 23 3 gt lt Event occurrence during DI status Event task is not executed is memorized and executed during DI status Except for NMI task Event processing by the fixed cycle Starting of the interrupt event task is accepted i 1 lt 1 gt 1 Executes by the new event task Points a Multiple events can be set to one Motion SFC program However multiple fixed cycles cannot be set b Multiple Motion SFC programs can be executed by one event c Motion control steps cannot be executed during the event task d The event task cannot be executed when it is disabled by the normal task The event that occurred during event task disable is executed the moment the event task is enabled Errors When the motion control step is executed by the Motion SFC program set to the event task the Motion SFC program error 16113 occurs and stops the Motion SFC program running 9 MOTION SFC PARAMETER NMI task operation Operations The Motio
196. g Coasting floating conditional conditional expression integer integer type point expression expression integer integer oint timer type type L ie E type KH KHD apet on o o l o ol o ps ome o Posy ol Tl I i Tl O Usable Note 1 Refer to the Section 1 2 5 for the correspondence version of the Motion CPU and the software Setting data special function module 000H to FFOH First address of the buffer memory which writes First device No which writing data are stored Number of words to be written 1 to 256 Functions 1 A part for n words of data from device specified with S are written to since address specified with D2 of the buffer memory in the intelligent function module special function module controlled by the self CPU specified with D1 D1 Intelligent function module special function module buffer memory Write the data Device memory of a part for n words D2 2 a a N g 6 a 2 5 3 fe No OOH No 10H No 20H D1 sets 20H by the system setting when a TO instruction is executed in the D A conversion module Q64DA 5 OPERATION CONTROL PROGRAMS 3 The word devices that may be set at D1 D2 S and n are shown below Word devices 2 _ 1 Note 1 No
197. g is insufficient these may come off during operation Always install the servomotor with reduction gears in the designated direction Failing to do so may lead to oil leaks Store and use the unit in the following environmental conditions Environment Motion controller Servo amplifier Servomotor Ambient gt 0 C to 40 C With no freezing According to each instruction manual temperature 32 F to 104 F 80 RH or less With no dew condensation Storage A 20 C to 65 C According to each instruction manual temperature 4 F to 149 F Indoors where not subject to direct sunlight Atmosphere f A No corrosive gases flammable gases oil mist or dust must exist Altitude 1000m 3280 84ft or less above sea level According to each instruction manual When coupling with the synchronization encoder or servomotor shaft end do not apply impact such as by hitting with a hammer Doing so may lead to detector damage Do not apply a load larger than the tolerable load onto the servomotor shaft Doing so may lead to shaft breakage When not using the module for a long time disconnect the power line from the Motion controller or servo amplifier Place the Motion controller and servo amplifier in static electricity preventing vinyl bags and store When storing for a long time please contact with our sales representative Ambient humidity According to each instruction manual A CAUTION Correct
198. gram edit information file svedtdan bin into internal codes Cam data files of cam No 1 to 64 lt Cam data files of cam No 101 to 164 Cam data files of cam No 201 to 264 lt Cam data files of cam No 301 to 364 Information file 9 for backup and load Information file 10 for backup and load Motion registers 0 to 8191 read file Only user device range 0 to 7999 is written Devices X Y M L B F D W Special relay Special register except read file Device setting information files Multiple CPU I O assigment data files Optional data monitor information files Communication setting information files 10 2 10 USER FILES 10 3 Online Change in The Motion SFC Program The online change is used to write to the Motion SFC program to the internal SRAM during the positioning control M RUN LED ON Program correction and a check of operation can be executed repeatedly at the Multiple CPU system start Data in which online change is possible are shown below Applicable data Online change System setting data System setting ae ee Servo setting data a Sh Motion SFC program Motion SFC parameter x l Online change is possible for the Motion SFC chart j only program during stop Operation control step F FS o o Transition G Online change of mode Servo program K ae assignment setting is not possible Mechanical system program SV22 e Sees Cam data SV22 a Possible X N
199. h the step FO is executed positioning ready A step in such an active state is called an active step 2 Whether the condition specified with the transition GO has enabled or not whether the positioning program can be started or not is checked The active step FO is deactivated at the completion of condition and the next step KO is START Entry of program Step operation control step The specified operation control program is executed at active status Transition shift Condition to transit to the next step Step motion control step The specified servo program is executed at active status END Program end activated servo program KO is started 3 The operating completion of the step KO positioning completion of the servo program KO is checked and control transits to the next step at operating completion completion of condition 4 With the transition of the active step as described in above 1 to 3 control is executed and ends at END Refer to Section 9 2 2 Task operation for details of the execution timing of the Motion SFC program such as above The number of steps which can be active steps simultaneously is up to 256 with those of all Motion SFC programs combined Excess of 256 will result in the Motion SFC Program error 16120 Each symbol of the Motion SFC program is as follows F FS Operation control K Positioning control G Judgment SET Y
200. he Motion SFC program is ended by END 4 MOTION SFC PROGRAMS 4 9 Branches Couplings 4 9 1 Series transition Transits execution to the subsequent step or transition connected in series 1 To start a servo program or subroutine and shift execution to the next without waiting for operation completion Set Shift at a transition In this case the transition shift may be omitted When you omitted the transition an unconditional shift transition is performed K1 Starts the servo program K1 Gi Transits to next by the completion of condition set at transition G1 without waiting for operating completion of the servo program K1 K2 Starts the servo program K2 For a subroutine start self program and a subroutine program are processed in parallel 2 To start a servo program or subroutine and proceed to the next step on operation completion Set WAIT at a transition K1 Starts the servo program Transits to next when the start axis stops in the servo program K1 start Ces accept flag turns OFF and condition is completed set at transition G1 Starts servo program K2 1 The above start accept flag of the axis started in the next servo program K2 is not included in interlocks To use it as an interlock the user should set it in the transition condition G1 2 WAIT must be set to proceed to the next step on operation completion However when there are specificall
201. he completion of transition condition If not formation of transition condition transits to the right connected step p Pn Jumps to the specified pointer Pn PO to P16383 of the Jump Jump JMP Pn self program 14 Indicates a jump destination pointer label This pointer can be set at a step transition branch Pointer Pointer Pn point or coupling point 8 PO to P16383 can be set in one program The same No may also be used in other programs 4 MOTION SFC PROGRAMS 4 3 Branch and Coupling Chart List Branch and coupling patterns which specify step and transition sequences in the Motion SFC charts are shown below Name 3 List Series transition Corresponding symbol size List representation corresponding to the Motion SFC chart symbols shown in Section 4 2 e Steps and transitions connected in series are processed in order from top to bottom Steps and transitions need not be lined up alternately When a transition is omitted unconditional shift processing is performed Selective branch Number of branches 2 x 10 Parallel branch Number of branches x 22 number of coupling points x2 12 Parallel coupling 8 Jump transition Corresponding symbol size lt Normal jump gt lt Coupling jump gt CALL Kn IFBm IFT1 SFT Gn CALL Fn
202. he diagnostic error D9008 is stored There are following two types information to be stored 1 Module No CPU No Base No e Module No or CPU No is stored according to the error which occurred in the case of the Multiple CPU system Refer to each error code which is stored CPU No 1 1 CPU No 2 2 CPU No 3 3 CPU No 4 4 2 Parameter No e The operation states of CPU as shown below are stored in D9015 B15 B12B11 B8 B7 B4 B3 T T T T T T T D9014 Error information Error information Operating state of Operating state of 1 Operating state of CPU 0 RUN 2 STOP S Main processing 2 STOP cause 0 RUN STOP switch Note Priority is earliest first 4 Error i Scan time e Main cycle is stored in the unit 1ms 7 Scan time ims units Setting range 0 to 65535 ms 9 Maximum scan _ Maximum scan The maximum value of the main cycle is stored in the unit 1ms time time 1ms units Setting range 0 to 65535 ms Stores the year 2 lower digits and month in BCD B8 B7 so Example July 1993 Clock data D9025 Clock data H9307 S U Request Year month D9010 D9011 D9012 D9013 D9015 g Ko g Ko 1 OVERVIEW Table 2 2 Special register list continued sia E t en sel Stores the day and hour in BCD draist to so Example 31st 10 a m anaes i H3110 Day hour i i to B12B11 to wags data TES l H3548 Minute second Vo M
203. he operating system software of Motion CPU is SV22 2 Motion CPU side is during DI interrupt disable event processing can make wait even as for the El interrupt enable instruction execution 3 SM390 turn on when the transmission of the instruction toward the target CPU was completed SM391 S P GINT instruction execution completion flag turned on simultaneously 3 MOTION DEDICATED PLC INSTRUCTION 4 SM390 turn off when the transmission of the instruction toward the target CPU was not completed SM391 S P GINT instruction execution completion flag turned off when the instruction toward the target CPU cannot be transmitted 5 Number of instruction execution does not have restriction if to self CPU high speed interrupt accept flag from CPUn in the target shared CPU memory of S P GINT instruction Operation EN PLC program S P GINT instruction To self CPU high speed interrupt accept flag from CPUn OFF Interrupt PLC to Event task executed processing to the other CPU the other Motion CPU _ P GINT instruction execution M391 Instruction executed _OFF complete flag S P GINT instruction non execution Errors The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO Complete status E de H Error factor Corrective action rror code 2110 The CPU No to be set by First I O No of the target CPU 16 is specifie
204. he same axis of the same Motion CPU No Operation PLC program END S P CHGV execution S P CHGV instruction accept flag from CPUn Speed changing flag I l I l I l I I I l To self CPU high speed interrupt 1 l l I l j 1 l 1 J 1 Speed change Speed change processing Instruction start accept complete device D1 0 State display device D1 1 at the instruction start accept completion Instruction accept completion at the Motion CPU side 3 MOTION DEDICATED PLC INSTRUCTION Setting range 1 Setting of axis to execute the speed change The axis to execute the speed change set as S1 sets J axis No in a character sequence _ St usabie range Q173HCPU 1 to 32 Q172HCPU 1 to 8 The number of axes which can set are only 1 axis The axis No set in the system setting is used as the axis No to start Refer to the Q173HCPU Q172HCPU Motion controller Programming Manual COMMON for system settings 2 Setting of the speed to change S2 usable range 2147483648 to 2147483647 Speed changing flag System area The complete status of the start accept flag is stored in the address of the start accept flag in the shared CPU memory Shared CPU memory address Description is decimal address The start accept flag is stored by the 1 to 32 axis each bit As for a bit s actually being set Q173HC
205. hich inputs the data of X0 XF to DO DIN DO XO 5 OPERATION CONTROL PROGRAMS FIFS 5 9 5 Bit device output OUT OUT D S Number of basic steps Usable data Usable Data Setting i 64 bit i 64 bit Bit Comparison data Bit device AOb Kapl floating Coasting ae 32bit floating Calculation conditional conditional integer integer 5 i integer integer type expression point expression expression type L type K H O Usable Setting data Setting data Data type of result o Do Bit device for device output Bit logical type Condition data which determines device output true false Functions 1 If the data specified with S is true the bit data specified with D is set and if the data specified with S is false the bit data specified with D is reset 2 When this instruction is set as a transition condition in the last block of a transient program whether the data specified with S is true or false is returned as logical type data 3 In this case S cannot be omitted Errors 1 An operation error will occur if e D or S is an indirectly specified device and its device No is outside the range Program examples 1 Program which sets M100 when MO is ON 1 and program which resets M100 when MO is OFF 0 OUT M100 MO 2 Program which sets M100 when MO and M1 are both on and resets M100 except it OUT M100 MO M1 3 Program which sets M100 when DO is equal t
206. i lt csa atsowte a ddol EET TTT EEE S pisai _ O ltem which must be set A Item which is set when required Controls Control using CHGA E instruction 1 Executing the CHGA E instruction changes the current value of the synchronous encoder shaft in the following procedure a The synchronous encoder shaft current value changing flag M2101 to M2112 corresponding to the specified synchronous encoder shaft is turned on b The current value of the specified synchronous encoder shaft is changed to the specified address c The synchronous encoder shaft current value changing flag is turned off at completion of the current value change 2 The used axis No can be set within the following range Q172HCPU Q173HCPU Axis 1 to 8 Axis 1 to 12 3 The address which made the current value change by CHGA E instruction is valid after also the power supply turned off 7 MOTION CONTROL PROGRAMS SSS SESS SSS Program example A program which made the current value change control of the synchronous encoder shaft is described as the following conditions 1 System configuration The current value change control of the synchronous encoder shaft P1 is executed C p axis AMP AMP AMP AMP AMP AMP AMP Axis 2 A Axis 1 xis Axis 4 Axis D Axis D Axis D Axis D Q 2 The current value change control conditions a The current value change control conditions are
207. ied circular interpolation CW 180 or more Absolute radius specified circular J interpolation less than CCW 180 Absolute radius specified circular ion CCW 180 or more Incremental radius specified circular interpolation less than CW 180 Incremental radius specified circular interpolation CW 180 or more Incremental radius specified circular interpolation less than CCW 180 Incremental radius specified circular interpolation CCW 180 or more 7 MOTION CONTROL PROGRAMS Positioning data n O Starting angle Amplitude Frequency Reference axis No Control unit Speed limit value Acceleration time Deceleration time Torque limit value at stop input interpolation S curve ratio Repeat condition Program No Command speed WAIT ON OFF deceleration time Fixed position stop Number of steps Rapid stop deceleration time Deceleration processing FIN acceleration deceleration Fixed position stop acceleration L s 3 3 D d s o E o 2 ro 2 Sd eo ee a aS E E a a a ea eee 2 2 2 2 fa ela we e T e Must be set A Set if required 1 Only reference axis speed specification 2 B indicates a bit device 7 MOTION CONTROL PROGRAMS Table 7 2 Servo Instruction List continued Positioning data no j 2 Dwell time Instruction symbol Auxiliary point Central
208. ied with S1 The CPU which reads is resetting The errors are detected in the CPU which read D is a bit device and the device number is not a multiple of 16 PX PY is set in D to D n 1 11 7 The block processing in execution is stopped and the next block is executed Error factor i A Error Processing Corrective Action Correct the program so that the number of words n to be written is within the range of 1 to 256 Correct the program so that the shared CPU memory address D of self CPU of the writing destination is within the range of shared CPU memory address Correct the program so that the shared CPU memory address D of self CPU of the writing destination number of words n to be written is within the range of shared CPU memory address e Correct the program so that first device No S which writing data are stored number of words n to be written is within the device range e Execute MULTW instruction again after the complete bit device of MULTW instruction is turned on e Correct the program to set a write enabled device at D1 e When S is a bit device set the device number to be multiple of 16 e When S is a bit device do not set PX PY Correct the program so that the number of words n to be read is within the range of 1 to 256 Correct the program so that the shared CPU memory first address S2 of the data which it will be read is within the de
209. ified device and its device No is outside the range Program examples 1 Program which finds the natural logarithm of DOF and substitutes the result to 0F 0F LN DOF 3 2 1 D2 D1 0 D3 DO 2 3025850929940 10 0 5 OPERATION CONTROL PROGRAMS FIFS 5 6 9 Exponential operation EXP EXP S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting ae bit f 32 bit floating ACHA as conditional conditional integer integer integer integer type expression i int expression expression type type L type K H K H L poin R P type F type K Lond dad aoad aoad aoa d aoa daoa dod aod ud O Usable Setting data Setting data Data type of result Data on which exponential operation will be Floating point type performed Functions 1 Exponential operation is performed on the base e data specified with S 2 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which performs exponential operation of DOF and substitutes the result to 0F 0F EXP DOF 3 1 D2 D1 2 0 D3 D1 DO 442413 30200802 lt 30 o 5 OPERATION CONTROL PROGRAMS FIFS
210. ift function provided JOG operation function Manual pulse generator i f Possible to connect 3 modules operation function Synchronous encoder R j i Possible to connect 12 modules Possible to connect 8 modules operation function 5 M code output function provided M code function f i M code completion wait function provided Limit switch output Number of output points 32 points function Watch data Motion control data Word device Made compatible by setting battery to servo amplifier Absolute position system Possible to select the absolute data method or incremental method for each axis 1 OVERVIEW Motion control specifications continued Q173HCPU Q173HCPU T Q172HCPU Q172HCPU T Number of SSCNET IZ Note 1 2 systems 1 system systems Q172LX 4 modules usable Q172LX 1 module usable Q172EX 6 modules usable Q172EX 4 modules usable module Note 2 Q173PX 4 modules usable Q173PX 3 modules usable Motion related interface Note 2 Note 1 The servo amplifiers for SSCNET cannot be used Note 2 When using the incremental synchronous encoder SV22 use you can use above number of modules When connecting the manual pulse generator you can use only 1 module b Motion SFC Performance Specifications Code total Motion SFC chart Operation control 543k bytes Motion SFC program capacity Transition Text total 4p4k bytes Operation control Transition y Number of Motion SFC progra
211. ignal status changes to ON When making a speed change at almost the same timing as a start always create a program which will execute the speed change after the positioning start completion signal has turned ON A return request which is made while the axis is at a stop waiting for FIN using the M code FIN signal waiting function during constant speed control will be ignored 3 In the above example if a return request is given right before P2 and the axis passes through P2 during deceleration the axis will return to P2 4 There will be a delay of time equivalent to an operation cycle at the maximum in the response time from when the CHGV instruction is executed until the speed begins to change actually Return request was given here Starting point 5 OPERATION CONTROL PROGRAMS FIFS 5 12 2 Torque limit value change request CHGT CHGT S1 S2 Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit f Calculation oi i f R floating Coasting g floating conditional conditional integer integer i integer integer type i expression point expression expression type type L type K H K H L type K maa eee a e a noe Ss ee ee ae eee ee ee ee ee ee ee O Usable Setting data Setting data Data type of result Axis No to which torque limit value change request will be given S1
212. in the same way that normal registers are used However data can be written as needed in order to control the Motion CPU Data stored in the special registers are stored as BIN values if no special designation has been made to the contrary The headings in the table that follows have the following meanings Indicates whether the register is set by the system or user and if itis set by system when setting is performed lt Set by gt S Set by system Motion CPU U Set by user Motion SFC program or test operation using a peripheral device S U Set by both system Motion CPU and user Set by lt When set gt Indicated only if setting is done by system Motion CPU When set Main process Set during each main processing free time processing of the CPU Initial process Set only during initial processing when power supply is turned ON or when executed the reset Status change Set only when there is a change in status Error Set when error is occurred Request Set only when there is a user request Special reray etc Operation cycle Set during each operation cycle of the Motion CPU 1 OVERVIEW Table 2 2 Special register list Name Meaning Details Sethy Remark When set Module No with When fuse blown modules are detected the lowest I O module No is stored D9000 Fuse blown No 3 blown fuse in D9000 1 is added to the stored value each time the input voltage becomes 85 AC DC DOWN Number of ti
213. ing Calculation snditional conditional integer integer i i integer integer type 5 expression 2 point expression expression type type L type K H K H L type K ae a a GT a l ae ae ae am ae an ae ae ae O Usable Setting data Setting data Data type of result S1 Multiplicand data Data type of S1 or S2 S2 Multiplier data which is greater Functions 1 The data specified with S1 is multiplied by the data specified with S2 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which substitutes the result of multiplying K123 by 0 to WO WO K123 0 123 Wo 56088 lt 0 456 2 Program which substitutes the result of multiplying 0F by 10 to DOL DOL 0F 10 1 0 a 789 DoL 1518532 J _ 0 The 64 bit floating point type data are used for multiplication and the result is converted into the 32 bit integer type and then substituted 5 14 5 OPERATION CONTROL PROGRAMS FIFS 5 4 5 Division S4 S2 Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 16 bit 32 bit i Calculation an P floating Coasting A 3 floating i condi
214. integer 5 i integer integer type j expression i point timer point expression expression type type L type F type K H K H L type K om fom o Il 1l Post o o sz o o Cw d l ol so Tl I i ll I O Usable Note 1 Refer to the Section 1 2 5 for the correspondence version of the Motion CPU and the software Setting data D First device No which stores the reading data _ First I O No of the PLC CPU Motion CPU which it will be read CPU No 1 3E0H CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H S2 The shared CPU memory first address of the data which it will be read 000H to FFFH Number of words to be read 1 to 256 Functions 1 A part for n words of data of the other CPU specified with S1 are read from the address specified with S2 of the shared CPU memory and are stored since the device specified with S2 Shared CPU S1 Shared CPU memory address memory of the 0H Self CPU operation specified CPU data area Device memory No with S1 Ed System area This area can Read the data of S2 be used at a part for n words 800H Automatic refresh users area gt area Note User defined area OFFFH Note When automatic refresh is not set it can be used as a user defined area And when automatic refre
215. inute Clock data he day of the week in BCD S U Request to B12B11 to B8 B7 B4 B3 to BO Example i IE a i Sei i hi Friday i i j I i i i t i i eerie fhe f D H0005 Clock dat E Day of week D9028 S Sunday Day of week 0 must be set here Monday Tuesday Wednesday Thursday Friday Saturday Error No of D9060 Error reset Error No of canceling error is stored releasing an error D9061 Multiple CPU No Multiple CPU No CPU No of the self CPU is stored S Initial processing When the servo amplifier or SSCNETII cable on the SSCNET system are exchanged or re connected an user side requires connect disconnect to a system and a system side stores the state of waiting for command accept or Connect execution of connect disconnect Connect disconnect of 0 Connect disconnect command accept waiting 7 1 S Main processing U 10 Connect command 2 Connect disconnect execute command It is operating in requirement error Each axis is stopping 0 Operating 1 information is stored as a bit data occurrence of the D9182 b0 to b15 Axis 1 to Axis 16 test mode axis D9183 b0 to b15 Axis 17 to Axis 32 information disconnect g SSCNET Connect disconnect execute waiting 1 to 32 Disconnect command Ete D9182 Test mode D9183 request error The following error codes are stored in D9184 1 SW fault 1 2 Operation c
216. ion START accept flag Current value change completion 4 Servo program lt K10 gt gt CHGA Servomotor virtual sevomotor shaft Axis 2 50 current value change control Axis NO US d ceceeeseceeeeeeeee 2 Current value change address 50 7 MOTION CONTROL PROGRAMS 1 Current value changing instructions e When PLC ready flag M2000 or PCPU ready flag M9074 is OFF a minor error Note 100 occurs and a current value change is not made e This change is made only during a stop If a current value change is made while the specified axis is starting a minor error Note 101 start accept signal of the corresponding axis is ON occurs and the current value change is not made If the servo of the corresponding axis is not READY a major error Note 1004 occurs and the current value change is not made e If the corresponding axis is in a servo error a major error Note 1005 occurs and the current value change is not made For SV22 Set the current value change program of the virtual servomotor shaft within the virtual mode program No range set in program mode assignment Set the current value change program of the servomotor output shaft within the real mode program No range If a virtual servomotor shaft current value change is executed in the real mode a servo program setting error Note 903 occurs and the current value change is not made If a serv
217. ion SFC error history clear request flag or programming software The error information is shown below D ipti Signal name escription Motion SFC control errors Conventional errors Error Motion SFC 0 to 255 Motion SFC program No in error program No 1 Independent of Motion SFC program Minor major error Minor major error virtual servomotor shaft SV22 only Minor major error synchronous encoder shaft SV22 1 F FS only 2 G Servo error Error type 1 K or other Servo program setting error not any of F FS G and SFC chart Mode change error SV22 only 2 Motion SFC chart 9 Manual pulse generator axis setting error 10 Test mode request error 11 WDT error 12 Personal computer link communication error 0 to 4095 F FS G K program No 0 to 4095 Servo program No when error type is 3 4 or Error program No 0 to 255 GSUB program No 7 1 Independent of F FS G K GSUB__ 1 Others 0 to 8191 F FS or G program s block No line No when error type is 1 Error block No or 2 1 to 32 Corresponding axis No when error type is any of 3 Motion SFC list 0 to 8188 Motion SFC list line No when error to 6 line No axis No type is 2 1 Others 1 Independent of block when error type is 1 or error type is 1 or 2 e Conventional error code less than 16000 when error type is any of 3 to 6 Error code stored in D9190 when error type is 7 Error
218. ion error will occur if Number of words n to be read is outside the range of 1 to 256 Motion CPU cannot communicate with intelligent function module special function module at the instruction execution Abnormalities of the intelligent function module special function module were detected at the instruction execution I O No s specified with S1 differ from the intelligent function module special function module controlled by the self CPU The address specified with S2 is outside the buffer memory range First device No D which stores the reading data number of words n to be read is outside the device range D is a bit device and device number is not a multiple of 16 PX PY is set in D to D n 1 5 OPERATION CONTROL PROGRAMS Program examples 1 1 word is read from the buffer memory address 10H of the intelligent function module special function module First I O No 020H and is stored in WO FROM WO H020 H10 K1 Intelligent function module special function module First I O No 020H Buffer memory Device memory 1 word transfer wE T G gg 5 OPERATION CONTROL PROGRAMS FIFS 5 13 10 Time to wait TIME TIME S Number of basic steps Usable data Usable Data Setting t 64 bit 64 bit Bit Comparison data Bit device aoe seul floating Coasting aol i S2ipit floating calculation conditional conditional integer integer integer integer type expression point expre
219. ion of Classification Symbol Function Format Basic steps ae on S Secon F FS conditional reference expression None Logica acknowiedgment Condiionai expression 0 o o o 5 0 4 a ee Conditional expression Logical operation Logical AND 5 10 3 conditional expression Logical OR Conditional expression 510 4 conditional expression Equal to Conditional expression 5 111 conditional expression _ Conditional expression l Not te 5 11 2 PARIERO conditional Oe a l 2 Less inan Conditiona expression lt 4 o O 6 5113 Comparison conditional expression operation Conditional expression lt lt Less than or equal to 3 5 11 4 conditional expression More than Conditional expression gt 5115 conditional expression Conditi ion gt More than or equal to Con en expression 4 O conditional expression Motion dedicated CHGV_ Speed change request een 4 O function EEE Ei Eventtaskenable Boka J 5134 Eaa e Se ce E e 9 ___ 583 Suet potraste ooo oS e e sa 5135 Write device data to shared CPU memory Read device data from shared CPU ce memory of the other CPU a MSS eae e Write device data to intelligent function TO TO D1 D2 S 7 5 13 8 e module special function module oe Pape FROM Read device Gate from intelligent function FROM D S1 S2 n 5 139 module special function module e e 3 Rough calculation
220. iorate Periodically replace these to prevent secondary damage from faults Replacements can be made by our sales representative 9 About processing of waste When you discard Motion controller servo amplifier a battery primary battery and other option articles please follow the law of each country area A CAUTION This product is not designed or manufactured to be used in equipment or systems in situations that can affect or endanger human life When considering this product for operation in special applications such as machinery or systems used in passenger transportation medical aerospace atomic power electric power or submarine repeating applications please contact your nearest Mitsubishi sales representative Although this product was manufactured under conditions of strict quality control you are strongly advised to install safety devices to forestall serious accidents when it is used in facilities where a breakdown in the product is likely to cause a serious accident 10 General cautions A CAUTION All drawings provided in the instruction manual show the state with the covers and safety partitions removed to explain detailed sections When operating the product always return the covers and partitions to the designated positions and operate according to the instruction manual REVISIONS x The manual number is given on the bottom left of the back cover Sep 2006 IB NA 0300112 B Additional m
221. iptions c cc0 8fbecied iced aa chal lacoste eid baceveded atid bias dec athe date deed 5 9 SA BNA O p rO S A ts cust sascavnadtseventsss evetataduadesscaengdea mebtycstatcaveascagmatessaueedest 5 10 5 4 1 SUDSUTUTION Seiten chee een chee ein chee cine eee ess Reve ee Ree en het 5 10 DAD AO Lo 11101 0 GE AEEA E ET ag P se cael EA dass weet EE ee PA eases oat ates Pa ae estes dae E E EE aa EPR 5 12 5 4 3 Subtraction steven seein neice eee lta adeeieie needed heeds 5 13 544 Multiplication T e a ev e a a e a et deed Sete edit fe eee eee eee 5 14 54 5 DIVISIONS fw ois a a ai ha dete hh cde aaaea cade tatu Acts eta ae ea Adnan iaa a 5 15 5 4 6 Remainder sarnana Beate eh lead ath aed a a hn Raden hahah 5 16 DD Bit OPelallOmS 2 visti a a sera soe a Bove fa eae at anes fa ie tatiana ited diate teak dt 5 17 5 5 1 Bit inversion COMPIEMENt ossssssnuissiinsiaani inna a aii daai 5 17 9 5 2 Bit logical AND Ea Aea a a ai A a ea eee ai 5 18 5 5 3 Bit logical OR ici csstecicesscelseeescecieatetet ataa E AAE a AR AA 5 19 SoA Bit exclusive logical OR Sia a e dda inva RE E E REA 5 20 55 9 BitrightShitt P Arari naaa E AA N AA N E RNA E A AN E A E Aa 5 21 5 5 6 Bit leftShifta 5 no tcc hehe thd eben lagi oh iced edhe bien adil wich ghd ieee es hes 5 22 5 5 7 Sign inversion Complement Of 2 oo eeeeeeeeeeeeeeeeeeeeeeaeeeaeeeaeeeeeeeaeeeaeeeaeeeaeeeaeeeaeeeaeeeaeeeaeeearenaeesas 5 23 5 6 Standard FUNCIONS iiet i hath ie Rd nie a RR ab en ities 5
222. ith n e S to S n 1 is outside the device range e D to D n 1 is outside the device range e n is O or a negative number e PX PY is set in S to S n 1 e PX PY is set in D to D n 1 when n specified is a word device 2 When conversion is made in program editing of the SW6RN GSVOP an error will occur if e S to S n 1 is outside the device range e D to D n 1 is outside the device range e n is O or a negative number PX PY is set in S to S n 1 constant e PX PY is set in D to D n 1 e S is a bit device and the device number is not a multiple of 16 e D is a bit device and the device number is not a multiple of 16 when n specified is a 5 OPERATION CONTROL PROGRAMS Program examples 1 Program which batch transfers a contents for 5 words from DO to all data for 5 words from 10 BMOV 10 D0 K5 10 DO 11 Batch transfer D1 12 m 13 D3 14 D4 2 Program which batch transfers a contents for 2048 words from 0 to the data area of cam No 2 resolution 2048 BMOV N2 0 K2048 Cam data of cam No 2 Oth stroke ratio First stroke ratio Second stroke ratio 2047th stroke ratio Cam stroke ratio is set within 0 to 7FFFH 3 Program which batch transfers a contents for 4 words from XO to all data for 4 words from 20 BMOV 20 X0 K4 20 21 22 23
223. ith no conversion processing performed Errors 1 An operation error will occur if e The S data is outside the range 32768 to 32767 or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which converts the data of DOL into a signed 16 bit integer value and substitutes the result to 0 0 SHORT DOL D1 DO 0 K 30000 e K 30000L H8AD0 HFFFF8AD0 5 OPERATION CONTROL PROGRAMS FIFS 5 7 2 Unsigned 16 bit integer value conversion USHORT USHORT S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting 16 bit f 32 bit floating ai sas conditional conditional integer integer integer integer type expression i int expression expression type type L type K H K H L poin R P type F type K Lond dad aoad aoad aoa dn aoa daoa dodod uda O Usable Setting data Setting data Data type of result Data which will be converted into unsigned 16 bit ae S i 16 bit integer type integer value Functions 1 The data specified with S is converted into an unsigned 16 bit integer value 2 The data range of S is 0 to 65535 3 When S is a 64 bit floating point type its fractional portion is rounded down before conversion is made 4 If S is a 16 bit integer type its value is returned unchanged with no conversion
224. itioning speed 2 Positioning address the indirect When OFF to ON of designation of the speed PX3 is detected K151 Real 1000 ms after 1 axis 1 INC 2 positioning completion Axis 1 OPLS stands by and the Axis 2 2PLS positioning of 2 axes Speed 4PLS s is executed and stands by to the positioning completion of 2 axes G156 Did you turn on PX4 IPX4 v When PX4 is on the linear interpolation control of the 1 axis and 2 axis is executed at a double speed in the action the opposition direction after the linear interpolation control of the 1 axis and 2 axis in position check And stands by to PX4 is OFF APP 20 APPENDICES 3 System setting data of the Motion CPU System setting is shown below System Setting GSV22P MT Developer ied File Edit View Option Communication Update Help S salts 2 2 JEHHARFRCAME qsv22P CPU Q173H Project C Program QH a Module setting Manual pulse generator interface module Q173PxX Slot 3 Ppt Manual pulse generator Synchronous encoder NC P2 Manual pulse generator Synchronous encoder INC _ b Basic setting 1 Multiple CPU setting Setting items Operating mode All CPU stop by stop error of CPU No 1 2 APP 21 APPENDICES 2 Automatic refresh setting 1 CPU CPU share memory G Dev starting Se Point sin end sian End es ee rene ee No2
225. k products past the limit When transporting the Motion controller or servo amplifier never hold the connected wires or cables When transporting the servomotor never hold the cables shaft or detector When transporting the Motion controller or servo amplifier never hold the front case as it may fall off When transporting installing or removing the Motion controller or servo amplifier never hold the edges Install the unit according to the instruction manual in a place where the mass can be withstood Do not get on or place heavy objects on the product Always observe the installation direction Keep the designated clearance between the Motion controller or servo amplifier and control panel inner surface or the Motion controller and servo amplifier Motion controller or servo amplifier and other devices Do not install or operate Motion controller servo amplifiers or servomotors that are damaged or that have missing parts Do not block the intake outtake ports of the servomotor with cooling fan Do not allow conductive matter such as screw or cutting chips or combustible matter such as oil enter the Motion controller servo amplifier or servomotor The Motion controller servo amplifier and servomotor are precision machines so do not drop or apply strong impacts on them A CAUTION Securely fix the Motion controller and servo amplifier to the machine according to the instruction manual If the fixin
226. l be inverted Data type of S Functions 1 The sign inverted value of the data specified with S is found Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which substitutes the sign inverted value of 0 to DO DO 0 Do 5 23 5 OPERATION CONTROL PROGRAMS FIFS 5 6 Standard Functions 5 6 1 Sine SIN SIN S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison data Bit device AB Plt Sebit floating Coasting ap Dit Sepil floating Calculation conditional conditional integer integer point timer integer integer type point expression expression expression type type L type F type K H K H L type K Lo dl dl o d o l o d o dl o lo dl o dl o dl d O Usable Setting data Setting data Data type of result Angle data on which SIN sine operation will be i S Floating point type performed Functions 1 SIN sine operation is performed on the data specified with S 2 The data specified with S is in an angle degree unit 3 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which performs the SIN operation
227. l relay M20 Latch relay L1000 Link relay B3FF Annunciator FO M9000 O usable X unusable Bit devices Speci l relay lt Restrictions on write enabled bit devices gt 1 Write to device X is allowed only within the input module non installed range 2 Special relay has predetermined applications in the system Do not perform write to other than the user setting device Note SET RST is disabled in the following device ranges SET RST disable range M2001 to M2032 Start accept device Note DOUT output disabled in the following device ranges DOUT output disable range Designation including M2000 to M2127 M9000 to M9255 1 OVERVIEW Table of the operation control transition control specification continued Word devices Data type Constant Number of instructions Read write response of input PX output PY Devices Symbol Accessibility Usable tasks Description ese le Nore Bret Fe JDataregister S OD CO lLinkregister Ww OT Co To ra F Special register b olo 2e Motion register Jolo Coastingtimer rm To x CAUTION lt Restrictions on write enabled word devices gt H X unusable 1 Special register has predetermined applications in the system Do not perform write to other than the user set device 16 bit integer type signed 32768 to 32767 K10 D100 etc 16 bit integer type unsigned 0 to 65535 32 bit integer type signed 21474
228. l system program can be used as an user device 1 37 1 OVERVIEW 4 Table of the synchronous encoder axis monitor devices SV22 only D1120 to Axis 1 monitor device D1129 D1130 to Axis 2 monitor device D1139 D1140 to Axis 3 monitor device D1149 D1150 to Axis 4 monitor device D1159 D1160 to Axis 5 monitor device D1169 D1170 to Axis 6 monitor device D1179 D1180 to Axis 7 monitor device D1189 D1190 to Axis 8 monitor device D1199 D1200 to Axis 9 monitor device D1209 D1210 to Axis 10 monitor device D1219 D1220 to Axis 11 monitor device D1229 D1230 to Axis 12 monitor device D1239 1 38 1 OVERVIEW e Detailes of each axis D1120 10n Current value D1121 10n D1122 10n D1123 10n D1124 10n prsim sable p1125 10n si 125 10n D1126 10n Current value after synchronous encoder axis D1127 10n main shaft s differential gear D1128 10n Error search output axis No D1129 10n Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 12 n 0 to 11 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 Device area of 9 axes or more is unusable in the Q172HCPU 1 39 1 OVERVIEW 5 Table of the cam axis monitor devices SV22 only D1240 D1400 to Axis 1 monitor device to Axis 17 monitor device D1249 D1409 D1250 D1410 to Axis 2 monitor device to Axis 18 monitor device D1259 D1419 D1260 D
229. ll is executed from No 110 stops too actual output PY is turned off Note 1 The program that a subroutine was started is made to stop if necessary when a subroutine start program is added because it does not stop Note 2 Real output is turned off if necessary Note 3 The occurrence detection of servo error and so on is added to the stop status with forced stop if necessary When a forced stop is released it is the structure which starts the program which does motion control from the initials again by sample program Therefore it is the system example that motion control is resumed when a forced stop release is executed after it stops forced for while c No 110 Motion control F110 SET M2042 All axes servo ON command ON G105 M2415 M2435 Is 1 axis and 2 axis servo on off status ON Motion control G110 IPX2 IPX1 6111 IPX2 PX1 G112 PX2 IPX1 G113 PX2 PX1 JOG Manual pulse generator Home position return Programming operation G115 Nait a subroutine NOP call completion o The subroutine call of the following program is executed corresponding to the status of PX1 PX2 Selective branch is made the program so that each subroutine may never start it in the plural at the same time And each subroutine makes the next step WAIT to become
230. ll be a charge for breakdown repairs exchange replacements and on site visits for the following four conditions otherwise there will be a charge 1 Breakdowns due to improper storage handling careless accident software or hardware design by the customer 2 Breakdowns due to modifications of the product without the consent of the manufacturer 3 Breakdowns resulting from using the product outside the specified specifications of the product 4 Breakdowns that are outside the terms of warranty Since the above services are limited to Japan diagnosis of failures etc are not performed abroad If you desire the after service abroad please register with Mitsubishi For details consult us in advance 2 Exclusion of Loss in Opportunity and Secondary Loss from Warranty Liability Mitsubishi will not be held liable for damage caused by factors found not to be the cause of Mitsubishi opportunity loss or lost profits caused by faults in the Mitsubishi products damage secondary damage accident compensation caused by special factors unpredictable by Mitsubishi damages to products other than Mitsubishi products and to other duties 3 Onerous Repair Term after Discontinuation of Production Mitsubishi shall accept onerous product repairs for seven years after production of the product is discontinued 4 Delivery Term In regard to the standard product Mitsubishi shall deliver the standard product without application settings or adjustments to the cus
231. ll be performed Functions 1 TAN A arctangent operation is performed on the TAN value data specified with S to find an angle 2 The operation result is in an angle degree unit 3 If S is an integer type it is converted into a floating point type before operation is performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which performs the TAN a arctangent operation of DOF and substitutes the result to 0F 0F ATAN DOF 3 oa D1 DO 5 OPERATION CONTROL PROGRAMS FIFS 5 6 7 Square root SQRT SORTS Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting ae bit f 32 bit floating ACHA as conditional conditional integer integer i integer integer type expression int expression expression type type L type K H KH L Pon e i type F type K Lond dad aoad aoa d aoa ee ee O Usable Setting data Setting data Data type of result Data on which square root operation will be l S Floating point type performed Functions 1 The square root of the data specified with S is found 2 Only a positive number may be specified with S Operation cannot be performed with a negative number 3 If S is an integer type
232. llel coupling point In the example of the diagram in Section 4 9 3 2 the number of parallel branches is 3 and that of couplings is 2 When a WAIT transition is set right after a parallel coupling the stop completions of the axes are not included in the waiting conditions if the parallel coupling is preceded by motion control steps To perform a parallel coupling on stop completions set WAIT transitions before a parallel coupling x l K3 L 1 lt Parallel coupling f Gt je If this is WAIT stop completions of axes started at K2 to K5 are not included in transition conditions O K2 K3 K4 K5 When you want to perform a coupling lt on stop completions of axes started in G2 G3 G4 G5 K2 to K5 set WAIT transition in each ee mS route to make parallel coupling lt Parallel coupling L G1 4 MOTION SFC PROGRAMS 4 10 Y N Transitions When routes are branch at a transition condition enables and disable Shift Y N transition or WAIT Y N transition will be useful Not e When a transition condition set at Gn leti Shift Y N ae oceticn enables execution shifts to the lower transition Gn NI step When that condition disables Completion Y execution shifts to the right connected of condition step Not Differences between Shift Y N and completion WAIT Y N of condition WAIT
233. loating Coasting et Ml Seat floating Calculation snditional conditional integer integer integer integer type A expression point expression expression type type L type K H K H L type K BISERE ee seal l olol lololo l dl ol l O Usable Setting data Data type integer type of S1 or S2 which is greater Integer type Functions 1 The data specified with S1 is divided by the data specified with S2 to find a remainder 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed Errors 1 An operation error will occur if e S2 is 0 or e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which divides K456 by 0 and substitutes a remainder to WO WO K456 0 456 wor oa 5 OPERATION CONTROL PROGRAMS FIFS 5 5 Bit Operations 5 5 1 Bit inversion Complement 9 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison data bi bi bi bi Calculati P i Bit device ap bit 3 bit floating Coasting hg bit Sabit floating mutes a conditional conditional integer integer i integer integer type expression i na timer point expression expression type type L type K H K H L type K type F Se Seo ee ee oe O Usable Setting data Setting data
234. lue change Character 1 Q173HCPU J1 to J32 Q172HCPU J1 to J8 sequence 16 bit S2 Setting of the torque limit value change to change Note 1 16 bit binary Complete devices D1 0 Device which make turn on for one scan at accept completion of instruction D1 1 Device which make turn on for one scan at accept abnormal completion of instruction D1 0 also turns on at the abnormal completion 16 bit D2 Device to store the complete status binary Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration Note 2 n shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 1 to 32 Q172HCPU Axis No 1 to No 8 n 1 to 8 3 MOTION DEDICATED PLC INSTRUCTION Controls 1 This instruction is dedicated instruction toward the Motion CPU in the Multiple CPU system Errors occurs when it was executed toward the CPU except the Motion CPU 2 The torque limit value of the axis specified with S1 is changed to the value of S2 regardless of the state of during operating or stopping at the real mode 3 S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P CHGT instruction When the Motion dedicated PLC instruction is started continuously It is necessary to take an interlock by the to self CPU high speed interrupt accept flag from CPUn Operation PLC program END
235. lute value of the specified speed and stops waits there Constant speed control Speed control I On completion of deceleration the axis reverses its moving direction at the absolute value of the specified speed The axis does not stop until a stop instruction is input Speed position control VPSTART Position follow up control PFSTART Th akis cannot return The speed change request is regarded as a Speed control with fixed normal speed change request position stop Minor error 305 N will occur and the axis Speed switching control VSTART will be controlled at the speed limit value JOG operation TEN A speed change cannot be made Minor High d llati OSC Dire EEA error 310 will occur A speed change cannot be made Minor error 301 will occur Note Minor error 301 A speed change was made during home position return Minor error 305 The setting speed is outside the range of 0 to speed limit value Minor error 310 A speed change was made during high speed oscillation Controls a Ifa speed change is made to a negative speed control is executed with the control mode during the start as indicated in the above table b The returning command speed is the absolute value of a new speed c When the axis is waiting at the return position 1 Signal states n Axis No m Axis No 1 e Start accept M2000 n ON unchanged from before execution of CHGV instructi
236. ly and securely wire the wires Reconfirm the connections for mistakes and the terminal screws for tightness after wiring Failing to do so may lead to run away of the servomotor After wiring install the protective covers such as the terminal covers to the original positions Do not install a phase advancing capacitor surge absorber or radio noise filter option FR BIF on the output side of the servo amplifier Correctly connect the output side terminals U V W Incorrect connections will lead the servomotor to operate abnormally Do not connect a commercial power supply to the servomotor as this may lead to trouble Do not mistake the direction of the surge absorbing diode installed on the DC relay for the control signal output of brake Servo amplifier signals etc Incorrect installation may lead to signals not being output when trouble occurs or the protective functions not functioning Control output Do not connect or disconnect the connection cables between signal each unit the encoder cable or PLC expansion cable while the power is ON Securely tighten the cable connector fixing screws and fixing mechanisms Insufficient fixing may lead to the cables combing off during operation Do not bundle the power line or cables 24VDC 5 Trial operation and adjustment A CAUTION Confirm and adjust the program and each parameter before operation Unpredictable movements may occur depending on the machin
237. m in the response time from when the CHGT instruction is executed until the torque limit value is changed actually 5 OPERATION CONTROL PROGRAMS FIFS 5 13 Other Instructions 5 13 1 Event task enable El Number of basic steps Usable data Usable Data Setting 64 bit f 64 bit Bit Comparison data Bit device A6 pit geni floating Coasting TOt sett floating Calculation conditional conditional integer integer integer integer type j expression ca expression expression type type L type K H O Usable Setting data There are no setting data Functions 1 The execution of an event task is enabled 2 This instruction is usable with a normal task only Errors 1 An operation error will occur if This instruction is used with other than a normal task Program examples 1 Enables the execution of an event task 5 OPERATION CONTROL PROGRAMS FIFS 5 13 2 Event task disable Dl Format Number of basi stops Usable data Usable Data Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit l 16 bit 32 bit i Calculation P data Bit device floating Coasting floating conditional conditional integer integer 5 integer integer type expression int expression expression type type L type K H wH L Pom e i type F type K Pp J O Usable Setting data There are no setting data Fun
238. m of 1B 0300145 EIA language G code 1XB915 This manual explains the servo parameters positioning instructions device list error list and others Optional 2 PLC Model Code QCPU User s Manual Hardware Design Maintenance and Inspection This manual explains the specifications of the QCPU modules power supply modules base modules SH 080483ENG extension cables memory card battery and others 13JR73 Optional QCPU User s Manual Function Explanation Program Fundamentals This manual explains the functions programming methods and devices and others to create programs SH 080484ENG with the QCPU 13JR74 Optional QCPU User s Manual Multiple CPU System This manual explains the functions programming methods and cautions and others to construct the SH 080485ENG Multiple CPU system with the QCPU 13JR75 Optional QCPU Q Mode QnACPU Programming Manual Common Instructions This manual explains how to use the sequence instructions basic instructions application instructions and SH 080039 micro computer program 13JF58 Optional QCPU Q Mode QnACPU Programming Manual PID Control Instructions This manual explains the dedicated instructions used to exercise PID control EOT Optional QCPU Q Mode QnACPU Programming Manual SFC This manual explains the system configuration performance specifications functions programming SH 080041 debugging error codes and others of MELSAP3 13JF60 Optional I
239. m within the Motion SFC program e When started by the S P SFCS instruction At occurrence of a valid event after execution of the S P SFCS instruction the program is run from the initial first step in accordance with the number of consecutive Start control transitions of the corresponding program e When subroutine started At occurrence of a valid event after execution of GSUB the program is executed from the first step in accordance with the number of consecutive transitions of the corresponding program e When subroutine called The program is executed immediately from the first step After that the program is executed continuously by the number of consecutive transitions of the corresponding program at occurrence of a valid event END control END As specified for END operation Errors None In the case of the program which is executed by the normal task write the program so that it is not ended by but it returns to the starting step by a jump when starting of the automatically from an initial again 9 MOTION SFC PARAMETER Error code Note 2 Execute task Description Set the timing task to execute a program Specify whether the program will be run by only one of the normal task main cycle event task fixed cycle external interrupt PLC interrupt and NMI task external interrupt When the event task is set multiple events among the fixed cycle external interrupt
240. mand speed WAIT ON OFF deceleration time Fixed position stop Number of steps Rapid stop deceleration time Deceleration processing Allowable error range for circular FIN acceleration deceleration Fixed position stop acceleration BOONE fe eal aM E E E EE e ae e SIP aia ap E TIL MES EE te e e a a a e e ih ee C E a A E E a al ee O Must be set A Set if required 1 Only reference axis speed specification 2 B indicates a bit device 7 MOTION CONTROL PROGRAMS Table 7 2 Servo Instruction List continued Positioning data no j 2 Dwell time Auxiliary point Central point Instruction symbol Processing Parameter block No Address travel value Command spee Torque limit value Positioning control Virtual enable el el Romi Rea Rera esl Eon en ea Re Number of steps EEE EEE Repeat range start setting NExT _ Repeatrange eraso f ff f START Simultaneous start ZERO Home position return start Repetition of same control used in speed switching control constant speed control Simultaneous position High speed oscillation High speed oscillation CHGA Servomotor Virtual Servomotor Shaft Current Value Change pean pave fofo ff Coe ees as fofof tt Current Value 7 MOTION CONTROL PROGRAMS Positioning data Starting angle Amplitude Frequency Reference axis No Control unit Speed limit valu
241. mber of steps Rapid stop deceleration time Deceleration processing FIN acceleration deceleration Sa Be es ced a en Ee ese a I em ed Ko ead om Row en en Reais 2 a a 6 aeaa a Cc 2 5 2 D a 2 wn c 2 Yn e a a D bad ic Allowable error range for circular Must be set A Set if required 1 Only reference axis speed specification 2 B indicates a bit device 7 MOTION CONTROL PROGRAMS Table 7 2 Servo Instruction List continued Positioning data no j 2 Dwell time Auxiliary point Central point Instruction symbol Command spee Processing Torque limit value Parameter block No Address travel value Positioning control Virtual enable Or os s6 20 6 0 6 a Gi Number of steps meet PEED EE ET INC 1 nce INC 3 INC 4 INC 27 Constant speed control passing point incremental specification INCC gt INC lt a Constant speed control INC Constant speed control passing point helical incremental specification Toto fa reno oman 1 tal Ltt 7 MOTION CONTROL PROGRAMS Positioning data Paranet ok os Starting angle Amplitude Frequency Reference axis No Control unit Speed limit value Acceleration time Deceleration time Torque limit value at stop input interpolation S curve ratio Repeat condition Program No Com
242. mes AC power supply 65 DC power supply or less of the rating while the counter No for AC DC DOWN CPU module is performing an operation and the value is stored in BIN code g Ko So O a When error is found as a result of self diagnosis error No is stored in BIN code e Refer to 2 4 Multiple CPU Error Codes of the Q173HCPU Q172HCPU Motion controller Programming Manual COMMON for details of the error code The age A D the rightmost two digits when data on D9008 are updated and the month stored with a BCD code two digits B15 to B8B7 to Bo Example October 1995 Year 0 to 99 Month 1 to 12 H9510 Dignostic error D9008 Diagnostic error number The day when data on D9008 are updated and the hour stored with a BCD Diagnostic error Diagnostic error code two digits occurrence time occurrence time B15 to B8B7 to BO Example 25st 10 a m Day 1 to 31 Hour 0 to 23 H2510 S Occur an error The minute when data on D9008 are updated and the second stored with a BCD code two digits B15 to B8B7_ to Bo Example 35 min 48 sec Minute 0 to 59 Second 0 to 59 H3548 The classification code to judge the error information stored in the error information D9014 is stored Error information Error information The following codes are stored classfication classfication code 0 None 1 Module No CPU No Base No 2 Parameter No Error information to comply with t
243. mplement OL 2L 8 45 D800L D802L 9 15 iw Q jo ia is io N g X 13 60 9 05 10 85 11 80 13 60 O w fer fer 2 2 S u nT o e 2 o fer O N g So T g Oo N Cc g O BK aa g f iH g O K m g fee oo T g O g o a Bit operation S g E g Q N APP 1 APPENDICES Processing time of operation instructions Continued Q173HCPU Q172HCPU Classifications Symbol Instruction Operation expression Unit us u 9 70 10 20 Bit right shift 7 15 Sign inversion complement of 2 Sine Coan 0F COS TE 23 05 i D800F COS D804F 25 50 0F TAN 4F 27 70 Tangent D800F TAN D804F 30 65 0F ASIN 4F 31 30 ASIN Arcsin ac el D804F 34 60 0F ACOS OF ACOS 4F 33 10 ACOS Arccosin D800F ACOS D804F 35 15 OF ATAN 4F 28 40 ATAN Arctangent D800F ATAN han ane 31 10 HOF SQRTWH4F SQRT Square root D800F SQRT D804F 10 65 i 0F LN 4F 14 35 Natural logarithm D800F al 23 95 0F OFSEXPWMF 17 80 Exponential operation D800F EXP Remon 27 05 HOF ABSGF Absolute value D800F ABS D804F 10 85 0F RND 4F 11 60 Round off Bit logical AND Bit logical OR D800F RND D804F 13 00 APP 2 APPENDICES Processing time of operation instructions Continued ee j Q173HCPU Q172HCPU Classifications Symbol Instruction Operation expression
244. ms 256 No 0 to 255 Motion SFC chart size program Up to 64k bytes Included Motion SFC chart comments Number of Motion SFC steps program Up to 4094 steps Number of selective branches branch 255 Number of parallel branches branch 255 Parallel branch nesting Up to 4 levels 4096 with F Once execution type and FS Scan execution type combined F FSO to F FS4095 Number of transition programs 4096 GO to G4095 Operation control program Code size program Up to approx 64k bytes 32766 steps F FS Number of blocks line program Up to 8192 blocks in the case of 4 steps min blocks Number of operation control programs r Number of characters block line Up to 128 comment included Transition program Number of operand block Up to 64 operand constants word device bit devices G nesting block Up to 32 levels _ Operation control program Calculation expression bit conditional expression Descriptive i re Calculation expression bit conditional expression expression Transition program F comparison conditional expression Number of multi execute programs Up to 256 Number of multi active steps Up to 256 steps all programs Normal task Execute in motion main cycle Event isle Fixed evels Execute in fixed cycle ix POR i ais 7 0 88ms 1 77ms 3 55ms 7 11ms 14 2ms Execute specification Execution F Executed nbs External Execute when input ON is set among interrupt module QI60 task interrupt 16 points masked
245. n Note 1 SV13 SV22 is the completely same version Note 2 When combinig with the programming software be sure to use the setup software MRZJW3 SETUP221E Version B1 or later 1 11 1 OVERVIEW 1 2 6 Positioning dedicated devices special relays special registers 1 Positioning dedicated devices The following section describes the positioning dedicated devices A range of up to 32 axes is valid in Q173HCPU and a range of up to 8 axes is valid in Q172HCPU Refer to the Q173HCPU Q172HCPU Motion controller SV13 SV22 Programming Manual REAL MODE Q173HCPU Q172HCPU Motion controller SV22 Programming Manual VIRTUAL MODE for details of the positioning dedicated devices a Table of the internal relays e Overall configuration SV13 SV22 MO User device MO User device to 2000 points to 2000 points M2000 Common device M2000 Common device to 320 points to 320 points M2320 Special relay allocated device Status M2320 Special relay allocated device Status to 80 points to 80 points M2400 M2400 Axis status Axis status 20 points x 32 axes to 20 points x 32 axes to Real mode Each axis Virtual mode Output module M3040 Unusable M3040 Unusable to 32 points to 32 points M3072 Common device Command signal M3072 Common device Command signal o 64 points to 64 points t t M3136 Special relay allocated device Special relay allocated device Command signal Command signal 64 poin
246. n S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P DDWR instruction It can be confirmed by data in the shared CPU memory of the target CPU Motion CPU whether the instruction is acceptable or not When the Motion dedicated PLC instruction is started continuously it is must be design to execute next instruction after executing instruction complete device on The target CPU device range check is not executed with self CPU at the S P DDRD instruction execution but it checks by the target CPU side and it becomes abnormal completion at the device range over S P DDRD instruction accepting and normal abnormal completion can be confirmed with the complete device D1 or status display device D2 at the completion a Complete device It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing b Status display device at the completion It is turned on off according to the status of the instruction completion e Normal completion OFF e Abnormal completion It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing SM390 turns on when the target CPU specified with n1 complete to accept SM390 turns off when the target CPU specified with n1 cannot be write correctly by the reset status or error factor 5000 to 5999 3 MOTIO
247. n SFC program is executed when the input set to the NMI task factor among external interrupts 16 points of QI60 turns on Program name PLC program EE External interrupts if Se ie NMI task END operation End lt 1 gt lt 2 gt lt 3 gt END operation Continue 1 2 3 1 2 l Jl l J Do not execute a Execute the number of When END operation is set as program before the consecutive transition for continuation continuation NMI task starting every NMI task occurrence operation is executed Note When making it When stopping it is make to always execute execute CLR by other programs set as automatic start Points a NMI task has the highest priority among the normal event and NMI tasks b If the event task is disabled DI by the normal task the interruption of the NMI task is executed without being masked Errors The motion control step is executed during NMI task If the motion control step is executed during NMI task the Motion SFC program error 16113 occurs and stops the Motion SFC program 9 MOTION SFC PARAMETER 9 3 Execution Status of The Multiple Task Execution status of each Motion SFC program when the Motion SFC program is executed multiple tasks is shown below 3 55ms NMI interrupt NMI interrupt S l l 1 F l NMI task execute program i ff i I 3 55ms event task execute program mEn _ When there are programs which are executed by the
248. n control program Fn FSn control step i Specified range FO to F4095 FS0 to FS4095 1 Once execution type operation control step Fn In the case of Fn executes the specified operation control program Fn n 0 to 4095 once Scan execution type operation control step FSn In the case of FSn repeats the specified operation control program FSn n 0 to 4095 until the next transition condition enables When the specified operation control program Fn FSn does not exist the Motion SFC program error 16201 will occur and stops to execute the Motion SFC program at the error detection Refer to Chapter 5 OPERATION CONTROL PROGRAMS for operation expressions that may be described in operation control programs If an operation or similar error occurs the operation control program running the Motion SFC program continues executing 4 MOTION SFC PROGRAMS 4 5 3 Subroutine call start step Operations Errors Subroutine Calls starts the Motion SFC program of the specified a name call start step i program name 1 Calls starts the Motion SFC program of the specified program name 2 Control varies with the type of the transition coupled next to the subroutine 2 call start step a WAIT Subroutine Call When the subroutine call step is executed control transits to the specified program as shown below and when END of the called program is executed control returns to the call source p
249. n expressions Q173HCPU Q172HCPU Classifications Symbol Instruction ermoa expression Unit t s ON Normally open contact ANE enables When condition enables Logical AND MO M1 Logical OR X100 X101 PX0 PX1 14 25 HO H1 D800 D801 Oo 6o i O OL 2L 6 90 D800F D804F HOI D800 D801 OLI 2L Not equal to D800L D802L HOFI AF D800F D804F D800 lt D801 OL lt 2L Less than D800L lt D802L HOF lt HAF D800F lt D804F 8 10 0 lt 1 D800 lt D801 Less than or equal to D800L lt D802L 0F lt 4F D800 lt D804F 0 gt 1 D800 gt D801 OL gt 2L More than D800L gt D802L HOF gt HAE D800F gt D804F 0 gt 1 5 10 D800 gt D801 OL gt 2L 7 55 More than or equal to D800L gt D802L 0F gt 4F D800F gt D804F APP 7 APPENDICES 3 Processing time by the combination F and G program described in F G is NOP F alone G alone F G GSUB CLR JMP coupling L i f i fi is ee F GON eso TA l l Note Note me SUB SUB P LP F END Retr Q173HCPU Q172HCPU us 28 85 26 10 31 45 81 65 36 15 16 70 Parallel branch 2 Pcs Parallel branch 5 Pcs IL a se E A Ee ea a 9 At coupling Q173HCPU Q172HCPU us 91 40 Selective branch 2 Pcs Selective branch 5 Pcs I I I
250. nal Axis 7 command signal Axis 8 command signal Axis 9 command signal Axis 10 command signal Axis 11 command signal Axis 12 command signal Axis 13 command signal Axis 14 command signal Axis 15 command signal Axis 16 command signal 1 20 Device No M5120 to M5139 M5140 to M5159 M5160 to M5179 M5180 to M5199 M5200 to M5219 M5220 to M5239 M5240 to M5259 M5260 to M5279 M5280 to M5299 M5300 to M5319 M5320 to M5339 M5340 to M5359 M5360 to M5379 M5380 to M5399 M5400 to M5419 M5420 to M5439 Signal name Axis 17 command signal Axis 18 command signal Axis 19 command signal Axis 20 command signal Axis 21 command signal Axis 22 command signal Axis 23 command signal Axis 24 command signal Axis 25 command signal Axis 26 command signal Axis 27 command signal Axis 28 command signal Axis 29 command signal Axis 30 command signal Axis 31 command signal Axis 32 command signal 1 OVERVIEW Detailes of each axis Error reset command Unusable M4816 20n Note 1 n in the above device No shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 0 to 31 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 The unused axis areas in the mechanical system program can be used as an user device 1 21 1 OVERVIEW 5 Table of the synchronous encoder axis statuses SV22 only Signal name ey wie Er
251. nect the Q173HCPU Q172HCPU to the peripheral devices Select New project create the project Read from Motion CPU Menu by the SW6RN GSVEP and also read the project from the Motion CPU Select the Monitor Error list Motion SFC error history and Error list Menu Display the error code and error message ananasa U N reve aH anan of Refer to the applicable the help of the SW6RN GSVOP for details of the SW6RN GSVOP operating method The occurrence date of the Motion CPU error history uses a watch function with the internal Motion CPU Make the set of the clock data and the clock data read request M9028 by user programs As for the self diagnosis error code confirmation can be done by the PC diagnosis of GX Developer Refer to the GX Developer operation manual for the GX Developer operation procedure 11 1 11 ERROR CODE LISTS 11 2 Motion SFC Error Code List Eight errors that occurred in the past during the Motion SFC control are stored in the error history devices 8000 to 8063 of the motion registers Check by SW6RN GSVOP The error codes for the Motion SFC program are shown below Refer to the Q173HCPU Q172HCPU Motion controller SV13 SV22 Programming Manual REAL MODE Q173HCPU Q172HCPU Motion controller SV22 Programming Manual VIRTUAL MODE for minor errors major errors servo errors and servo program setting errors Table 11 1 Motion SFC dedicated devices 8000 to 8063
252. nical structure when the ball screw and servomotor are connected with a timing belt etc Install a stopping device to ensure safety on the machine side 2 Parameter settings and programming A CAUTION Set the parameter values to those that are compatible with the Motion controller servo amplifier servomotor and regenerative resistor model and the system application The protective functions may not function if the settings are incorrect The regenerative resistor model and capacity parameters must be set to values that conform to the operation mode servo amplifier and servo power supply module The protective functions may not function if the settings are incorrect Set the mechanical brake output and dynamic brake output validity parameters to values that are compatible with the system application The protective functions may not function if the settings are incorrect Set the stroke limit input validity parameter to a value that is compatible with the system application The protective functions may not function if the setting is incorrect Set the servomotor encoder type increment absolute position type etc parameter to a value that is compatible with the system application The protective functions may not function if the setting is incorrect Set the servomotor capacity and type standard low inertia flat etc parameter to values that are compatible with the system application The protective functions may
253. not function if the settings are incorrect Set the servo amplifier capacity and type parameters to values that are compatible with the system application The protective functions may not function if the settings are incorrect Use the program commands for the program with the conditions specified in the instruction manual A CAUTION Set the sequence function program capacity setting device capacity latch validity range I O assignment setting and validity of continuous operation during error detection to values that are compatible with the system application The protective functions may not function if the settings are incorrect Some devices used in the program have fixed applications so use these with the conditions specified in the instruction manual The input devices and data registers assigned to the link will hold the data previous to when communication is terminated by an error etc Thus an error correspondence interlock program specified in the instruction manual must be used Use the interlock program specified in the special function module s instruction manual for the program corresponding to the special function module 3 Transportation and installation A CAUTION Transport the product with the correct method according to the mass Use the servomotor suspension bolts only for the transportation of the servomotor Do not transport the servomotor with machine installed on it Do not stac
254. not less than the data specified with S is found 2 If the S value is positive the absolute value will be greater and if it is negative the absolute value will be smaller 3 If S is an integer type its value is returned unchanged with no conversion processing performed Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which finds the rounded up fractional portion value of DOF and substitutes the result to 0F 0F FUP DOF 3 a D1 DO i asa 2 Program which finds the rounded up fractional portion value of D4F and substitutes the result to 0F when D4F is a negative number 0F FUP D4F 3 2 D5 D4 aaa aE Cee eS ae 5 OPERATION CONTROL PROGRAMS FIFS 5 6 14 BCD BIN conversion BIN BIN S Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device a8 bit 32 bit floating Coasting 16 bit eo floating aoa ak conditional conditional integer integer integer integer type expression i int expression expression type type L type K H K H L poln P P type F type K Lond dad aoad ee aoad aoa dadd add O Usable Setting data Setting data Data type of result Data type of S S BCD data which will be converted into BIN data Integer type Functions 1 The BCD
255. nt timer point expression expression type type L type F type K H K H L type K Bf I aI a a aa o en a ae ee eee ee ee ee o ee O Usable Note 1 PX is write disabled and cannot be used at D Note 2 M2001 to M2032 cannot be used at D Setting data Setting data Data type of result Bit data for device reset Bit logical type Condition data which determines whether device S true false reset will be performed or not 1 If the data specified with S is true the bit data specified with D is reset Functions 2 S can be omitted At this time the format is RST D and device reset is made unconditionally 3 When this instruction is set as a transition condition in the last block of a transient program whether the data specified with S is true or false is returned as logical type data In this case S cannot be omitted Errors 1 An operation error will occur if e D or S is an indirectly specified device and its device No is outside the range 5 OPERATION CONTROL PROGRAMS Program examples 1 Program which resets M100 when either of MO and XO is 1 RST M100 MO XO vo 0 M100 0 lt True x 7 2 Program which resets M100 when 0 is equal to DO RST M100 0 DO wo 00 mioo 0 lt I True Do 250 3 Program which resets YO unconditionally RST YO vo O7 5 OPERATION CONTROL PROGRAMS FIFS
256. o M3399 M3400 to M3419 M3420 to M3439 M3440 to M3459 M3460 to M3479 M3480 to M3499 M3500 to M3519 Signal name Axis 1 command signal Axis 2 command signal Axis 3 command signal Axis 4 command signal Axis 5 command signal Axis 6 command signal Axis 7 command signal Axis 8 command signal Axis 9 command signal Axis 10 command signal Axis 11 command signal Axis 12 command signal Axis 13 command signal Axis 14 command signal Axis 15 command signal Axis 16 command signal 1 16 Device No M3520 to M3539 M3540 to M3559 M3560 to M3579 M3580 to M3599 M3600 to M3619 M3620 to M3639 M3640 to M3659 M3660 to M3679 M3680 to M3699 M3700 to M3719 M3720 to M3739 M3740 to M3759 M3760 to M3779 M3780 to M3799 M3800 to M3819 M3820 to M3839 Signal name Axis 17 command signal Axis 18 command signal Axis 19 command signal Axis 20 command signal Axis 21 command signal Axis 22 command signal Axis 23 command signal Axis 24 command signal Axis 25 command signal Axis 26 command signal Axis 27 command signal Axis 28 command signal Axis 29 command signal Axis 30 command signal Axis 31 command signal Axis 32 command signal 1 OVERVIEW Detailes of each axis M3200 20n Stop command Stop command M3201 20n Rapid stop command Rapid stop command Forward rotation JOG start M3202 20n Forward rotation JOG start command command Reverse rotation JOG start M3203 20n
257. o llon 1 axis and 2 axes Restart continuation G21 M9076 Did you turn on a forced Istop isa continuation F25 DOUT PY10 H0000 PY10 to PY1F I 16 points OFF 0 is set on the continuation point 100 as an initial value The subroutine starts No 160 Restart continuation after all axis servo are turned on and servo on of 1 axis and 2 axes is confirmed when a forced stop is released Because the next step is a shift it becomes a subroutine start and the next step is executed at the same time with subroutine practice too No 160 Restart continuation is made to stop by the forced stop and real output PY is turned off Note 1 The program that a subroutine was Started is made to stop if necessary when a subroutine start program is added because it does not stop Note 2 Actual output is turned off if necessary Note 3 The occurrence detection of servo error and so on is added to the stop condition with forced stop if necessary APP 26 When a forced stop is released it is the structure which starts the program which does motion control from the initials again by sample program Therefore it is the system example that motion control is resumed when a forced stop release is executed after it stops forced for while APPENDICES b No 160 Restart continuation Restart continuation
258. o D2000 and resets M100 when D is not equal to D2000 OUT M100 DO D2000 5 53 5 OPERATION CONTROL PROGRAMS FIFS 5 10 Logical Operations 5 10 1 Logical acknowledgement None S Number of basic steps __ Usable data Usable Data Setting 64 bit 64 bit Bit Comparison data Bit device AB Plt Sebit floating Coasting ae Dit seni floating Calculation conditional conditional integer integer oint finer integer integer type point expression expression expression type type L ve a type KH KHL peo Lod o dl gt O Usable Setting data Setting data Data type of result Data which will be logically acknowledged Logical type true false Functions 1 Whether the logical type data specified with S is true or false is returned unchanged Logical acknowledgement Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which sets M100 when either of MO and XO is ON 1 MO False m E M00 gt xo T True 5 OPERATION CONTROL PROGRAMS FIFS 5 10 2 Logical negation Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit i 16 bit 32 bit Calculation i data Bit device f floating Coasting f floating i conditional conditional integer integer i integer integer type expression int expression expre
259. o turn it off when positioning completion is not turned on after the motion control is executed WARRANTY Please confirm the following product warranty details before using this product 1 Gratis Warranty Term and Gratis Warranty Range If any faults or defects hereinafter Failure found to be the responsibility of Mitsubishi occurs during use of the product within the gratis warranty term the product shall be repaired at no cost via the sales representative or Mitsubishi Service Company However if repairs are required onsite at domestic or overseas location expenses to send an engineer will be solely at the customer s discretion Mitsubishi shall not be held responsible for any re commissioning maintenance or testing on site that involves replacement of the failed module Gratis Warranty Term Note that an installation period of less than one year after installation in your company or your customer s premises or a period of less than 18 months counted from the date of production after shipment from our company whichever is shorter is selected Gratis Warranty Range 1 Diagnosis of failure As a general rule diagnosis of failure is done on site by the customer However Mitsubishi or Mitsubishi service network can perform this service for an agreed upon fee upon the customer s request There will be no charges if the cause of the breakdown is found to be the fault of Mitsubishi 2 Breakdown repairs There wi
260. oating conditional conditional integer integer 5 j integer integer type 5 expression point expression expression type type L type K H K H L type K eee ae e aa eee noe SS ee ee oo es ee l O Usable Setting data Setting data Data type of result S1 Minuend data Data type of S1 or S2 S2 Subtracted data which is greater Functions 1 The data specified with S2 is subtracted from the data specified with S1 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which substitutes the result of subtracting 0 from K123 to WO WO K123 0 123 wo 3335 a 0 456 2 Program which substitutes the result of subtracting 10 from 0F to DOL DOL 0F 10 3 2 1 0 a bi 12345 789 DOL tee 12222 789 10 The 64 bit floating point type data are used for subtraction and the result is converted into the 32 bit integer type and then substituted 5 13 5 OPERATION CONTROL PROGRAMS FIFS 5 4 4 Multiplication S1 S2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit s Bit Comparison data Bit device 16 bit Sebit floating Coasting 16bits n 32bit float
261. ocks 2 For fire prevention A CAUTION Install the Motion controller servo amplifier servomotor and regenerative resistor on inflammable material Direct installation on flammable material or near flammable material may lead to fire If a fault occurs in the Motion controller or servo amplifier shut the power OFF at the servo amplifiers power source If a large current continues to flow fire may occur When using a regenerative resistor shut the power OFF with an error signal The regenerative resistor may abnormally overheat due to a fault in the regenerative transistor etc and may lead to fire Always take heat measures such as flame proofing for the inside of the control panel where the servo amplifier or regenerative resistor is installed and for the wires used Failing to do so may lead to fire 3 For injury prevention A CAUTION Do not apply a voltage other than that specified in the instruction manual on any terminal Doing so may lead to destruction or damage Do not mistake the terminal connections as this may lead to destruction or damage Do not mistake the polarity as this may lead to destruction or damage Do not touch the servo amplifier s heat radiating fins regenerative resistor and servomotor etc while the power is ON and for a short time after the power is turned OFF In this timing these parts become very hot and may lead to burns Always turn the power OFF before t
262. ode file File after conversion g0000 cod to g4095 cod of transition program GO to FIFS list file f0000 bin to f4095 bin G4095 list file gn bin OSn 4095 into internal codes List file of operation control programs F FSO to F FS4095 list file F FS code file f0000 cod to f4095 cod lt File after conversion of operation control program F FSO to F FS4095 list file fn bin O ns 4095 into internal codes Motion SFC program conversion file control code sfcprog cod File where SFC code G code and F FS code files are combined and converted into CPU s Motion SFC program code memory storage format Motion SFC program conversion file text sfcprog bin File where G list and F FS list files are combined and converted into CPU s Motion SFC program text memory storage format Motion SFC parameter file sfcprm bin K code file svprog bin Automatic numbering autono inf setting information file PC type file gsvp cnf System setting data file svsystemH bin High speed read setting file Optinal data monitor setting file svlatch bin svsysmon bin Servo data file svdataH bin svparaH bin svls bin Mechanical system program editing file Note 1 32 axes only svedtda2 bin Note 1 svedtda3 bin Note svedtdad bin Note 1 svedtdat bin Mechanical system program conversion file svmchprm bin Cam da
263. odel Q61P MR J3 OB RJ006 Additional function Control loop changing command Control loop monitor status Bit device setting by Motion SFC instruction Additional correction partial correction About Manuals Restriction by the version Device lists User file list etc Japanese Manual Number IB NA 0300092 This manual confers no industrial property rights or any rights of any other kind nor does it confer any patent licenses Mitsubishi Electric Corporation cannot be held responsible for any problems involving industrial property rights which may occur as a result of using the contents noted in this manual 2005 MITSUBISHI ELECTRIC CORPORATION A 11 INTRODUCTION Thank you for choosing the Q173HCPU Q172HCPU Motion Controller Please read this manual carefully so that equipment is used to its optimum CONTENTS Safety PreCAauUtiOns ara a a Ta a E E E E T N a a a a A 1 Revisions crien T T E A 11 Contents aa hina wan a a wal a a E A a OAR A 12 About Manuals x22 caucasian aks cas ai catia eat ean aioe eat ean NA A 17 1 OVERVIEW 1 1 to 1 50 WD OVGIVIGW E treeless cette it tata rete th E E elie a eed ieee eal 1 1 aa T EEE T ATE E EDE S T T T E E A E E T E E T E E T E E 1 3 1 2 1 Features of Motion SFC programs S naea E EE AEE REAR 1 3 1 2 2 Performance specifications cccccecceeeeeceeeeeeeseeeeeeeeeneeeaeeecaeeeeaeessaaeeseaeeseaeeseaeeseaceesisesineeseaeessaees 1
264. of 3 is used for transition program executed by the frol value of within the range and control count error normal task is outside the write it to the CPU range 1 to 30 Note 0000H normal 9 MOTION SFC PARAMETER 2 Interrupt setting Description Set whether 16 interrupt input points 10 to 115 of the QI60 interrupt module loaded in the motion slot are used as NMI or event task inputs Setting can be made freely per point All points default to event tasks Errors None 9 MOTION SFC PARAMETER 9 5 Program Parameters Set the following parameters for every Motion SFC program Setting range Initial value Remark Start setting Automatically started or not Not setting It is only one of normal event and NMI tasks Normal task When you have set the event task further set the event which will be enabled Always set any one of the following 1 to 3 1 Fixed cycle It is one of 0 88ms 1 77ms 3 55ms 7 11ms and 14 2ms or none External interrupt make selection from those set to event task Multiple interrupt can be set from among 10 11 12 13 14 15 16 17 18 19 110 111 112 113 114 and 115 Execute task ee ce can be set from among 10 11 12 nn aime eut tie etre M2000 and used for control 13 14 15 16 17 18 19 110 111 112 113 114 and 115 1 to 3 can be set also by OR These parameters are imported there after When setting changing the values of th
265. off time is longer for 1 month or more continuous power off time is longer for 1 month or Note 3 more Note 4 Note 1 Use the Dividing unit Q173DV or dividing cable Q173J2B ACBLOIM Q173HB ACBLOIM Note 2 When selecting the each servo amplifier input the speed position switching control cannot be executed And the external stop input cannot be used Note 3 When adding the external battery Q6BAT use the Q170HBATC Note 4 When adding the external battery AGBAT MR BAT use the Q173DV Q173HCPU use or Q170BAT Q172HCPU use 1 10 Expansion of speed setting range in the unit degree Minor error 303 304 Processing with power supply OFF of servo amplifier Back up battery for internal memory 1 OVERVIEW 1 2 5 Restrictions by the version There are restrictions in the function that can be used by the version of Motion CPU module operating system software and programming software The combination of each version and a function is shown below Operating system p g sy f Programming CPU module version Section of Function software version M i Note 1 software version Q173HCPU T Q172HCPU T reference Fully closed loop control servo amplifer MR J3 CB RJo06 2 Filter external setting signal Bit device setting by Motion SFC instruction Section i BMOV FMOV MULTW MULTR TO Cc M 5 13 4 to 5 13 9 FROM Po NT There is no restriction by the versio
266. omotor output shaft current value change is executed in the virtual mode a servo program setting error Note 904 occurs and the current value change is not made If a current value change is made during mode changing a servo program setting error 907 real virtual changing or 908 virtual real changing occurs and the current value change is not made Note Refer to the Q173HCPU Q172HCPU Motion controller SV13 SV22 Programming Manual REAL MODE Q173HCPU Q172HCPU Motion controller SV22 Programming Manual VIRTUAL MODE for minor error major error and servo program setting error 7 MOTION CONTROL PROGRAMS 7 3 Synchronous Encoder Shaft Current Value Change Control SV22 only The current value of the specified synchronous encoder shaft is changed in the virtual mode Items set on peripheral device Common Circular Parameter block Others slzlzlglel s slelslzlels elelels al sela s 2 2 5 2 5 3 a Sls 9 5188 8 5 8 2 x s o Salal el al Sy eye S al ol a S ols 2 lal e Zls s 5 Zle o l 8 o 8 3 z D 212 21 8 S Elezleel Z ro els fe Servo Positioning Number of Fo 2j l of S s s SEs 3 2 Speed 5 D ne x 9 oO olol 2 o ls 1 3S instruction method Control axes 2 g E S 2 S 3 3 8 SIs E 2 change o O O ol FJS D TA Q rag alol o oo fe w le doj ols ajjaj ole Is E o u g s e T a D 8 e 3 v a je o F zZ X H
267. omplete flag CPU No 1 read completion normally by MULTR instruction CPU No 2 MULTR OFF to ON Turn on when the data read from CPU No 2 is performed complete flag CPU No 2 read completion normally by MULTR instruction CPU No 4 MULTR complete flag QO v Cc z 9 L n oO a o Q CPU No 2 reset flag CPU No 3 reset flag CPU No 4 reset flag CPU No 1 error flag CPU No 2 error flag CPU No 3 error flag CPU No 4 error flag S Read completion CPU No 3 MULTR OFF to ON Turn on when the data read from CPU No 3 is performed complete flag CPU No 3 read completion normally by MULTR instruction OFF to ON Turn on when the data read from CPU No 4 is performed CPU No 4 read completion normally by MULTR instruction OFF CPU No 1 reset release CPU No 1 resetting CPU No 2 reset release CPU No 2 resetting CPU No 3 reset release CPU No 3 resetting CPU No 4 reset release CPU No 4 resetting CPU No 1 normal On CPU No 1 stop error CPU No 2 normal On CPU No 2 stop error CPU No 3 normal On CPU No 3 stop error CPU No 4 normal On CPU No 4 stop error Turn off at reset release of the CPU No 1 Turn on during reset of the CPU No 1 It also contains when a CPU is removed from the base unit e The other CPU is also resetting Turn off at reset release of the CPU No 2 Turn on during reset of the CPU No 2 It also contains when a CPU is r
268. on e Positioning start completion M2400 20m ON unchanged from before execution of CHGV instruction e Positioning completion M2401 20m OFF e In position M2402 20m ON e Command in position M2403 20m OFF Speed change 0 accepting flag M2240 m ON 5 66 5 OPERATION CONTROL PROGRAMS SSS ES SSL 2 Make a speed change to a positive speed for a restart 3 Turn on the stop command to end the positioning 4 Anegative speed change made again will be ignored d While the axis is reversion in the speed control mode 1 Make a speed change to a positive speed to change the travel direction again 2 Turn ON the stop command to make a stop 3 A speed change is made in the opposite direction if a negative speed change is made again Errors 1 An operation error will occur and a speed change will not be made if e The specified axis No of S1 is outside the range e S2 is an indirectly specified device and its device No is outside the range 2 A minor error will occur and a speed change will not be made if e The axis specified with S1 is home position return Minor error 301 If the speed change is executed for the axis specified with S1 during deceleration the speed change is ignored An error will not occur in this case 3 A minor error will occur and the axis to be controlled at the speed limit value if e The absolute value of the speed specified with S2 is greater than the speed limit value
269. on module at the instruction execution e Abnormalities of the intelligent function module special function module were detected at the instruction execution I O No s specified with S1 differ from the intelligent function module special function module controlled by the self CPU e The address specified with S2 is outside the range buffer memory First device No D which stores the reading data number of words n to be read is outside the device range D is a bit device and the device number is not a multiple of 16 e PX PY is set in D to D n 1 11 8 words n to be read is within the range of 1 to 256 Replace the intelligent function module special function module if there is a fault Correct the program so that I O No s specified with S1 is intelligent function module special function module controlled by the self CPU Correct the program so that the address specified with S2 is within the buffer memory range e Correct the program so that first device No D which stores the reading data number of words n to be read is within the device range When D is a bit device set the device number to be multiple of 16 e When D is a bit device do not set PX PY 11 ERROR CODE LISTS Table 11 5 Operation control transition execution errors 16300 to 16599 continued Error factor Error code aT Error Processing Name Description Indirectly specified 16 bit motion
270. on conditional expression specified with S is not omissible 3 Only the bit or comparison conditional expression cannot be set in other than the last block Device set SET device reset RST can be set in other than the last block 7 MOTION CONTROL PROGRAMS 7 MOTION CONTROL PROGRAMS 7 1 Servo Instruction List Table 7 1 lists servo instructions used in servo programs Refer to Section 7 2 to 7 4 for details of the current value change control CHGA CHGA E CHGA C Refer to the Q173HCPU Q172HCPU Motion Controller SV13 SV22 Programming Manual REAL MODE for other servo instructions 1 Guide to servo instruction list Table 7 1 Guide to Servo Instruction List itioning data Parameter block Q fo 3 3 fo m Q 3 Address travel Dwell time Auxiliary point Central point Starting angle Amplitude Frequency Reference axis No Control unit at stop input Allowable error range for circular S O a interpolation S curve ratio Program No WAIT ON OFF Fixed position stop acceleration deceleration time Fixed position stop Instruction Processing symbol Positioning control Parameter block No Command speed Torque limit value Speed limit value Acceleration time Deceleration time Rapid stop deceleration time Torque limit value Repeat condition FIN acceleration deceleration Number of steps Deceleration processing Virtual enable O 0 0 Number of step
271. on control execute The Motion SFC program code is corrupted code error program Fn FSn Turn PLC ready flag M2000 OFF and write the Motion SFC program again POPA Gn program code e Internal code error in the transition program Or replace the external battery if it passed error Gn over a life 16207 Specified the invalid The invalid device T C in the program is set Correct the program which does set the device up effective device 11 4 11 ERROR CODE LISTS Table 11 5 Operation control transition execution errors 16300 to 16599 Error factor Corrective Action Error code Error Processing Event task enable may be executed in the Event task enable Event task enable was executed at except for 16301 El execution error the normal task normal task only Correct the program Event task disable _ Event task disable was executed at except for Event task disable may be executed in the DI execution error the normal task normal task only Correct the program The cam data of the cam No specified with D or S is not yet registered to the Motion controller Correct the program so that cam data is that The resolution of the cam No specified with of the already registered cam No D or S differs from the number of Correct the program to match n with the transferred words specified with n cam resolution Block transfer e S to S n 1 is outside the device range e
272. on dedicated PLC instruction is frequently performed from the PLC CPU the scan time of the PLC CPU is not only prolonged but delay will arise in the communication processing of the Motion CPU Perform execution of the Motion dedicated PLC instruction from the PLC CPU by S P DDWR S P DDRD S P CHGV instruction etc only at the time of necessity 3 MOTION DEDICATED PLC INSTRUCTION 3 Complete status The error code is stored in the complete status at abnormal completion of the Multiple CPU dedicated instruction The error code which is stored is shown below The error code marked is dedicated with the Motion CPU Complete status Error fact Corrective Error code H Saad action fg Normal completion 4C00 The specified device cannot be used in the Motion CPU Or it is outside the device range 4C01 The instruction for the Multiple CPU system which did not be correspond with operating system software of the Motion CPU was executed 4C02 The Motion SFC program No to start is outside the range 0 to 255 4C03 The servo program No to execute is outside the range 0 to 4095 4C04 Axis No set by SVST instruction is injustice 4C05 Axis No set by CHGA instruction is injustice 4C06 Axis No set by CHGV instruction is injustice 4C07 Axis No set by CHGT instruction is injustice Confirm a e When using the S P SFCS S P SVST S P CHGA instruction There are 33 or more instruction requests to the Motion CPU from the P
273. once And the same operation is processed continuously in the next cycle In this case the transition destination step is executed in the next cycle when the transition condition enables Consecutive transition control indicates that transition destination steps are executed one after another in the same one execution cycle when their transition conditions have enabled single basic operation is performed consecutively In this case set the number of consecutive transitions Control exercised is common to the Motion SFC programs executed by normal tasks Set the number of consecutive transitions to the Motion SFC programs executed by event and NMI tasks for every program 9 MOTION SFC PARAMETER 9 2 2 Task operation 1 Normal task operation Operations The Motion SFC program is executed in the main cycle free time of the Motion CPU processing Program 1 Program 2 Program name Program name A Ey Ey F20 1 A F1 F oS F2 2 B F3 F x F END i 7 wo oO il H n oO END SFCS1 SFCS2 PLC program cel L_ le Main cycle sja Main cycle gt Normal task lt A gt 2 B Main cycle i gt Normal task is ended with END No continuation operation When making it operate continuously it returns to starting step in a jump Points a The Motion SFC program which includes motion control steps should be set to a normal task b
274. onditions 1 Combinations with motion control steps a Motion control step Shift 7 Operations e Transits to the next step by formation of transition condition C o Gn without waiting for the operating completion of the servo program Kn started at the motion control step b Motion control step WAIT Operations e Waits for the operating completion of the servo program Kn started at the motion control step and then transits to the next step by formation of transition condition Gn Cen e The operation completion condition of the servo program Kn is not needed in the transition condition Gn An error stop of the started servo program Kn at during a start is also regarded as an operation completion c WAITON WAITOFF Motion control step Operations Prepares for the start of the motion control step next to WAITON WAITOFF and makes a start immediately when the specified bit device turns ON OFF When the motion control step is executed without being used lt i OFF MO with WAITONWAITOFF preparations for a start are made after the transition condition Kn Kn preceding the motion control step enables This will cause a variation of delay starting time between when the transition condition is completed and when a start is made but a combination with WAITON WAITOFF can eliminate the variation of the above delay starting time Kn e Specifiable bit devices Ti
275. ording to the status of the instruction completion e Normal completion OFF e Abnormal completion It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing Setting range 1 Setting of the starting axis The starting axis set as S1 sets J Axis No in a character sequence _ St usable range Q173HCPU 1 to 32 Q172HCPU Up to 8 axes can be set If multiple axes are set it sets without dividing ina space etc The axis No set in the system setting is used as the axis No to start Refer to the Q173HCPU Q172HCPU Motion controller Programming Manual COMMON for system settings And the axis No to start does not need to be a order Example When multiple axes Axis1 Axis2 Axis10 Axis11 are set J1J2J10J11 2 Setting of the servo program No S2 usable range 0 to 4095 3 MOTION DEDICATED PLC INSTRUCTION sss sss Start accept flag System area The complete status of the start accept flag is stored in the address of the start accept flag in the shared CPU memory Shared CPU memory address is decimal address Description The start accept flag is stored by the 1 to 32 axis each bit As for a bit s actually being set Q173HCPU J1 to J32 Q172HCPU J1 to J8 OFF Start accept flag usable ON Start accept flag disable 205H 517 b15 204H 516 204H 516 address J16 205H 517 address J32
276. ot possible 1 Program writing is executed during the positioning control in the online change Be safely careful enough for work Programs writing to the internal SRAM of Motion CPU at the mode operated by ROM in the online change If the online change is executed at the mode operated by ROM it returns to the contents of program written in the internal FLASH ROM by the next power ON or resetting If the online change is executed simultaneously to one Motion CPU from the multiple personal computers a program writing may not be executed Please do not perform If the online changes are executed by other personal computer during the following operation by SW6RN GSVLPP injustice of a monitor value and operation failure may occur Please do not perform e Monitor mode of the Motion SFC program Test mode e Debug mode of the Motion SFC program If the online change of Motion SFC chart added newly is executed since the online change of Motion SFC parameter cannot be executed it operates as the normal task default value When using the SV22 if the online change is executed by changing the program servo program editor screen Mode assignment setting the contents of change are not reflected If the cables between the peripheral devices and Motion CPU fall out or the power supply of the Motion CPU turns OFF or resets the program is corrupted Write the program again with the communication screen of SW6RN GSVOP 10 3 10 USER FILE
277. ouching the servomotor shaft or coupled machines as these parts may lead to injuries Do not go near the machine during test operations or during operations such as teaching Doing so may lead to injuries 4 Various precautions Strictly observe the following precautions Mistaken handling of the unit may lead to faults injuries or electric shocks 1 System structure A CAUTION Always install a leakage breaker on the Motion controller and servo amplifier power source If installation of an electromagnetic contactor for power shut off during an error etc is specified in the instruction manual for the servo amplifier etc always install the electromagnetic contactor Install the emergency stop circuit externally so that the operation can be stopped immediately and the power shut off Use the Motion controller servo amplifier servomotor and regenerative resistor with the combi nations listed in the instruction manual Other combinations may lead to fire or faults If safety standards ex robot safety rules etc apply to the system using the Motion controller servo amplifier and servomotor make sure that the safety standards are satisfied Construct a safety circuit externally of the Motion controller or servo amplifier if the abnormal operation of the Motion controller or servo amplifier differ from the safety directive operation in the system In systems where coasting of the servomotor will be a problem
278. out waiting for the operating completion of subroutine When just before is the motion control step waits for the motion operating completion and then transits to the next step by the completion of transition condition Gn GO to G4095 When just before is the operation control step transits to the next step by formation of transition condition after operating execution Same operation as Shift When just before is subroutine call or starting step waits for the operating completion of subroutine and then transits to the next step by the completion of transition condition Prepares for starting of the next motion control step Transition and issues an instruction immediately when the WAITON WAITON bit device specified bit device turns ON Always pair this transition with the motion control step one for one Prepares for starting of the next motion control step and issues an instruction immediately when the WAITOFF WAITOFF bit device specified bit device turns OFF Always pair this transition with the motion control step one for one When just before is the motion control step transits to the next step by formation of transition condition Gn GO to G4095 without waiting for the motion operating IFT1 completion If not formation of transition condition transits to the right connected step Not SFT Gn i A completion i When just before is the operation control step transits of condition to the next step by the
279. pe L type K H K H L type K ae a Tl a a l ae a aaa aE ae l ee ee eee O Usable Setting data Data type of result S1 Data to be left shifted Data type of S1 S2 Number of left shifts Integer type Functions 1 The data specified with S1 is shifted to the left by the number of times specified with S2 2 0 enters the least significant bit of the left shift result 3 When S1 is a 16 bit integer type and S2 is a negative number or not less than 16 the result is 0 4 When S1 is a 32 bit integer type and S2 is a negative number or not less than 32 the result is 0 Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which shifts 0 one bit position to the left and substitutes the result to DO b15 bO o PARRE Enh a 0 ornen 5 OPERATION CONTROL PROGRAMS FIFS 5 5 7 Sign inversion Complement of 2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit l 16 bit 32 bit i Calculation P data Bit device floating Coasting floating conditional conditional expression integer integer type point expression expression integer integer oint finer type ype P type K H K H L type F type K Hande o l a l o o H a H H O Usable Setting data Setting data Data type of result Data whose sign wil
280. pecified Confirm a o447 The CPU except the Motion CPU by First I O No of the program and a CPU 16 is specified correct it to a goo Specified instruction is wrong sd instruction is wrong correct PLC devices Since 0 to 3DFH 3E4H is specified by First I O No of the target CPU 16 is specified Note 0000H Normal Program example This program starts the Motion SFC program No 10 of the Motion CPU No 4 XO sP sFes H3E3 K10 mo Do MO M1 m Normal complete program w Abnormal complete program 3 MOTION DEDICATED PLC INSTRUCTION 3 3 Servo Program Start Request from The PLC CPU to The Motion CPU S P SVST PLC instruction S P SVST Usable devices Internal devices MELSECNET 10 Special a a File Bit Indirectly drean Finch Index eat i eyetom User ist digit specified irec MEAN register Other register specified device Note Setting dat O Usable A Usable partly Note Setting data except S1 Index qualification possible Instruction Condition Start request sp svst Seu Start request S SVST _ S SVST Setting data Setting data Description Data type First I O No of the target CPU 16 F n Note 1 16 bit n1 Value to specify actually is the following b ina CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H Y Axis No Jn A 2
281. peed Change Instruction from The PLC CPU to The Motion CPU S P CHGV PLC instruction S P CHGV oo ccc ccccsccsecsscseecsecseeeeseecseesesseseecaesseseessaeeaesaeseeseateates 3 30 3 6 Torque Limit Value Change Request Instruction from The PLC CPU to The Motion CPU S P CHGT PLC instruction S P CHGT ccccccsccsecssessscseecsececsseseecsecsesseeseecsessesseseaesaesaeeeeseaeeates 3 34 3 7 Write from The PLC CPU to The Motion CPU S P DDWR PLC instruction S P DDWR 3 38 3 8 Read from The Devices of The Motion CPU S P DDRD PLC instruction S P DDRD 3 42 3 9 Interrupt Instruction to The Other CPU S P GINT PLC instruction S P GINT eeseeeeeeeeees 3 46 4 MOTION SFC PROGRAMS 4 1 to 4 28 4 1 Motion SFC Program Configuration ccceecceecececeeeeeneeseeeseeeeneesieeseesaeeseesaeesieesieesieesieesieesieesieesieeeieee 4 1 4 2 Motion SFC Chart Symbol HIST aiian eeceeceeeeeeeeeeeeeeeeeeeeeeeeeseeeseeseeesaeseeseeseeeseeeseeeseeeseeeseaeseaeseneseneeaes 4 2 4 3 Branch and Coupling Chart List cecceceseeeceeeeeeeeeeesneeseeeeeesaeeseesaeesaeeseesieesieeseesieesieesieeneesieesieeseee 4 5 4 4 Motion SFC Program NaMe rasaserra aeaa aN AE ANA A AANA EAA E AANE ENAN AA AEA NAA 4 9 ALD SIODS EEEE a toes E EE E E E E E E E E E E E A EAT 4 10 4 5 1 Motion Control Step cccccccscceeeeeceeeeeeeeeeeeeeeeeneesaeeceaeeesaceeseaeesaeeseaeeesaceesaeeseaeeseaeeeeessieeeseaeessaees 4
282. ples 1 2 words from 0 is written to since buffer memory address of the Intelligent function module special function module First I O No 010H TO H010 HO 0 K2 Intelligent function module special function module First I O No 010H Buffer memory 5 words transfer Device memory OH q 70 1H 1 DO DO 5 OPERATION CONTROL PROGRAMS FIFS 5 13 9 Read device data from intelligent function module special function module FROM FROM D S1 S2 n Number of basic steps Usable data Usable Data Bit device 64 bit 64 bit Bit Comparison 16 bit 32 bit 7 16 bit 32 bit oF Calculation ne d i floating Coasting floating conditional conditional integer integer oint fimer integer integer type dint expression expression expression P type K H K H L P type type L type F type K om oe o Pst o o sa o o Cow d l o l l l ol l l l l l O Usable Note 1 Refer to the Section 1 2 5 for the correspondence version of the Motion CPU and the software Setting data Setting data E holga motte special furci module OOOH to FFOH S2 First address of the buffer memory which it will be read Number of words to be read 1 to 256 Functions 1 A part for n words of
283. point Processing Parameter block No Address travel value Command spee Torque limit value Positioning control man olololofo olololol 1E Evie sea ABSA Absolute central point specified circular interpolation CW Absolute central point specified circular anbi interpola ion CCW ee opel pac al rele INC A Incremental central point specified circular interpolation CW 5 Incremental central point specified circular interpolation COW roller a FAE led N Circular interpolation Central point specified ABH A gt Absolute auxiliary point specified helical interpolation INH Incremental auxiliary point specified helical interpolation ETTA Absolute radius specified helical JABHA interpolation less than CW 180 Absolute radius specified helical ABH interpolation CW 180 or more RREPA Absolute radius specified helical ABHSA interpolation less than CCW 180 ROSY Absolute radius specified helical ABHC interpolation CCW 180 or more linn Incremental radius specified helical interpolation less than CW 180 INH gt Incremental radius specified helical interpolation CW 180 or more Pinte za Incremental radius specified helical NE S interpolation less than CCW 180 Incremental radius specified helical INHC interpolation CCW 180 or more ABHA Absolute central point specified helical interpolation CW 5 Absolute central point specified helical BH interpolation CCW INH A Incremental
284. program MAIN Pea END When the specified program has been subroutine started the subroutine program started continues processing Shown below MAIN If the program has been subroutine started as shown on the left a When the started program MAIN is cleared Even if the subroutine SUB is running the started program MAIN stops running but the started subroutine SUB SUB 1 continues processing Shift END When the subroutine SUB is cleared If the subroutine SUB is running only the subroutine SUB stops running END When the servo program started from the specified program is starting the servo program continues processing When the Motion SFC program specified with the clear step does not exist the Motion SFC program error 16203 will occur When the Motion SFC program specified with the clear step is not starting an error does not occur specifically and this step is ignored If the Motion SFC program running is stopped by the clear step the output is held 4 14 4 MOTION SFC PROGRAMS 4 6 Transitions You can describe conditional and operation expressions at transitions The operation expression described here is repeated until the transition condition enables as at the scan execution type operation step Refer to Chapter 6 TRANSITION PROGRAMS for the conditional operation expressions that can be described in transition c
285. pt accept flag from CPU 1 M1 U3E1 G48 0 i D100 RST SET g z N a To self CPU high speed interrupt accept flag from CPU 1 M2 U3E1 G48 0 m D100 M2 M10 M11 Read the data from DO to D100 I and normality complete processing Read the data from DO to D100 and abnormality complete processing BIE J Read the data from D200 to D300 II and normality complete processing Read the data from D200 to D300 land abnormality complete processing Read the data from D200 to D300 iI and normality complete processing Read the data from D200 to D300 and abnormality complete processing There is the following restriction in the case as the example 2 1 The Multiple CPU dedicated instruction of Motion CPU cannot be used Interrupt program fixed cycle executive type program and low speed executive type program When it is used an instruction may not work by the timing APP 12 APPENDICES APPENDIX 2 3 Motion control example by Motion SFC program 1 The Motion SFC program composition example to execute motion control This sample program example is described to every following function Function list of sample program 1 Monitor of the positioning The positioning dedicated device status of the Motion CPU CPU No 2 dedicated device is reflected on M2400 to and DO to of the PLC CPU CPU No 1 The clock data read request
286. put relay Yn PYn 0 to 1FFF Internal relay Mn 0 to 8191 latchrelay tn S oosa O Linkrelay Bn tot O Annunciator Fn to 2087 O a When using the device in DIN or DOUT as batch bit data specify n as a multiple of 16 5 OPERATION CONTROL PROGRAMS 3 Indirect specification of device No In the above word bit device descriptions device No n can be specified indirectly a Indirect specification of device No n using word device e The word device which the device No was specified indirectly cannot be used e You can use the 16 bit and 32 bit integer type word devices for indirect specification The 64 bit floating point type cannot be used Description examples Good example Bad example D10 D D5 b Indirect specification of device No n using word device using operation expression e Device No can be specified indirectly by calculation expressions which use the following data and operators 16 bit integer type word device 32 bit integer type word device Usable data 16 bit integer type constant 32 bit integer type constant Addition Subtraction Multiplication Usable operators e The word device which the device No is specified indirectly cannot be used e Only one operator may be used Description examples Good example Bad example D10 K5 D D5 F K20 D 10L H6L F D 4L lt lt K2 Note When you want to use the result of calculation other
287. qme niema relay M109 tobi stop SET M100 Stop ON Initials set i Stop The subroutine starts 170 stop and 150 Programming operation Programming operation Xx G20 The subroutine that motion control was executed at the time of the forced stop M9076 Did you release a forced listop Wh ocea sionis released Ie did not stop and which started it for a bed aa naa bane ac ar aN while goes on and it is executed by F110 servo on command are turned on this sample program SET M2042 All axes servo ON command Motion control is stopped after servo Ilis ON OFF is detected at the time of the forced stop in the inside of the subroutine Real output PY is turned off at the time of the forced stop G21 Resuming of the motion control is 7 Note 1 A subroutine d the start g M9076 Did you turn on forced Nore neta esto if necessary S executed after all the axis servo ON listop 7 command were turned on in this Note 2 Actual output is turned off if necessary Note 3 The occurrence detection of servo error and so on is added to the stop condition with the forced stop if necessary program and the detection of servo ON was done on the subroutine side when a forced stop is released F25 DOUT PY10 H0000 PY10 to PY1F I 16 points OFF en a a b No 170 Stop C Stop gt
288. r B register module specified device O Usable A Usable partly Note Setting data n1 to D2 Index qualification possible Instruction Condition Start request SP DDWR n1 SP DDWR_4 Start request S DDWR _ s DpDwp n1 Setting data Setting data Description Data type First I O No of the target CPU 16 n1 Value to specify actually is the following CPU No 1 3E0H CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H 16 bit First device of the self CPU in which control data is stored binary Note 1 First device of the self CPU in which writing data is stored First device of the target Motion CPU which stores the writing data Bit device which make turn on for one scan at completion of instruction Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration Control data Setting Device Item Setting data Set by range The condition result at the completion of the instruction is stored Complete status System 0 No error Normal completion Except 0 Error code 3 MOTION DEDICATED PLC INSTRUCTION Controls 1 This instruction is dedicated instruction toward the Motion CPU in the Multiple 4 6 CPU system Errors occurs when it was executed toward the CPU except the Motion CPU A part for the number of writing data of the control data specified with S1 of data since the
289. r a search up to 4095 a search is made from 0 to the set G number 1 b When set to automatic numbering Searches for a free number forward or backward in the automatic numbering range starting with the automatically numbered G number 1 or 1 at the Shift Y N or WAIT Y N symbol The searching method is as in the automatic numbering setting 2 Automatic logical NOT program generation feature Automatically generates a program which logically negates the conditional expression block last block of the transition program set at Shift Y N or WAIT Y N The basic is shown below lt Setting program conditional expression block gt Conditional expression bit conditional expression or comparison conditional expression lt Logically negated automatically generated program conditional expression block gt Conditional expression bit conditional expression or comparison conditional expression Examples are shown below lt Setting program conditional expression block gt Example 1 Mmo _ Bit device ON Example 2 DO K100 Data register DO is not K100 lt Logically negated automatically generated program conditional expression block gt Example 1 MO IBit device OFF Example 2 DO K100 Data register DO is K100 Refer to Section 1 2 3 2 Table of the operation control transition instruction for the instructions usable in the conditional expressions of Shift Y N or
290. r interpolation starting servo programs Items set for high speed oscillation Set when changing the parameter block default value when not set data set in the servo program to control The parameter block data are not changed Setting items other than the common circular and parameter block items Items to be set vary with the servo instruction Indicates the number of steps of each servo instruction 7 MOTION CONTROL PROGRAMS E c fe is i 2 5 s e Qa 2 o g pa fp D a Circular interpolation control Positioning control Radius specified 2 Servo instruction list Table 7 2 indicates the servo instructions available for servo programs and the positioning data set in servo instructions Table 7 2 Servo Instruction List Positioning data j 2 Instruction symbol Processing Address travel value Command speed Dwell time Torque limit value Parameter block No Auxiliary point Radius Central point Virtual enable fofolo lo lolo lolololoa Number of steps 0000000000 ae omer falofofefala _ net peen fafo oof ff isa moe a fofofof la nee fome Tafofofofsfal sss sne afo o Incremental 4 axes linear interpolation Absolute auxiliary point specified circular interpolation Incremental auxiliary point specified circular interpolation Absolute radius specified circular interpolation less than CW 180 Absolute radius specif
291. ram intelligible for anyone can be created in flow chart form by macking a sequence of machine operation correspond to each operation step maintenance nature improves Since transition conditions are judged with Motion CPU side and positioning starts there is not dispersion in the response time influenced by PLC scan time High speed and high response processing is realizable with the step processing method only active steps of Motion SFC Not only positioning control but also numerical operations device SET RST etc can be processed with Motion CPU side making via PLC CPU is unnecessary and a tact time can be shortened By transition condition description peculiar to Motion SFC the instructions to servo amplifier is possible at completion of starting condition By transition condition description peculiar to Motion SFC after starting transition to next step is possible without waiting for positioning completion Motion SFC program that responds and executes it at high speed for interrupt input from external source can be set Motion SFC program executed in the fixed cycle 0 88ms 1 77ms 3 55ms 7 11ms 14 2ms by synchronizing to the Motion operation cycle can be set 1 OVERVIEW 1 2 2 Performance specifications 1 Basic specifications of Q173HCPU Q172HCPU a Motion control specifications Q173HCPU Q173HCPU T Q172HCPU Q172HCPU T Number of control axes Up to 32 axes Up to 8 axes 0 44ms 1 to 3 axes 0 88ms 4 to
292. re is unusable in the Q172HCPU Note 3 The unused axis areas in the cam axis command signal can be used as an user device 1 24 1 OVERVIEW 8 Table of the smoothing clutch complete signals SV22 only Rereshoycie Fetchcycie Signal direction M5520 A Main shaft side Output axis 1 M5521 Auxiliary input side M5522 Main shaft side Output axis 2 M5523 Auxiliary input side M5524 Main shaft side Output axis 3 M5525 Auxiliary input side M5526 Main shaft side Output axis 4 a M5527 Auxiliary input side M5528 Main shaft side Output axis 5 M5529 Auxiliary input side M5530 Output axis 6 Main shaft side M5531 Auxiliary input side M5532 Main shaft side Output axis 7 REUT M5533 Auxiliary input side M5534 Main shaft side Output axis 8 M5535 Auxiliary input side M5536 i Main shaft side Output axis 9 oe M5537 Auxiliary input side M5538 Main shaft sid Output axis 10 ans a S M5539 Auxiliary input side M5540 Output axis 11 Main shaft SiGe M5541 Auxiliary input side M5542 Main shaft sid M5542 output axis 12 ain shaft side M5543 Auxiliary input side M5544 Main shaft sid Output axis 13 SUA il S e M5545 Auxiliary input side M5546 Main shaft side Output axis 14 M5547 Auxiliary input sid M5548 Output axis 15 Main shaft side M5549 Auxiliary input sid M5550 Output axis 16 Malhshatt side M5551 Auxiliary input sid M5552 A Main shaft side Operation cycle Status signal Output axis 17 M55
293. red 3 After CPU power on or reset processing Motion SFC programs run is shown below e The SFC programs set to start automatically are run from the beginning by turning PLC ready flag M2000 on in the PLC program e The other Motion SFC programs are also executed from the first at starting 9 11 Operation Performed when CPU is Switched from RUN STOP When a RUN STOP switch is operated PLC ready flag M2000 turns on off in accordance with Operation at STOP to RUN of a setting of a basic systems Refer to Section 3 1 3 Individual parameters of the Q173HCPU Q172HCPU Motion controller Programming Manual COMMON for the details of Operation at STOP to RUN And refer to the next section for PLC ready flag M2000 off on 9 MOTION SFC PARAMETER 9 12 Operation Performed when PLC Ready flag M2000 Turns OFF ON This section explains about the turns off on of PLC ready flag M2000 The on off condition of PLC ready flag M2000 differences in Operation at STOP to RUN of a setting of a basic systems Refer to Section 3 1 3 Individual parameters of the Q173HCPU Q172HCPU Motion controller Programming Manual COMMON for details M2000 OFF ON If there is no fault when PLC ready flag M2000 turns off to on the PCPU ready flag M9074 turns on When this PCPU ready flag M9074 turns on Motion SFC programs can be executed An automatic start Motion SFC program starts execution from the first M2000 ON OFF Wh
294. remark column 1 30 1 OVERVIEW b Table of the data registers e Overall configuration DO Axis monitor device to 20 points x 32 axes pee Control change register 2 points x 32 axes D04 Common device Command signal 54 points Dine Common device Monitor 42 points D800 User device 7392 points D8191 DO Axis monitor device 20 points x 32 axes to Real mode Each axis Virtual mode Output module D640 Control change register 2 points x 32 axes Bie Common device Command signal 54 points ore Common device Monitor 42 points D800 Virtual servomotor axis monitor device Note 10 points x 32 axes Mechanical system setting axis only D1120 i Syncronous encoder axis monitor device Note 10 points x 12 axes D1240 Cam axis monitor device Note 10 points x 32 axes D1560 User device 6632 points D8191 Note It can be used as an user device in the SV22 real mode only 1 31 1 OVERVIEW 1 Table of the each axis monitor devices SV13 SV22 D320 Axis 1 monitor device to Axis 17 monitor device D339 D340 Axis 2 monitor device to Axis 18 monitor device D359 D360 Axis 3 monitor device to Axis 19 monitor device D379 D380 Axis 4 monitor device to Axis 20 monitor device D399 D400 Axis 5 monitor device to Axis 21 monitor device D419 D420 Axis 6 monitor device to Axis 22 monitor device D439 D440 Axis 7 monitor device to Axis 23 monitor device D459 D460 Axis
295. ric shocks Never run the unit with the front case or terminal cover removed The high voltage terminal and charged sections will be exposed and may lead to electric shocks Never open the front case or terminal cover at times other than wiring work or periodic inspections even if the power is OFF The insides of the Motion controller and servo amplifier are charged and may lead to electric shocks When performing wiring work or inspections turn the power OFF wait at least ten minutes and then check the voltage with a tester etc Failing to do so may lead to electric shocks Be sure to ground the Motion controller servo amplifier and servomotor Ground resistance 100 or less Do not ground commonly with other devices The wiring work and inspections must be done by a qualified technician Wire the units after installing the Motion controller servo amplifier and servomotor Failing to do so may lead to electric shocks or damage Never operate the switches with wet hands as this may lead to electric shocks Do not damage apply excessive stress place heavy things on or sandwich the cables as this may lead to electric shocks Do not touch the Motion controller servo amplifier or servomotor terminal blocks while the power is ON as this may lead to electric shocks Do not touch the built in power supply built in grounding or signal wires of the Motion controller and servo amplifier as this may lead to electric sh
296. roduced in a 64 bit floating point type data operation Especially when using 64 bit floating point type data in a comparison operation note that a round off error may cause an intended operation Example In the following transition program the result of the comparison operation may not become true depending on the value of 200F due to a round off error 1 0OF SQRT 200F 300F 100F 100F 200F 300F d Bit data The bit data is the data where a contact coil or similar device is handled in increments of 1 bit It is used in device set SET and device reset RST Example 1 Te Bit data e Batch bit data The batch bit data is the data where bit data is handled in increments of 16 32 points It is used in device input DIN and device output DOUT As indicated below whether the bit data is handled in increments of 16 or 32 points is governed by the data type of the word device used as an input destination output source D Increments of 16 points Increments of 32 points DIN 0 MO DIN 0L MO DOUT MO DO DOUT MO DOL Program example Specified device No to Specified device No to specified device No 15 specified device No 31 Used devices f MO to M15 in the above program MO to M31 in the above program example example 5 OPERATION CONTROL PROGRAMS f Logical data The logical data is a value returned by a bit or comparison conditional expression and indicates whether the result is true or
297. rogram b Except WAIT Subroutine Start When the subroutine start step is executed control starts the specified program and then shifts to the next as shown below Since the start source and destination Motion SFC programs are executed in parallel The started program ends at END execution MAIN SUB MAIN SUB e a ae es j 3 3 SUB 2 r SUB j 2 WATT p gt END Shift END a 4 i 2 re END END WAIT Except WAIT Subroutine call Subroutine start When the specified Motion SFC program does not exist at a subroutine call start the Motion SFC program error 16005 will occur and stops to execute the Motion SFC program at the error detection When the called started Motion SFC program is already starting at a subroutine call start the Motion SFC program error 16006 will occur and stops to execute the Motion SFC program at the error detection When the self program is started at a subroutine call start the Motion SFC program error 16110 will occur and stops to execute the Motion SFC program at the error detection When the subroutine to be called started at a subroutine call start in the Motion SFC program 2 running which was called started from the Motion SFC program 1 is the Motion SFC program 1 call source start program the Motion SFC program error 16111 will occur and the call start source Motion SFC progr
298. rogram can also be started automatically 3 Combined speed 30000 PLS s by parameter setting SLEEPER E Nesta R EOE EAE AAPEEE AAEE ANE AASTA Positioning control parameters System settings Fixed parameters Servo parameters Parameter blocks Home position return data JOG operation data Limit switch output data 2 STRUCTURE OF THE MOTION CPU PROGRAM 2 2 Motion Control in SV22 Virtual Mode 1 Software based synchronous control is performed using the mechanical system program constructed by virtual main shaft and mechanical module in SV22 virtual mode 2 Mechanical system programs is required in addition to the positioning parameter servo program Motion SFC program used in real mode 3 The procedure of positioning control in virtual model is shown below 1 Motion SFC program for virtual mode is requested to start using the S P SFCS instruction of the PLC program Motion SFC program can also be started automatically by parameter setting 2 The virtual servomotor in the mechanical system program is started 3 Output the operation result obtained through the transmission module to the servo amplifier set as the output module 4 The servomotor is controlled Program structure in SV22 virtual mode
299. rol and in Programming operation mode a f i position check is executed after the location of axis No 2 is executed the program stands by until No 1 2 locates of the linear control is executed at a double speed in the opposition direction and PX4 turns off The following the manual pulse generator operation is executed e Manual pulse generator operation of 1 axis is executed with the APP 13 APPENDICES 2 Contents processing of the Motion SFC program Motion SFC program list No i Contents of processing e This program starts automatically at the time of run of Q173HCPU and it is always executed e The positioning dedicated device bit device for monitor is transferred to WO to Normal Start The positioning dedicated device word device for monitor is transferred to W100 to Note WO to is assigned to M2400 to of the PLC CPU CPU No 1 and W100 to is assigned to DO to by the automatic refresh setting e This program starts automatically at the time of run of Q173HCPU and it is always executed e Watch data is taken out and clock data read request M9028 Nonna eta is turned on When a forced stop is canceled a subroutine starts a No 110 Motion control e No 110 Motion control is stopped at the time of the forced stop and real output PY is turned off Normal Not start 3 PX2 ON PX1 OFF No 140 Home position return 4 PX2 ON PX1 ON No 150 Programming operation 1 The JO
300. ror detection External signal TREN Error detection External signal TREN Axis 4 on sane a re ae a Axis 10 F A e Axis 11 F 3 7 a Axis 12 z A Note 1 The range of axis No 1 to 8 is valid in the Q172HCPU Note 2 Device area of 9 axes or more is unusable in the Q172HCPU 1 22 1 OVERVIEW 6 Table of the syncronous encoder axis command signals SV22 only M5440 Error reset M5441 Unusable M5442 Unusable M5443 Unusable M5444 Error reset Unusable Unusable Unusable Error reset f Unusable AS Unusable Unusable Error reset Unusable AAR Unusable Unusable Error reset 7 Unusable os Unusable Unusable Error reset Unusable pues Unusable Unusable Error reset F Unusable AG Unusable Unusable Error reset Unusable MXS g Unusable Unusable Error reset Unusable Axisa Unusable Unusable Error reset Unusable ANSY Unusable Unusable Error reset Unusable Aist Unusable Unusable Error reset Unusable Asda Unusable Unusable Note 1 The range of axis No 1 to 8 is valid in the Q172HCPU Note 2 Device area of 9 axes or more is unusable in the Q172HCPU 1 23 1 OVERVIEW 7 Table of the cam axis command signals SV22 only Axis 10 cam ballscrew switching Axis 17 cam ballscrew switching Axis 24 cam ballscrew switching Note 1 The range of axis No 1 to 8 is valid in the Q172HCPU Note 2 Device area of 9 axes or mo
301. ror will occur if e The data is other than 0 to 9999 when S is a 16 bit integer type e The data is other than 0 to 99999999 when S is a 32 bit integer type or e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which converts the BIN data of DO into BCD data and substitutes the result to 0 0 BCD D0 BCD 9999 BIN 9999 Y Yv y Y Thousands Hundreds Tens Units 5 OPERATION CONTROL PROGRAMS FIFS 5 7 Type Conversions 5 7 1 Signed 16 bit integer value conversion SHORT SHORT S Number of basic steps Usable data Usable Data Bit device Setting 64 bit 64 bit Bit Comparison 16 bit 32 bit i 16 bit 32 bit i Calculation ah P floating Coasting a floating A conditional conditional integer integer type expression x point expression expression data integer integer i 1 point timer t L t K H K H L type ype L type F ype K H type K O Usable Setting data Setting data Data type of result Data which will be converted into signed 16 bit oo S 16 bit integer type integer value 1 The data specified with S is converted into a signed 16 bit integer value Functions 2 The data range of S is 32768 to 32767 3 When S is a 64 bit floating point type its fractional portion is rounded down before conversion is made 4 If S is a 16 bit integer type its value is returned unchanged w
302. rs in length e The project path name project name are restricted to 230 characters in length Example C Usr project name 10 USER FILES 10 2 User File List A user file list is shown below sk Indicates the file data stored in CPU memory Project name folder Sfc m gt 1 m gt 2 m gt 3 Flist Fcode o Ck gt Ck gt k gt Ck Lp temp 8 9a 9b 10 11 12 13 14 15 16 17 18 19 20 24 Sub folders fixed Project file Project name prj Folder of user set project name x1pc Information file of correspondence between Motion SFC program No 0 to 255 and SFC program names SFC files Motion SFC chart file SFC program name sfc x256 pcs Motion SFC chart ed it information and comment information file of one Motion SFC program Motion SFC list file SFC program name txt x256 pcs Text file after conversion of Motion SFC chart of one Motion SFC program into list Motion SFC code file File after conversion SFC program name cod x256 pcs of list file of one Motion SFC program into internal codes including comment information G list file g0000 bin to g4095 bin lt Llst file of transition programs GO to G4095 G c
303. s keep at power on or reset e Cleared by latch clear Servo monitor devices e Cleared at power on or reset only 128 points The motion registers cannot be set as indirectly specified devices of mechanical system programs 8 MOTION DEVICES a Motion SFC dedicated devices 8000 to 8063 The Motion SFC dedicated devices are shown below The device s refresh cycle is indicated when the signal direction is status or its fetch cycle when the signal direction is commana Signal direction Refresh Status Command cycle Device No Signal name Seventh error information in past Oldest error information Sixth error information in past Fifth error information in past Fourth error information in past Motion SFC error history At error Third error information in past 8 errors occurrence 64 points Second error information in past First error information in past Latest error information 8 MOTION DEVICES 1 Motion SFC error history devices The error information occurred is stored as a history of up to eight past errors The latest error is stored in 8056 to 8063 All errors including the Motion SFC control errors and the conventional minor major servo servo program and mode changing errors are stored in this history At error occurrence the Motion SFC error detection flag M2039 is also set Motion SFC error history can be cleared by the Mot
304. s n to be written is outside the range of 1 to 256 The shared CPU memory address D of self CPU of the writing destination device is outside the range 800H to FFFH of the shared CPU memory address The shared CPU memory address D of self CPU of the writing destination device number of words n to be written is outside the range 800H to FFFH of the shared CPU memory address First device No S which writing data are stored number of words n to be written is outside the device range e MULTW instruction was executed again before MULTW instruction is executed and complete bit device is turned on D1 is a write disabled device S is a bit device and device number is not a multiple of 16 PX PY is set in S to S n 1 5 OPERATION CONTROL PROGRAMS Program examples 1 2 words from DO is written in the shared CPU memory to since AOOH and transits to next step after confirmation of writing completion FO RST MO MULTW _ HAOO DO K2 MO GO MO Shared CPU memory Device memory AOH DO A01H 200 2 words transfer D1 200 m ke 5 82 5 OPERATION CONTROL PROGRAMS F FS 5 13 7 Read device data from shared CPU memory of the other CPU MULTR MULTR D S1 S2 n Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit i 16 bit 32 bit i Calculation a p i R floating Coasting n floating i conditional conditional integer
305. s controlled of within the range and write it to consecutive the CPU NMI task consecutive transitions of the Motion SFC program started by the NMI task is outside the transition count error range 1 to 10 Note 0000H normal 9 MOTION SFC PARAMETER Control at execution 4 END operation Description Set the operation at execution of the END step toward the program executed by the event or NMI task This varies the specifications for the following items e Program run by NMI task When ended When continued Ends the self program Ends to execute the self program with this event interrupt Restart after execution Restarted at occurrence of the next event interrupt and run Again the program is started by the Motion SFC from the initial first step in accordance with the number of start instruction S P SFCS from the PLC or consecutive transitions of the corresponding program by a subroutine call start GSUB made from the After that at occurrence of an event interrupt the program is Motion SFC program executed in accordance with the number of consecutive transitions of the corresponding program Restart after end by clear step CLR Again the program is started by the Motion SFC start instruction S P SFCS from the PLC or by a subroutine call start GSUB made from the Motion SFC program The END operation of subroutine called program is controlled
306. s function ON Abnormal When the Motion CPU detects a WDT error it executes an OFF Normal immediate stop without deceleration of the operating axes The error cause is stored in the Motion CPU WDT error cause D9184 e When the PLC ready flag M2000 turn off to on the fixed parameters servo parameters and limit switch output data etc are checked and if no error is detected S Request this flag turns on e Turn off when the PLC ready flag M2000 turns off e This flag status indicates whether a TEST mode ON TEST mode is in established from a peripheral device is currently in effect effect OFF TEST mode is notin e If the TEST mode is not established in response to a effect TEST mode request from a peripheral device the TEST mode request error flag M9078 will turn on External forced stop ON _ Forced stop OFF Iie P input flag OFF Forced stop ON This flag status indicate whether the forced stop S Operation cycle 3S l g w D E lt D v 8 gt Hu oO oO oO Q gt O roy iS a Q fe is a o a 5 o 2 2 a E T o Q z S S Occur an error ON PCPU READY PCPU READY complete completion flag OFF PCPU READY uncompletion le le fo x x a i o le U QO U Cc v o 2 3 e S D a l gq a D Q 3 fe Q D ie Zz D a S Request le q ro 1 O VE
307. sers area H0005 n words 800H Automatic refresh This area HOOOA __ area Note can be a a User defined area used at H0000 OFFFH users area Note When automatic refresh is not set it can be used as a user defined area And when automatic refresh is set up since the automatic refresh transmitting range becomes a user defined area 2 Do resetting of the complete bit device by the user program 5 OPERATION CONTROL PROGRAMS 3 Another MULTW instruction cannot be processed until MULTW instruction is executed and a complete bit device is turned on When MULTW instruction was executed again before MULTW instruction is executed and complete bit device is turned on the MULTW instruction executed later becomes an error 4 The word devices that may be set at D S n and D1 are shown below Note 1 Note 1 Note 2 Word devices Bit devices O O O Note 4 Note 4 Note 1 The device No cannot be specified indirectly Note 2 Specify a multiple of 16 as the device number of bit data Note 3 PX and PY cannot be set Note 4 PX can be set PY cannot be set 5 Adjust an executive task the number of transfer word referring to the operation processing time so that this instruction may not obstruct the execution of the motion operation because processing time becomes long in argument to the number of words n to be written Errors 1 An operation error will occur if Number of word
308. sh is set up since the automatic refresh transmitting range becomes a user defined area 5 OPERATION CONTROL PROGRAMS 2 The word devices that may be set at D S n and D1 are shown below Word devices 0 Bit devices N77 Note 2 Setting data Note 1 The device No cannot be specified indirectly Note 2 Specify a multiple of 16 as the device number of bit data Note 3 Special relays M9000 to M9255 and dedicated devices M2000 to M2399 cannot be set Note 4 PX and PY cannot be set 3 When data are read normally from the target CPU specified with S1 the reading complete flag M9216 to M9219 CPU No 1 M9216 CPU No 2 M9217 CPU No 3 M9218 CPU No 4 M9219 corresponding to the target CPU turns on If data cannot be read normally the reading complete flag of the target CPU does not turn on 4 Adjust an executive task the number of transfer word referring to the operation processing time so that this instruction may not obstruct the execution of the motion operation because processing time becomes long in argument to the Number of words n to be read oa a When multiple MULTR instructions are executed to the same CPU simultaneously the reading complete flag M9216 to M9219 turns on as a result of MULTR that it is executed at the end 6 Reset the reading complete flag M9126 to M9219 using the user program Errors 1 An operation error will occur if e Number of words n
309. sition G1 with cancel device condition specified with servo program KO will cancel to execute of servo program K1 KO and allow servo program K1 to start 7 5 2 Indirect designation using motion devices 1 The motion registers 0 to 8191 cannot be used to make indirect specification in the mechanical system programs The motion register values are used in the servo or mechanical system programs substitutes them to data registers D link registers W 2 The coasting timer FT cannot used to make indirect specification in the servo program and mechanical system program 8 MOTION DEVICES 8 MOTION DEVICES The motion registers 0 to 8191 and coasting timer FT are available as Motion CPU dedicated devices They can be used in operation control F FS programs or transition G programs 8 1 Motion Registers 0 to 8191 Motion device Specifications Number of points 8192 points 0 to 8191 Data size 16 bit point i Only a user device is latched Motion register Latch All points are cleared by latch clear operation Usable tasks Normal event and NMI Access Read and write enabled in whole range 1 Motion register list a Common to all operating system Device No Application Signal direction User devices 8000 points Motion SFC Cleared at power on or reset only dedicated devices Cleared by the Motion SFC error history request flag on 64 point
310. ssion type type L type K H KH L PO j i type F type K Londonda 9 92 O Usable Setting data Setting data Data type of result Data which will be logically negated Logical type true false Functions 1 The data specified with S is logically negated Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range Program examples 1 Program which sets M100 when either of MO and X0 is not ON 1 when MO and X0 are both OFF 0 SET M100 MO X0 MO False True False Ea M100 _ xo 0 __ False 5 OPERATION CONTROL PROGRAMS FIFS 5 10 3 Logical AND S1 S2 Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit a 16 bit 32 bit DF Calculation a pe floating Coasting floating conditional conditional l i i expression l integer integer integer integer type point P expression expression type type L type K H K H L type K m a e a ea Tee e eee eee ee ee ee er l O Usable Setting data Setting data Data type of result Data which will be ANDed Logical type true false Functions 1 The data specified with S1 and the data specified with S2 are ANDed Errors 1 An operation error will occur if e S is an indirectly specified device and
311. ssion expression type type L type F type K H K H L type K Lo l l ol ol I l ol ol ee eee eee O Usable Setting data Setting data Data type of result S Waiting time 0 to 2147483647 ms Logical type true false Functions 1 A wait state continues for the time specified with S The result is false when the elapsed time is less than the preset time or the result is true and execution transits when the preset time has elapsed 2 When a 16 bit integer type word device is used to specify any of 32768 to 65535 ms at S convert it into an unsigned 16 bit integer value with USHORT Refer to the program example Errors 1 An operation error will occur if e S is an indirectly specified device and its device No is outside the range or e The data device data at indirect specification specified with S is outside the range of 0 to 2147483647 Program examples 1 Program which sets a wait of 60 seconds when constant is specified TIME K60000 2 Program for a case where there may be a wait of 32768 to 65535 ms for 16 bit integer type indirect designation 0 TIME USHORT 0 3 Program which SETS RSTs a bit device when the specified time has elapsed SET M100 TIME K60000 5 OPERATION CONTROL PROGRAMS 1 When the waiting time setting is indirectly specified with a word device the value imported first is used as the device value for exercising control The set time cannot be
312. stop is executed during the positioning operating the positioning operation is interrupted and the servomotor is stopped It is resumed from the interrupted positioning operation when the forced stop was released next Continuation execution of the subroutine re start is executed by this program example by the following processing a While motion control with the subroutine is executed it is memorized whether the positioning of which motion control step was completed in the user device b The subroutine re start is resumed from the motion control step of stopping the information memorized by the above a c A motion control step should locate absolute to cope with it when it is resumed after it stops on the way of the positioning d A positioning complete signal M2401 20n is used for the decision whether servomotor is stopped during the positioning APP 24 APPENDICES 2 Contents of processing the Motion SFC program Motion SFC program list _ Number of Automatic No Program name Task connective Contents of processing operation oe transitions e This program starts automatically at the time of RUN of Q173HCPU and it is always executed e Watch data is taken out and clock data read request M9028 is turned on 0 is set on the continuation point 100 user device as an 20 Main Normal Start initial value e The subroutine starts a No 160 Re start continuation after all axes servo are
313. stored First device of the self CPU which stores the reading data D2 Bit device which make turn on for one scan at completion of instruction Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration Note 1 Control data F 3 Setting Device Item Setting data Set by range The condition result at the completion of the instruction is stored Complete status System 0 No error Normal completion Except 0 Error code Number of reading s S1 1 ne Set the number of reading data 1 to 16 User ata 3 MOTION DEDICATED PLC INSTRUCTION Controls 1 This instruction is dedicated instruction toward the Motion CPU in the Multiple 4 6 CPU system Errors occurs when it was executed toward the CPU except the Motion CPU A part for the number of reading data of the control data specified with S1 of data since the device specified with S2 in the target CPU n1 is stored to since the word device specified with D1 of the self CPU in the Multiple CPU system Figure specification of the bit device is possible for S2 and D1 However figure specification is 4 figures and a start bit device number is only the multiple of 16 It becomes INSTRCT CODE ERROR 4004 when other values are specified If the target CPU is not instruction acceptable condition even if the S P DDWR instruction is executed it may not be processed In this case it is necessary to execute the S P DDWR instruction agai
314. struction for the Multiple CPU system which did not be correspond with operating system software of the Motion CPU was executed Confirm a program 4C05 Axis No set by CHGA instruction is injustice and correct it to a There are 33 or more instruction requests to the correct PLC Motion CPU from the PLC CPU in S P SFCS program S P SVST S P CHGA S P GINT sum table simultaneously and the Motion CPU cannot process them 4C09 CPU No of the instruction cause is injustice Note 0000H Normal The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO Note 2 e The CPU No to be set by First I O No of the target 2110 CPU 16 is specified The self CPU by First I O No of the target CPU 16 ak is specified Confirm a program 2117 The CPU except the Motion CPU by First I O No of and correct it to a the target CPU 16 is specified correct PLC The instruction is composed of devices except usable program 4004 devices 4100 Since 0 to 3DFH 3E4H by First I O No of the target CPU 16 is specified Note 0000H Normal 3 MOTION DEDICATED PLC INSTRUCTION Program example Program which changes the current value of the axis No 1 of the Motion CPU CPU No 4 from PLC CPU CPU No 1 to 10 To self CPU Cam axis within one revolution high speed current value changing flag of the axis interrupt accept No 1 CPU No 4 flag from CP
315. t box Turn PLC ready flag M2000 OFF make The initial value normal F correction and write a correct value to the E ted task task is used for control OAS Two or more fixed cycles of the event task have CPU setting is illegal b t event een se 11 11 11 ERROR CODE LISTS MEMO 11 12 APPENDICES APPENDICES APPENDIX 1 Processing Times APPENDIX 1 1 Processing time of operation control Transition instruction 1 Operation instructions Processing time of operation instructions sale Q173HCPU Q172HCPU Classifications Symbol Instruction Operation expression Unit us u Substitution 1 2 7 00 10 00 OL 2L 4L Addition HOF 4F 8F O 1 2 OL 2L 4L Subtraction F OF 4F 8F 10 25 1 2 11 75 10 35 D800 D801 D802 OL 2L 4L oO o Q T s o O N O 2 So im O oS N rg 0 ras A m 14 00 8 40 o Q i s O A T g O oo T g fee Q T g o a g O N 9 85 12 00 11 10 13 55 8 55 9 75 10 50 11 65 g fo g O N a g O K hz O Q jo nh g oO A T o O 00 TT oO Multiplication HOF 4F 8F D804F D808F 11 40 O 1 2 ia H OL 2L 4L Division HOF 4F 8F 13 85 O 1 2 9 15 D802 11 55 Remainder A OL 2L 4L 12 00 L D804L 13 45 1 7 10 Bit inversion D800 D801 8 00 co
316. t i i i i i Cam axis Current value change accept complete device D1 0 State display device D1 1 at the instruction start accept completion OFF Na Abnormal completion only j 1 i 1 i 3 f Current value change 1 f LON i 1 k Instruction start T 1 1 1 1 1 1 T Instruction accept gt completion at the Motion CPU side 1 The current value status of the cam axis within one revolution current value change can be confirmed with the cam axis within one revolution current value changing flag in the shared CPU memory of target CPU 2 S P CHGA instruction accepting and normal abnormal completion can be confirmed with the complete device D1 or status display device D2 at the completion a Complete device It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing b Status display device at the completion It is turned on off according to the status of the instruction completion e Normal completion OFF e Abnormal completion It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing 3 MOTION DEDICATED PLC INSTRUCTION Setting range 1 Setting the cam axis which execute the within one revolution current value change e cam axis to execute the within one revolution current value change set as Th t te th th lut t val h t S1
317. t by CHGT instruction is injustice program 4Cc09 CPU No of the instruction cause is injustice Note 0000H Normal The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO Note f The CPU No to be set by First I O No of the target 2110 CPU 16 is specified The self CPU by First I O No of the target CPU 16 aig is specified Confirm a program 2117 The CPU except the Motion CPU by First I O No of and correct it to a the target CPU 16 is specified correct PLC The instruction is composed of devices except usable program 4004 devices 4100 Since 0 to 3DFH 3E4H by First I O No of the target CPU 16 is specified Note 0000H Normal 3 MOTION DEDICATED PLC INSTRUCTION SESE SS SS SSS Program example Program which changes the torque limit value of the axis No 1 of the Motion CPU CPU No 4 from PLC CPU CPU No 1 to 10 To self CPU high speed interrupt accept flag from CPU U3E3 M100 G48 0 M SP CHGT H3E3 J1 K10 mo Do MO M1 eae M1 3 MOTION DEDICATED PLC INSTRUCTION 3 7 Write from The PLC CPU to The Motion CPU S P DDWR PLC instruction S P DDWR na Usable devices i S Internal devices MELSECNET 10 Special Ca l Bit Indirecty pecia Index Sz System User File of direct JO O_ function Constant Bo digit specified register Othe
318. t gt Indicated only if setting is done by system Motion CPU When set Main process Set during each main processing free time processing of the CPU Initial process Set only during initial processing when power supply is turned ON or when executed the reset Status change Set only when there is a change in status Error Set when error is occurred Request Set only when there is a user request Special reray etc Operation cycle Set during each operation cycle of the Motion CPU 1 OVERVIEW Table 2 1 Special relay list Se O S a en sel OFF Normal Turn on when there is one or more output modules control M9000 Fuse blown detection ON Fuse blown module of self CPU which fuse has been blown detected Remains on if normal status is restored e Turn on if a momentary power interruption of less than OFF AC DC DOWN 20 ms occurred during use of the AC power supply not detected module and reset by turning power off to on M9005 AC DC DOWN detection ON AC DC DOWN e Turn on if a momentary power interruption of less than detected 10 ms occurred during use of the DC power supply module and reset by turning power off to on e Turned on when the voltage of the external battery reduces to less than specified value Turn off when the OFF Normal voltage of the external battery becomes normal ON _ Battery low e Synchronizes with BAT LED S Occur an error e Check the voltage of the external battery
319. t notice
320. ta Description Data type First I O No of the target CPU 16 16 bit n1 Value to specify actually is the following N binary CPU No 2 3E1H CPU No 3 3E2H CPU No 4 3E3H Axis No Jn N to execute the current value change Q173HCPU J1 to J32 Q172HCPU J1 to J8 S1 Synchronous encoder axis No En to execute the current value change Character Q173HCPU E1 to E12 Q172HCPU E1 to E8 sequence Cam axis No Cn to execute the within one revolution current value change Q173HCPU C1 to C32 Q172HCPU C1 to C8 32 bit S2 Setting of the current value to change inary Complete devices D1 0 Device which make turn on for one scan at accept completion of instruction D1 1 Device which make turn on for one scan at accept abnormal completion of instruction D1 0 also turns on at the abnormal completion 16 bit D2 Device to store the complete status binary Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration Note 2 n shows the numerical value which correspond to axis No Q173HCPU Axis No 1 to No 32 n 1 to 32 Q172HCPU Axis No 1 to No 8 n 1 to 8 3 16 3 MOTION DEDICATED PLC INSTRUCTION When an axis No Jn was specified with S1 Controls 1 This instruction is dedicated instruction toward the Motion CPU in the Multiple CPU system Errors occurs when it was executed toward the CPU except the Motion CPU The current value change of axis
321. ta conversion file Note 1 32 axes only svcampr4 bin Note 1 svcampr2 bin Note 1 svcamprm bin svcampr3 bin Note 1 Backup data file svbackup9 bin svbackup10 bin Motion register file modevice bin Device memory file devmem bin Device setting screen devset inf information file Q series PLC param wpa common parameter file Optional data monitor setting file svsysmon bin Communication setting information file communi inf Program editing temporary directory Note 2 The above two files are always updated simultaneously Motion SFC control parameter setting information files Internal code files of servo program KO to K4095 file size is fixed length Automatic numbering setting information files CPU type information files System setting data information files High speed read setting information files Optinal data monitor information files Axis data fixed home position return JOG operation parameter block information files Servo parameter information files Limit switch setting data information files Mechanical system program edit information files page 1 to 8 Mechanical system program edit information files page 9 to 16 Mechanical system program edit information files page 17 to 24 Mechanical system program edit information files page 25 to 32 File after conversion of mechanical system pro
322. tatus is stored in the following format B15 B12B11 B8 B7 B4 B3 T T T T T T T 3 1 CPU switch status 0 RUN 1 STOP D9200 State of switch State of CPU switch 2 L CLR S Main processing 2 Memory card switch Always OFF 3 Dip switch B8 through B12 correspond to SW1 through SW5 of system setting switch 1 0 OFF 1 ON B13 through B15 is not used e Information concerning which of the following states the LEDs on the CPU are in is stored in the following bit patterns O is off 1 is on and 2 is flicker B15 B12B11 B8 B7 gt 5 RUN 5 BOOT S Change status ERROR 6 No used M RUN 7 No used BAT ALARM 8 MODE Bit patterns for MODE 0 OFF 1 Green 2 Orange D9201 State of LED State of CPU LED 1 2 3 4 1 OVERVIEW MEMO 2 STRUCTURE OF THE MOTION CPU PROGRAM 2 STRUCTURE OF THE MOTION CPU PROGRAM Motion CPU programs is created in the Motion SFC of flowchart format The motion control of servomotors is performed using the real mode servo programs specified by motion control steps in a Motion SFC program in SV13 SV22 real mode Virtual servomotors in a mechanical system program are controlled using the virtual mode servo programs specified by motion control steps so as to enable synchronous control 2 in SV22 virtual mode Refer to the documents below for the details of Motion SFC programs motion control in real mode and motion control in virtual mode
323. te 2 peee a Bit devices R Es EEEE o po ee eee oT The device No cannot 2 L Note 2 Specify a multiple of 16 as the device number of bit data Note 3 PX and PY cannot be set 4 Adjust an executive task the number of transfer word referring to the operation processing time so that this instruction may not obstruct the execution of the motion operation because processing time becomes long in argument to the number of words n to be written 5 The following analogue modules can be used as the control module of Motion CPU Q62DA Q64AD Q64DA e Q68ADV e Q68DAV Q68ADI Q68DAI Errors 1 An operation error will occur if Number of words n to be written is outside the range of 1 to 256 Motion CPU cannot communicate with intelligent function module special function module at the instruction execution Abnormalities of the intelligent function module special function module were detected at the instruction execution I O No s specified with D1 differ from the intelligent function module special function module controlled by the self CPU The address specified with D2 is outside the buffer memory range First device No S which writing data are stored number of words n to be written is outside the device range S is a bit device and device number is not a multiple of 16 PX PY is set in S to S n 1 5 OPERATION CONTROL PROGRAMS SSS ES SSSSSSSSSSSSSSSSSSSSSSS_L_g Program exam
324. te of waiting for the step until the completion of completion of condition for Gn condition for program that the The conditional sentences of online change was made program to write are except the TIME instruction e Online change of the Gn e After completion of online change program including the TIME Gn is ended regardless of the instruction is executed in the waiting time of TIME instruction state of waiting for the and the next step is executed completion of condition for Gn e Online change of the Gn e After execution of servo program program during the servo the program of changed Gn is program execution for Kn executed 10 USER FILES 3 When the servo program editor screen Store is used Online change of the servo program during edit is executed by selecting the Store key Online change is possible to the servo program during execution A program that the online change was made is executed at the next servo program start Servo Program Editor K10_ Real x Command Set Program No Previous No Next No el e era Santen a l 100 PLS 200 PLS sec lt lt Add Delete gt gt ica 200 sizl Used Steps 4 Program Steps 4 Total Steps 14334 e Store Key Instruction Details Mode Allocation Sort Direct setting nm Commanded speed setting range 0 01 to 6000000 00 mm min linch degree 0 001 to 600000
325. than the above to specify the device No indirectly describe it in two blocks as shown below DO SHORT ASIN 0F WO D0 5 OPERATION CONTROL PROGRAMS 5 3 Constant Descriptions The constant descriptions of the 16 bit integer type 32 bit integer type and 64 bit floating point type are shown below 16 Bit integer type 32 Bit integer type 64 Bit floating point type Decimal K 1 79E 308 to K 2 23E 308 ecima K 32768 to K32767 K 2147483648L to K2147483647L KO 0 representation K2 23E 308 to K1 79E 308 Hexadecimal i H0000 to HFFFF HOOOOOOOOL to HFFFFFFFFL representation 1 The 32 bit integer type is ended by L and the 64 bit floating point type is provided with a decimal point and exponent part E to denote their data types explicitly 2 The constant without the data type is regarded as the applicable minimum type 3 The constant in decimal representation is headed by K and the one in hexadecimal representation by H K can be omitted 4 The 64 bit floating point type cannot be represented in hexadecimal 5 OPERATION CONTROL PROGRAMS FIFS 5 4 Binary Operations 5 4 1 Substitution DS Number of basic steps Usable data Usable Data Setting 64 bit 64 bit Bit Comparison bi bi bi bi Calculati data Bit device 16 bit Seu floating Coasting ae Sakis floating metas a conditional conditional i i i i expression integer integer a timer integer integertype oint 3 expression expr
326. the Motion CPU it is necessary to take an interlock by user program because there is no flag which can distinguish the axis starting in the PLC CPU Start accept flag M2001 to M2032 of the motion devices or positioning start completion flag M2400 20n is used as the interlock condition 6 Itis necessary to take an inter lock by the start accept flag of the shared CPU memory so that multiple instructions may not be executed toward the same axis of the same Motion CPU No Operation PLC program S P SVST execution S P SVST instruction To self CPU high speed interrupt accept flag from CPUn OFF Start accept flag axis Servo program Servo program execution LON i Instruction start accept complete device D1 0 State display device D1 1 at the instruction start accept completion Instruction accept completion at the Motion CPU side 3 MOTION DEDICATED PLC INSTRUCTION 1 The start accept status of each axis can be confirmed with the start accept flag in the shared CPU memory of target CPU 2 S P SVST instruction accepting and normal abnormal completion can be confirmed with the complete device D1 or status display device D2 at the completion a Complete device It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing b Status display device at the completion It is turned on off acc
327. the self CPU The address specified with D2 is outside the buffer memory range First device No S which writing data are stored number of words n to be written is outside the device range Error Processing Error factor Error code Corrective Action Correct the program so that the number of words n to be written is within the range of 1 to 256 Replace the intelligent function module special function module if there is a fault Correct the program so that the first I O No s specified with D1 is intelligent function module special function module controlled by the self CPU e Correct the program so that the address specified with D2 is within the buffer memory range Correct the program so that first device No S which writing data are stored number of words n to be written is within the device range e S is a bit device and the device number is not e When S is a bit device set the device a multiple of 16 number to be multiple of 16 e PX PY is set in S to S n 1 e When S is a bit device do not set PX PY Number of words n to be read is outside the Correct the program so that the number of The block processing in execution is stopped and the next block is executed Read device data from intelligent function module special function module FROM execution error range of 1 to 256 Motion CPU cannot communicate with intelligent function module special functi
328. tice Note 0000H Normal 3 MOTION DEDICATED PLC INSTRUCTION The error flag SMO is turned on an operation error in the case shown below and an error code is stored in SDO 2110 The CPU No to be set by First I O No of the target CPU 16 is specified AT The self CPU by First I O No of the target CPU 16 is specified Confirm a program 2117 The CPU except the Motion CPU by First I O No of and correct it to a the target CPU 16 is specified correct PLC 4004 The instruction is composed of devices except usable program devices 4100 Since 0 to 3DFH 3E4H by First I O No of the target CPU 16 is specified Program example Note 0000H Normal Program which changes the current value of the axis No 1 of the Motion CPU CPU No 4 from PLC CPU CPU No 1 to 10 To self CPU Start accept flag high speed of the axis No 1 interrupt accept CPU No 4 flag from CPU U3E3 U3E3 G516 0 M100 G48 0 i vi SP cHGA H3E3 J1 K10 mo Do MO M1 e M1 3 MOTION DEDICATED PLC INSTRUCTION When an axis No En was specified with S1 Controls 1 This instruction is dedicated instruction toward the Motion CPU at the Multiple CPU system Errors occurs when it was executed toward the CPU except the Motion CPU The synchronous encoder axis current value specified with S1 is changed into the current value specified S2 at the virtual mode This instruc
329. tion Current Value Change Control SV22 only 7 20 TO Programming INStructions aei ene a E tag ated Maegan a eingiag la 7 22 Del Ganieell E A E E E E N ea E EE E E EA E E EE E ESE E T EE wares 7 22 7 5 2 Indirect designation using motion GEVICES ee eceeeeeeeeeereeeeeteeeeeeeteeeteeeteeeseneseeeseeeseneseaeseneseaneaetenes 7 22 8 MOTION DEVICES 8 1 to 8 6 8 1 Motion Registers 0 to 8191 cece ce eeeeeeeeeeceteeeeeeeseeeneseseneneeeeeedueseseeeeeeeedeeseeeeeedeeeteedeedeneediees 8 1 8 2 Coasting Timer Fl eis cited heat tebe Ea EEA ee dee ceed ele EEA RAEE AEN 8 6 9 MOTION SFC PARAMETER 9 1 to 9 18 9 1 Task Definitions nucenou aaa Abie lade al de dati headed ded ede 9 1 9 2 Number of Consecutive Transitions and Task Operation c ccsccceeeeeeeeeeeeeeeeeeeeeeeeaeeteaeeteneeesnneetaes 9 2 9 2 1 Number of consecutive transitions eee cece cece eeeeeeeeeeeeeeeeteeeeeeeseeeseeseeeseeeseeeseeeseeeseaeseaeeaeeeneeeaes 9 2 9 22 Taskoperation rs he teee cde ca erect tte ate tat cd co ae ade ee ea ea ee od ee te tena a Seas 9 3 9 3 Execution Status of The Multiple Task cc ccccscceeeceeeceeeeneeeeeeeeeaeeeeaeeesaceeseneeseaeescaeesceeesiaeeseeeteeessaees 9 7 9 4 Task Parameters ae tits bilan eA A ARMA AMAR Me aA ananAL 9 8 9 5 Program Parameters cecceecccccesseeeeeeeeeeseeeeeeeseeseesaeeeaeeeaeeeaeesaeesaeesaeesaeesaeesaeesaeesaeesaeesaeeaeeseeseeseeeateeas 9 10 9 6 How to Start The Motion SFC
330. tion Data type of result Do Bit data for device set Bit logical type Condition data which determines whether device S true false set will be performed or not 1 If the data specified with S is true the bit data specified with D is set Functions 2 S can be omitted At this time the format is SET D and device set is made unconditionally 3 When this instruction is set as a transition condition in the last block of a transient program whether the data specified with S is true or false is returned as logical type data In this case S cannot be omitted Errors 1 An operation error will occur if e D or S is an indirectly specified device and its device No is outside the range 5 OPERATION CONTROL PROGRAMS Program examples 1 Program which sets M100 when either of MO and X0 is 1 SET M100 MO XO vo 0 M100 True xo 2 Program which sets M100 when 0 is equal to DO SET M100 0 DO m M100 True Do 3 Program which sets YO unconditionally n m 4 lt oO vo C7 5 OPERATION CONTROL PROGRAMS FIFS 5 9 2 Device reset RST RST D S Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit a 16 bit 32 bit Df Calculation a pe floating Coasting floating conditional conditional integer integer i integer integer type expression f poi
331. tion is always effective regardless of the state of real mode virtual mode mode switching when the operating system software of Motion CPU is V22 S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P CHGA instruction When the Motion dedicated PLC instruction is started continuously It is necessary to take an interlock by the to self CPU high speed interrupt accept flag from CPUn When the servo program is executed also at the motion control step Kn in the Motion CPU it is necessary to take an interlock by user program because there is no flag which can distinguish the axis starting in the PLC CPU Synchronous encoder current value changing flag M2101 to M2112 of the motion devices is used as the interlock condition in the Motion CPU It is necessary to take an interlock by the current value changing flag of the shared CPU memory so that multiple instructions may not be executed toward the same synchronous encoder axis of the same Motion CPU No The current change value is also possible when the servo program which execute the CHGA instruction toward the synchronous encoder axis is executed in the S P SVST instruction 3 MOTION DEDICATED PLC INSTRUCTION Operation PLC program S P CHGA instruction To self CPU high speed interrupt accept flag from CPUn Start accept flag encoder axis Current value change Current
332. tional conditional integer integer i integer integer type expression f point expression expression type type L type K H K H L type K GE a ae DS ae a aL es ee ec ee ee a el ee ee ee ee ee ee O Usable Setting data Data type of result Setting data S1 Dividend data Data type of S1 or S2 S2 which is greater Functions 1 The data specified with S1 is divided by the data specified with S2 to find a quotient 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before operation is performed Errors 1 An operation error will occur if e S2 is 0 or e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which divides K456 by 0 and substitutes a quotient to WO WO K456 0 456 wos 0 123 2 Program which divides 0F by 10 and substitutes a quotient to DOL DOL 0F 10 3 2 1 0 12345 789 D1 DO wo 100 3722683 o 723 The 64 bit floating point type data are used for division and the quotient is converted into the 32 bit integer type and then substituted 5 15 5 OPERATION CONTROL PROGRAMS FIFS 5 4 6 Remainder S1 S2 Number of basic steps Usable data Usable Data Setting 64 bit i 64 bit Bit Comparison data Bit device 16 bit aa f
333. to be read is outside the range of 1 to 256 The shared CPU memory first address S2 of the data which it will be read is outside the range OOOH to FFFH of the shared CPU memory address The shared CPU memory first address S2 of the data which it will be read number of words n to be read is outside the range O00H to FFFH of the shared CPU memory address First device No D which stores the reading data number of words n to be read is outside the device range Except 3E0H 3E1H 3E2H 3E3H is set at S1 The self CPU is specified with S1 The CPU which reads is resetting The errors are detected in the CPU which read D is a bit device and device number is not a multiple of 16 PX PY is set in D to D n 1 5 OPERATION CONTROL PROGRAMS SSS SS SSS Program examples 1 It checks that a CPU No 1 is not resetting 2 words is read to since 0 from the shared CPU memory COOH of CPU No 1 and transits to next step after reading completion GO IM9240 FO RST M9216 MULTR 0 H3E0 HCOO K2 GO M9216 Device memory Shared CPU memory sof 100 Zwords transfer COOH 1 1 200 CO1H 200 5 OPERATION CONTROL PROGRAMS FIFS 5 13 8 Write device data to intelligent function module special function module TO TO D1 D2 S n Number of basic steps Usable data Usable Data Bit device Setting data 64 bit 64 bit Bit Comparison 16 bit 32 bit 7 16 bit 32 bit oF Calculation a pe floatin
334. to start Character Q173HCPU J1 to J32 Q172HCPU J1 to J8 sequence S1 16 bit S2 Servo program No to start binary Complete devices D1 0 Device which make turn on for one scan at accept completion of instruction Bit D1 1 Device which make turn on for one scan at accept abnormal completion of instruction D1 0 also turns on at the abnormal completion binary Note 1 Motion CPU cannot used CPU No 1 in the Multiple CPU configuration Note 2 n shows the numerical value correspond to axis No Q173HCPU Axis No 1 to No 32 n 1 to 32 Q172HCPU Axis No 1 to No 8 n 1 to 8 3 MOTION DEDICATED PLC INSTRUCTION Controls 1 This instruction is dedicated instruction toward the Motion CPU in the Multiple CPU system Errors occurs when it was executed toward the CPU except the Motion CPU 2 Request to start the servo program specified with S2 3 This instruction is always effective regardless of the state of real mode virtual mode mode switching when the operating system software of Motion CPU is SV22 4 S P SFCS S P SVST S P CHGA S P CHGV S P CHGT S P DDRD S P DDWR cannot be executed simultaneously toward the CPU executing S P SFCS instruction When the Motion dedicated PLC instruction is started continuously It is necessary to take an interlock by the to self CPU high speed interrupt accept flag from CPUn 5 When the servo program is executed also at the motion control step Kn in
335. tomer and Mitsubishi is not liable for on site adjustment or test run of the product 5 Precautions for Choosing the Products 1 These products have been manufactured as a general purpose part for general industries and have not been designed or manufactured to be incorporated in a device or system used in purposes related to human life 2 Before using the products for special purposes such as nuclear power electric power aerospace medicine passenger movement vehicles or under water relays contact Mitsubishi 3 These products have been manufactured under strict quality control However when installing the product where major accidents or losses could occur if the product fails install appropriate backup or failsafe functions in the system 4 When exporting any of the products or related technologies described in this catalogue you must obtain an export license if it is subject to Japanese Export Control Law MOTION CONTROLLER Qseries SV13 SV22 Motion SFC Programming Manual Q173HCPU Q172HCPU sfa MITSUBISHI ELECTRIC CORPORATION HEAD OFFICE TOKYO BUILDING 2 7 3 MARUNOUCHI CHIYODA KU TOKYO 100 8310 JAPAN MODEL Q173H P SV13 22 SFCE MODEL CODE 1XB912 When exported from Japan this manual does not require application to the IB NA 030011 2 B 0609 MEE Ministry of Economy Trade and Industry for service transaction permission IB NA 0300112 B 0609 MEE Specifications subject to change withou
336. tor F n read error 11 9 11 ERROR CODE LISTS Table 11 5 Operation control transition execution errors 16300 to 16599 continued Error factor i Error code lt Error Processing Indirectly specified 16 bit batch input relay X n read error Corrective Action Indirectly specified 32 bit batch input relay X n read emor e The indirectly specified device No is outside f i the range or is not a multiple of 16 Indirectly specified 16 bit batch output relay Y n read error The block processing in Correct the program so that the indirectly execution is stopped and the specified device No is proper next block is executed Indirectly specified 32 bit batch output relay Y n read error Indirectly specified 16 bit batch internal latch relay The indirectly specified device No is outside M n L n read the range or is not a multiple of 16 error Indirectly specified 32 bit batch internal latch relay M n L n read error Indirectly specified 16 bit batch internal latch relay B n read error Indirectly specified 32 bit batch internal latch relay The block ing i B n read error e The indirectly specified device No is outside 9 S OCF PrOPSSSINg N Correct the program so that the indirectly tion is st d and th Indirectly specified the range or is not a multiple of 16 PAE E SOPPOR specified device No is proper X next block is executed 16 bit batch annunciator
337. truction List continued Positioning data no j 2 Dwell time Auxiliary point Central point Instruction symbol Processing Parameter block No Address travel value Command spee Torque limit value Positioning control Virtual enable eel el Rom Ree era tea ed Eon en ea Red Number of steps ay Speed control with fixed position stop fafofofofafal ff PVF absolute specification PVR Oii p ha TON ack aa falofofo fal ale k ee a a CPSTART1 axis constant speed control start e erena abel lol 1 sein a alo fot Reverse Forward rotation position stop rotation control with fixed Position follow up control 4 axes constant speed control start Lalo ABS 3 J gt Ww ve A gt ius n k Constant speed control passing point absolute specification allele HBE gt ius no Constant speed contro gt ivy n 2 gt jes n 7 gt W ak Constant speed control passing point helical absolute specification alal HEL gt W I G 7 MOTION CONTROL PROGRAMS Positioning data ok it Starting angle Amplitude Frequency Reference axis No Control un Speed limit value Acceleration time Deceleration time Torque limit value at stop input interpolation S curve ratio Repeat condition Program No Command speed WAIT ON OFF deceleration time Fixed position stop Nu
338. ts 64 points M3200 Axis command signal Axis command signal 20 points x 32 axes to 20 points x 32 axes Real mode Each axis Virtual mode Output module M3840 Unusable Note 1 160 points Virtual servomotor axis status Note 1 2 20 points lt 32 axes Mechanical system setting axis only 960 points Synchronous encoder axis status Note 2 4 points X 12 axes to User device Unusable Note 1 112 points 1 12 1 OVERVIEW to e Overall configuration Continued SV13 SV22 User device 3392 points Virtual servomotor axis command signal Note 1 2 20 points lt 32 axes Mechanical system setting axis only Synchronous encoder axis command signal Note 2 4 points X 12 axes Cam axis command signal Note 1 2 1 point x 32 axes Mechanical system setting axis only Smoothing clutch complete signal Note 1 2 2 points X 32 axes Unusable Note 1 16 points User device 2592 points Note 1 It can be used as an user device in the SV22 real mode only Note 2 Do not set the M4000 to M5599 as a latch range in the virtual mode 1 13 1 OVERVIEW 1 Table of the axis statuses SV13 SV22 M2400 M2720 to Axis 1 status to Axis 17 status M2419 M2739 M2420 M2740 to Axis 2 status to Axis 18 status M2439 M2759 M2440 M2760 to Axis 3 status to Axis 19 status M2459 M2779 M2460 M2780 to Axis 4 status to Axis 20 status M2479
339. turn request Te 10 IS 4 10 ie d i a0 PLS s q 600000000 mm min 600000000 inch min 2147483647 pe 10000000 Note 1 When the speed control 10 X multiplier setting for degree axis is set to valid in the fixed parameter the unit is lt 10 degree min b Virtual mode e request 10000000 10000000 5 The speed changed by CHGV instruction is effective only on the servo program during starting 6 The speed change does not executed for the axis specified with S1 during deceleration stop 5 OPERATION CONTROL PROGRAMS 7 By specifying a negative speed and making a speed change request during the start allows the axis to start deceleration at that point and return in the opposite direction upon completion of deceleration The following operations by the servo instruction are shown below Control mode ABS 1 LINC 1 ABS 2 INC 2 On completion of deceleration the axis Linear control reverses its moving direction returns to the ABS 3 LINC 3 positioning starting point at the absolute value of the specified speed and stops waits there Circular interpolation INC crower For circular interpolation the axis returns in ABS circular INC circular the circular path Fixed pitch feed FEED 1 FEED 2 FEED 3 On completion of deceleration the axis CPSTART1 CPSTART2 reverses its moving direction returns to the CPSTART3 CPSTART4 preceding point at the abso
340. uction part Indicates the function of that instruction e Data part Indicates the data used in the instruction Substitution structure example DO 0 Data part Source S Instruction part Data part Destination D a Source S 1 The source is the data used in an operation 2 It varies with the device specified in each instruction is shown below e Bit or word device Specify the device which stores the data used in operation The data must have been stored in the specified device until the operation is executed Changing the data stored in the specified device during program execution allows changing the data used in that instruction Constant Specify the numerical value used in an operation As the constant is set during program creation it cannot be changed during program running b Destination D 1 As the destination data after operation data is stored 2 Destination data is always set the device for storing the data 5 OPERATION CONTROL PROGRAMS 4 How to specify data There are the following six different data usable in each instruction Data usable in each instruction Numerical data Integer data 16 bit integer type data 32 bit integer type data 64 bit floating point type data Bit data Batch bit data Logical data a 16 bit integer type data The 16 bit integer type data is 16 bit integer value data Word devices are used in increments of 1 point Data ranges ar
341. ultaneously active steps 16120 active step count i maximum 256 Re examine the Motion SFC exceeded 256 during execution excess program Table 11 4 Motion SFC program run errors 16200 to 16299 Error factor i 3 Error code a Error Processing Corrective Action No specified The servo program Kn specified with the 16200 p pied Knysp Create the specified servo program program Kn motion control step does not exist No specified The operation control program Fn FSn yi 3 fa J Create the specified operation control 16201 program specified with the operation control step does Fn FSn not exist Program N ified S PERNS The program Gn specified with the transition y i 16202 program i Create the specified transition program Gn does not exist No specified Li Correct the specified Motion SFC program The Motion SFC ified with th 16203 program eae Bee eee s name or create the specified Motion SFC clear step does not exist Motion SFC Stop to execute the program No setting of applicable Motion SFC The program Gn specified with the transition N Met aan 16204 operation does Not havea conditional expression program No Be sure to set a conditional expression in 4 For the subroutine called the last block of the transition program expression condition tti setting al expression 9 program the call source program also stops to 16205 Fn FSn program Internal code error in the operati
342. uter Program memory Programming software Program No 0 Program No 0 Program No 2 Program No 2 Program transfer Program No 5 Program No 5 Program No 6 Program No 6 Program No 100 Program No 100 Free area 2 Program writing by the Online change a After online change a program to execute the online change is stored in the free area after the program stored previously Refer to 1 After that the program written in previously is made invalid and the new program is made valid Refer to 2 Motion CPU Personal computer Program memory Programming software Program No 0 Program No 0 Program No 2 Program No 2 FProgram No 5 2 Program No 5 Program No 6 Program No 6 Program No 100 Program No 100 1 Program No 5 lt Free area 10 7 10 USER FILES b If the online change is executed repeatedly the free space in program memory is lost and the online change may not be executed In this case an error message is displayed by SW6RN GSVDP at the online change and Online change OFF is set Motion CPU Personal computer Programming software Program memory Program No 0 ProgramNo 2 _ P regranNe 5 Program No 6 Program No 0 Program No 2 xX Online change setting cannot be executed because there is no fre
343. ution error Read device data from shared CPU memory of the other CPU MULTR execution error Number of words n to be written is outside the range of 1 to 256 The shared CPU memory address D of self CPU of the writing destination device is outside the range 800H to FFFH of the shared CPU memory address The shared CPU memory address D of self CPU of the writing destination device number of words n to be written is outside the range 800H to FFFH of the shared CPU memory address First device No S which writing data are stored number of words n to be written is outside the device range MULTW instruction was executed again before MULTW instruction is executed and complete bit device is turned on D1 is a write disabled device S is a bit device and the device number is not a multiple of 16 PX PY is set in S to S n 1 Number of words n to be read is outside the range of 1 to 256 The shared CPU memory first address S2 of the data which it will be read is outside the range 000H to FFFH of the shared CPU memory address The shared CPU memory first address S2 of the data which it will be read number of words n to be read is outside the range 000H to FFFH of the shared CPU memory address First device No D which stores the reading data number of words n to be read is outside the device range Except 3E0H 3E1H 3E2H 3E3H is set at S1 The self CPU is specif
344. value change ON l Instruction start accept complete device D1 0 State display device D1 1 at the instruction start accept completion Setting range Instruction accept gt completion at the Motion CPU side 1 The current value status of the synchronous encoder axis can be confirmed with the current value changing in the shared CPU memory of target CPU 2 S P CHGA instruction accepting and normal abnormal completion can be confirmed with the complete device D1 or status display device D2 at the completion a Complete device It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing b Status display device at the completion It is turned on off according to the status of the instruction completion e Normal completion OFF e Abnormal completion It is turned on by the END processing of scan which the instruction completed and turned off by the next END processing 1 Setting of the synchronous encoder axis to execute the current value change The synchronous encoder axis to execute the current value change set as S1 sets E synchronous encoder axis No in a character sequence _ St usabie range Q173HCPU 1 to 12 Q172HCPU 3 MOTION DEDICATED PLC INSTRUCTION The number of axes which can set are only 1 axis The axis No set in the system setting is used as the axis No to start Refer to the Q173HCPU Q172HCP
345. vice range of shared CPUmemory address Correct the program so that the shared CPU memory first address S2 of the data which it will be read number of words n to be read is within the range of shared CPU memory address Correct the program so that first device No D which stores the reading data number of words n to be read is within the device range Correct the program so that 3E0H 3E1H 3E2H 3E3H is set at S1 Correct the program so that the self CPU is not specified with S1 Check that the reset flag M9240 to M9243 is OFF then correct the program to execute the MULTR instruction If the errors are detected in the CPU which read exchange the CPU e When D is a bit device set the device number to be multiple of 16 e When D is a bit device do not set PX PY 11 ERROR CODE LISTS Table 11 5 Operation control transition execution errors 16300 to 16599 continued Write device data to intelligent function module special function module TO execution error Number of words n to be written is outside the range of 1 to 256 e Motion CPU cannot communicate with intelligent function module special function module at the instruction execution e Abnormalities of the intelligent function module special function module were detected at the instruction execution I O No s specified with D1 differ from the intelligent function module special function module controlled by
346. vice reset APP 3 APPENDICES Processing time of operation instructions Continued ee A F 3 Q173HCPU Q172HCPU Classifications Symbol Instruction Operation expression Unit us u SET M1000 0 13 35 SET M1000 D800 D801 13 75 SET M1000 0L 2L 14 75 Equal to SET M1000 D800L D802L 14 00 SET M1000 0F 4F 14 20 SET M1000 D800F D804F 15 30 SET M1000 0 1 13 00 SET M1000 D800 D801 14 25 SET M1000 0L 2L 14 30 Not equal to SET M1000 D800L D802L 14 80 F SET M1000 0F 4 14 00 SET M1000 D800F D804F 15 50 SET M1000 0 lt 1 14 00 SET M1000 D800 lt D801 14 50 SET M1000 0L lt 2L 14 20 Less than SET M1000 D800L lt D802L 14 90 APP 4 APPENDICES Processing time of operation instructions Continued ee Q173HCPU Q172HCPU Classifications Symbol Instruction Operation expression Unit us u SET M1000 0 gt 1 14 25 SET M1000 D800 gt D801 22 50 SET M1000 0L gt 2L 21 25 More than SET M1000 D800L gt D802L 16 70 SET M1000 0F gt 4F 14 70 SET M1000 D800F gt D804F 16 75 SET M1000 0 gt 1 13 00 SET M1000 D800 gt D801 14 00 SET M1000 0L gt 2L 13 85 More than or equal to SET M1000 D800L gt D802L 14 25 SET M1000 0F gt 4F 15 00 SET M1000 D800F gt D804F 15 30 CHGV K1 0 13 55 CHGV K1 D800 14 20 Speed change request CHGV K1 0L 13 85 CHGV K1 D800L 14 05 CHGT K1 0 Torque limit value change CHGT K1 D800 7 80 r
347. vo program setting error flag M9079 turns on the error code information program corresponding to the erroneous setting item will be stored e The loading status loading 1 non loading 0 of the servo amplifier checked in initial process and stored as the bit data Servo amplifier D9191 b0 to b15 axis 1 to axis 16 Servo amplifier i P as D loading loading infomation D9192 b0 to b15 axis 17 to axis 32 S Initial processing information 9 The axis which turned from non loading to loading status after power on is handled as loaded However the axis which turned from loading to non loading status remains as loaded Real virtual mode Real virtual mode e When a mode switching error occurs in real to virtual or virtual to real switching error Switching mode switching or a mode continuation error occurs in the virtual mode information error code its error information is stored The following error code is stored 00 No error 01 Receiving timing error PC link PC link 02 CRC error communication communication error 03 Communication response code error S Occur an error error codes codes 04 Received frame error 05 Communication task start error Each error code is reset to 00 when normal communication is restarted Operation cycle Operation cycle of the Motion of the Motion CPU The time when the setting operation cycle is stored in the ys unit S Initial processing CPU setting setting The CPU switch s
348. when it was SET M3223 PX6 1M3222 described as the following in the case of the processing RST M3223 PX6 which could be described only with SET RST because it is made low Ilis repeated to the JOG mode completion IPX1 IPX2 J F122 N eas award Ast te N Forward rotation reverse rotation JOG status of 1 2 axis is RST oneal IS Teed gt turned off at the time of the JOG mode completion not to continue a JOG movement after it moves to other mode of the RST M3203 safet RST M3222 iA RST M3223 J END e No 130 Manual pulse generator Manual pulse generator F130 D720 100 1 pulse input magnification setting of 1 axis D721 100 1 pulse input magnification setting of 2 axes D714L H00000001 P1 is controlled The setup of the following is executed to do manual pulse generator operation of P1 with 1 axis P2 with 2 axis Setting of 1 pulse input magnification of the 1 axis and 2 1 axis axis D716L H00000002 P2 is controlled z A i I2 axes Manual pulse generator axis No setting register is setup to control of P1 with 1 axis P2 with 2 axis Manual pulse generator axis enable flag of P1 P2 is turned on SET M2051 P1 Manual pulse generator Ienable flag is ON SET M2052 P2 Manual pulse generator lenable flag is ON G130 PX2 PX1 Did you complete a manual pulse generator mode a F131 RST M2051 P1 Manual pulse generator lenable
349. xis No 1 to No 32 n 0 to 31 Q172HCPU Axis No 1 to No 8 n 0 to 7 Note 2 The unused aixs areas in the mechanical system program can be used as an user device 1 41 1 OVERVIEW 6 Table of the common devices SV13 SV22 y Signal Signal Device No Signal name Device No Signal name derecrtion derecrtion D704 PLC ready flag request D740 Axis 21 Speed switching point specified fla D705 Pee een Pe es gen D741 request D706 All axes servo ON command request Real virtual mode switching request D707 SV22 JOG operation simultaneous start D708 D744 command request D7o9 unusable os JOG operation simultaneous start axis setting register Command D742 device D743 Manual pulse generators 1 pulse input magnification Axis 27 Setting register Note 1 2 to D713 Command device D714 D715 Manual pulse generator axis 1 No setting register D751 Axis 32 Manual pulse generator 1 smoothing D716 Manual pulse generator axis 2 No D752 f D717 magnification setting register setting register Manual pulse generator 2 smoothing magnification setting register Manual pulse generator axis 3 No magnification setting register D720 D721 Axis 2 Manual pulse generators 1 pulse input magnification setting register Note 1 2 D753 D718 D719 D755 Manual pulse generator 1 enable flag request D756 Manual pulse generator
350. xpression integer integer a timer integer integer type point p expression expression type type L type K H K H L type K type F ST SA e SS a e aa SE ET ES l l o l o l ee a ee I O Usable Setting data data Data type of result Data which will be compared Logical type true false Functions 1 The data specified with S1 and the data specified with S2 are compared and the result is true if they are equal 2 When S1 and S2 differ in data type the data of the smaller data type is converted into that of the greater type before comparison is performed Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which compares whether 0 and DO are equal or not 0 DO 0 True q po E o 5 OPERATION CONTROL PROGRAMS FIFS 5 11 2 Not equal to S1 2 Number of basic steps Usable data Usable Data Setting 64 bit i 64 bit Bit Comparison data Bit device 16 bit aa floating Coasting een el seme floating Calculation snditional conditional integer integer integer integer type int expression Sxpression expression type type L type K H K H L KAA ae eT a a a l o lololol olo lolol l O Usable Setting data Setting data Data type of result S1 T Data which will be compared Logical type true false Functions
351. xt lower part The start source and destination programs are executed simultaneously and the call destination program ends at END execution Scan execution type operation control step Subroutine Program name call start step Stops and ends the specified program running After an end it is started from the initial start step by restarting the program When the specified program is during subroutine call CLR rogram name the subroutine program is a99 stopped to execute Clear step Program name CLR program name When the specified program is after subroutine start the subroutine program is not stopped to execute When clearing to the subroutine by which the subroutine call was executed the specified subroutine is stopped to execute returns to the call source program and transits to the next 4 MOTION SFC PROGRAMS Symbol Classification Name List representation Function Code size byte When just before is the motion control step transits to the next step by formation of transition condition Gn GO to G4095 without waiting for the motion operating completion Shift When just before is the operation control step transits Pre read to the next step by the completion of transition transition condition after operating execution When just before is subroutine call or starting step transits to the next step by formation of transition condition with
352. y no conditions to be set as interlocks set NOP No Operation in the transition program Gn 4 MOTION SFC PROGRAMS 4 9 2 Selective branch selective coupling 1 Selective branch Executes only the route which condition was judged to have enabled first among the conditions of multiple transitions connected in parallel Transitions must be all Shifts or WAITs Example WAIT After start axis in the servo K1 Starts the servo program K1 program K1 has stopped start accept flag turns OFF the conditions of transitions G1 to E See A G255 are judged and execution transits to route which condition is completed Max number of selective branches 255 1 Transition condition judgment is not always executed from left to right 2 Using Shift and WAIT together will cause a parallel branch 2 Selective coupling Recoupling of routes into a single route after their processing completions following a selective branch will be a selective coupling However you can also make a setting where no coupling will be made as shown below o ee ee e a Po Jump transition normal jump END Program END IFE2 4 MOTION SFC PROGRAMS 4 9 3 Parallel branch parallel coupling 1 Parallel branch Multiple routes connected in parallel are executed simultaneously Each parallel branch destination may be st
353. ycle over 3 Q bus WDT error 4 WDT error 30 Information processor H W error 201 to 215 Q bus H W fault 250 to 253 Servo amplifier interface H W fault 300 S W fault3 S Occur an error Error meaning of WDT error cause WDT error occures 301 15 CPSTART instructions of 8 or more points were started simultaneously e Contents of the manual pulse generator axis setting error is stored when the manual pulse generator axis setting error flag M9077 turn on Normal 0 Setting error 1 Manual pulse D9185 The manual pulse generator axis setting error is stored in bO to b2 generator axis P1 to P3 setting error The smoothing magnification setting is stored in b3 to b5 P1 to P3 information D9186 One pulse input magnification setting error is stored in bO to b15 axis 1 to axis 16 D9187 One pulse input magnification setting error is stored in bO to b15 axis 17 to axis 32 D9185 Manual pulse D9186 generator axis D9187 setting error 1 48 1 OVERVIEW Table 2 2 Special register list continued Set b Name Meaning Details ey Remark When set nee operation Motion operation A A i r A i D9188 i e The time when the motion operation cycle is stored in the ys unit S Operation cycle cycle D9189 Eror program Error program No of When the servo program setting error flag M9079 turns on the erroneous servo program servo program No will be stored S Occur an error Error item Error code of servo When the ser
354. ype expression x point expression expression type type L type K H K H L type K BISERE EAE AEA E seal l o lol l olol ol dl o l O Usable Setting data S1 Data to be right shifted Data type of S1 Integer type Functions 1 The data specified with S1 is shifted to the right by the number of times specified with S2 2 If the most significant bit of S1 is 1 1 enters the most significant bit of the right shift result If the most significant bit of S1 is 0 0 enters the most significant bit of the right shift result 3 When S1 is a 16 bit integer type and S2 is a negative number or not less than 16 the result is 0 4 When S1 is a 32 bit integer type and S2 is a negative number or not less than 32 the result is 0 Errors 1 An operation error will occur if e S1 or S2 is an indirectly specified device and its device No is outside the range Program examples 1 Program which shifts 0 two bit positions to the right and substitutes the result to DO oo PORT 40 Pomp 5 21 5 OPERATION CONTROL PROGRAMS FIFS 5 5 6 Bit left shift lt lt S1 lt lt 2 Number of basic steps Usable data Usable Data Setting 64 bit 64 bit s Bit Comparison data Bit device 16 bit Sebit floating Coasting een a seme floating Calculation snditional conditional integer integer i i integer integer type expression x point expression expression type ty

Download Pdf Manuals

image

Related Search

Related Contents

Rheem Classic Series: Up to 92% AFUE PSC Motor Multi Position Specification Sheet  Technical M anual and Replacem ent Parts List Refrigerator  FiberSim User Manual - The Information and Telecommunication  Téléchargez tout le magazine ici  FRC 2011 Sensor Manual  LG LW1213HR Specification Sheet  QUICK-START GUIDE  LG PB60G Specification Sheet  PTID-7350NRBT - Power Acoustik  VI25 User Guide  

Copyright © All rights reserved.
Failed to retrieve file