External E-Stop

More
17 Nov 2012 00:38 - 12 Nov 2013 20:35 #26684 by BigJohnT
BigJohnT created the topic: External E-Stop
This method uses the ESTOP_LATCH component to connect up an external physical E-Stop to LinuxCNC.
# estop
loadrt estop_latch
addf estop-latch.0 servo-thread
net estop-loopout iocontrol.0.emc-enable-in <= estop-latch.0.ok-out
net estop-loopin iocontrol.0.user-enable-out => estop-latch.0.ok-in
net estop-reset iocontrol.0.user-request-enable => estop-latch.0.reset
net remote-estop estop-latch.0.fault-in <=  parport.0.pin-in10-not

The typical estop loopback looks like this so either comment it out or remove it.
#  ---estop signals---
net estop-out <= iocontrol.0.user-enable-out
net estop-out => iocontrol.0.emc-enable-in
John
Last Edit: 12 Nov 2013 20:35 by BigJohnT.
The following user(s) said Thank You: OT-CNC
More
18 Nov 2012 12:21 #26739 by jmelson
jmelson replied the topic: External E-Stop

BigJohnT wrote: This method uses the ESTOP_LATCH component to connect up an external physical E-Stop to LinuxCNC.

net remote-estop estop-latch.0.fault-in <=  hm2_5i20.0.gpio.025.in_not

Well, if you are going to post hardware-specific code, I have to match that with the
code that I use with my hardware.
# connect e-stop write/sense to I/O controller
# and ppmc's fault with estop's output, so  estop FF is reset, but
#      prevent continued estop signal from ppmc from holding FF cleared
newsig ppmcEstop bit
linksp ppmcEstop ppmc.0.din.estop.in
linksp ppmcEstop and2.0.in0
newsig EstopOkIn bit
linksp EstopOkIn estop-latch.0.fault-in
linksp EstopOkIn and2.0.out
newsig EstopOkOut bit
#linksp EstopOkOut ppmc.0.dout.07.out
linksp EstopOkOut ppmc.0.dout.Estop.out
linksp EstopOkOut iocontrol.0.emc-enable-in
linksp EstopOkOut estop-latch.0.ok-out
linksp EstopOkOut and2.0.in1
newsig emc-estop-out bit
linksp emc-estop-out iocontrol.0.user-enable-out
linksp emc-estop-out estop-latch.0.ok-in
newsig emc-estop-reset bit
linksp emc-estop-reset iocontrol.0.user-request-enable
linksp emc-estop-reset estop-latch.0.reset

This links up a hardware Estop sense circuit and estop latch
with a software one in LinuxCNC. Anthing that breaks the
Estop sense loop in the hardware, or a software command
to go to E-stop will cause both hard and soft E-stop latches
to go to E-stop. Only when the hardware Estop chain is
closed and the software command is given to come out of E-stop
will it do so. The hardware also has a watchdog timer to cause
an E-stop if LinuxCNC stops controlling it.
The timing of these functions is critical, as handled
by the order of addf's in the ppmc_load.hal file.
addf motion-command-handler servo-thread
addf and2.0 servo-thread
addf estop-latch.0 servo-thread
addf motion-controller servo-thread

Since there is a delay of one servo cycle between sending a command to
the hardware and reading back the status, these operations have to be
done in the right order.

Jon
More
18 Nov 2012 22:02 #26751 by BigJohnT
BigJohnT replied the topic: External E-Stop

jmelson wrote: Well, if you are going to post hardware-specific code


That was not my intention I just quickly copied and pasted the example I had at hand.

John
More
19 Nov 2012 04:57 #26779 by jmelson
jmelson replied the topic: External E-Stop

BigJohnT wrote:

jmelson wrote: Well, if you are going to post hardware-specific code


That was not my intention I just quickly copied and pasted the example I had at hand.

John

Just a little ribbing, I should have thrown in one of those :laugh:
emoticons!

Jon
More
08 Aug 2016 16:04 #78495 by cparsons
cparsons replied the topic: External E-Stop
I am trying to get my estop to work - and saw your example, I am going to do some experimenting but wondered if the line

net remote-estop estop-latch.0.fault-in <= parport.0.pin-in10-not

should be

net remote-estop estop-latch.0.fault-in <= parport.0.pin-10-in-not

I also wondered what the line 'addf estop-latch.0 servo-thread' does - I don't have servos, I have stepper motors??

Regards

Chris
The following user(s) said Thank You: tommylight
More
08 Aug 2016 17:06 #78496 by tommylight
tommylight replied the topic: External E-Stop

cparsons wrote: I am trying to get my estop to work - and saw your example, I am going to do some experimenting but wondered if the line

net remote-estop estop-latch.0.fault-in <= parport.0.pin-in10-not

should be

net remote-estop estop-latch.0.fault-in <= parport.0.pin-10-in-not

I also wondered what the line 'addf estop-latch.0 servo-thread' does - I don't have servos, I have stepper motors??

Regards

Chris

Yes it should.
Tom
More
14 Aug 2016 21:49 #78775 by BigJohnT
BigJohnT replied the topic: External E-Stop

cparsons wrote: I am trying to get my estop to work - and saw your example, I am going to do some experimenting but wondered if the line

net remote-estop estop-latch.0.fault-in <= parport.0.pin-in10-not

should be

net remote-estop estop-latch.0.fault-in <= parport.0.pin-10-in-not

I also wondered what the line 'addf estop-latch.0 servo-thread' does - I don't have servos, I have stepper motors??

Regards

Chris


If you don't have normally closed estop then yes you need to change the input.
The "servo-thread" is for some reason unknown to me means the slower thread with math and has nothing to do with the drives you may be using.

JT
More
14 Aug 2016 21:53 #78776 by tommylight
tommylight replied the topic: External E-Stop
The first line has an error at "....in10-not....", should be ".....10-in-not".
regards,
Tom
More
30 Aug 2016 19:04 #79737 by OT-CNC
OT-CNC replied the topic: External E-Stop
# estop
loadrt estop_latch
addf estop-latch.0 servo-thread
net estop-loopout iocontrol.0.emc-enable-in <= estop-latch.0.ok-out
net estop-loopin iocontrol.0.user-enable-out => estop-latch.0.ok-in
net estop-reset iocontrol.0.user-request-enable => estop-latch.0.reset
net remote-estop estop-latch.0.fault-in <= parport.0.pin-in10-not

Thanks for posting this. My E-stop circuit is now improved.
I'd like to add my limits to the estop circuit through software if necessary. As physically wired, I can't run the limits in series with the estop. What is your opinion on this? This would protect the machine only from a drive failure. I'm using DMM servo drives in step mode and I don't know how they would react if an encoder wiring would fail down the road. Runaway? Or is it safe enough to rely on a drive enable signal to disable the drive? Linking the limit signal to disable the drives?
Time to create page: 0.143 seconds
Powered by Kunena Forum