Custom Macro Enables Automated CNC Program Generation
Rex Materials Group uses a custom macro from DP Technology to automate CNC programming.
Share




Automation doesn’t always have to take the form of robots or unattended machining cells. Rex Materials Group used a custom macro from DP Technology (Camarillo, California) to automate CNC programming of custom-engineered insulation products. In fact, the macros completely eliminated engineering from the production process, enabling the company to produce the product faster and at a lower price.
Fowlerville, Michigan-based Rex Materials specializes in high-temperature insulation products made from materials including vacuum-formed ceramic fiber, fused silica, insulating refractory and a ceramic/ceramic-metal matrix composite. These products are custom-formed to fit water heaters, kilns, injection molding barrels and more. Production involves mixing components, such as fiberglass flakes, water and other chemicals, in a batch tank, pumping the mixture into a mold and baking it in an oven. Normally, the products are cast to near net shape and then cut to final dimensions on a CNC machine.
One of Rex Materials’ newest products, Rex TCS, is designed to control barrel temperature in plastic extrusion and injection molding applications. To ensure the product line’s competitiveness, the company needed to decrease the cost by reducing the manufacturing engineering time needed to ready the design for production. “There’s a lot of variability in the lengths and diameters of barrels, which require a custom layout for the different heaters,” explains Adam Boyd, Rex Materials manufacturing engineer. Depending on the complexity of the part, it can take 2 to 12 hours to program the company’s MultiCAM and CNT Motion cutting machines. “If this product was going to make it to the widest possible market, we had to reduce programming time,” Mr. Boyd says.
The first step in achieving this goal was moving the TCS from manual to CNC production. A year and a half earlier, the company had adopted Esprit CNC programming software from supplier DP Technology in an effort to reduce engineering time. Esprit’s KnowledgeBase CAM software helps determine the best method to machine a given part or feature by automatically selecting the most appropriate machining cycles, cutting tools and machining parameters. “We bought Esprit because we were trying to avoid the expense of having an engineer look at every part,” Mr. Boyd explains. “Having software that could make some of the machining decisions would be a step toward that.”
A programmer begins by importing a SolidWorks CAD model into Esprit and selecting and organizing part features. The next step is defining machining operations. For each toolpath, the programmer selects a tool and defines its diameter, length, toolholder and speeds and feeds. After the toolpath is generated, the programmer uses the software’s simulation functionality to visualize the cutting process. The entire machining process, including each individual cut, is rendered in dynamic 3D solids. The program also generates a representation of the finished part for comparison to the original design.
Esprit helps program complex parts quickly, Mr. Boyd says, because the software can recognize and apply tool paths to complex curvatures. The mold function enables the operator to apply a roughing operation first, if necessary, and tells the software what can and cannot be touched. It then runs simulation to ensure the operation performs as expected. In addition to saving time, Esprit saves the cost of having to purchase special tools.
For the TCS, Mr. Boyd decided to take advantage of Esprit’s macro programming functionality. Macros simplify the creation of CNC programs by prompting the programmer to enter dimensions and other basic information for each type of part. He says the macro is well-suited for TCS production because the length, height and width of the products vary according to the shapes of customers’ injection barrels.
Esprit’s macro programming language is based on the industry-standard programming language Microsoft Visual Basic for Applications (VBA). Esprit enables programmers to use VBA to access virtually all of its capabilities. However, rather than developing the macro in-house, Mr. Boyd decided to have DP Technology create it for the company. He supplied a model of the basic heater, which is a hollow cylinder, and indicated all the dimensions and how they could vary. He also provided a sample CNC program to show the cutting strategy.
The macro that DP Technology created completely eliminates engineering from the TCS production process. “It uses information obtained by the sales person to automatically generate the CNC file,” Mr. Boyd says. A sales person enters values for the length, height, outside diameter and inside diameter of the product into a configurator. Special instructions, such as needing a flat instead of a rounded top, can also be entered into the configurator. The information then is exported into a Microsoft Excel file. In Esprit, a technician opens the macro and selects the Excel file. “Nearly everyone coming into our plant knows how to use Microsoft Windows, and that’s all they need to know to create the TCS machining programs,” Mr. Boyd says. Using the information in the Excel file, the macro writes the CNC program. As an added benefit, it also creates a drawing and a bill of materials.
Before implementing the Esprit macro, the company’s traditional programming process took at least 2 hours per part. Now, the TCS products can be automatically generated in 15 to 20 minutes. At 40 such programs a month, the macro saves 13 hours per month. Also, because the work is done by a technician rather an engineer, the cost savings enables the company to sell the new product at a more competitive price.
Related Content
Building A Powerful Bridge from the CAM Programmer to the Shop Floor Operator
SolidCAM for Operators provides a powerful bridge from CAM programming to the shop floor to best streamline the machine shop process with its CAM part simulation. It provides a clear picture to the operator for setup and prove-out, enables minor G-Code changes and avoids crashes, broken tools and scrapped parts.
Read MoreCutting Part Programming Times Through AI
CAM Assist cuts repetition from part programming — early users say it cuts tribal knowledge and could be a useful tool for training new programmers.
Read MoreThe Power of Practical Demonstrations and Projects
Practical work has served Bridgerland Technical College both in preparing its current students for manufacturing jobs and in appealing to new generations of potential machinists.
Read MoreCan ChatGPT Create Usable G-Code Programs?
Since its debut in late 2022, ChatGPT has been used in many situations, from writing stories to writing code, including G-code. But is it useful to shops? We asked a CAM expert for his thoughts.
Read MoreRead Next
AMRs Are Moving Into Manufacturing: 4 Considerations for Implementation
AMRs can provide a flexible, easy-to-use automation platform so long as manufacturers choose a suitable task and prepare their facilities.
Read MoreLast Chance! 2025 Top Shops Benchmarking Survey Still Open Through April 30
Don’t miss out! 91ÊÓÆµÍøÕ¾ÎÛ's Top Shops Benchmarking Survey is still open — but not for long. This is your last chance to a receive free, customized benchmarking report that includes actionable feedback across several shopfloor and business metrics.
Read MoreMachine Shop MBA
Making Chips and 91ÊÓÆµÍøÕ¾ÎÛ are teaming up for a new podcast series called Machine Shop MBA—designed to help manufacturers measure their success against the industry’s best. Through the lens of the Top Shops benchmarking program, the series explores the KPIs that set high-performing shops apart, from machine utilization and first-pass yield to employee engagement and revenue per employee.
Read More