eStop with lcec input issue

More
18 Nov 2024 16:49 #314773 by CallumRD1
Hi all,

I have a simple question that I can't seem to find an answer to. I have a NC eStop switch wired up to an input on my Delta B3 drives running Ethercat. I have the following line in my Hal file for that eStop switch:

net estop-ext <= lcec.0.0.in-1-eStop

This appears to work, but has the sign backwards. (i.e. would operate fine if my eStop switch was NO instead of NC). How do I invert the sign of this input so it operates correctly with my NC switch? I found references to adding a "-not" or "_not" to the end of the input, but that isn't working, I get a variable error as it appears to be treating the "-not" as part of the variable string.

Thanks,
Callum

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

More
18 Nov 2024 18:34 #314785 by Aciera
Replied by Aciera on topic eStop with lcec input issue
use the 'not' hal component:
linuxcnc.org/docs/html/man/man9/not.9.html

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

More
18 Nov 2024 18:59 - 18 Nov 2024 19:12 #314787 by CallumRD1
I don't mean to be obtuse, but do you mind explaining the syntax of a Hal component like that? I don't understand how to integrate the function into my 'net estop-ext <= lcec.0.0.in-1-eStop'.

Edit: I understood it better than I thought. I was chasing around a typo and not realizing it. This is what worked for me. (I know it's not the most compact or elegant syntax, but it works!)

addf not.0 servo-thread
net estop-ext <= lcec.0.0.in-1-eStop
net estop-ext => not.0.in
net not-estop-ext not.0.out => iocontrol.0.emc-enable-in

Thank you for the help!
Last edit: 18 Nov 2024 19:12 by CallumRD1.

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

Time to create page: 0.057 seconds
Powered by Kunena Forum