Presentation is loading. Please wait.

Presentation is loading. Please wait.

UTC400P 4-Axis Motion Controller

Similar presentations


Presentation on theme: "UTC400P 4-Axis Motion Controller"— Presentation transcript:

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

1 UTC400P 4-Axis Motion Controller

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

3 UTC400P-PACK LAYOUT

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

5 UTC400P Multi-Tasking Executes Motion Program Executes PLC 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 Continuously scan PLC’s as fast as processor time allows PLC’s are useful for any task that is asynchronous to the motion

6 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

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

8 UT-747 UT-750 UT-735 UT-740 UT-725

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

10

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

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

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

14 UTC400P Variables (continue)
3. Q-Variables (1024) General-purpose use 32-bit floating point format Coordinate system specific 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

15 System I-Variables I0 Card Number
I1 Coordinate System Activation Control I2 COM2 Baudrate Control I3 COM2 Handshake Control I4 Wait State Control I5 Position/Velocity Response Control I6 PLC Programs On/Off Control I9 Maximum Digit for Floating Point Returned I10 Real Time Interrupt Period I18 Extension I/O Board Enable I19 Digital Inputs Debounce Cycle

16 Motor I-Variables (x = motor number (1~ 4) )
Ix00 Motor x Activate Control Ix01 Motor x Jog / Home Acceleration Time Ix02 Motor x Jog / Home S-Curve Time Ix03 Motor x Jog Speed Ix05 Motor x Master Following Enable Ix06 Motor x Master Scale Factor Ix07 Motor x Homing Speed and Direction Ix08 Motor x Home Offset

17 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 1 Hex($)5 4

18 Motor I-Variables (continue)
Ix10 Motor x Positive Software Limit Ix11 Motor x Negative Software Limit Ix12 Motor x Coordinate Position Displacement Ix13 Motor x Coordinate Position Scaling Ix14 Motor x Coordinate Unit Scaling Ix15 Motor x Backlash Size Ix16 Motor x Backlash Takeup Rate Ix17 Motor x Rollover Range Ix19 Motor x Velocity Weighting Ix20 Motor x Proportional Gain (Kp) Ix21 Motor x Derivative Gain (Kd) Ix22 Motor x Velocity Feedforward Gain (Kvff)

19 Ix23. Motor x Integral Gain (Ki) Ix24. Motor x Integration Mode Ix25
Ix23 Motor x Integral Gain (Ki) Ix24 Motor x Integration Mode Ix25 Motor x Acceleration Feedforward Gain Ix26 Motor x Position Feedback Address Ix27 Motor x Velocity Feedback Address Ix28 Motor x Velocity Feedback Scale Ix29 Motor x DAC Bias Ix30 Motor x DAC Limit Ix31 Motor x Fatal Following Error Ix32 Motor x Dead Band Size Ix33 Motor x In Position Band Ix34 Motor x Big Step Size Ix35 Motor x Integration Limit

20 C.S. I-Variables (x = c.s. number (1~ 4) )
Ix50 Blended Move Enable Control Ix51 Maximum Permitted Acceleration Ix52 Default Program Acceleration Time Ix53 Default Program S-Curve Time Ix54 Default Program Feedrate Ix55 Time Base Slew Rate Ix56 Rapid Move Feedrate Ix57 Rapid Move Acceleration Time Ix58 Acceleration Mode Ix59 Rotate Angle Ix60 External Time Base Scale Ix61 External Time Base Source

21 Encoder I-Variables (x = encoder ch. (1~ 4) )
Ix80 Encoder x Decode Control Ix81 Encoder x Capture Control Ix82 Encoder x Capture Flag Control Ix83 <Reserved> Ix84 <Reserved> Ix85 Master x Source Address Ix86 Master x Moving Average Buffer Size

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

23 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= Set jog speed of motor 1 to 30 counts / msec I201= 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.

24 Home Searching Commands
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.

25 UTC400P Home Searching I-Variables
Ix01 Acceleration Time (unit: msec) Ix07 Home Speed / Direction (unit: counts / sec) Ix08 Home Offset (unit: counts) Ix09 Flag Control

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

27 Motion Profile of Home Searching
Trigger Occurs FL False Offset FL False Offset Ix01 Ix07 Ix01 Ix01 Ix01 Ix01 Offset:−Ix18 Offset:Ix18 Offset:+Ix18

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

29 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 Use an equation to generate points on the fly OR X1 X1.0173 X1.0343 . X0.9824 P1=0 WHILE (P1<361) P2=SIN(P1)+COS(P1) X(P2) P1=P1+1 ENDWHILE

30 Program Calculations UTC400P’s 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) P3=2 IF(P1>99) p3=99 ENDIF X2000 P1=P1+1 ENDWHILE CLOSE

31 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

32 Q-Variables Memory Map

33 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 31 30 29 28 27 26 25 24 23 22 21 20 Sign Width Start Bit Type Address Address - Memory address, range 0000 - FFFF Type - 0: Don’t 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

34 M-Variable Definition
Mxx->* Don’t 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,8 Point to Machine Input 1-8 M102->AA,S Point to #1 Command Velocity Using M-Variables M1 = 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

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

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

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

38 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. { &1 #1->X #1->Y &1 #1->X &2 This is NOT permitted. A motor will receive conflicting commands while running two program. The second coordinate definition will be rejected. {

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

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

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

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

43 UTC400P Logic Operators used in Motion Programs and PLCs
& (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

44 Example 1: A Simple Move 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 F ; Set feedrate (speed) of units(cts)/minute X10000 ; Move X-axis to position 10000 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

45 Example 1: A Simple Move

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

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

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

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

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

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

52 Motion Acceleration I-Variables
Ix52 Program Acceleration Time (unit: msec) Ix53 Program S-Curve Time (unit: percent) 0 > TS>100 Ts=TA*TS/2 V T Ts Ts Ts Ts Ta Ta

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

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

55 UTC400P “S” Curve Acceleration
TIME MAX. VELOCITY Ts Ts TIME Ts Ts TA

56 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 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

57 Example 2: A More Complex Move
5000 Repeat 9 More Times (count/second) Velocity 1 2 3 4 5 6 Time (second) -5000

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

59 Difference Between Blended and non-Blended Move
Y Y X X Vx Vx t t Vy Vy t t Non-Blended Blended

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

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

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

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

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

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

66 Blended Between Linear and Circular
Line / Line Line / Arc Arc / Arc Non-Tangent Tangent

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

68 Example of circular interpolation
16 ;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 14 12 10 8 6 4 2 2 4 6 8 10 12 14 16

69 UTC400P Precalculation 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 UTC400P’s precalculation of the program

70 Timing of UTC400P Precalculation
2 3 4 1 Execute "R" time Calculate Time 3 4 5 1 2 Calculate

71 UTC400P Subroutine Call 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

72 Parameter Passing and Checking
{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

73 • 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=25-1) Q100 set to 0 at beginning of READ Successful read of letter value sets corresponding bit of Q100 to 1 Z Y F E D C B A Letter 1 1 Q100 25 24 5 4 3 2 1 Bit # 2 25 2 24 32 16 8 4 2 1 Bit Value (Dec) 25 24 2 2 20 10 8 4 2 1 Bit Value (Hex) PROG1 PROG500 CALL 500 D10 E20 READ (D,E)

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

75 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 (won’t stop program) DEL ROT Delete rotary buffer

76 Function of Dip Switch OFF ON 1 2 3 4 5 6 7 8 SW1

77 UTC400P PLC Program * Perform many tasks like hardware PLC’s
* 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

78 UTC400P PLC Types Foreground PLC (PLC0) Background PLC (PLC1-15)
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

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

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

81 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}”

82 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 won’t effect the scanning of other PLCs..

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

84 PLC Example ;********************* 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

85 Suggested M-Variable Definition
; 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 ; ; MAC HINE 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 INPUT 1 1 M12 - > I:2F ,1,1 ; ; MACHINE INPUT 1 2 M13 - > I:2F ,2,1 ; ; MACHINE INPUT 1 3 M14 - > I:2F ,3,1 ; ; MACHINE INPUT 1 4 M15 - > I:2F ,4,1 ; ; MACHINE INPUT 1 5 M16 - > I:2F ,5,1 ; ; MACHINE INPUT 1 6 M17 - > I:2F ,6,1 ; ; MACHINE INPUT 1 7 M18 - > I:2F ,7,1 ; ; MACHINE INPUT 1 8 M19 - > I:2F,0 , 8; ; MACHINE INPUT 11~18

86

87

88

89 ;REGISTERS ASSOCIATED WITH AXISx
Mx01 ; #x 16-BIT UPDOWN COUNTER (COUNTS) Mx02 ; #x SPEED CODE (UNIT: 16 COUNT/MSEC) Mx03 ; #x 16-BIT CAPTURE REGISTER (COUNTS) Mx04 ; #x CAPTURED INDEX Mx05 ; ADCx 12-BIT ANALOG INPUT (BUFFERED) Mx14 ; #x SERVO ON/OFF Mx16 ; #x ENCODER CAPTURED FLAG Mx17 ; #x POSITION CAPTURED FLAG (MUST CLEARED AFTER READ) Mx20 ; HMFLx INPUT STATUS Mx21 ; -LIMx INPUT STATUS Mx22 ; +LIMx INPUT STATUS Mx23 ; FAULTx INPUT STATUS Mx24 ; HMFLx INPUT STATUS Mx31 ; #x POSITIVE LIMIT SET Mx32 ; #x NEGATIVE LIMIT SET Mx33 ; #x ABORT FLAG Mx39 ; #x DRIVER ENABLE BIT Mx40 ; #x IN-POSITION BIT Mx41 ; #x JOG IN PROGRESS

90 Mx42 ; #x HOME IN PROGRESS Mx43 ; #x DRIVER FAULT SET Mx44 ; #x FATAL FOLLOWING ERROR Mx45 ; #x HOME COMPLETE Mx47 ; #x INC MODE Mx48 ; #x JOG SEGMENT (4 MEANS ACC/DECEL COMPLETE) Mx61 ; #x COMMAND POSITION (COUNTS) Mx62 ; #x ACTUAL POSITION (COUNTS) Mx63 ; #x JOG REGISTER POSITION (COUNTS) Mx64 ; #x POSITION BIAS (COUNTS) Mx65 ; #x COORDINATE TARGET POSITION (USER UNITS) Mx66 ; #x COORDINATE TARGET POSITION (COUNTS) Mx67 ; #x ACTUAL VELOCITY (UNIT: COUNTS/MSEC) Mx68 ; #x PRESENT MASTER VELOCITY (UNIT: COUNTS/MSEC) Mx69 ; #x COMMAND VELOCITY (UNIT: COUNTS/MSEC) Mx91 ; #x AXIS SCALE Mx92 ; #x AXIS DEFINITION Mx93 ; #x DEFINED IN WHICH C.S.

91 ;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 ; <RESERVED> 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

92 ;DEFINITION OF FIRST MT0170
M ; IN1..32 M ; OUT1..16 ;DEFINITION OF SECONT MT0170 M ; IN1..32 M ; OUT1..16 0C000FFF M-Var Definition Buffer (1024 words) L:100013FF P-Variables Buffer (1024 words) L:140017FF Q-Variables Buffer (1024 words) 1800C3DF Motion and PLC Programs Buffer (44000 words) C3E0C45F Internal Used Buffer(128 words) C460C67F Interpreter Temporary Used Buffer(544 words) C680C6BF Open Buffer, Cleared to 0 on Power Up(64 words) C6C0C6FF Open Buffer (64 words) C700C77F PLC Online Command Buffer (128 words) C780C7FF Online Command Buffer (128 words) C800CBFF M-Variables Buffer (1024 words)


Download ppt "UTC400P 4-Axis Motion Controller"

Similar presentations


Ads by Google