collaboration Training Exercises innovation global solutions VERICUT for Pro/ENGINEER Machine Simulation © 2001 PTC Introduction Terms © 2001 PTC ‘MS’ stands for ‘Machine Simulation’ in this exercise 2 Exercise 1 - Outline Outline 3 axis milling machine Work in Pro/E Create machine components and assembly in Pro/E Export STL file of each machine component against Machine Zero CSYS Create tool path file(NCL and TAP) using Pro/NC and G-Post Work in VERICUT Machine Simulation Build machine kinematics in VERICUT Machine Simulation Load machine components (STL file) to VERICUT MS Load Control file Save MCH, CTL and JOB file in your working directory Test machine with MDI Job, Machine setting Create or load tool library file, tool gauge length setting Load tool path file and simulate tool path © 2001 PTC 3 Exercise 1 - 3 axis milling machine Build 3 axis milling machine and simulate tool path Work in Pro/E Preparation Copy all the machine simulation exercise folder and files to your computer, set Pro/E working directory to: …\exercise 1 Machine components and assembly In Pro/E, Open file ‘3axis-mill.asm’ base-z-slide z-axis z-axis-cylinder base stock fixture y-axis x-axis base-x-slide © 2001 PTC 4 Exercise 1 - 3 axis milling machine Export component: ‘base.prt’ in STL format In Pro/E, choose: File/Export/Model/STL Select ‘Include’, pick part ‘BASE.PRT’, click ‘Done Sel’ Click Pick Coordinate System icon, select machine zero ‘ACSO’ Give chord Height=0.1, File name: ‘base’ Click ‘Apply’ © 2001 PTC 5 Exercise 1 - 3 axis milling machine Export all of other components in STL format Tips Choose the right Coordinate System - machine zero (ACSO) for all components, because there is no rotary axis on this machine Give Chord Height: 0.1 or smaller Change file name Pro/E assembly ‘3ax-mill.asm’ includes two ‘base-y-slide’ components, choose both of them when exporting ‘base-y-slide’, same comments for ‘base-z-slide’ base-y-slide z-axis y-axis z-axis-cylinder base © 2001 PTC base-z-slide x-axis fixture stock 6 Exercise 1 - 3 axis milling machine Work in VERICUT Machine Simulation Access VERICUT Machine Simulation In command line, type in ‘proems’ then click enter Or click batch file ‘proems.bat’ (‘$PRO_DIRECTORY \bin\proems.bat’) Choose: File/New Save JOB file in your working directory (… \exercise 1) Build machine kinematics © 2001 PTC In MS, choose: File / Save as, give file name ‘3ax-mill.job’ In MS, choose: Machine / Components 7 Exercise 1 - 3 axis milling machine Build components tree as following figure shows In components window, click Add Add base component: In Add components window, give type as base, color as cyan, then click ‘Apply’ Components Tree © 2001 PTC 8 Exercise 1 - 3 axis milling machine Using the same method to add other components, make sure ‘Type’, ‘Color’, motion axis, and ‘Connect To’ is right. See following figure for details. Z Linear © 2001 PTC Tool Y Linear 9 Exercise 1 - 3 axis milling machine Components: X-Linear, Fixture and Stock After finish last component - ‘Stock’, click OK in Add Component window X Linear © 2001 PTC Fixture Stock 10 Exercise 1 - 3 axis milling machine Load STL files to VERICUT MS © 2001 PTC Load base STL files In Components window, choose ‘Base’ (Base is highlighted), click STL file icon Open file ‘base.stl’, (find this file in …\exercise 1 folder) Using the same method, load STL files: ‘base-y-slide.stl’, ‘base-z-slide.stl’, to component base. 11 Exercise 1 - 3 axis milling machine Load STL files to other components Load ‘z-axis.stl’ and ‘z-axis-cylinder.stl’ to component Z Load ‘y-axis.stl’ to component Y Load ‘x-axis.stl’ to component X Load ‘fixture.stl’ to component Fixture Load ‘stock.stl’ to component Stock Change color of Primitives © 2001 PTC In Components window, choose ‘base-y-slide.stl’, click ‘Atrib button’, choose Color: White Using save method, change color of ‘base-z-slide.stl’ to white Change ‘z-axis-cylinder.stl’ to color white 12 Exercise 1 - 3 axis milling machine Change Tool connect position In Pro/E, find distance from gauge point to work table plane (machine zero), It is 15.2 inch. We will move tool connect position from machine zero to gauge point In VERICUT MS, choose: Machine / Components In Components window, choose: ‘Tool’, then click Modify In Modify window, set Connect position=(0 0 15.2), then click OK Close Components window Gauge Point 15.2 Machine Zero © 2001 PTC 13 Exercise 1 - 3 axis milling machine Save machine file in your working directory Load control file In VERICUT MS, choose: Control / Open, open file ‘generic.ctl’, find this control file in category ‘CGTECH_RP2LIB’ Save control file in your working directory © 2001 PTC In VERICUT MS, choose: Machine / Save as, give file name ‘3ax-mill.mch’, make sure you save it in …\exercise 1 folder In VERICUT MS, choose: Control / Save as, give file name ‘generic.ctl’, make sure save it in …\exercise 1 folder 14 Exercise 1 - 3 axis milling machine Test your machine with MDI In VERICUT MS, choose: Job / MDI Test X axis, type in ‘x10’ in MDI, click Apply. Notice movement of X axis Test negative direction of X axis (x-10) Test Y and Z axis (Notes: if axis doesn’t move, check if you load control file correctly) © 2001 PTC 15 Exercise 1 - 3 axis milling machine Set machine table In Pro/E, use Analysis/Measure, check distance between gauge point to stock surface, It is 7.7 inch. We will set top surface center of stock as programming zero In VERICUT MS, choose: Machine / Table In Machine Table window, choose: Table Name=‘Input Program Zero’, Sub-System ID=1, Index=1, Values=‘0 0 -7.7’. Click Add, then close (Notes, Machine Table contents can also be defined in Job Table, if a Job Table is defined, it will over write Machine Table) 7.7 © 2001 PTC 16 Exercise 1 - 3 axis milling machine Set Travel Limits In VERICUT MS, choose: Machine / Travel Limits In Travel Limits window, type in Min and Max travel limits of each axis, then click Modify See following figure for limits value of 3 axis Toggle Overtravel Detection On Click OK © 2001 PTC 17 Exercise 1 - 3 axis milling machine Collision setup In VERICUT MS, choose: Job / Collision Set: Component 1=Fixture, Component 2=Tool, Tolerance=0.1 Toggle Collision Detection On Click OK © 2001 PTC 18 Exercise 1 - 3 axis milling machine Tool library Method 1, retrieve tool library in VERICUT exercise 4a&b folder © 2001 PTC copy file ‘cgtpro.tls’ from ‘VERICUT exercise 4a&b folder’, paste it in your current working directory - ‘VERICUT MS exercise 1 folder’ In VERICUT MS, choose: Tools / Tool File, open file ‘cgtpro.tls’, find it in your current working directory Change tool gauge length. In VERICUT MS, choose: Tools / Tool Manager In Tool Manager window, click Modify 19 Exercise 1 - 3 axis milling machine © 2001 PTC In Tool Modify window, click Properties In Tool Properties window, set Gage Length=4, click OK In Tool Modify window, click OK In Tool Manager window, click Save, then Close 20 Exercise 1 - 3 axis milling machine Method 2, create tool library in VERICUT MS by yourself In Tool Manager window, click Add In Tool Add window, give: ID=1, Description=‘1 inch FEM’, Choose FEM icon, give: Diameter=1, Length=4, click Add then click OK © 2001 PTC Save tool library file. In Tool Manager window, choose: File / Save as, give file name ‘3axmill.tls’, save it in exercise 1 folder Close Tool Manager window Click ‘Yes’ in the small question window 21 Exercise 1 - 3 axis milling machine Load tool path In VERICUT MS, choose Job / Setting In Job Settings window, open Toolpath file ‘tool-com.tap’, find this file in exercise 1 folder Other settings: see following figure for details © 2001 PTC For Log file, give file name: ‘3ax-mill.log’, and select exercise 1 folder In Job Setting window, click OK Reset Machine Simulation Run machine simulation 22 Exercise 2 - Outline Outline © 2001 PTC 4 axis milling machine Build machine kinematics Load STL files Machine Table, Travel Limits, Collision setting Load tool library, set tool gauge length offset Load tool path file, control file Tool path simulation 23 Exercise 2 - 4 axis milling machine Build 4 axis milling machine © 2001 PTC Build machine kinematics See following figures for machine kinematics Make sure component Type, Connect to, Motion axis and Connect Position is right Notice connect position of rotary axis A is: (0 0 4), Design is: (0.5 0 0) (Notes: For Multi-Axis machine uses CSYS on rotary centerline for rotary axis) 24 Exercise 2 - 4 axis milling machine © 2001 PTC Build machine kinematics 25 Exercise 2 - 4 axis milling machine © 2001 PTC Build machine kinematics 26 Exercise 2 - 4 axis milling machine © 2001 PTC Build machine kinematics 27 Exercise 2 - 4 axis milling machine © 2001 PTC Load STL files Base - ‘base.stl’ Z - ‘head.stl’ and ‘spindle.stl’ Tool - Nothing Y - Nothing X - ‘table.stl’ Other - ‘rotary_box.stl’ A - ‘rotary_chuck.stl’ Design - ‘ncmach.stl’ (Notes 1: all Primitives connect position is: [0 0 0] ) (Notes 2: find STL files in …\exercise 2 folder) 28 Exercise 2 - 4 axis milling machine © 2001 PTC Set Machine Table See following Machine Table figure for details Set Travel limits See following Travel Limits figure for details Save machine file Give file name: ‘prolight.mch’, save it in …\exercise 2 folder 29 Exercise 2 - 4 axis milling machine © 2001 PTC Job setting Load tool path file: ‘op010.tap’, find this file in …\exercise 2 folder Other settings, see following figure Collision setup See following Collision Setup figure for details 30 Exercise 2 - 4 axis milling machine © 2001 PTC Load tool library and set tool gauge length offset Load tool library file ‘ncmach_gage.tls’, find it in …\exercise 2 folder Set gauge point at top of each tool Gauge Point Control file Load control file ‘tmc2000.ctl’, find this file in …\exercise 2 folder Save Job file Give JOB file name: ‘prolight.job’, save it in …\exercise 2 folder Tool path simulation 31 Exercise 2a- Outline Outline 5 axis laser machine In Pro/E, export components in STL format Base and linear axis - Against Machine Zero CSYS Rotary axis - Against CSYS at rotary center Build machine kinematics, rotary axis and tool connect position calculation Load STL files to machine Machine Table, initial machine location, RTCP pivot offset calculation Load tool library and set gauge length offset Load tool path file, control file Tool path simulation © 2001 PTC 32 Exercise 2a - 5 axis laser machine Build 5 axis laser machine Preparation Set Pro/E working directory to …\exercise 2a Open file ‘laserdyne.asm’ Export components in STL format Export base and all linear axis using CSYS at machine zero XAXIS ZAXIS YAXIS CAXIS DAXIS Base © 2001 PTC Table 33 Exercise 2a - 5 axis laser machine Export rotary components (C and D axis) using CSYS at centerline of rotary axis Using ‘ACS0’ for CAXIS, and ‘ACS1’ for DAXIS (Notes: Use same name as Pro/E part for STL files) CAXIS © 2001 PTC DAXIS 34 Exercise 2a - 5 axis laser machine Build machine kinematics & load STL files Base Type: Base, Name: Base, Color: Blue , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘base.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) XAXIS Type: Z Linear, Name: Z, Motion Axis, Z , Connect To: X, Connect Position: (0 0 0) Color: Magenta , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘zaxis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) YAXIS © 2001 PTC Primitives: ‘xaxis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) ZAXIS Type: X Linear, Name: X, Motion Axis, X, Connect To: Base, Connect Position: (0 0 0) Color: Cyan , Mixed Mode: Shade, Angles: (0 0 0) Type: Y Linear, Name: Y, Motion Axis: Y, Connect To: Z, Connect Position: (0 0 0) Color: Yellow , Mixed Mode:Shade, Angles: (0 0 0) Primitives: ‘yaxis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) 35 Exercise 2a - 5 axis laser machine CAXIS Primitives: ‘daxis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Type: Tool, Name: Tool, Motion Axis: Z, Connect To: D, Connect Position: (0, 8.5, -15) Color: Red , Mixed Mode: Shade, Angles: (0 0 0) Table © 2001 PTC Type: B Rotary, Name: D, Motion Axis: Y, Connect To: C, Connect Position: (0 8 -6) Color: Tan , Mixed Mode:Shade, Angles: (0 0 0) Tool Primitives: ‘caxis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) DAXIS Type: C Rotary, Name: C, Motion Axis: Z, Connect To: Y, Connect Position: (0, -16.5, 21) Color: orange , Mixed Mode: Shade, Angles: (0 0 0) Type: Other, Name: Table, Connect To: Base, Connect Position: (0 0 0) Color: Blue , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘table.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) 36 Exercise 2a - 5 axis laser machine Design Type: Design, Name: Design, Connect To: Table, Connect Position: (0 0 0) Color: Green , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘test_laserdyne.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Components Tree © 2001 PTC 37 Exercise 2a - 5 axis laser machine Rotary axis & tool connect position calculation C-axis connect position is measured from Machine Zero to C-axis CSYS D-axis connect position is measured from C-axis CSYS to D-axis CSYS Tool connect position is measured from D-axis CSYS to Gauge Point (in this case it is Machine Zero) C-axis CSYS D-axis CSYS -6 21 8 © 2001 PTC -16.5 Machine Zero 38 Exercise 2a - 5 axis laser machine Set machine table Set Initial Machine Location=(0 0 20) Set RTCP pivot offset=(0 -16.5 15) RTCP Offset Xval-Zval are calculated by subtracting the location of the Tool component origin from the rotary pivot point location (with all axes at their Initial Machine Location ) Save machine file 15 -16.5 © 2001 PTC 39 Exercise 2a - 5 axis laser machine © 2001 PTC Load tool library and set gauge length offset Load file ‘tool.tls’, find it in exercise 2a folder Set gauge offset=8 Load control Load control file ‘laserdyne.ctl’, find it in exercise 2a folder Load Toolpath file Load file ‘op010.tap’, find it in exercise 2a folder Save JOB file Run simulation 40 Exercise 3 - Outline Outline © 2001 PTC Build your own machine Choose one machine from list shown in next 7 slides Build machine components and assembly in Pro-E Export components in STL format against right CSYS Create machine kinematics in VERICUT Machine Simulation Load machine components (STL file) to VERICUT MS Load control file (fan16M, find it in category of CGTECH_RP2LIB) and save it in your current directory Machine & Job setting Test your machine with MDI Create or load tool library file, set tool gauge length Create Post-Processor (optional), generate TAP file Load a tool path file (TAP file), run simulation 41 Exercise 3 - Build your own machine 3 Axis Vertical Mill © 2001 PTC 3 Axis Horizontal Mill 42 Exercise 3 - Build your own machine 4 Axis Vertical Mill Table A © 2001 PTC 4 Axis Horizontal Mill Table B 43 Exercise 3 - Build your own machine 5 Axis Vertical Mill Head A on B © 2001 PTC 5 Axis Vertical Mill Head B / Table A 44 Exercise 3 - Build your own machine 5 Axis Vertical Mill tables A on C © 2001 PTC 5 Axis Horizontal Mill Heads A on B 45 Exercise 3 - Build your own machine 5 Axis Horizontal Mill tables B on A © 2001 PTC 5 Axis Horizontal Mill Head A / Table B 46 Exercise 3 - Build your own machine 5 Axis Gantry Mill - Heads B on C © 2001 PTC 47 Exercise 3 - Build your own machine 5 Axis Gantry Mill - Heads A on B © 2001 PTC 48 Exercise 4, 4a, 4b Exercise 4 Menu View Attributes View Select/Store Exercise 4a Menu Job Job Setting Job Table Collision Exercise 4b © 2001 PTC Menu Machine Machine Tables Travel Limits 49 Exercise 4 - Menu/View Menu View Open file ‘prolight.job’ in …\exercise 4 folder Attributes In VERICUT MS, choose: View / Attributes Show CSYS Toggle Component Origin, Primitive Origin and Machine Zero On, then click Apply CSYS appears © 2001 PTC 50 Exercise 4 - Menu/View Draw Mode Choose Draw Mode=Lines, click Apply, notice the change Choose Draw Mode=Hidden, click Apply, notice the change Change Draw Mode back to ‘Shade’ You can also use the icon show below to switch draw mode Usage of line mode, when simulation, if tool is not shown up, you can switch to line mode, find where tool is Line © 2001 PTC Hidden 51 Exercise 4 - Menu/View © 2001 PTC View Select/Store Choose: View / Orient. In Orientation window, click ISO icon Choose: View / Select/Store. In Select/Store View window, click Add In View Add window, give view name: ‘iso1’, then click OK Using same method, add XY and YZ view You can switch view by clicking view name 52 Exercise 4a - Menu/Job Menu Job © 2001 PTC Job Setting Choose: Job / Setting In Job Setting, click ‘Select (beside output file)’ to specify output APT file name(ex4a.apt) and directory(…\exercise 4) In Job Setting, click ‘Select (beside Log File)’ to specify output Log file name(ex4a.apt) and directory(…\exercise 4) In Job Setting window, Click OK Toggle Conversion: On Reset VERICUT MS Run simulation Find file ‘ex4a.apt’ and ‘ex4a.log’ in your …\exercise 4 folder 53 Exercise 4a - Menu/Job © 2001 PTC Job Table (Notes: Job Table performs same function as Machine Table. If the same tables are defined in both job and machine configurations, the job table values override those in the machine) Choose: Job / Tables, in Job Table window, select ‘Initial Machine Location’, give Values= (0 0 12), click Add then Close Reset VERICUT MS, see change of initial machine location Delete Job Table contents 54 Exercise 4a - Menu/Job © 2001 PTC Collision Choose: Job / Collision In Collision Setup window, select first line (component A and Tool), change Tolerance to 5 (this is for exercise purpose only). Click ‘Modify’, then click ‘Ok’ Reset VERICUT MS, run simulation During simulation, both A axis and tool are in error color-red Change tolerance back to ‘0.1’ 55 Exercise 4b - Menu/Machine Menu Machine © 2001 PTC Tables Choose: Machine / Tables In Machine Tables, change Initial Machine Location values to: (0 0 12), click Modify, then close Reset VERICUT MS, notice change of machine initial location Change it back to (0 0 8) (Notes: 1. if there is the same record in Job Table, Machine Table will be over written. 2. Changes to Table are only effective after reset VERICUT MS) 56 Exercise 4b - Menu/Machine © 2001 PTC Travel Limits Choose: Machine / Travel Limits Change Z limits to: (Min=-1, Max=7), click Modify Toggle Overtravel Detection On, click OK Reset VERICUT MS, run simulation Z axis becomes red (error color) during simulation. An error message also appears in message line. Open Log file to view error information Change Z limits back to (-1, 8) 57 Exercise 5 - Outline Outline Run VERICUT and Machine Simulation simultaneously Machine simulation setting Change Fixture and Stock connection position Job Table setting Job Setting Load tool library, set gauge length offset VERICUT Setting Tool retract setting © 2001 PTC 58 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Run VERICUT and Machine Simulation simultaneously Machine Simulation setting Open file ‘3ax-mill.job’, find it in exercise 5 folder © 2001 PTC Notes: differences between this job file and the one in exercise 1 are: Fixture and Stock STL files are replaced by those in VERICUT exercise 6 - ‘sub.usr’ Tool library file is replaced by ‘tools.tls’ in VERICUT exercise 6-’sub.usr’ We find fixture and stock are not in right position 59 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Move fixture and stock to center of machine table In VERICUT MS, choose: Machine / Components In Components window, choose ‘Fixture’, then click ‘Modify’ In Modify Component window, give connect position (-12.5, -12.5, 1) Hint: Fixture Dimension is (25x25x1), by setting connect position, it is moved 12.5 inch left, 12.5 inch back and 1 inch up © 2001 PTC 60 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Job table setting Set Input Program Zero In VERICUT MS, choose: Job / Tables In Job Tables, choose ‘Input Program Zero’, give value (-12.5, -12.5, -14.2), this is to move input program zero to ‘near-top-left corner’ of fixture (Notes, distance from gauge point to machine table is: 15.2, fixture thickness is: 1) 15.2 Y © 2001 PTC Z X 61 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Set work offset (fixture offset) Refer Job Table figure on last slide, and VERICUT exercise 6 (sub.usr) for details (Notes: Stock thickness is 2) Job setting Choose: Job / Settings Select tool path file ‘sub.tap’ in exercise 5 folder Give Log file name: ‘3ax-mill.log’, save it in exercise 5 folder Other settings: Programming method, Tool Tip. Simulation, On. Conversion, Off. Conversion Method, Scan On. Default Tolerance, 0.05. (notes, if tool path contains subroutines, Conversion Method must be set to: Scan On) (13, 13, 2) (1, 13, 2) Z Y X © 2001 PTC (13, 1, 2) (1, 1, 2) 62 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Test your machine with MDI Give (X0Y0Z0), machine should be at position as following figure shows Rest machine simulation XZ plane © 2001 PTC YZ plane 63 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Load tools and Set gauge length offset In VERICUT MS, choose: Tools / Tool File, open file ‘tools.tls’, find it in exercise 5 folder Tool gauge length setting © 2001 PTC Choose: Tools / Tool Manager In Tool Manager window, choose a tool then click ‘Modify’ In Tool Modify window, choose Tool Properties In Tool Properties window, give tool gauge length value Change gauge point of all five tools to the most top point of each tool Gauge point 64 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Save machine file, save job file Set Layout to 3 views Run simulation © 2001 PTC 65 Exercise 5 - Run VERICUT & Machine Simulation simultaneously VERICUT Setting Open user file ‘sub.usr’, find it in exercise 5 folder Machine simulation window is opened too (Notes: this user file is same as the one in VERICUT exercise 6) Change user file setting In VERICUT, choose: Toolpath / Toolpath Control © 2001 PTC In toolpath control window, choose toolpath file ‘sub.tap’(it’s in VERICUT MS exercise 5 folder) 66 Exercise 5 - Run VERICUT & Machine Simulation simultaneously G-Code setting In G-Code Setting window, open Job file ‘3ax-mill.job’, find this file in VERICUT MS exercise 5 folder. Close window Right after successfully change Job file, machine appears in VERICUT MS window. Save User file Resize VERICUT, and Machine Simulation window Run simulation (Hint: you can control simulation in both window) © 2001 PTC 67 Exercise 5 - Run VERICUT & Machine Simulation simultaneously Tool retract setting We find there is a gouge in both fixture and stock, it because that there is no tool retract when tool changing Set tool retract © 2001 PTC In VERICUT MS, choose: Modals / Tooling In Tooling window, change Tool Change Retract Method to ‘Retract (Z-Axis only)’,then click OK (Notes: this can also be set in VERICUT / Toolpath / Toolpath Control / G-Code setting) Save Job file, reset VERICUT Run simulation, now everything is running well 68 Exercise 6, 6a - Outline Exercise 6 Menu Control Use Control/Subroutine Create main program and subroutine Load subroutine to control Load new toolpath file (main program) Exercise 6a Menu Modals Control simulation Slow down machine simulation Stop simulation when error occurs © 2001 PTC 69 Exercise 6 - Menu/Control Use Control / Subroutine © 2001 PTC Create new main program and subroutine file Create two new text file in exercise 6 folder, named ‘mainprogram.tap’ and ‘subroutine.sub’ Open file ‘sub.tap’, copy lines from beginning to N510(the end of main program), paste it in file ‘main-program.tap’. Copy remaining of ‘sub.tap’ (subroutines) and paste it in file ‘subroutine.sub’ 70 Exercise 6 - Menu/Control © 2001 PTC (Notes, we divided toolpath file to two files, main program and subroutines) Load subroutine to Control In VERICUT MS, choose: Control / Subroutines In Subroutine window, open file ‘subroutine.sub’, find it in exercise 6 folder Choose file ‘subroutine.sub’, click ‘Insert’, then click OK 71 Exercise 6 - Menu/Control Change toolpath file Choose: Job / Job Setting, change toolpath file to ‘mainprogram.tap’ Run simulation (Note 1: Subroutine can also be defined in: Job / Subroutine) (Note 2: When M98 is executed) 1. Search the remainder of the current tool path file for the specified subroutine 2. If not found, access job subroutine files for the specified subroutine © 2001 PTC 3. If still not found, access control subroutine files for the specified subroutine 72 Exercise 6a Menu/Modals Control machine simulation © 2001 PTC Open file ‘3ax-mill.job’, find it in exercise 6 folder Slow down machine movements In VERICUT MS, choose: Modals / Motion / Max Distance Give Max Distance=0.1, run machine simulation Notice speed difference Change Max Distance back to 0 73 Exercise 6a Menu/Modals © 2001 PTC Stop simulation when an error occurs In VERICUT, choose: Modals / General / Max Errors Give Max Errors=1 Toggle ‘Collision Detection’(find it in menu: Job / Collision) and ‘Over Travel Detection’(find it in menu: Machine / Travel Limits) On Run simulation It stops when an error occurs 74 Exercise 7 - Outline Turning machine © 2001 PTC Build turning machine In Pro/E, export STL file of each component (optional) Build machine kinematics Load STL files Load control Set Input program zero Test machine with MDI Transfer tools from Pro/NC to VERICUT Load tool library to Machine Simulation Set tool gauge offset Load tool path file, build tool index table Run simulation Use X-Caliper to check dimension of model after cut 75 Exercise 7 - Turning machine Build turning machine In Pro/E, export STL file of each component (optional) Export all components except Turret against machine Zero CSYS Machine Zero is located at right plane center of spindle X Machine Zero Z © 2001 PTC 76 Exercise 7 - Turning machine Export Turret Use CSYS-ACS4 It is at located at left plane center of turret © 2001 PTC 77 Exercise 7 - Turning machine Build machine kinematics Read next two pages for details Find STL files in exercise 7 folder Turret Base X-axis Z-axis Spindle Fixture Stock © 2001 PTC 78 Exercise 7 - Turning machine Machine components Base Type: Base, Name: Base, Color: 3Light Steel Blue, Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘base.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Primitives: ‘base-slide.stl’, Color, white, Position (0 0 0), Angle (0 0 0) Spindle Type: Fixture, Name: Fixture, Connect To: Spindle, Connect Position: (0 0 0) Color: 5Magenta , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘fixture.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Stock © 2001 PTC Primitives: ‘spindle.stl’, Color, inherit, Position (0 0 0), Angle (0 0 0) Fixture Type: Spindle, Name: Spindle, Motion Axis: Z, Connect To: Base, Connect Position: (0 0 0) Color: 3Light Steel Blue, Mixed Mode: Shade, Angles: (0 0 0) Type: Stock, Name: Stock, Connect To: Fixture, Connect Position: (0 0 0) Color: 6Yellow , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘stock.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) 79 Exercise 7 - Turning machine Z Primitives: ‘z-axis.stl’, Color, Inherit,Rapid Rate, 200, Position (0 0 0), Angle (0 0 0) Primitives: ‘z-slide.stl’, Color, white, Position (0 0 0), Angle (0 0 0 X Primitives: ‘x-axis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Type: B Turret, Name: Turret, Motion Axis, Z, Connect To: X, Connect Position: (12.9103, 0, 15) Color: 2Green, Rapid Rate, 200, Mixed Mode: Shade, Angles: (0 0 0) (Notes: Offset value is measured from machine zero to left plane center of turret) Primitives: ‘turret.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Tool 1 © 2001 PTC Type: X Linear, Name: X, Motion Axis: X, Connect To: Z, Connect Position: (0 0 0) Color: 3Light Steel Blue, Rapid Rate, 200, Mixed Mode: Shade, Angles: (0 0 0) Turret Type: Z Linear, Name: Z, Motion Axis: Z, Connect To: Base, Connect Position: (0 0 0) Color: 4Cyan , Rapid Rate, 200, Mixed Mode: Shade, Angles: (0 0 0) Type: Tool, Name: Too l 1, Motion Axis, Z, Connect To:Turret, Connect Position: (0 0 0) Color: Red, Mixed Mode: Shade, Angles: (0 0 0) 80 Exercise 7 - Turning machine Tool 2 © 2001 PTC Type: Tool, Name: Too l 2, Motion Axis, Z, Connect To:Turret, Connect Position: (0 0 0) Color: Magenta, Mixed Mode: Shade, Angles: (0 0 -90) Save machine file in exercise 7 folder, give file name ‘2xturn.mch’ Add control file to machine use control file ‘2xturn-inch.ctl’, find it in exercise 7 folder 81 Exercise 7 - Turning machine About control file SUPERGROUP "Toolchange" { WORD_VALUE "T" { COND_AND "G" "65" { MACRO "MacroVar" } A super group ‘Toolchange’ must be in control file to enable turret rotation when tool change. See right box for details Open control file ‘2xturn-inch.ctl’ to find this super group © 2001 PTC } WORD_VALUE "T 1" { COND_AND "G" "65" { MACRO "NullMacro" } } WORD_VALUE "T 2" { COND_AND "G" "65" { MACRO "NullMacro" } MACRO "TurretRetract" MACRO "TurretIndex" MACRO "TurretLoadTool" MACRO "TurretActivateTool" MACRO "DwellTime" { OVERRIDE_VALUE 29.1655 } MACRO "DwellMacro" } WORD_VALUE "T 3" { COND_AND "G" "65" { MACRO "NullMacro" } MACRO "XAxisIncreMotion" { OVERRIDE_VALUE 0 } MACRO "ZAxisIncreMotion" { OVERRIDE_VALUE 0 } MACRO "ToolOffsetIndex" MACRO "ToolOffsetUpdate2" MACRO "ToolOffsetAptAdj2" MACRO "CutterCompValue" MACRO "ToolNoseCompValue" } } 82 Exercise 7 - Turning machine Set Input Program Zero Choose: Job / Tables In Job Tables window, choose: ‘Input Program Zero’, see following figure for other parameters setting Give Index=1 (Note 1: Values (-12.9103, 0, -8) is measured from left plane center of turret to right plane center of stock) (Note 2: We are going to use right plane center of stock as programming center) Z X © 2001 PTC 83 Exercise 7 - Turning machine © 2001 PTC Test your machine with MDI X0Z0 position is shown in the following figure Stock and turret center lines are coincident Right plane of stock and left plane of turret are adjacent 84 Exercise 7 - Turning machine Transfer tools from Pro/NC to VERICUT Open MFG file in Pro/NC Change Pro/E working directory to …\exercise 7 Open MFG file ‘turn.mfg’, In Pro/NC, choose: CL Data / NC Check / CL File (open ‘turn.ncl’) /Done Run simulation, exit VERICUT (Notes, by running VERICUT simulation, tools data can be transferred from Pro/NC to VERICUT automatically, which will be called in VERICUT MS) © 2001 PTC Load tool library to VERICUT MS In VERICUT MS, choose: Tools / Tool File Open file ‘cgtpro.tls’, find this file in exercise 7 folder 85 Exercise 7 - Turning machine © 2001 PTC Set Tool gauge offset In VERICUT MS, choose: Tools / Tool Manager In Tool Manager window, choose Tool 1, then click Modify In Tool Modify window, choose Properties In Tool Properties window, change Gage Offsets to: (7, 0, 0.25) Change Tool 2 gauge offset to (7 0 0.25) Save tool library Close Tool Manager window 86 Exercise 7 - Turning machine © 2001 PTC Load tool path file In VERICUT MS, choose: Job / Setting In Job Setting window, load tool path file to ‘turn.tap’, find in exercise 7 folder Change Log file to ‘2xturn.log’, save it in exercise 7 folder See following figure for other settings 87 Exercise 7 - Turning machine © 2001 PTC Build Tool Index Table In VERICUT MS, choose: Tools / Tables In Tool Tables window, choose Table Name as ‘Tool Index Table’, then click Build Tool List, 2 lines of tool index info appears. Two tools appears on turret too. Close Tool Tables window. Save JOB file Give JOB file name ‘2xturn.job’, save it in exercise 7 folder 88 Exercise 7 - Turning machine Run simulation Check dimension after simulation Use Analysis / X-Caliper to check diameters, D1 and D2, see if it is same as design model in Pro/NC D1 © 2001 PTC D2 89 Exercise 8 - Outline Outline Mill/Turn machining center Create components and assembly in Pro/E Export components in STL format Linear components Rotary components Build machine kinematics and load STL files Set input program zero Load control file, mill-turn control introduction Create MFG file in Pro/NC, generate TAP file using PP Run NC Check to transfer tools and Stock data from Pro/NC to VERICUT, which will be used later Load tool library file to Machine Simulation. Set turning tool gage offset Load Tool path file © 2001 PTC 90 Exercise 8 - Outline Build tool list Set Turret rotation angle for milling tools Play Machine Simulation Run VERICUT and Machine Simulation simultaneously Open USR file Load stock file Set toolpath orientation Load Tool library file Load Tool path file G-Code setting, connect USR file with a JOB file Open Machine Simulation form VERICUT © 2001 PTC Run VERICUT and Machine Simulation together 91 Exercise 8 - Mill/Turn Build Mill/Turn machining center © 2001 PTC Load machine components and assembly in Pro/E Set Pro/E working directory to: …\exercise 8\machine-proe\ Open file: ‘mill-turn.asm’ Find all components and assembly file in folder: …\exercise 8\machine-proe\ 92 Exercise 8 - Mill/Turn Export components in STL format Export non rotary components It includes all components except ‘turret’ and ‘tool-holder’ User CSYS in machine zero, it is located at right side plane center of spindle Take both ‘z-slide’ components when exporting ‘z-side’, same comments for ‘x-slide’ Use ‘0.1’ or smaller for chord height Give STL files same name as proe part X Z ACS3 © 2001 PTC 93 Exercise 8 - Mill/Turn Export rotary components It includes ‘turret’ and four ‘tool-holder’ Use CSYS (ACS4) at rotating center of turret Export four holder components separately, give them name ‘holder-1, holder-3, holder-5, holder-7. See following figure for holder number and location Holder-1 Holder-3 Holder-7 Holder-5 © 2001 PTC 94 Exercise 8 - Mill/Turn Build machine kinematics See following figure and next 3 pages for details Tips © 2001 PTC Make sure Tool Index Number is set right Make sure Angle is right 95 Exercise 8 - Mill/Turn Machine components Base Type: Base, Name: Base, Color: 3Light Steel Blue, Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘base.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Primitives: ‘base-slide.stl’, Color, white, Position (0 0 0), Angle (0 0 0) Spindle Type: Fixture, Name: Fixture, Connect To: Spindle, Connect Position: (0 0 0) Color: 5Magenta , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘fixture.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Stock © 2001 PTC Primitives: ‘spindle.stl’, Color, inherit, Position (0 0 0), Angle (0 0 0) Fixture Type: Spindle, Name: Spindle, Motion Axis: Z, Connect To: Base, Connect Position: (0 0 0) Color: 3Light Steel Blue, Mixed Mode: Shade, Angles: (0 0 0) Type: Stock, Name: Stock, Connect To: Fixture, Connect Position: (0 0 0) Color: 6Yellow , Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘stock.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) 96 Exercise 8 - Mill/Turn Z Primitives: ‘z-axis.stl’, Color, Inherit,Rapid Rate, 200, Position (0 0 0), Angle (0 0 0) Primitives: ‘z-slide.stl’, Color, white, Position (0 0 0), Angle (0 0 0 X Type: X Linear, Name: X, Motion Axis: X, Connect To: Z, Connect Position: (0 0 0) Color: 3Light Steel Blue, Rapid Rate, 200, Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘x-axis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Primitives: ‘x-slide.stl’, Color, white, Position (0 0 0), Angle (0 0 0) Y © 2001 PTC Type: Z Linear, Name: Z, Motion Axis: Z, Connect To: Base, Connect Position: (0 0 0) Color: 4Cyan , Rapid Rate, 200, Mixed Mode: Shade, Angles: (0 0 0) Type: Y Linear, Name: Y, Motion Axis: Y, Connect To: X, Connect Position: (0 0 0) Color: 4Cyan, Rapid Rate, 200, Mixed Mode: Shade, Angles: (0 0 0) Primitives: ‘y-axis.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) 97 Exercise 8 - Mill/Turn Turret (Notes: Offset value is measured from machine zero to left plane center of turret) Primitives: ‘turret.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Tool 1 Primitives: ‘holder-1.stl’, Color, Inherit, Position (-4.5,0,5.5), Angle (0 0 0) Type: Tool, Name: Too l 3, Motion Axis, Z, Connect To:Turret, Connect Position: (0, 4.5, -5.5) Color: Magenta, Mixed Mode: Shade, Angles: (0 0 0) , Tool Index Number: 3 Primitives: ‘holder-3.stl’, Color, Inherit, Position (0, -4.5,5.5), Angle (0 0 0) Tool 5 © 2001 PTC Type: Tool, Name: Too l 1, Motion Axis, Z, Connect To:Turret, Connect Position: (4.5, 0, -5.5) Color: Magenta, Mixed Mode: Shade, Angles: (0 0 0), Tool Index Number: 1 Tool 3 Type: B Turret, Name: Turret, Motion Axis, Z, Connect To: Y, Connect Position: (12.9103, 0, 13) Color: 2Green, Rapid Rate, 200, Mixed Mode: Shade, Angles: (0 0 0) Type: Tool, Name: Too l 5, Motion Axis, Z, Connect To:Turret, Connect Position: (0 0 0) Color: Magenta, Mixed Mode: Shade, Angles: (0 0 0) , Tool Index Number: 5 Primitives: ‘holder-5.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) 98 Exercise 8 - Mill/Turn Tool 7 © 2001 PTC Type: Tool, Name: Too l 2, Motion Axis, Z, Connect To:Turret, Connect Position: (0 0 0) Color: Magenta, Mixed Mode: Shade, Angles: (0 0 45) , Tool Index Number: 2 Tool 4 Primitives: ‘holder-7.stl’, Color, Inherit, Position (0 0 0), Angle (0 0 0) Tool 2 Type: Tool, Name: Too l 7, Motion Axis, Z, Connect To:Turret, Connect Position: (0 0 0) Color: Magenta, Mixed Mode: Shade, Angles: (0 0 0) , Tool Index Number: 7 Type: Tool, Name: Too l 4, Motion Axis, Z, Connect To:Turret, Connect Position: (0 0 0) Color: Magenta, Mixed Mode: Shade, Angles: (0 0 135) , Tool Index Number: 4 Save machine file, give name: ‘mill-turn.mch’ 99 Exercise 8 - Mill/Turn Set Input program zero It is measured from left side turret plane center to right side stock plane center Load Control file Open control file ‘mill-turn.ctl’ Save JOB file, ‘mill-turn.job’ Test your machine with MDI X Z X0Y0Z0 © 2001 PTC 100 Exercise 8 - Mill/Turn About Mill-Turn Control © 2001 PTC SUPERGROUP "Toolchange" { WORD_VALUE "T" { COND_AND "G" "65" { MACRO "MacroVar" } A super group ‘Toolchange’ must be in control file to enable turret rotation when tool change. } WORD_VALUE "T 1" { COND_AND "G" "65" { MACRO "NullMacro" } } WORD_VALUE "T 2" { COND_AND "G" "65" { MACRO "NullMacro" } MACRO "TurretRetract" MACRO "TurretIndex" MACRO "TurretLoadTool" MACRO "TurretActivateTool" MACRO "DwellTime" { OVERRIDE_VALUE 29.1655 } MACRO "DwellMacro" } WORD_VALUE "T 3" { COND_AND "G" "65" { MACRO "NullMacro" } MACRO "XAxisIncreMotion" { OVERRIDE_VALUE 0 } MACRO "ZAxisIncreMotion" { OVERRIDE_VALUE 0 } MACRO "ToolOffsetIndex" MACRO "ToolOffsetUpdate2" MACRO "ToolOffsetAptAdj2" MACRO "CutterCompValue" MACRO "ToolNoseCompValue" } } 101 Exercise 8 - Mill/Turn Mill/Turn mode change macro must be in M_Misc Supergroup WORD_VALUE "M" "35" { MACRO "VC_ModeMilling" } WORD_VALUE "M" "36" { MACRO "VC_ModeTurning" } © 2001 PTC 102 Exercise 8 - Mill/Turn X multiplier © 2001 PTC X multiplier for word X must match the setting in Lathe post-processor 103 Exercise 8 - Mill/Turn MFG file in Pro/NC Set Pro/E working directory to: …\exercise 8\mfg-pronc\ Open file: ‘mill-turn-2.mfg’ Create NCL file for whole operation, give name: ‘millturn.ncl’ Performing NC Check to transfer Tools from Pro/NC to VERICUT In Pro/NC, choose: CL Data / NC Check / CL File / (choose file ‘mill-turn.ncl’) /Done Create TAP file Using Post-Processor ‘fan16t’ to post the NCL file, give TAP file name ‘mill-turn.tap’ PP ‘fan16t’ is merged with PP ‘fan16m’, it is a mill/turn merged post-processor © 2001 PTC 104 Exercise 8 - Mill/Turn Load Tool and Tool Path file Copy file ‘cgtpro.tls’ and ‘mill-turn.tap’ to folder …\exercise 8\VERICUT. Change file name of ‘cgtpro.tls’ to ‘mill-turn.tls’ Load tool library Set turning tool gage offset © 2001 PTC In VERICUT MS, choose: Tools / Tool File, open file ‘mill-turn.tls’ Set both turning tool (T2 and T4) gage offset to (7, 0, 0.25). Refer Exercise 7 for details 105 Exercise 8 - Mill/Turn © 2001 PTC Load Tool path file In VERICUT MS, choose: Job / Job Setting Load tool path file ‘mill-turn.tap’ Build tool list Choose: Tools / Tables / Tool Index Table /Build Tool List Reset Machine Simulation, tools appear on turret 106 Exercise 8 - Mill/Turn Set turret rotation angle for two milling tools Turret rotation angle only need to be set for milling tools Choose: Tools / Tables / Turret Rotation, see following figure for details, index # here reflects Tool ID # Turret rotates this angle when the tool is called in tool path file The angle is measured from the tool original orientation to dash line (position when tool in use) X Save JOB file Tool 1 Y Tool 3 Rotate To © 2001 PTC 107 Exercise 8 - Mill/Turn Play simulation Reset VERICUT MS, play simulation Run VERICUT and Machine Simulation simultaneously USR file setting Copy files ‘cgpro.usr’ and ‘cgpro1.stk’ in folder …\exercise 8\mfg-pronc\ then paste then in folder …exercise 8\vericut\ Change USR file name to: ‘mill-turn.usr’ Open USR file ‘mill-turn.usr’ © 2001 PTC Load stock file. In VERICUT choose: Model / Model Definition / Stock / (open polygon file ‘cgtpro1.stk’) / Apply 108 Exercise 8 - Mill/Turn Set Toolpath orientation In VERICUT, choose: Toolpath / Toolpath Orientation Give (0 0 7) for Ref(XYZ) Notice that from right side of stock (input programming zero) to it primitive origin is 7 7 © 2001 PTC 109 Exercise 8 - Mill/Turn Load Tool library file © 2001 PTC In VERICUT, choose: Tools / Tool Control / Tool Library (open tool library file ‘mill-turn.tls’) / OK 110 Exercise 8 - Mill/Turn Load Tool path file In VERICUT, choose: Toolpath / Toolpath Control In Toolpath Control window, open Tool path file ‘mill-turn.tap’, set toolpath type=G-Code Data, Multiple Toolpath Files=No © 2001 PTC 111 Exercise 8 - Mill/Turn G-code settting In Toolpath Control window, choose G-code setting In G-Code Setting window, choose: File / Open (open file ‘millturn.job’) Choose: File / Close Choose Ok in Tool path control window © 2001 PTC Connect to Machine Simulation In VERICUT, choose: Applications / Machine Simulation 112 Exercise 8 - Mill/Turn Resize VERICUT and Machine Simulation window Click Play button (in either window) © 2001 PTC 113