Presentation is loading. Please wait.

Presentation is loading. Please wait.

Micro Trend Automation Ltd. Programmable 4-Axis Controller UTC ® Series.

Similar presentations

Presentation on theme: "Micro Trend Automation Ltd. Programmable 4-Axis Controller UTC ® Series."— Presentation transcript:

1 Micro Trend Automation Ltd. Programmable 4-Axis Controller UTC ® Series

2 UTC400P 4-Axis Motion Controller

3 Pulse/Direction DAC FLASH 512K*8 SRAM 128K*32 TMS 320C32 16C55216C Expan Port LCM Port DIP Switch MIO Port LED Encoder Interface Digit In Port Digit Out Port Analog Input Data Address FPGA JDI JDO JAI CN1 JACC CN2 JDSP CN3 JTHW JAO Pulse/Voltage Command Line Receiver Analog Port JHW ENC A,/A,B/B,Z,/Z Encoder Feedback Driver1..4 Pulse/Direction DAC Com1 Com2 Block Diagram


5 UTC400P is a multifunctional general-purpose programmable motion controller; use the most advanced 32-bit floating-point DSP and special FPGA as its kernel. Application Field n n Sealing Machine n n Lathe Machine n n Brush Maker n n Bar Feeder n n Fly Cutter/Fly Shear n n Printing Machine n n Gilding Machine n n PC Board Maker n n Packing Machine n n Rotary Table n n Drilling Machine n n Electronic Machine n n Spring Coiling Machine n Glue Dispensing Machine n Milling Machine/Engraving Machine n Laser Cutter n Wood Cutting Machine n Stamping Machine n Grinding Machine n Press Feeder n Folding and Gluing Machine n Steel Cutting Machine n Winding Machine n Foam Cutting Machine n Injection Molding Machine

6 UTC400P Multi-Tasking Executes Motion Program UTC400P executes one move at a time, performing all calculations up to that move UTC400P is always working ahead to blend into the upcoming move UTC400P also has Spline Move capability Executes PLC Program C ontinuously scan PLCs as fast as processor time allows PLCs are useful for any task that is asynchronous to the motion

7 UTC400P Multi-Tasking ( continued ) General Housekeeping Watch Dog Timer Hardware Overtravel Limits Software Overtravel Limits Amplifier Faults Communicates with the host computer UTC400P can communicate with the host at any time, and response to any request by host. If the command is illegal, it will report an error to the host

8 UTC400P Interface n n LCD Module l l Standard LCD Module (40x2 or 20x4) l l PLC Programmable Display n UT740 / UT725 Panel l Parameters Setting l Manual / Auto Mode l Basic Function Keys n PLC Man-Machine Interface l User Defined Operation Panel l User Defined Function Key l Integer, Floating-Point Mathematics l Macro Definition

9 UT-747 UT-750 UT-735 UT-740 UT-725

10 UTC400P PC User Interface UTCSetup® Provides a windows-based operation environment that can easily connect to UTC400P. In this program, the users can : n n Issue any online commands to UTC400P n n Upload / Download motion programs and PLC programs n n Monitor motors position, I/O, and system status n n Setup motors and system parameters n n Backup card configuration


12 UTC400P Classic System Configuration Hardware System Wiring Safety Verification Parameter M-Variable Definition (SETUP.UTC) Coordinate System Definition Program User Interface, Motion Program, PLC Program Program Coding and Debug

13 UTC400P Commands 1. Online Commands A. Global Commands B. Coordinate Commands (&n …) C. Motor Commands (#n…) Modal Setting, Motor Jogging, Get Position, Set Variable Value, Buffer Control…etc. 2. Buffered Commands A. Motion Program Motor Move, Interpolation, Computation, Logic Control, Online Commands, Send Messages. B. PLC Program Computation, Logic Control, Online Commands, Send Messages.

14 UTC400P Variables Initialization and Setup I0~I99: Global System Setup Ix01~Ix49: Motor Parameter Setup Ix50~Ix70:Coordinate System Setup Ix80~Ix89: Encoder Setup 1. I-Variables General-purpose use 32-bit floating point format Usable by all programs and coordinate systems 2. P-Variables (1024)

15 UTC400P Variables (continue) General-purpose use 32-bit floating point format Coordinate system specific 3. Q-Variables (1024) 4. M-Variables (1024) Pointers to registers, I/O, A/D, D/A…etc. Can specify start bit and width Ssigned integer, unsigned integer or floating point format

16 I0Card Number I1Coordinate System Activation Control I2COM2 Baudrate Control I3COM2 Handshake Control I4Wait State Control I5Position/Velocity Response Control I6PLC Programs On/Off Control I9Maximum Digit for Floating Point Returned I10Real Time Interrupt Period I18Extension I/O Board Enable I19Digital Inputs Debounce Cycle System I-Variables

17 Ix00Motor x Activate Control Ix01Motor x Jog / Home Acceleration Time Ix02Motor x Jog / Home S-Curve Time Ix03Motor x Jog Speed Ix05Motor x Master Following Enable Ix06Motor x Master Scale Factor Ix07Motor x Homing Speed and Direction Ix08Motor x Home Offset Motor I-Variables (x = motor number (1~ 4) )

18 Ix09 – Motor x Flag Control = 0 DAC or Pulse Command Not Converted = 1 DAC or Pulse Command Converted = 0 Jog Affected by Feedrate Override = 1 Jog Not Affected by Feedrate Override = 0 Keep Current Position on Power Up = 1 Reset Current Position on Power Up = 0 Servo Disable on Power Up = 1 Servo Enable on Power Up = 0 Driver Fault is High True (Normally Close) = 1 Driver Fault is Low True (Normally Open) = 0 Driver Fault Enable = 1 Driver Fault Disable = 0 Driver Enable is Low True = 1 Driver Enable is High True = 0 Servo Enable Deactivate(Can be used as DOUT) = 1 Servo Enable Activate = 0 Limit Switch is High True (use B-type switch) = 1 Limit Switch is Low True (use A-type switch) = 0 Hardware Limit Enable = 1 Hardware Limit Disable = 0 Reset Motor Position After Home Complete = 1 Keep Motor Position After Home Complete = 0 Home Move Allowed = 1 Home Move not Allowed 01 Hex($)

19 Ix10Motor x Positive Software Limit Ix11Motor x Negative Software Limit Ix12Motor x Coordinate Position Displacement Ix13Motor x Coordinate Position Scaling Ix14Motor x Coordinate Unit Scaling Ix15Motor x Backlash Size Ix16Motor x Backlash Takeup Rate Ix17Motor x Rollover Range Ix19Motor x Velocity Weighting Ix20Motor x Proportional Gain (Kp) Ix21Motor x Derivative Gain (Kd) Ix22Motor x Velocity Feedforward Gain (Kvff) Motor I-Variables (continue)

20 Ix23Motor x Integral Gain (Ki) Ix24Motor x Integration Mode Ix25Motor x Acceleration Feedforward Gain Ix26Motor x Position Feedback Address Ix27Motor x Velocity Feedback Address Ix28Motor x Velocity Feedback Scale Ix29Motor x DAC Bias Ix30Motor x DAC Limit Ix31Motor x Fatal Following Error Ix32Motor x Dead Band Size Ix33Motor x In Position Band Ix34Motor x Big Step Size Ix35Motor x Integration Limit

21 Ix50Blended Move Enable Control Ix51Maximum Permitted Acceleration Ix52Default Program Acceleration Time Ix53Default Program S-Curve Time Ix54Default Program Feedrate Ix55Time Base Slew Rate Ix56Rapid Move Feedrate Ix57Rapid Move Acceleration Time Ix58Acceleration Mode Ix59Rotate Angle Ix60External Time Base Scale Ix61External Time Base Source C.S. I-Variables (x = c.s. number (1~ 4) )

22 Ix80Encoder x Decode Control Ix81Encoder x Capture Control Ix82Encoder x Capture Flag Control Ix83 Ix84 Ix85Master x Source Address Ix86Master x Moving Average Buffer Size Encoder I-Variables (x = encoder ch. (1~ 4) )

23 Motor Jogging Commands J+ - Jog motor in positive direction J- - Jog motor in negative direction J/ - Stop jogging motor; enable driver if disabled J= - Jog motor to variable specified position J={constant} - Jog motor to specified position J: - Jog motor variable specified distance J:{constant} - Jog motor specified distance J* - Jog motor to last programmed position Jog speed is determined by Ix03, a change in this parameter will not effect until the next jog command issued.

24 Motor Jogging Examples #1J+ - Motor 1 jog in positive direction #1J=1000 #2j+ - Motor 1 jog to count 1000 position Motor 2 jog in positive direction I103=30 - Set jog speed of motor 1 to 30 counts / msec I201=50 - Set jog acceleration time of motor 2 to 50 msec We cannot jog the motor defined in the coordinate system that is running a program. If we want to do this, we should issue a S command first to stop the motor at end of a block then jog the motor.

25 HM - Perform homing search move for motor HMZ - Declare current position to be home position Examples : #1HM – Motor 1 perform a homing search #1HM #2HM #3HM – Three motors perform homing search simultaneously. We cannot perform a home searching of a motor defined in the coordinate system that is running a program. Home Searching Commands

26 UTC400P Home Searching I-Variables Ix01Acceleration Time (unit: msec) Ix07Home Speed / Direction (unit: counts / sec) Ix08Home Offset (unit: counts) Ix09Flag Control

27 Motion Profile of Home Searching Ix02 Ix01 Ix02 Ix01 Ix02 Ix07 Home Complete=0 Home Search In Progress=1 Position Captured Trigger Occurs Net distance from trigger position Home Complete=1 Time Vel Ix02 Trigger Occurs Again Output Pulse by Pulse About 2kpps

28 Offset Trigger Occurs FL FalseOffset FL False Ix01 Ix07 Offset Ix18 Offset +Ix18 Motion Profile of Home Searching

29 P-VariablesP-Variables They are used for : 1. Calculations P100=P101*(sin(45)) 2. Software triggers IF(M1!= 1 AND P10 = 0) General-Purpose Use 32-bit Floating Point Format Global Variable (Independent with coordinate System)

30 P-Variables (continue) Suppose you wanted to move a motor along the position profile defined by SIN(q) + COS(q). You could do one of the following: Use hard-coded and pre- calculated points in a program X1 X X X X1 P1=0 WHILE (P1<361) P2=SIN(P1)+COS(P1) X(P2) P1=P1+1 ENDWHILE Use an equation to generate points on the fly OR

31 Program Calculations UTC400Ps DSP provides you the computational power to do a tremendous amount of calculations inside your motion program OPEN PROG 1 CLEAR WHILE(1=1) IF(P1>0) P2=SIN(P1)+COS(P1) p3=2 IF(P1>3) P2=SIN(P1)+COS(P1) P3=2 IF(P1>99) P2=SIN(P1)+COS(P1) p3=99 ENDIF X2000 P1=P1+1 ENDWHILE CLOSE

32 Q-Variables Memory Allocation The physical memory accessed by typing Q(number) changes according to the currently addressed Coordinate System. &1 Q0 accesses location $1400 &2 Q0 accesses location $1600 &7 Q0 accesses location $1580 &8 Q0 accesses location $1780 This kind of addressing simplifies memory management on multiple coordinate system applications. If we have 4 coordinate systems and 4 programs that uses them, all programs can use the same number variables Q0 to Q255 without redundancy therefore without memory conflicts

33 Q-Variables Memory Map

34 M-Variables Used to access UTC400P memory and I/O points Can define any start bit and width Format can be signed integer, unsigned integer and floating point Address- Memory address, range 0000-FFFF Type- 0: Dont point to any address 1: Point to data area, DP = 00 2: Point to I/O area, DP = FF Start Bit- Starting bit of the word to be used, range 0-31 Width- Number of bits of the word to be used, range 0-31 Sign- 1: Signed integer format 0: Unsigned integer format Bit 31- 0: The word to be used is integer 1: The word to be used is floating point Address Type Start Bit Width Sign

35 M-Variable Definition Mxx->* Dont point to any address (can be used as signed integer) Mxx->addr[,start][,width][,s] Point to data area (integer) Mxx->L:addr Point to data area (32-bit floating point) Mxx->I:addr[,start][,width][,s]Point to I/O area Mxx-> Report current M-variable definition Defining M-Variables: M0->536,S Point to Interrupt Counter M1->14,16,1 Point to Machine Output 1 M19->I:FF41,16,8Point to Machine Input 1-8 M102->AA,S Point to #1 Command Velocity Using M-Variables M1 = 0 Turn on Machine Output 1 M9 = 45 Turn on Machine Outputs 1,3,4,6 and turn off Machine Outputs 2,5,7,8 45 = binary

36 UTC400P Coordinate Systems Permitted Axis Names: X,Y,Z,U,V,W,A,B,C Name of axis can be redundant Scale must be any positive floating point value Motor direction can be set by Ix04 We can not jog the motor defined in the coordinate system that is running a program. But we can still jog the motors defined in another coordinate system that is not running program in the same time.

37 Defining Coordinate Systems Choose a motor and give it a axis name and scale Unit of scale: counts / user unit &1 #1->800X #2->800Y #3->800Z &2 #4->20X Suppose the encoder resolution of motor is 4000 counts per revolution, the pitch of ball screw is 5mm :

38 &1 #1->X &2 #2->X &1 #1->X #2->X This is permitted. The two motors will act as X-axes in independent coordinate systems. { { Multiple Axis Definitions (&->Coordinate; #->Motor; X->Axis) This is permitted. The motors will act on identical X-axis trajectories, as in a gantry system.

39 &1 #1->X #1->Y &1 #1->X &2 #1->X { { Multiple Axis Definition (continue) This is NOT permitted. A motor cannot perform two different motions at same time in a program. The first axis definition will be cancelled out by the second. This is NOT permitted. A motor will receive conflicting commands while running two program. The second coordinate definition will be rejected.

40 UTC400P programs u Are executed one move at a time, performing all calculations up to that move u Run in coordinate systems u One program can simultaneously run in multiple coordinate systems u One program can run in any coordinate system u A coordinate system can only run one motion program at a time Motion Programs

41 Starting a program u Address to the desired coordinate system using the on-line command: &n u Point the coordinate system to the desired program using the on-line command: Bn u Use the on-line commands: R or ^R Stopping a program u Point to the desired coordinate system using the on-line command: &n u Use the on-line commands: S, A, or ^S,^A, Motion Programs (continue)

42 n Move Commands X1000 Y2000 Z3000 U(P1* ) V(20*SIN(Q6)) DWELL, DELAY n Modal Commands ABS, INC, FRAX, NORMAL LIN, RPD, CIR1, CIR2, SPLINE TA, TS, TM, F n Variable Value Assignment {variable} = {expression} UTC400P Motion Program Commands

43 n Logic Control Statements N, GOTO, GOSUB, CALL, RET G, M, T, (special CALL statements) IF, ELSE, ENDIF, WHILE, ENDWHILE n Miscellaneous Statements CMD, SEND, DISP ENAPLC, DISPLC UTC400P Motion Program Commands (continue)

44 n Logic Operators &(bit by bit AND) |(bit by bit OR) ^(bit by bit Exclusive OR) Comparators = (equal to) !=(not equal to) <(less than) <=(less than or equal to) >(greater than) >=(greater than or equal to) Functions SIN, COS, TAN, ASIN, ACOS, ATAN, ATAN2, SQRT, LN, EXP, FABS, INT, ROUND UTC400P Logic Operators used in Motion Programs and PLCs

45 This example shows how to program a simple move on the program specifies how to do the move, then commands the move. ********************* Set-up and Definitions ********************* &1; Coordinate System 1 CLOSE; Make sure all buffers are closed #1->X; Assign motor 1 to the X-axis - 1 program unit ; of X is 1 encoder count of motor #1 ********************* Motion Program Text ************************* OPEN PROG 1; Open buffer for program entry, Program #1 CLEAR; Erase existing contents of buffer LINEAR; Blended linear interpolation move mode ABS; Absolute mode - moves specified by position TA500; Set 1/2 sec (500 msec) acceleration time TS0; Set no S-curve acceleration time F300000; Set feedrate (speed) of units(cts)/minute X10000; Move X-axis to position DWELL500; Stay in position for 1/2 sec (500 msec) X0; Move X-axis to position 0 CLOSE; Close buffer - end of program To run this program: &1 B1 R; Coord. System 1, point to Beginning of Program 1, Run Example 1: A Simple Move


47 Linear Mode Trajectories Small Acceleration Time V time TA V time TA TM or P/F TM or P/F TM or P/F

48 Linear Mode Trajectories (continue) Small Acceleration Time V time TA V time TA TM or P/F TM or P/F TM or P/F TM or P/F TM or P/F

49 Linear Mode Trajectories (continue) Acceleration Time matches Move Time V time V V V TA TM or TM or P/F TM or TM or P/F TM or TM or P/F

50 Linear Mode Trajectories (continue) Acceleration Time matches Move Time V time V TA V time V TA TM or TM or P/F TM or TM or P/F TM or TM or TM or P/F TM or P/F

51 V time V TA TA TM or P/F TM orP/F TM orP/F Linear Mode Trajectories (continue) Large Acceleration Time

52 V time TA TM orP/F TM orP/F Linear Mode Trajectories (continue) Large Acceleration Time

53 Motion Acceleration I-Variables Ix52Program Acceleration Time (unit: msec) Ix53Program S-Curve Time (unit: percent) 0 > TS>100 Ts=TA*TS/2 Ts T V Ta

54 Motion Acceleration I-Variables (continue) Ts 2*Ts Note that TA=2Ts T V TS= 100

55 Motion Acceleration I-Variables (continue) TA V T TS = 0

56 0 MAX. TA VELOCITY TIME 2a2a a ACCELERATION TIME 1.5a 0 Ts UTC400P S Curve Acceleration

57 Example 2: A More Complex Move This example introduces incremental and time-specification of moves, looping logic, using variables, scaling of axes, and simple arithmetic. Note that logical and mathematical operations do not delay moves. ;******************** Set-up and Definitions ******************** &1; Coordinate system 1 CLOSE; Make sure all buffers are closed #1->1000X; 1 unit (cm) of X is 1000 counts of motor 1 ;******************** Motion Program Text *********************** OPEN PROG 2; Open buffer for entry, Program #2 CLEAR; Erase existing contents of buffer LIN; Blended linear interpolation move mode INC; Incremental mode - moves specified by distance TA500; 1/2 sec (500 msec) acceleration time TS100; 1/4 sec in each half of S-curve TM2000; 2 sec move time (to start of decel) P1=0; Initialize a loop counter variable WHILE (P1<10); Loop until condition is false (10 times) X10; Move X-axis 10 cm (=10,000 cts) positive DWELL500; Hold position for 1/2 sec X-10; Move X-axis back 10 cm negative DWELL500; Hold position for 1/2 sec P1=P1+1; Increment loop counter ENDWHILE; End of loop CLOSE; Close buffer - end of program To run this program: &1 B2 R; Coordinate System 2, point to Beginning of Program 2, Run

58 Example 2: A More Complex Move Repeat 9 More Times Time (second) Velocity (count/second)

59 UTC400P Blended Move UTC400P will blend moves together unless one of the following conditions is true: u The moves are separated by a DWELL statement u 2 backward jumps in the program are encountered before the next move statement (GOTO, ENDW) u The move blend enable is not set (Ix50=0) Blending allowed Blending not allowed

60 Y Y Vx Vy XX tt tt Non-BlendedBlended Difference Between Blended and non-Blended Move

61 DWELL Vs. DELAY DWELL u Always uses fixed time base u Time does not include preceding deceleration time u Next move will not be calculated until after end of DWELL Move Time TM or D P/F DWELL Time Calculate Time TAMove Time TM or D P/F

62 DELAY u Uses variable time base (% value) u Time includes preceding deceleration time u Minimum time is current TA time u Upcoming move calculated at beginning of DELAY DWELL Vs. DELAY (continue) Move Time TM or D P/F DELAY Time Move Time TM or D P/F

63 Vector Feedrate Axes INC FRAX (X,Y) X3 Y4 F10 INC FRAX (X,Y) X3 Y4 Z12 F10

64 Vector Feedrate Axes (continue) INC FRAX (X,Y,Z) X3 Y4 Z12 F10 INC FRAX (X,Y) C10 F10

65 +Z+Z +X+X+Y+Y +Z+Z +X+X+Y+Y +Z+Z +X+X+Y+Y +Z+Z +X+X+Y+Y +Z+Z +X+X+Y+Y +Z+Z +X+X +Y+Y NORMAL K-1 NORMAL I-1 NORMAL J-1 NORMAL K1 NORMAL J1 NORMAL I1 CW G17 G18 G19 Vector Direction of Circular Interpolation

66 YY (25,20) J I I CENTER (15,20) START END (15,10) X X Y Y CIR2 TM1000 X15Y10I-10 X START (10,0) END (0,10) CIR2 TM2000 X0Y10R-10 CIR2 TM2000 X0Y10R10 X X I Y J CENTER (20,20) START,END (30,10) X X Y Y NORMAL K-1 ABS (X,Y) CIR1 F10 X25Y30I20J5 START (10,5) CENTER (30,10) END (25,30) UTC400P Circular Interpolation Defaults CIR1 F25 X30Y10I-10J10 or I-10J10

67 Blended Between Linear and Circular Line / Line Line / Arc Arc / Arc Non-TangentTangent

68 Vprof (t) ) Vprof (t) Vx (t) = Vx ( = R (-sin Vy (t) = Vy ( = Rcos Y X 1 2 Vprof t V Vy Vx Profile of Circular Interpolation

69 Example of circular interpolation ;Setup and definitions &1 #1->10000x #2->10000y ;Motion Program Text open prog4 clear rpd x1 y4 f5 lin y13 cir1 x2 y14 i1 j0 lin x3 cir1 x4 y13 i0 j-1 lin y7 cir2 x7 y4 i3 j0 lin x13 cir1 x14 y3 i0 j-1 lin y2 cir1 x13 y1 i-1 j0 lin x4 cir1 x1 y4 i0 j4 dwell100 rpd x0 y0 close

70 All program calculations and assignments between the move in progress and the move being calculated are performed one line at a time during the look-ahead. This may be a problem with M-variables, particularly outputs, as the action will take place sooner than expected. Example:LIN;linear move mode X10;move X-axis to 10 X20;move X-axis to 20 M1=0 ;turn on output #1 X50;move X-axis to 50 The output M1 will be turned on at the beginning of the X20 move due to UTC400Ps precalculation of the program UTC400P Precalculation

71 Calculate Time time "R" Execute Calculate Timing of UTC400P Precalculation

72 GOSUB 300 jumps to: N 300 of same motion program, CALL 500 jumps to: PROG 500, at the top (N0) CALL jumps to: PROG 500, label N10000 CALL jumps to: PROG 500, label N12000 CALL jumps to: PROG 500, label N12345 On-line command B700 points to: PROG 700, (N0) ready to run On-line command B points to: PROG 700, N34000, ready to run UTC400P Subroutine Call

73 {PROG 1} CALL 500 D10E20 {PROG 500} READ (D,E) sets Q104 to 10 sets Q105 to 20 A argument reads into Q101 B argument reads into Q102 Y argument reads into Q125 Z argument reads into Q126 Parameter Passing and Checking

74 Z Y F E D C B A Letter 0Q100 0Bit # 1Bit Value (Dec) 1Bit Value (Hex) PROG1 CALL 500 D10 E20 PROG500 READ (D,E) Q100 set to 0 at beginning of READ Successful read of letter value sets corresponding bit of Q100 to 1 Bit (n-1) of Q100 set to 1 if nth letter passed argument in last READ statement IF(Q100 & 16>0) is true when E (5th letter) has been passed (1=2 5-1 )

75 n For RS-274 compatible motion programs G 73 is equivalent to Call M 3 is equivalent to Call T 01 is equivalent to Call G,M,T Codes Definition

76 Rotary Buffer Used for DNC or MDI DEF ROT {size} Define specified size of rotary buffer, unit is word B0 Point the program counter to the head of rotary buffer.(the rotary buffer must be in closed status, otherwise it will be taken as move of axis B) OPEN ROT Open rotary buffer CLEAR Clear contents of current buffer R Execute motion program PR Report number of program lines remaining in rotary buffer CLOSE Close rotary buffer (wont stop program) DEL ROT Delete rotary buffer

77 Function of Dip Switch SW1 OFF ON

78 UTC400P PLC Program * Perform many tasks like hardware PLCs * Cycle through calculations repeatedly and rapidly regardless of status of motion programs PLCs are used for: monitoring inputs setting outputs changing variables monitoring card status commanding actions sending messages

79 UTC400P PLC Types Foreground PLC (PLC0) Operates on servo interrupt Repetition rate is controlled by I10 For time critical tasks - KEEP SHORT!! Background PLC (PLC1-15) Operates between servo cycles Repetition rate is a function of: Servo Frequency Number and types of motors Calculation requirements of motion programs Length and complexity of PLC programs

80 PLC Program Control I6 = 0No PLCs can be enabled = 1Foreground PLCs can be enabled (PLC0) Background PLCs cannot be enabled = 2Foreground PLCs cannot be enabled Background PLCs can be enabled (PLCs 1-15) = 3All PLCs can be enabled All existing PLCs permitted by I6 are enabled on power-up or reset

81 Online Command, Motion and PLC command ENAPLC n DISPLC n control programs individually or in groups ENAPLC4 DISPLC1,2,3,4,5 Disable all PLCs OPEN PROG and OPEN PLC will disable PLC temporarily CLOSE will go back to previous PLC status PLC Program Control (continue)

82 UTC400P PLC Commands 1. Conditional Statements (nestable) IF({condition}) WHILE({condition}) AND({condition}) OR({condition}) where {condition}={expression}{comparitor}{expression} [AND/OR{expression}{comparitor}{expression}...] 2. Logical Control Statements ELSE ENDIF ENDWHILE 3. Action Statements {variable} = {expression} CMD {on-line command} SEND{C1/C2} {message} DISP {message}

83 PLC Timer Since DWELL and DELAY commands can only be used in motion programs, UTC400P timer registers can be used to issue time delays in a PLC program M0->536,0,24,S;Interrupt counter,increase 1 per ;millisecond M71->532,0,24,S;Timer 1,decrease 1 per msec M72->537,0,24,S;Timer 2,decrease 1 per msec Example: If you wanted a 1 second delay in a PLC program open plc 1 clear. m71=1000 while(m71>0) endwhile. close Note:Statements in the same PLC after endwhile will stop scan temporarily. But it wont effect the scanning of other PLCs..

84 PLC COUNTER DELAY Start Variable = Initial Value While Variable < Limit Variable=Variable +1 Perform Desired actions Perform Desired Actions End Read Other PLC's

85 ;********************* Set-up and Definitions***************** CLOSE M11->I:FF41,16,1; Machine Input 1 ;P11; Latching flag for M11 ;****************** PLC Program Text ********************** OPEN PLC 1 CLEAR IF (M11=0); Motor 1 jog plus switch on IF (P11!=0); But not on last time CMD"#1J+"; Issue command P11=0`; Set latching flag ENDIF ELSE; Motor 1 jog plus switch off IF (P11!=1); But not off last time CMD"#1J/"; Issue stop command P11=1; Set latching flag ENDIF CLOSE PLC Example

86 ; All These variables are defined in 400V210.UTC, download this file to use, ; M0->9E9,0,24,S; ; INTERRUPT COUNTER ; GENERAL PURPOSE INPUTS AND OUTPUTS M1->22,0,1; ; MACHINE OUTPUT 1 M2->22,1,1; ; MACHINE OUTPUT 2 M3->22,2,1; ; MACHINE OUTPUT 3 M4->22,3,1; ; MACHINE OUTPUT 4 M5->22,4,1; ; MACHINE OUTPUT 5 M6->22,5,1; ; MACHINE OUTPUT 6 M7->22,6,1; ; MACHINE OUTPUT 7 M8->22,7,1; ; MACHINE OUTPUT 8 M9->22,0,8; ; MACHINE OUTPUT 1-8 BYTE M11->I:2F,0,1; ; MACHINE INPUT11 M12->I:2F,1,1; ; MACHINE INPUT12 M13->I:2F,2,1; ; MACHINE INPUT13 M14->I:2F,3,1; ; MACHINE INPUT14 M15->I:2F,4,1; ; MACHINE INPUT15 M16->I:2F,5,1; ; MACHINE INPUT16 M17->I:2F,6,1; ; MACHINE INPUT17 M18->I:2F,7,1; ; MACHINE INPUT18 M19->I:2F,0,8; ; MACHINE INPUT 11~18 Suggested M-Variable Definition






92 ;Registers associated with coordinate system x Mx80; &x RUN REQUEST Mx81; BUFFER OPENED Mx82; INS MODE Mx83; &x PROGRAM HOLD Mx84; &x PROGRAM NUMBER Mx85; &x RAPID MODE Mx86; &x LINEAR MODE Mx87; &x CIR MODE (-1:CIR1 / 1:CIR2) Mx88; &x CALL STACK POINTER Mx89; &x DWELL IN PROGRESS Mx90; Mx95; &x HOME IN PROGRESS Mx97; &x COMMAND FEEDRATE OVERRIDE Mx98; &x PRESENT FEEDRATE OVERRIDE ; M ;Registers associated with #1 captured data M ;Registers associated with #2 captured data M ;Registers associated with #3 captured data M ;Registers associated with #4 captured data

93 ;DEFINITION OF FIRST MT0170 ; M ; IN1..32 M ; OUT1..16 ; ;DEFINITION OF SECONT MT0170 ; M ; IN1..32 M ; OUT1..16 ; 0C00 0FFFM-Var Definition Buffer (1024 words) L: FFP-Variables Buffer (1024 words) L: FFQ-Variables Buffer (1024 words) 1800 C3DFMotion and PLC Programs Buffer (44000 words) C3E0 C45FInternal Used Buffer(128 words) C460 C67FInterpreter Temporary Used Buffer(544 words) C680 C6BFOpen Buffer, Cleared to 0 on Power Up(64 words) C6C0 C6FFOpen Buffer (64 words) C700 C77FPLC Online Command Buffer (128 words) C780 C7FFOnline Command Buffer (128 words) C800 CBFFM-Variables Buffer (1024 words)

Download ppt "Micro Trend Automation Ltd. Programmable 4-Axis Controller UTC ® Series."

Similar presentations

Ads by Google