What's new
What's new

Using coolant MCode or sensors for magnetic chuck

GiroDyno

Cast Iron
Joined
Apr 19, 2021
Location
PNW
Two problems I'd like to solve here:
Basic idea is we have a pair of Haas VFs with mag chucks dedicated to milling a family of cast iron parts (brake rotors) after turning. These parts are located by a modular puck on the chuck that fits tightly into a central bore. Frontside of the part gets machined, then flipped and located on opposite side of bore and backside is machined. We have a front/back machined on the table every cycle.

First problem:
Sometimes this bore is a little too tight, and its possible for an operator to have a part not sitting entirely flat on the table without an extra whack of the mallet to seat the part. I'd like to probe Z in two different spots on the part, and if the difference is greater than say +/-0.01" halt the program. I understand the theory but I don't do a lot of macro programming so I'm not exactly sure of the "syntax" or whatever. I'm sure a macro wizard here walk me through this in their sleep.

Second problem, and the less obvious solution:
Because these parts are run 100's each day, but different sizes/programs its possible in the hustle for an operator to accidentally forget to turn on the magnet/not press the button hard enough. It has also happened that the cable was just loose enough the magnet wasn't activated. I'd like to add an mcode to activate the chuck, but more importantly I'd like to be able to sense if the magnet is on even with manual activation.
These machines run dry, I'm wondering if we can reconfigure the coolant mcode to turn on the chuck, and if we can use the coolant level sensor to somehow read the magnet? I thought I heard the coolant level sensor uses m-fin which means it should need to see a signal from the magnet (sensor) before proceeding with the program which sounds just like what I want.
Anybody have experience with this or something similar?
 
Plug the power to the magnet to the place on the machine that goes to the coolant pump then just use the code for coolant to turn on magnet
Don


Sent from my iPhone using Tapatalk Pro
 
First problem:
Sometimes this bore is a little too tight, and its possible for an operator to have a part not sitting entirely flat on the table without an extra whack of the mallet to seat the part. I'd like to probe Z in two different spots on the part, and if the difference is greater than say +/-0.01" halt the program. I understand the theory but I don't do a lot of macro programming so I'm not exactly sure of the "syntax" or whatever. I'm sure a macro wizard here walk me through this in their sleep.

I just did this exact thing with a laser cut blank'd part. What is below is a local subroutine, so if you aren't running any subs, you'll have to put the #3000 alarm line (N3000) where it makes sense.

N1 (PROBE ALL Z OFFSETS)
M6 T25
G43 H25
G65 P9832
T1
G103 P1
G54 G90
G0 X-.55 Y-.64 Z.65
G65 P9811 Z.4 S1. (PROBE G54 Z)
G4 P.1
G4 P.1
G4 P.1
#800=#187

G0 X.725 Y.35 Z.65
G65 P9811 Z.4 (PROBE TO COMPARE)
G4 P.1
G4 P.1
G4 P.1
#801=#187
G65 P9833

G4 P.1

#810=[#800-#801] (G54 Z COMPARE)

G4 P.1

#810=ABS[#810]

G4 P.1

IF [#810 GT .004] GOTO 3000

G103
M99

N3000
G0 G53 Z0.
G0 G53 Y0.
#3000=1 (NEAR LEFT NOT SEATED - RESET,FIX,CYCLE START)
 
I just did this exact thing with a laser cut blank'd part. What is below is a local subroutine, so if you aren't running any subs, you'll have to put the #3000 alarm line (N3000) where it makes sense.
Thanks for that, seeing an actual cycle implemented gives me a chance to decipher what's going on so I appreciate that.

Looking through the inspection plus manual (reading? ew gross right) it looks like there's a probe routine that already does all of this "Stock allowance – macro O9820"
That will probably do what I need in a few less lines of code.

For automating the mag chucks using the coolant power; it will turn the controller on/off, but the magnet itself wouldn't turn on/off. I think the more important feature would just be verification that the magnet is on at all. Not sure if the coolant level sensor port/hardware/relay could be repurposed for this end? One has what looks like an RJ45 port and the other is a 4 pin connector.
 
.
For automating the mag chucks using the coolant power; it will turn the controller on/off, but the magnet itself wouldn't turn on/off. I think the more important feature would just be verification that the magnet is on at all. Not sure if the coolant level sensor port/hardware/relay could be repurposed for this end? One has what looks like an RJ45 port and the other is a 4 pin connector.

Do not turn the mag controller itself on and off unless a very simple one.
Wire the coolant on/off to a relay in place of the now in use operator's switch.
Why the sense side? Do you not trust the currently used switch if thrown or pushed? Failures here?
Any in machine probing is expensive in cycle time but it seems you need it.
Wild to me is that the bores are done after the rotor face turn. I have not seen this part sequencing. How tight to set the go/nogo for good and bad part load?
What is the finish product runout tolerance?
Bob
 
The cable to the mag chuck has apparently come unplugged before, but I've never seen it happen.
I think for process reliability (and any future automation possibilities) it is important to be confirm we have active clamping as opposed to blindly trusting the green light means good to go. Operators already try and twist parts to verify the magnet is on, why not have the machine do that test for us. Maybe I'll come up with some sort of spring loaded widget to repurpose the coolant float sensor for this.

Why do you say don't turn the controller on/off? What would be the difference between switching on the box vs. the magnet pendant?
 
Why do you say don't turn the controller on/off? What would be the difference between switching on the box vs. the magnet pendant?

Depends on the controller and if you understand it.
There are simple bridge guys to line and there are more complicated.
Broken cable... one can go crazy with error protection and I like it but since you have never seen it how much money, time, and effort is reasonable?
Bob
 
For all that bullshit I'd use a 4th with a fixture to drop in a pair of rotors and hold by the OD. Different size rotors use bushings or spacers. Hydraulic swing clamps hold each rotor.

Both sides get done in one op and M-codes run the clamps.
 
Plug the power to the magnet to the place on the machine that goes to the coolant pump then just use the code for coolant to turn on magnet
Don


Sent from my iPhone using Tapatalk Pro

The coolant pump is tied to a GFI plug on the back of the machine separate from where the coolant pump cord twist lock plugs in. I am not saying it will be a problem but the GFI may not like the magnetic chuck. Just something to be aware of.

Your Haas should have several user interface relays with separate mcodes to run them from the factory.
 
For all that bullshit I'd use a 4th with a fixture to drop in a pair of rotors and hold by the OD. Different size rotors use bushings or spacers. Hydraulic swing clamps hold each rotor.

Both sides get done in one op and M-codes run the clamps.

300 different size ODs would be a lot of bushings...
But taking that idea and running with it, maybe a "V block" on one side and a long stroke clamp pushing straight from the other side could accommodate a range of sizes. Cutting forces are pretty light.
But then we have to deal with 300 different thicknesses and how we hold it level...
I like the idea though, I'll do some thinking on that one.
 
Depends on the controller and if you understand it.
There are simple bridge guys to line and there are more complicated.
Broken cable... one can go crazy with error protection and I like it but since you have never seen it how much money, time, and effort is reasonable?
Bob

I haven't taken one of these apart, but I'll see if I can find a diagram somewhere.
If I can dig up the float sensor I bet I can draw up a mounting bracket and get it started on a 3D printer in 30 minutes (if I could find 30 minutes to spare)
For one extra layer of security that seems reasonable.
 
I would think a momentary switch with a steel lever on it would get sucked down by the magnet, perhaps tied to the door interlock would make the safety you were wanting
 
I would think a momentary switch with a steel lever on it would get sucked down by the magnet, perhaps tied to the door interlock would make the safety you were wanting
THis

because it is better to prevent the cycle start button than auto turn on the chuck. This gives you the opportunity to say, hey maybe I didn't put that part in right rather than the machine making that assumption

Pretty easy to implement a relay that interrupts the door switch when the mag chuck is open, is already inside the enclosure and 24 volts
 
Something I haven't seen mentioned yet. I am not personally familiar with Haas controls, but according to the haas website....

"The M06 command automatically stops the spindle, stops coolant, moves the Z Axis to the tool change position, and orients the spindle for the tool change"

Turning the magnet off mid cycle could cause some real issues, if the part lifts a little and chips/particles get under it, your next op is going to be ugly.
 
Yeah, I'm beginning to think reusing coolant anything isn't going to work. We just had all the stuff sitting around so I was hoping to cobble something together.
Adding a switch activated by the magnet to the door interlock sounds quick and easy enough, only issue is you wouldn't know if the door or the chuck was the problem.

I used the 9820 Stock Allowance cycle yesterday but it threw an alarm and it was the end of the day so decided to come back to it.
This morning I am trying to use the 9811 Z Touch instead, and am getting two different errors:
I get one if I use protected moves approaching a touch point "Range Error"
And if I replace G65 P9810 with a regular G0 it will touch and come up but then I get a "1093 Probe Error" alarm

Our work zero is always the same X and Y, but we have a lot of parts with different thicknesses so I added a Q value to cover that range, not sure if that's exactly the right way to do that...
We have engraving on the parts so we need to compensate for thickness otherwise we would just set the chuck as Z0 and be done with it.

Here is my code (Thanks for letting me copy your answers Matt!) with the protected moves included.

/
/(START NEW PROBING CYCLE TO TEST FLATNESS)
/

T24 M06
T5
G53 Z0.
G56 X0 Y6.2
G43 H24 Z2.

G65 P9832 (PROBE ON)

G65 P9810 X0 Y6.2 Z2. (SAFE MOVE)
G65 P9811 Z0 Q.2 S3 (PROBE P1 REAR MIDDLE SET G56 ANULUS )
G4 P1.
#800=#5263 (Set P1 Z to G56 Z)
G4 P.1
Z2.

G65 P9810 X-5.4 Y-3.1 Z2. (SAFE MOVE)
G65 P9811 Z0 Q.2 (PROBE P2 FRONT LEFT TO COMPARE)
G4 P1.
#801=#187 (Set P2 Z)
G4 P.1
Z2.

G65 P9810 X5.4 Y-3.1 Z2. (SAFE MOVE)
G65 P9811 Z0 Q.2 (PROBE P3 FRONT RIGHT TO COMPARE)
G4 P1.
#802=#187 (Set P3 Z)
G4 P.1
Z2.

G65 P9833 (PROBE OFF)

#810=[#800-#801] (P1 P2 Compare)
G4 P.1
#811=[#800-#802] (P1 P3 Compare)
G4 P.1
#812=[#801-#802] (P2 P3 Compare)
G4 P.1

#810=ABS[#810]
G4 P.1
#811=ABS[#811]
G4 P.1
#812=ABS[#812]
G4 P.1

IF [#810 GT .01] GOTO 3000
G4 P.1
IF [#811 GT .01] GOTO 3000
G4 P.1
IF [#812 GT .01] GOTO 3000
G4 P.1

G103
M99

N3000
G0 G53 Z0.
G0 G53 Y0.
#3000=1 (PART NOT SEATED - RESET AND RELOAD PART)

/
/(END NEW PROBING CYCLE TO TEST FLATNESS)
/
 
I think you are making this more complicated than it needs to be by messing around with the coolant pump. You also need to be clearer in your description of what you have. For example "I have a 2004 VF3 with a xxxx magnetic chuck that is currently activated using xxxx volts from a user operated switch."

Unless you have you have an ancient VF the VF should have everything you need to make this work. Most VFs have at least 4 user relays inside that can be activated by m-codes and an m-fin connection for external input.

Assuming that your magnetic chuck is activated via an AC voltage then go to automationdirect.com and get a 12v magnetic contactor. The contactor will be wired to one of the internal relays (+ 12v power) and the magnetic chuck so that when you execute the m-code the chuck will turn on and off.

Next go to mcmastercarr.com and search for magnetically actuated switches, you want an SPST-NO switch. For example McMaster-Carr, you don't need the magnet part of the switch. You may need to make a riser to adjust the position of the switch in relation to the chuck so it only actuates when the magnet is on.
Wire this magnetic switch to an m-fin cable, the Haas m-fin cables are very expensive so make your own, instructions are online.

For the contactor and the magnetic m-fin switch you will need to either tap into the 12V power from the Haas power PCB or provide a separate 12v power supply.
When all of this is wired up you should be able to activate the chuck via an m-code in the range M21-M29, these m-codes will wait for an m-fin signal from the magnetic switch before continuing the program.

If you need a more detailed description of what to do please post a very detailed description of what you have, pictures help too.
 
The problem with a light is operator not paying attention to it over time.
Trust me, they will not and when things go bad they will swear on the bible that it was on.
Bob

In this scenario, the machine would do nothing[door open error] so the operator would learn to look for the light instead of: clear error, push button[look for light] push cycle start again.

The best process minimizes ability of operator error, and makes it obvious when they are about to make an error

In my shop I am usually the 'better idiot', so I tend to focus on process....
 
My thoughts in red. My code should work as is, it came directly off an '07 VF2ss:

/
/(START NEW PROBING CYCLE TO TEST FLATNESS)
/

T24 M06
T5
G53 Z0.
G56 X0 Y6.2
G43 H24 Z2.

G65 P9832 (PROBE ON)

G65 P9810 X0 Y6.2 Z2. (SAFE MOVE) (I wonder if a protected positioning move MUST move? As it's programmed, there is no actual movement.)
G65 P9811 Z0 Q.2 S3 (PROBE P1 REAR MIDDLE SET G56 ANULUS ) (What'd you call me?) (I would drop the Q argument and get it working on the part you're doing at the moment, then try to get fancy later.) (Is a 2 inch travel distance too far for P9811?)
 








 
Back
Top