Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: GytarrMann19 on December 28, 2011, 06:07:12 PM

Title: Spindle output messes up tool change
Post by: GytarrMann19 on December 28, 2011, 06:07:12 PM
Good evening all,

I have a very confusing problem. When an M3 command is active, and I try to initiate a tool change, the tool change fails and I get the message "limit switch activated." Tool changing works fine any other time. At first I assumed it was a noise issue with the VFD- not so. I disconnected power to the VFD and the problem persists. I have a turret up/down switch, and a turret home switch, Port 2 pins 9 and 11 respectively. I then assumed maybe one of these port/pin assignments was shared with an M3 function, i.e. motor step/direction and CW/CCW outputs. They are not.

Any ideas as to what might be going on?

Thanks!
Kevin
Title: Re: Spindle output messes up tool change
Post by: Hood on December 29, 2011, 02:01:41 AM
Are you running any brains or plugins that may be interfering?
If you attach your xml I can look and see if I can find a config issue.
Hood
Title: Re: Spindle output messes up tool change
Post by: GytarrMann19 on December 29, 2011, 05:49:32 PM
Don't know anything about brains, and I think the only plugin is the smoothstepper one. .xml attached.

Kevin
Title: Re: Spindle output messes up tool change
Post by: Hood on December 30, 2011, 06:00:31 AM
Xml seemed fine but didnt have a SS there when I tested so will have to remember to take one home tonight to test again.
Hood
Title: Re: Spindle output messes up tool change
Post by: Graham Waterworth on December 30, 2011, 06:52:49 AM
If you issue a M5 before the tool change will it work?

Graham
Title: Re: Spindle output messes up tool change
Post by: Tweakie.CNC on December 30, 2011, 07:18:03 AM
As Graham says, it would seem logical that a tool change would be prohibited whilst the spindle is actually running.  ;)

Tweakie.
Title: Re: Spindle output messes up tool change
Post by: Hood on December 30, 2011, 07:41:02 AM
As Graham says, it would seem logical that a tool change would be prohibited whilst the spindle is actually running.  ;)

Tweakie.

No, it is definitely not that, or as  far as Mach is concerned,  as I never stop the spindle to tool change.
Hood
Title: Re: Spindle output messes up tool change
Post by: Graham Waterworth on December 30, 2011, 09:41:22 AM
I was asking to see if there was some sort of interlock in the M3/4 that is cancelled in the M5

Graham
Title: Re: Spindle output messes up tool change
Post by: Hood on December 30, 2011, 10:03:22 AM
Not really sure what you are meaning Graham but I just tested on the lathe. I used the rear turret as it indexes one tool at a time so is slow. I had the spindle doing a M3 then called tool5 (it was on tool 1) and whilst the turret was indexing I called a M4 and then a M3 then M4 again and all was fine.
Hood
Title: Re: Spindle output messes up tool change
Post by: GytarrMann19 on December 30, 2011, 12:32:02 PM
Yes, this is on a lathe. Issuing the M5 before tool changing allows it to work. Might there be something in the M3 macro causing the trouble?

Kevin
Title: Re: Spindle output messes up tool change
Post by: Hood on December 30, 2011, 04:00:58 PM
Whats in your M3 macro? What about the toolchange macro?
Hood
Title: Re: Spindle output messes up tool change
Post by: Graham Waterworth on December 30, 2011, 04:54:43 PM
If you can not find the problem post your macro files M3.m1s, M4.m1s, M5.m1s, M6Start.m1s and M6End.m1s so we can have a look at them, it looks as if there is interlock code in them.

Graham
Title: Re: Spindle output messes up tool change
Post by: GytarrMann19 on January 04, 2012, 07:20:56 PM
M3, M4, and M5 consist of DoSpinCW(), DoSpinCCW(), and DoSpinStop() respectively. M3 also includes Sleep 2. The funny thing is, today it runs just fine. What gives?

Kevin