John broke my estop

More
06 Jun 2012 14:54 #20682 by cwebs
John broke my estop was created by cwebs
Hay John, after helping me get my relay working last weekend you fixed my .hal file. You also fixed the estop button in Axis. And now the desktop Icon works to start Linuxcnc, but the external estop switch and max limit switches don't stop the machine . In Hal Configuration Pins/parport/0/Pin-10-in-not, changes state when the estop switch is pushed. Pins/ halui/estop/halui.estop.is-activated, changes state when estop button is Axis is clicked and when F1 is pushed. Just a note. My max limit switches and estop switch are in series to use pin 10. All switches are NC
As everyone now knows I know nothing about the code but here is what I have tried.

#Try to get estop switch working
#net estop.is-activated haluiestop.is-activated <= parport.0.pin-10-in-not
#net estop-ext halui.estop-ext <= parport.0.pin-10-in-not
#net halui.estop.is-activated <= parport.0.pin-10-in-not
#net estop-ext <= parport.0.pin-10-in-not
#net estop-in <= parport.0.pin-10-in-not
#net limit-x,y,z <= parport.0.pin-10-in-not

This is the one that did work, #net estop-in <= parport.0.pin-10-in-not
No hurry, when someone gets the time, Carl

Please Log in or Create an account to join the conversation.

More
07 Jun 2012 11:44 - 07 Jun 2012 11:45 #20704 by BigJohnT
Replied by BigJohnT on topic Re:John broke my estop
Carl,

That does look like a lot of guessing going on... except for testing that the parallel port 10 does change state when you press the e-stop button. The only example of connecting an external e-stop I can find is on the wiki and it uses classicladder which I fear if you can't master the net command might be a bit much for you to implement. Here is the example anyway.

wiki.linuxcnc.org/cgi-bin/wiki.pl?Sample_HAL_And_ClassicLadder

Now on to the manual... linuxcnc.org/docview/html/gui/halui.html

E-Stop

halui.estop.activate (bit, in) - pin for requesting E-Stop

halui.estop.is-activated (bit, out) - indicates E-stop reset

halui.estop.reset (bit, in) - pin for requesting E-Stop reset

These are the three halui estop pins, two of them can be connected to a parallel port input pin as noted by the (bit, in). The problem with most of your guesses is either you have a signal name but only one input or your trying to connect an output to an output.

This one you have the pin name and signal name reversed, the signal name must be after the net.
net estop.is-activated haluiestop.is-activated <= parport.0.pin-10-in-not

This one you have two signal names
net estop-ext halui.estop-ext <= parport.0.pin-10-in-not

This one you are trying to connect to an out pin
net halui.estop.is-activated <= parport.0.pin-10-in-not

The next three won't do anything unless you connect the signal names in another line to the proper halui input pin.
net estop-ext <= parport.0.pin-10-in-not
net estop-in <= parport.0.pin-10-in-not
net limit-x,y,z <= parport.0.pin-10-in-not

I normally don't type such long replies but I'm trying hard to get you to understand the basics of the net command in HAL.

net signal-name pin-name-in pin-name-out

So following the above syntax

net external-estop halui.estop.activate <= parport.0.pin-10-in-not

external-estop is the signal name that I just made up
halui.estop.activate is the in pin that we want to act on
parport.0.pin-10-in-not is the out pin that will trigger the in pin when it changes states

John
Last edit: 07 Jun 2012 11:45 by BigJohnT.

Please Log in or Create an account to join the conversation.

More
07 Jun 2012 19:05 #20724 by cwebs
Replied by cwebs on topic Re:John broke my estop
Thanks for the time John. Believe me, after your example and reading the manuals I do have a better understanding of the way to connect the pins. The best way for me to grasp the hal and ladder is buy doing while studying so I have an older Emachine that I installed Ubuntu 10.04 on. I'll use this to learn and experiment on with no CNC machine connected. If I use one of the simulators will the changes show? Thanks, Carl

Please Log in or Create an account to join the conversation.

More
07 Jun 2012 19:16 #20726 by andypugh
Replied by andypugh on topic Re:John broke my estop
cwebs wrote:

My max limit switches and estop switch are in series to use pin 10

Is that deliberate, or were you just short of pins?

Ideally an E-stop should stop the machine independently of the PC being functional.
My E-stop has two switch modules, a NC which drops out the contactor when it is opened, and an NC which is wired to an input pin, and from there to my halui.estop.activate

I don't think you really want to drop the machine into e-stop when you hit a limit switch, especially if they also get used for homing.

Please Log in or Create an account to join the conversation.

More
07 Jun 2012 19:51 #20730 by cwebs
Replied by cwebs on topic Re:John broke my estop
Yes I ran out of inputs. I don't have the estop switch connected with the home switches. It is connected with the MAX limit switchs. They are a long distance from where I normaly work so I have time to shut it down IF I have to. So far in the last three years I havent had to. BUT I still want them to work. Thanks, Carl

Please Log in or Create an account to join the conversation.

More
07 Jun 2012 21:19 #20735 by BigJohnT
Replied by BigJohnT on topic Re:John broke my estop
cwebs wrote:

Thanks for the time John. Believe me, after your example and reading the manuals I do have a better understanding of the way to connect the pins. The best way for me to grasp the hal and ladder is buy doing while studying so I have an older Emachine that I installed Ubuntu 10.04 on. I'll use this to learn and experiment on with no CNC machine connected. If I use one of the simulators will the changes show? Thanks, Carl


IIRC the sims don't even load the parallel port but I might be wrong. You could just create a config with the stepconf wizard and play with that on your spare computer. Maybe connect up some micro switches to the parallel port for testing...

John

Please Log in or Create an account to join the conversation.

Time to create page: 0.132 seconds
Powered by Kunena Forum