G-code - Programming Environments

Programming Environments

G-code's programming environments have evolved in parallel with those of general programming—from the earliest environments (e.g., writing a program with a pencil, typing it into a tape puncher) to the latest environments that stack CAD (computer-aided design), CAM (computer-aided manufacturing), and richly featured G-code editors. (G-code editors are analogous to XML editors, using colors and indents semantically to aid the user in ways that basic text editors can't. CAM packages are analogous to IDEs in general programming.)

Two high-level paradigm shifts have been (1) abandoning "manual programming" (with nothing but a pencil or text editor and a human mind) for CAM software systems that generate G-code automatically via postprocessors (analogous to the development of visual techniques in general programming), and (2) abandoning hardcoded constructs for parametric ones (analogous to the difference in general programming between hardcoding a constant into an equation versus declaring it a variable and assigning new values to it at will; and to the object-oriented approach in general). Macro (parametric) CNC programming uses human-friendly variable names, relational operators, and loop structures much as general programming does, to capture information and logic with machine-readable semantics. Whereas older manual CNC programming could only describe particular instances of parts in numeric form, parametric CAM programming describes abstractions which can be flowed with ease into a wide variety of instances. The difference has many analogues, both from before the computing era and from after its advent, such as (1) creating text as bitmaps versus using character encoding with glyphs; (2) the abstraction level of tabulated engineering drawings, with many part dash numbers parametrically defined by the one same drawing and a parameter table; or (3) the way that HTML passed through a phase of using content markup for presentation purposes, then matured toward the CSS model. In all of these cases, a higher layer of abstraction was introduced in order to pursue what was missing semantically.

STEP-NC reflects the same theme, which can be viewed as yet another step along a path that started with the development of machine tools, jigs and fixtures, and numerical control, which all sought to "build the skill into the tool". Recent developments of G-code and STEP-NC aim to build the information and semantics into the tool. The idea itself is not new; from the beginning of numerical control, the concept of an end-to-end CAD/CAM environment was the goal of such early technologies as DAC-1 and APT. Those efforts were fine for huge corporations like GM and Boeing. However, for small and medium enterprises, there had to be an era in which the simpler implementations of NC, with relatively primitive "connect-the-dots" G-code and manual programming, ruled the day until CAD/CAM could improve and disseminate throughout the economy.

Any machine tool with a great number of axes, spindles, and tool stations is difficult to program well manually. It has been done over the years, but not easily. This challenge has existed for decades in CNC screw machine and rotary transfer programming, and it now also arises with today's newer machining centers called "turn-mills", "mill-turns", "multitasking machines", and "multifunction machines". Now that CAD/CAM systems are widely used, CNC programming (such as with G-code) requires CAD/CAM (as opposed to manual programming) to be practical and competitive in the market segments served by these classes of machines. As Smid says, "Combine all these axes with some additional features, and the amount of knowledge required to succeed is quite overwhelming, to say the least." At the same time, however, programmers still must thoroughly understand the principles of manual programming and must think critically and second-guess some aspects of the software's decisions.

Since about the mid-2000s, the era has finally arrived when "the death of manual programming" (that is, of writing lines of G-code without CAM assistance) sometimes seems to be approaching. However, it is currently only in some contexts that manual programming is obsolete. Although it is true that plenty of CAM programming can and does take place nowadays among people who are rusty on, or incapable of, manual programming, it is not true that all CNC programming can be done, or done as well or as efficiently, without being able to speak the language of G-code. Tailoring and refining the CNC program at the machine is an area of practice where it can be easier or more efficient to edit the G-code directly rather than editing the CAM toolpaths and re-post-processing the program.

Read more about this topic:  G-code

Famous quotes containing the words programming and/or environments:

    If there is a price to pay for the privilege of spending the early years of child rearing in the driver’s seat, it is our reluctance, our inability, to tolerate being demoted to the backseat. Spurred by our success in programming our children during the preschool years, we may find it difficult to forgo in later states the level of control that once afforded us so much satisfaction.
    Melinda M. Marshall (20th century)

    Corporate America will likely be motivated to support child care when it can be shown to have positive effects on that which management is concerned about—recruitment, retention and productivity. Indeed, employers relate to child care as a way to provide growth fostering environments for young managers.
    Dana E. Friedman (20th century)