Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.First time visiting? Here are some places to start:
- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
GENERATE GCODE FOR HOLE PATTERN ON PART FACE DIRECTLY FROM PART STUDIO?
I would like to create a feature for generating GCode for CNC drilling a hole pattern on a part face directly from a Part Studio without the use of a conventional CAM program.
Our specific application involves fabricating frames for FIRST Robotics Competition robots and related structures from T-Slot extrusion (8020 10 series). The frame members are joined by bolted connections that require through- or counterbored holes on one or more faces. A typical robot assembly may include 50 or more frame member instances drawn from 20 or more unique parts.
Our current fabrication workflow involves cutting extrusion stock to length and manually drilling the holes on a DRO-equipped mill, guided by an ordinate-dimensioned Onshape part drawing of the relevant part faces. This workflow involves several wasteful steps and multiple opportunities for human error.
Migrating to a CNC fabrication method offers only limited advantages over the manual workflow. The Onshape-connected desktop CAM programs that will accept an exported part file impose a considerable burden of learning and effort for this simple task. A DXF or other 2D image of the part face must be exported from Onshape to a CAM program, vectors or points describing the hole positions must be mapped to a toolpath for calculation, and the Gcode output saved to a file for use by the CNC.
Most CNC controllers enable the use of “canned” drilling methods. The GCode block for a typical extrusion hole pattern requires only a dozen or so lines of header information specifying tool information and depth of cut and a single line for the XY coordinates of each hole. Given the limited information needed to complete the task, using a CAM program that is equipped for a wide range of toolpath options adds considerable overhead to this simple task.
I envision a feature that would allow the Onshape user to specify an extrusion face and select the type of hole (simple, counterbore). The method would perceive the hole locations and write the Gcode header and hole positions to a text file that could be exported directly to the CNC. A useful adjunct to the hole pattern feature would be to export a Gcode block that would score the beginning and ending edges of the extrusion face as a guide to sawing the part to length.
Full disclosure: I have extremely limited coding experience and have never attempted FeatureScript. I would appreciate any input or critique regarding the feasibility of the above scheme and advice on the best path to follow to make it happen.