Automatically Backing Up Your Fixture Offsets
In most applications, offsets are so dynamic (often changed) that that you wouldn’t even consider keeping a backup copy. But consider a more complicated machining center qualified setup. A backup copy may prove to be beneficial.
In most applications, offsets are so dynamic (often changed) that that you wouldn’t even consider keeping a backup copy. With turning center wear offsets, for example, the operator must often change the value of each to keep parts on size. Additionally, offset values commonly change with each setup. Turning center geometry offsets, for example, rarely remain exactly the same from one time a job is run to the next.
Even when it is feasible to back up your offsets, it is usually pretty simple to write them down and manually create G10 commands. Consider a qualified setup on a machining center that requires only one program-zero assignment. It’s pretty easy to write down the fixture offset settings and plug them into a G10 command.
For these reasons, most control manufacturers provide no way to back up offset settings. By comparison, of course, you can back up your CNC programs and parameter settings. With most machines, doing so requires the use of the communications (serial) port on the machine in conjunction with some kind of distributive numerical control (DNC) system.
But consider a more complicated machining center qualified setup. Maybe the machine is an HMC with a rotary table and two pallets and one program-zero assignment is required for each side of the pallet. This means eight sets of program zero assignment values (48 values) must be backed up. The more sets of values you must deal with, the longer it will take to manually transfer them into G10 commands, and the more prone to errors you’ll be.
A custom macro B function called DPRNT allows you to send data from the machine using the serial port—the same port used to transfer programs and parameters. When used in conjunction with other custom macro B commands, you can have the machine automatically create a complete program containing fixture offsetting G10 commands and send it out through the serial port to your DNC system. These commands will reference the current fixture offset settings. The next time the job is run, you can load and run the G10 program just as you would any other CNC program. Or, you could also copy and paste the G10 commands into the machining program with a text editor.
This custom macro, provided by Steve Legg in Toronto, Canada, will output the fixture offset program through the serial port. It assumes the standard set of (six) fixture offsets is being used and that fixture offset system variables are in the #5200 series. Note that if you have the 48 fixture offset option, this program must be modified, but very similar techniques can be used.
O5555 (Fixture offset output program)
(Operator must set #9)
#9=6. (Number of fixture offsets to output -- Max=6)
#4=1. (Initialize counter)
POPEN (Open the serial port gate)
DPRNT[]
DPRNT[O0001]
DPRNT[]
DPRNT[M00]
WHILE [#4 LE #9] DO 1 (Loop to write each fixture offset)
#33=5200. + [#4 * 20.] (Point at current fixture offset system variable)
#32=53. + #4 (G code number for fixture offset)
DPRNT[]
DPRNT[G#32[20]] (Output fixture offset G code – like G54)
#24=#[#33 + 1.] (X register data)
#25=#[#33 + 2.] (Y register data)
#26=#[#33 + 3.] (Z register data)
#2=#[#33 + 4.] (B register data)
DPRNT[G90*G10*L2*P#4[10]*X#24[34]*Y#25[34]*Z#26[34]*B#2[43]]
#4=#4 + 1. (Step the counter)
END 1
DPRNT[]
DPRNT[M30]
PCLOS (Close the serial port gate)
M30
Here is the program that will be sent through the serial port:
O0001
M00
G 54
G90 G10 L2 P 1 X- 32.8616 Y- 34.2843 Z- 49.9746 B 269.917
G 55
G90 G10 L2 P 2 X- 31.5296 Y- 34.2843 Z- 51.3859 B 359.917
G 56
G90 G10 L2 P 3 X- 30.1183 Y- 34.2843 Z- 50.0539 B 89.917
G 57
G90 G10 L2 P 4 X- 31.4503 Y- 34.2843 Z- 48.6426 B 179.917
G 58
G90 G10 L2 P 5 X- 32.8466 Y- 34.2843 Z- 50.2202 B 280.206
G 59
G90 G10 L2 P 6 X- 30.1333 Y- 34.2843 Z- 49.8083 B 100.206
M30
Read Next
The Future of High Feed Milling in Modern Manufacturing
Achieve higher metal removal rates and enhanced predictability with ISCAR’s advanced high-feed milling tools — optimized for today’s competitive global market.
Read MoreIncreasing Productivity with Digitalization and AI
Job shops are implementing automation and digitalization into workflows to eliminate set up time and increase repeatability in production.
Read MoreInside Machineosaurus: Unique Job Shop with Dinosaur-Named CNC Machines, Four-Day Workweek & High-Precision Machining
Take a tour of Machineosaurus, a Massachusetts machine shop where every CNC machine is named after a dinosaur!
Read More