Machine warning lights (Red, Amber, Green)

More
17 Jan 2017 21:53 #86011 by Todd Zuercher
Andy would win hands down. (he wrote the hardware interface driver for my first Linuxcnc machine, and helped walk me through setting it up.)

All I'm good for is the occasional bit of hal setup or ladder logic. A programmer I am not.

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

More
24 Sep 2023 09:00 #281540 by camb0
If anyone is following this thread I did it in HAL, it was actually quite easy, here's the config:
Put this in your main hal file
# Load classic ladder
loadrt classicladder_rt numPhysInputs=15 numPhysOutputs=15 numS32in=10 numS32out=10 numFloatIn=10 numFloatOut=10 numBits=50 numWords=50
addf classicladder.0.refresh servo-thread
# TODO switch back to this later loadusr classicladder --nogui custom.clp
loadusr classicladder custom.clp

Then in your post_gui (as you'll need some of the pins that load).
Note that pdnt pins are for my pendant the general lines are above but commented out:
########### SETUP THE MACHINE LIGHT #########
# Turn on the machine light to red to kick things off.
setp hm2_7i96s.0.7i76.0.1.output-12 true
net greenlight hm2_7i96s.0.7i76.0.1.output-10 classicladder.0.out-02
net yellowlight hm2_7i96s.0.7i76.0.1.output-11 classicladder.0.out-01
net redlight hm2_7i96s.0.7i76.0.1.output-12 classicladder.0.out-00
net e-stop halui.estop.is-activated classicladder.0.in-00
#net pwr-on halui.machine.is-on classicladder.0.in-01
net machine.is-on classicladder.0.in-01
#net prg-run halui.program.is-running classicladder.0.in-02
net pdnt.program-is-running halui.program.is-running classicladder.0.in-02
#net halui.program.is-idle classicladder.0.in-03
net pdnt.program-is-idle classicladder.0.in-03



The classic ladder file is attached. 

File Attachment:

File Name: custom.clp
File Size:5 KB
Attachments:

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

Time to create page: 0.182 seconds
Powered by Kunena Forum