Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Tony Woollacott on April 22, 2013, 02:27:45 AM

Title: No response from limit switches
Post by: Tony Woollacott on April 22, 2013, 02:27:45 AM
Ok, so I finally got a breakout board with individual drivers to replace my all in one 4 axis board. It all works well, the motors run a lot smoother, but for some reason my limit switches have no effect on the motors.
In the diagnostics page the input led's from 1 to 4 are lit, and when any of the limit switches are manually operated the led's go out.
Any ideas?? :-\
Tony
Title: Re: No response from limit switches
Post by: Hood on April 22, 2013, 02:57:36 AM
Sounds like you dont have the limits configured correctly in Mach.
 You say LEDs are lit and say Input 1-4.
If they are lit when not triggered then you have the active state wrong.
If you are really meaning input 1-4 LEDs then you have them set to Inputs instead of limits in Machs Ports and Pins/ Inputs page.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 22, 2013, 03:08:35 AM
That's what I thought. What I find confusing is that on the all in one board the output signal pins for enable 1 to 4 are all different, but for this breakout board they are all set to pin 1.
Where exactly are the settings for the limit switches?
Title: Re: No response from limit switches
Post by: Hood on April 22, 2013, 03:43:11 AM
If you attach your xml and also info on the breakout and drives you have and which pins on the breakout you have the limits connected to I will have a look.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 22, 2013, 04:06:34 AM
Thanks, Hood, I will have to get that all together for you tonight.
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 22, 2013, 01:54:16 PM
Ok Hood, here are the 3 attachments.
Title: Re: No response from limit switches
Post by: Hood on April 22, 2013, 02:02:31 PM
Are your limit switches normally open or normally closed?
Do you have just a single switch per axis or do you have 2 or more per axis?
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 22, 2013, 02:07:36 PM
I am pretty sure they are normally closed, and I have 2 per axis.
Title: Re: No response from limit switches
Post by: Hood on April 22, 2013, 02:13:37 PM
Ok so take it you have a wire from terminal 10 on BOB going to one terminal 1 on first switch then terminal 2 on that switch goes to 1 on next then 2 on that switch goes to the Gnd connector beside terminal 10?

If so then you should get a change in LED state of M1++ M1-- M1 home LEDs on the diagnostics page when you press any of the switches on the X axis.
 If you dont then possibly they are normally Open switches and in that case you will not get anything unless you press both switches at the same time.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 22, 2013, 02:22:09 PM
Actally I have the 2 switches in parallel.
Title: Re: No response from limit switches
Post by: Hood on April 22, 2013, 02:26:20 PM
Ok then that will be your problem if they are Normally Closed, you need Normally Closed in series.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 22, 2013, 02:28:25 PM
Ok, I will change them over and let you know what happens. Thanks again.
Title: Re: No response from limit switches
Post by: Hood on April 22, 2013, 02:30:16 PM
to test if you press both you should get a change in LED state on diagnostics page.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 01:45:45 PM
Ok, I am getting the change in led state, but no response from the motors?
Title: Re: No response from limit switches
Post by: Hood on April 23, 2013, 01:48:21 PM
So if you dont press the switches are the LEDs on diagnostics page lit for M1++ etc?
If they are you have the active state wrong.

Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 01:50:42 PM
no they only light when the switch is depressed.
Title: Re: No response from limit switches
Post by: Hood on April 23, 2013, 01:54:25 PM
Ok so the reset does not flash when you press them?
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 01:55:26 PM
no, they have no effect on anything.
Title: Re: No response from limit switches
Post by: Hood on April 23, 2013, 01:57:07 PM
Ok attach your latest xml and also what version of Mach do you have loaded?
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 01:59:45 PM
the xml is the one already attached, and I am running the latest version of mach 3.
Title: Re: No response from limit switches
Post by: Hood on April 23, 2013, 02:01:08 PM
Ok try an older version of Mach and see if it helps.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 02:08:10 PM
ok I'll give that ago.
Title: Re: No response from limit switches
Post by: Hood on April 23, 2013, 02:10:56 PM
Please get back to me one way or the other, the sooner the better ;)
Hood
Title: Re: No response from limit switches
Post by: Chaoticone on April 23, 2013, 02:13:22 PM
Tony, you can find them here.  ftp://anonymous:guest@machsupport.com/ (ftp://anonymous:guest@machsupport.com/)  Try 3.043.056

Brett
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 03:14:44 PM
Thanks Brett, I have tried several of the downloads, but for some reason they all time-out and won't complete. Any suggestions?
Title: Re: No response from limit switches
Post by: Chaoticone on April 23, 2013, 03:29:45 PM
I don't know why they would be timing out unless you security is blocking them.  I could try to email you a zip file.

Brett
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 03:45:32 PM
Just sent a pm thanks Brett
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 23, 2013, 05:48:08 PM
One thing still puzzles me. This is the same PC with the same version of Mach 3 working on the same CNC. The only thing that has changed is the BOB and driver boards. ???
Title: Re: No response from limit switches
Post by: Hood on April 24, 2013, 02:59:29 AM
That is the problem with the latest version and the bugs in it, assuming of course that this is your issue. Some people have the issues, some dont, why I have no idea. I do know however that there are many problems with the latest version and a lot more people than normal suffer from them.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 26, 2013, 11:52:39 AM
Sorry for the delay I have only just got back to it. I have un-installed my version and re-installed 3.043.056. There is no change. When the switch is made the led lights up, but the axis does not react and the reset does not flash.
Title: Re: No response from limit switches
Post by: Hood on April 26, 2013, 01:28:36 PM
That is very strange indeed.
Can you please attach the xml as it is now and I will see if I can find the problem.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 26, 2013, 02:29:57 PM
Ok, this is it.
Title: Re: No response from limit switches
Post by: Hood on April 26, 2013, 05:21:29 PM
Well it works fine here when I simulate things so I cant understand what is wrong for you.

Looking at your xml it would seem you have Normally Open switches and they are in parallel, is that correct?
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 26, 2013, 05:50:03 PM
They were, but they are now nc and daisy chained.
Title: Re: No response from limit switches
Post by: Hood on April 26, 2013, 05:54:55 PM
Something strange there then, I would expect them to be active High.
What is your limit switch? NC or NO?
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 26, 2013, 06:08:16 PM
either, it depends how they are wired.
Title: Re: No response from limit switches
Post by: Hood on April 26, 2013, 06:09:58 PM
Sorry meant E-Stop, not Limits ;D

Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 26, 2013, 06:15:21 PM
Honestly don't know, I would have to go and check. Too late now as I need to run an extension lead down to the garage for light etc. I will only be able to get back to it on Sunday.
Title: Re: No response from limit switches
Post by: Hood on April 26, 2013, 06:17:32 PM
Ok no probs, just you have that active High so I would expect it to be normally closed. However if that is the case then your limits should also be active high unless that BOB does funny things to the signals :D
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 26, 2013, 06:18:46 PM
I will let you know asap. Thanks for all your time.
Title: Re: No response from limit switches
Post by: Hood on April 26, 2013, 06:20:19 PM
No problem.
It could be your BOB is inverting the signals and that you have the E-Stop Normally Open but we will see on Sunday :)

Hood
Title: Re: No response from limit switches
Post by: stirling on April 27, 2013, 05:41:50 AM
Had a play with this and I think I've figured it out. In the xmls posted the E-stop is set to pin 13 active high. But the A axis limit is also set to pin 13 but active low. To me this should mean it is impossible to get Mach out of reset - and yet you can.

It turns out either by design or accident that if you create this impossible situation Mach automatically sets both auto limit override AND manual limit override on - thus although the diagnostic leds light Mach ignores the limit. Try for the moment just disabling the A axis limits and then there is no conflict so Mach does not then "auto" set the limits off.

The "real" solution of course is NOT to create this impossible situation with the E-Stop pin.

Ian
Title: Re: No response from limit switches
Post by: Hood on April 27, 2013, 05:43:57 AM
Bloody hell, missed that, did notice the overrides though and couldnt work out why it was on ;D
Hood
Title: Re: No response from limit switches
Post by: stirling on April 27, 2013, 06:03:52 AM
 ;D
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 28, 2013, 03:43:19 AM
Thanks to all of you for your time, you have been a great help as usual. X,Y and Z limits and E-Stop are now all working. There is another twist now, however. I have the auto zero set, but when I 'Home All' all the axes go to home limit and auto zero, but then immediately the reset flashes. The axis led's do not go green either. Any suggestions?
Title: Re: No response from limit switches
Post by: Hood on April 28, 2013, 04:44:14 AM
Ok so does the Z move to switch, back off , machine coords Zero and Z LED go green, then it moves to the Y etc?
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 28, 2013, 05:02:58 AM
I have tried with all 3 axes reaching home first and they all back off and go green, but as soon as the last one backs off all leds go back to red and the reset flashes. ???
Title: Re: No response from limit switches
Post by: stirling on April 28, 2013, 07:42:34 AM
please post your xml and your 'ref all home' macro

Ian
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 28, 2013, 01:59:39 PM
Where do I find the 'ref all home' macro?
Title: Re: No response from limit switches
Post by: Hood on April 28, 2013, 08:00:03 PM
Normally the script is held in the RefAll button and with you saying that you tried in different orders it sounded like you were using a custom scrippt.

If that is not the case then just attach your latest xml and we will assume the scriot is standard.

If you can try homing from the Diagnostics page. Press Ref Z and see if it homes correctly. Wait a few mins and then do Y, wait then do X.
If it fails at any of them tell us which. If it fails after the last one you do (X) then reset Mach and only home that one and see if it fails.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 29, 2013, 03:03:07 AM
Yes the script is standard. When I changed the orders all I did was jog each axis further away from the limit switch in turn.
I did go to the diagnostics page and homed each axis individually. The reset flashed on every axis as it backed off and zeroed.
I will only be able to post the xml this evening at around 5.30.
Title: Re: No response from limit switches
Post by: Hood on April 29, 2013, 03:12:14 AM
The script can not be standard if all axes are moving at the same time as default is Z first then Y then X then A.
Anyway regardless of that sounds like your switches may be bouncing.
Hood
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 29, 2013, 01:49:06 PM
 ;D I got it!!!!!!!!! It was all about that pin 13 mixup. Pin 13 is for the A limit and pin 15 is for E Stop. Of course having disabled the A axis to try and get it all working made it look like the E Stop was working, but it was actually giving the A axis over travel signal. So I have switched the pins in the input signals and now it all works. ;)
BUT, I haven't messed with the script in the 'all home' button, and when activated all 3 axes move together. How do I change this to the default of 1st Z then Y then X. I don't want to crash cutters. :D
I have attached the latest xml, if that helps.
Title: Re: No response from limit switches
Post by: Tony Woollacott on April 30, 2013, 03:14:54 AM
I have just noticed that when pressing the 'home all' button on the screen, the Z moves first so it must be that when I configured my number pad pendent I did not get the movement right. I will have to have a look and see if there is another way to do it.

Once again a huge thank you to all of you for all your help, you certainly make this process much easier for the challenged like me.
Title: Re: No response from limit switches
Post by: Hood on April 30, 2013, 07:14:20 AM
Good you got it :)
Hood
Title: Re: No response from limit switches
Post by: Chaoticone on April 30, 2013, 09:36:40 AM
 :)

Brett