Research Proposal: Easy, Open-Source Toolpath Software

Complex commercial toolpath software interface.

Complex & expensive commercial toolpath software interface.

The purpose of this research is to develop robust and easy-to-use open-source software for converting digital designs into machine tool output (toolpathing), as well as exhaustive documentation structured around use & modification.

This research proposal is directly related to the Accessible CNC Designs proposal and the DIYLILCNC project, and could take place as concurrent or separate research.

Background

CNC devices such as waterjet cutters, laser cutters, CNC mills and 3D printers have had a large impact on industry and manufacturing over the last several decades.  The precision and repeatability with which a CNC device can fabricate a part are on par with more mature mass production techniques such as casting or die stamping; however, unlike traditional mass production processes, CNC manufacturing is not subject to the constraints of inflexibility and lead-time for machine setup.  Generally speaking, it is no more expensive per part to use a CNC device to fabricate a single iteration than it is to produce multiples, unlike mass production where one-off products are prohibitively expensive due to setup costs.  Additionally, CNC-fabricated parts are based on descriptions stored in digital files, allowing for relatively quick and easy modification, as well as sharing over long distances.

For all their benefits, CNC devices are still marginal tools from the perspective of a small-scale artist, designer or tinkerer (aka Maker).  This is due in large part to the high cost of such devices.  Further, the software workflows used to create and prepare a CNC part description can be both prohibitively expensive and difficult to use; most of the educational content centered around CNC software processes is aimed at engineers and machinists, and is often unhelpful to Makers with more diverse backgrounds.

CNC manufacturing is in a state today that parallels digital computing in its early stages: devices and easy-to-use software are expensive and scarce, making access on the part of untrained Makers difficult, if not impossible.  Digital computers have become cheaper and more prevalent over the past several decades; at the same time, open-source operating systems and software packages–such as Mozilla Firefox, Linux and Apache–have bolstered the digital computing revolution, allowing users free and customizable control over their info-processing devices.

The digital computing revolution comes at the tail end of a centuries-long shift in information control.  Images and text were once produced by just a handful of elite individuals; since the advent of the mechanical printing press, there has been a steady push towards democratizing technology that enables ordinary people to create and distribute information.  Access to affordable, networked digital computing hardware and access to robust, easy-to-use open-source software have worked together to accelerate this process even further.

In order for digital fabrication technology to show its true potential, CNC devices and the software used to control them, must undergo a change similar to that of digital computing and open-source projects such as Linux, respectively.  Since the Industrial Revolution, production of physical parts and products has been controlled by a relatively small number of industrialists.  Networks of distributed, low-cost CNC production devices, controlled by easy-to-use open-source software, have the same democratizing potential for the means of physical production as digital computing has for information production.  The implications of such a change are potentially huge; many basic scenarios that we take for granted, from the size and orientation of our cities to the way we grow and eat food, are byproducts of mass production’s role in society.  The proliferation of easy-to-use open-source software and supplementary educational materials that facilitate use and modification of CNC devices is the first step towards a distributed object creation network.

Technical Challenges

The software workflow used to prepare and manufacture parts using a CNC device usually requires multiple programs, each with a different area of specialization.  Some steps in the workflow are supported by robust, easy-to-use open-source software; other steps are not.  Open-source software–defined as computer software which is made freely available in human-readable/editable source code form–contrasts with proprietary software, which is licensed under the ownership of its author, generally restricting any rights to modification or reverse engineering on the part of the end user.  Open-source software is often developed in a public, collaborative manner, allowing any author to make changes or improvements to the source code.  Open-source software offers several advantages over proprietary software, including: ease of modification and porting to other software languages or operating systems; independence from the life of a business;  reviewable code allows checks for security flaws; and, of course, affordability.

Typical CNC Software Workflow:

  1. CAD. CNC fabrication starts with a computer aided design (CAD) program that allows a Maker to create a digital representation of an ideal two or three-dimensional part, often through a graphical interface.  Many CAD programs have built-in measurement and snapping tools which make precise digital drafting much easier.  Common proprietary programs for CAD include Rhino, AutoCAD, Solidworks, and many others, ranging in price from just under $1,000, up to $20,000 or more.  Some open-source alternatives do exist: older programs such as BRL-CAD offer learning curves just as steep as commercial packages; newer programs such as FreeCAD and NaroCAD are still in their infancy and are not robust enough for serious CAD production.
  2. Toolpathing. Once a digital design is complete, it is translated through a process called toolpathing, which determines numeric descriptions of the physical tool behaviors required to produce a digital design.  For example, a CNC device that uses a rotary cutter to carve parts from stock material requires numerical coordinates for each point in space where the cutting tool must travel to remove material.  When generating toolpaths, applications can take into account many different machine attributes such as cutting tool diameter, motion speeds, material density, and the number of motion axes.  Additionally, toolpathing programs can choose from different generalized operations such as roughing, which will remove or deposit large volumes of stock in a coarse manner; or finishing, which will more finely add or remove material for smooth finishes.  Toolpaths are most often saved as plain text files, formatted in the simple machine movement called G-Code.  Toolpathing programs vary in their ability to handle processes for two or three-dimensional parts, and so span a broader range of prices: from under $100 to $10,000 or more.  Common toolpathing programs include VisualMill, MasterCam and CamBam.  Some very nascent open-source and online toolpathing programs are emerging, such as PyCAM and PartKAM.
  3. CAM. Computer aided manufacturing (CAM) is the final process in CNC production, where toolpath information stored in a digital file is passed through a program that translates toolpath coordinates into physical machine movements.  CAM processes require software to interpret toolpaths and send corresponding signals to motion controllers as well as hardware to cycle power to motors and other machining devices.  CAM software is often proprietary, and packaged with a commercial CNC device.  Low-cost generic CAM programs exist, such as Mach3 or TurboCNC.  Additionally, CAM processes are supported by a very robust and reliable open-source software package called Enhanced Machine Controller (EMC), which is packaged with the open-source operating system Linux.  EMC is relatively easy to use, and is supported by a large group of users and developers.

G-code was first developed in the 1950’s, and has become more complex over time.  It has the advantages of being a commonly accepted standard for CNC device programming, however there may be methods for machine control that offer more intuitive means of interaction with a Maker.  Many toolpathing software packages are written with a wizard-style interface that hides G-code generation from the user, making generation less complex but also limited to the constraints of the software.  A question this research aims to address is whether G-Code is the appropriate standard for CNC device programming, or whether a new, more user-friendly standard for encoding digital designs is preferable and feasible to create.  An ideal CNC toolpathing software package will combine the ease-of-use of a wizard-style interface with opportunities for customization on the part of a Maker.

An additional challenge in designing a software package for CNC toolpathing is the broad range of CNC devices in existence and their various requirements for control: laser cutters need different toolpath settings than 3D printers, for example.  This problem could be addressed by making generic profiles for several of the common styles of CNC device, however this would not necessarily take into account future modifications to these machine definitions, nor would it address CNC devices that are as yet uninvented.  A better approach, perhaps, would be to design a software with a CNC device modeling component, that would allow a Maker to create custom profiles for any CNC device, no matter how unorthodox.  This component could include choices for axial motion (linear vs. rotary), reductive vs. additive processes, size constraints, etc.

Functionality is the bare minimum for any software package. Useful programs have to run without crashing, the controls have to be responsive, etc.  For many open-source software packages, functionality is the first major hurdle; most initial development effort goes into making an application that is simply functional.  Unfortunately, functionality is not enough.  Even the most elegantly programmed, crash-proof software is all but useless without thorough documentation and educational resources for users.  This research aims to incorporate a strong base of Maker-oriented documentation that explains in lay terms every aspect of toolpath generation, combined with opportunities for Makers to contribute to and improve documentation and tutorials on use and modification of the software.  This could be accomplished using a few different approaches: including tooltip-style interface notes that pull from a centralized, community-editable documentation website; hosting an online user forum for questions and answers; publishing tutorials for specific, common applications of toolpath software.