Rapid Prototyping Lab
 VersaLaser    Fused Deposition    CNC Mill   Choose your machine (FAQ)  
   
                                             General Information    Preparation instructions    Operating instructions 

Our site is under construction and the information will be updated as we continue to test the prototyping machines


File Preparations for the CNC Mill



File Format and Preparation

To use the CNC Mill, a user must first create a Computer Aided Design file using a CAD software packages such as Solid Works, IronCAD, AutoCAD, and ProEngineer or illustrator.

Next the tool selection and path must be programmed; the user needs to decides where the path followed by cutting tool (as well as the depth) , and which tool will be mounted and when to change tools. This process is described by the G and M codes.

There are several methods to generate G-code from a cad file or a drawing. We describe here the definition of a 2D tool path from DXF to gcode using the ACE converter.

Additional information on preparing G-Code files: VMC 4000 Information Page.

You can also program your own G-code and test it with the simulator below.

 

Preparing the CAD file:

When preparing your CAD file, you need to draw the exact cutting path for the tool, therefore, you need to consider the size of the tool.

Make sure you define your units in either inches or millimeters consistently (throughout the whole process) starting from the drawing or model file, the Gcode generator, and the Benchman operation software.

  • Prepare a 2D drawing file using Autocad, Illustrator, or IronCAD
  • Save this in DXF (version 12 or 13 work best).

 

Converting to G-code (using the ACE converter)

ACE converter is A free G-code generator that allows you to define tool paths in 2D. ACE will only read 2D dxf files.
It is located in the computer in the RP LAB. (downloads sources below)

  • Open ACE converter software

  • Load the DXF file

  • Set properties for each layer
    You can assign a depth of cutting for each layer of the file, therefore accounting for many cutting types and depths.



  • Set the post-priority, the pre- priority and the release value (for the whole file)

  • The pre-priority code is Mcode to add in the begriming of the file, usually to set the tool number and spindle speed. Ex::
    M06 T08 (tool change #8)
    M03 S1000 (clockwise and speed 1000)

  • The post-priority code is the Mcode to add in the end of the file, usually to end the program. Ex:
    M05 stop
    M02 end the program

  • The release-value is for is for moving the tool above the material between cuts. Zero is where the material starts. Ex
    (.25 inch above zero in the z-axis)




  • After the setting is complete, click convert: it will convert the drawing to Gcode.
    Save your file as a .txt or a .nc file

  • You can test the Gcode generated in ACE using CNC simulator.







Free G and M Code Generators and Simulators



G and M Codes

G-Code is for describing the tool path by means of coordinates, while M-codes are for describing machine commands, such as tool types, speeds and starting the ending the program. Both are necessary to run the program.

Short introduction to G and M codes to know.

G00  positioning (rapid traverse)
G54  work coordinate system 1 select
G01  linear interpolation (feed) 
G55  work coordinate system 2 select
G02  circular interpolation CW 
G56  work coordinate system 3 select
G03  circular interpolation CCW
G57  work coordinate system 4 select
G04  dwell
G58  work coordinate system 5 select
G07   imaginary axis designation
G59  work coordinate system 6 select
G09   exact stop check 
G60  single direction positioning
G10   offset value setting
G61  exact stop check mode
G17   XY plane selection
G64  cutting mode
G18   ZX plane selection
G65  custom macro simple call
G19  YZ plane selection
G66  custom macro modal call
G20  input in inch
G67  custom macro modal call cancel
G21  input in mm
G68  coordinate system rotation ON
G22  stored stroke limit ON
G69  coordinate system rotation OFF
G23  stored stroke limit OFF
G73  peck drilling cycle
G27  reference point return check
G74  counter tapping cycle
G28  return to reference point
G76  fine boring
G29  return from reference point
G80  canned cycle cancel
G30  return to 2nd, 3rd & 4th ref. point
G81  drilling cycle, spot boring
G31  skip cutting
G82  drilling cycle, counter boring
G33  thread cutting
G83  peck drilling cycle
G40  cutter compensation cancel
G84  tapping cycle
G41  cutter compensation left
G85,G86   boring cycle
G42  cutter compensation right
G87  back boring cycle
G43  tool length compensation + direction
G88,G89  boring cycle
G44  tool length compensation - direction
G90  absolute programming
G49  tool length compensation cancel
G91  incremental programming
G45  tool offset increase
G92  programming of absolute zero point
G46  tool offset decrease
G94  per minute feed
G47  tool offset double increase
G95  per revolution feed
G48  tool offset double decrease
G96  constant surface speed control
G50  scaling OFF
G97  constant surface speed control cancel
G51  scaling ON
G98  return to initial point in canned cycle
G52  local coordinate system setting
G99  return to R point in canned cycle

 

M00  program stop
M21  tool magazine right
M01  optional stop
M22  tool magazine left
M02  end of program (no rewind)
M23  tool magazine up
M03  spindle CW
M24  tool magazine down
M04  spindle CCW
M25  tool clamp
M05  spindle stop
M26  tool unclamp
M06  tool change
M27  clutch neutral ON
M07  mist coolant ON
M28  clutch neutral OFF
M08  flood coolant ON
M30  end program (rewind stop)
M09  flood coolant OFF 
M98  call sub-program
M19  spindle orientation ON
M99  end sub-program


Cost

Cost is dependent on Material, Tolerance, and Size.

Material: certain stock materials are more expensive than others. Higher grades of stock take more time to cut and are therefore more expensive. Stronger materials cause more wear on the mill.

Tolerance: Tolerances using a CNC milling machine can be as tight as 1 thousandth of an inch. Production tolerances are sometimes acceptable because human error and machine deviance are inevitable. The tighter the tolerances needed, the higher the cost.

Size and complexity: Larger pieces lead to higher costs; larger, more complex parts take longer to produce, and therefore, cost more.

You need to buy your materials (machine wax) from the Mechanical Engineering Workshop

 

 
Rapid Prototyping Lab @ Carnegie Mellon University --- Contact Webmaster hoda@cmu.edu Top of Page Top