Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: StefanV on June 23, 2012, 03:19:29 PM

Title: X-Y offset in tool change? Macro?
Post by: StefanV on June 23, 2012, 03:19:29 PM
Brainstorming here,...

The cost of a tool changer is way expensive.

I cut mainly cabinet parts. I use 3 tools, a 3/8" for cutting, 8mm for dowel holes, 5mm for system holes.
Besides my main spindle that holds the 3/8" bit, I'm thinking of adding 2 smaller spindles for drilling the 8mm and 5mm holes.

My quest would now be;
- When I do a tool change, I need to select 1 of these 3 spindles and make this the only Z-axis to move.
- At the same time, besides the z-offset, I now also need the x and y offset changed, this should be calibrated once and stored.

I suppose this could be done using a custom g-code builder that "considers" these offsets. Better would be do have Mach3 store the offsets and make it happen automatically. But Mach3 only allows for z-offsets. Could a Mach3 macro cover this?


Stefan V

Title: Re: X-Y offset in tool change? Macro?
Post by: HimyKabibble on June 23, 2012, 03:38:50 PM
G54-G59 fixture offsets will do exactly what you need.

Regards,
Ray L.
Title: Re: X-Y offset in tool change? Macro?
Post by: ger21 on June 23, 2012, 06:51:23 PM
I think you might be better off using G52 offsets, in a macropump which automatically does the offsets based on the current tool #. Just make sure you use a unique too # for the 5mm & 8mm tools. Or use it in an M6 macro when the tools are changed.
Something like this.

tool = GetSelectedTool()
if tool=1 then
code"G52 x0 y0 z0"
end if
if tool=2 then
code"G52 x10 y0 z0"
end if
Title: Re: X-Y offset in tool change? Macro?
Post by: StefanV on June 23, 2012, 09:05:47 PM
Anyone out there that uses a similar system? It is not make multiples of the same part using an offset, but using different spindles to work on the same part.

I have another CNC with a tool changer, so I hope to be able to use the same g-code. So the whole procedure of switching spindles and automatically changing the XYZ offset should be triggered by one simple tool change command. I figure that a decent tool changer can't be found for less than 5K, an extra spindle for boring only, can be build for a few hundred.

Stefan V
Title: Re: X-Y offset in tool change? Macro?
Post by: HimyKabibble on June 23, 2012, 09:58:51 PM
Anyone out there that uses a similar system? It is not make multiples of the same part using an offset, but using different spindles to work on the same part.

I have another CNC with a tool changer, so I hope to be able to use the same g-code. So the whole procedure of switching spindles and automatically changing the XYZ offset should be triggered by one simple tool change command. I figure that a decent tool changer can't be found for less than 5K, an extra spindle for boring only, can be build for a few hundred.

Stefan V

You've been given two very simple ways of doing what you need.  What more are you looking for??

Regards,
Ray L.
Title: Re: X-Y offset in tool change? Macro?
Post by: ger21 on June 23, 2012, 10:03:48 PM
The code I posted above is a sample from someone on the Yahoo group who has a machine with 37 spindles.
So yes, someone is doing exactly what I posted.