Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Ricey3 on April 12, 2013, 09:52:26 AM

Title: Input pin help
Post by: Ricey3 on April 12, 2013, 09:52:26 AM
I am shortly about the make a touch plate for auto z function so I thought I'd check things out with my mach set up.

On ports and pins/inputs I have 4 of the 5 input pins used 3 home switches and an estop. This leaves me pin 13 to use.

A quick check down at my breakout board shows 5v end shows 5v already on the pin. I'm guessing the port itself has pull up resistors at the computer end.  So I set pin13 as the probe pin, enable it, set active low, apply the settings and clear the estop trigger and the green digitise led illuminates on the diagnostics page.

All good so far. Now I then ground p13 but led stays illuminated. The ground I use is common with the port ground. I've tried grounding through a resistor everything but nothing happens. I've tried it with putting a separate 5v on the pin via a pull up resistor before I realised it already had 5v on it.

Has anyone got any ideas?
Title: Re: Input pin help
Post by: Tweakie.CNC on April 12, 2013, 11:41:06 AM
Hi Ricey3,

The digitize LED should only illuminate when the touch plate (pin 13 in your case) is connected to GND.

Here are a couple of things you may like to check again...

Check that you have pin 13 enabled and configured for active low.
Check that you do not have pin 13 configured elsewhere in your setup (causing a conflict).
Check that the GND connection you are using is the same GND that the Breakout board uses.

Hope this helps.

Tweakie.
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 01:26:06 PM
Thanks for the advice.

Unless there is somewhere else to check for conflicts pin 13 is not assigned anywhere else in ports and pins.

Defo enabled and set for active low. When I check the diagnostic page the digitise led is on with nothing connected anywhere.

I'm stuck!
Title: Re: Input pin help
Post by: Hood on April 12, 2013, 02:04:15 PM
Do you have it set as emulated? If you do disable that.

If you want to attach your xml I will have a look and see if I can find an issue.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 02:20:21 PM
Not on emulation.

How do you get your XML? Sorry I'm more mechanical than computers and electronics :)
Title: Re: Input pin help
Post by: Hood on April 12, 2013, 02:39:46 PM
For the fun of it just try active High first then if not you can attach your xml as follows.
Open Mach and look at the name of the profile you are using. Close Mach then browse to your mach3 folder and find a file with that name and a xml file extension. Copy it to your desktop and then rename to Ricey3.xml and then use the additional options button on the reply page to browse to your desktop and attach.

The reason you will need to rename is the forum only accepts a file name once so likely a file with the name of your xml will already have been attached unless you made a custom xml.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 02:52:21 PM
Cheers hood.

Will copy that off shortly. Tried with it active high. No light lit on digitise. Earthing/ applying 5v makes no difference again.
Title: Re: Input pin help
Post by: Hood on April 12, 2013, 03:01:24 PM
Really sounds like it may be a port or breakout board issue but I will have a look through the xml in case I find something.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 03:09:08 PM
Ok XML attached.

Just to add. My set up is a denford starmill, the breakout board is the standard one. The parrallel port cable goes into the enclosure and all the unused wires (of which pin 13 is one) are just cut short.

The mill works perfectly and has done for a few years, the only change i have ever made (shortly after buying it) was to change the debounce value as i was getting erratic emergency stop actrivations. this cured it and it has worked perfectly since.

Cheers
brendan
Title: Re: Input pin help
Post by: Hood on April 12, 2013, 03:16:05 PM
Ok there is no probe set up in that xml, did you disable it or is it the wrong xml?

What I would try is remove one of your home switches, for example the X is connected to pin 10, if you put your probe to that input, disable the X Home switch in Ports and Pins and then set the probe as port 1 pin 10 and enable it and see what happens.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 03:25:14 PM
Yeah I would of put it back to standard.

I did similar with the estop pin 15 and set that to probe. Operating the estop button changed the digitise status led as you would expect.

Title: Re: Input pin help
Post by: Hood on April 12, 2013, 03:27:21 PM
Ok definitely sounds like a port/cable/breakout issue, you could confim by setting and connecting the E-Stop to pin 13 and see if the E-Stop LED works as it should, I suspect it will not.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 03:35:32 PM
No it does not work, again I tried it both as low and high.

Title: Re: Input pin help
Post by: Hood on April 12, 2013, 03:39:17 PM
Ok so that suggests its either a port/cable or BOB Issue, Is there any way you can connect the probe direct to the port? That would bypass the BOB and rule it in or out.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 03:55:31 PM
I actually connect direct to the wire coming from the parallel port for the probe, nothing goes through the bob.

I use the ground on the bob which is common to the grounds on the port
Title: Re: Input pin help
Post by: Hood on April 12, 2013, 03:58:20 PM
Sounds like it may be your port that is the problem then, dont suppose you have another computer you could test with? Or possibly  a PCI card you can put in and try?

You could try one of the utilities that are available like PortMon to see if it sees the port working correctly.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 04:09:28 PM
Just the one computer and don't have a spare card. I'll have a look tomorrow at the utility you mentioned and see what that shows.

If I were to change out the parallel port for a new one (assuming thats the fault) would it be literally just plugging the cable back in and everything works as it should - ie I would not have to start retuning motors and spindles and assigning pins etc?
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 04:09:45 PM
Thank you for the help by the way.
Title: Re: Input pin help
Post by: Hood on April 12, 2013, 04:17:45 PM
The only thing you would have to do is get the address of the new port and enter it into the Port1 box in Mach.
Hood
Title: Re: Input pin help
Post by: Hood on April 12, 2013, 04:21:55 PM
Just thinking, you said you have the Gnd connected to the BOB, have you confirmed it does actually share the same Gnd as the port? It may be you are using the Gnd at the isolated side of the BOB, assuming of course the BOB is isolated.
Hood
Title: Re: Input pin help
Post by: Ricey3 on April 12, 2013, 04:38:48 PM
I will re confirm tomorrow. But fairly certain the port ground wires terminated on the bob and Tried using those and the ground accociated with the 5v supply I started off using and had the same fault on each occasion
Title: Re: Input pin help
Post by: Ricey3 on April 15, 2013, 01:33:06 PM
Ok. Put a new card in a pci slot today which has 2 parralel ports. The probe pin now works as it should looking at the diagnostics page.

However when I plug the mill in the estop circuit won't clear. I got the address of the new port via device manager and put in as port 2 on the ports and pins page, unticked port 1 and ticked port 2. I also changed all the port 1 settings to port 2 in the inputs page, still no joy.

What am I missing here?
Title: Re: Input pin help
Post by: Hood on April 15, 2013, 04:24:34 PM
Should work ok but if you attach your new xml I will have a look and see if I can find a problem.
Hood