- Posts: 4739
- Thank you received: 2
Machine warning lights (Red, Amber, Green)
- Todd Zuercher
- Offline
- Platinum Member
-
Regardless, I believe that the hal example I posted would flash the green light anyway (probably on opposite sides of the stepgen pulse though.)
Please Log in to join the conversation.
- tommylight
-
- Offline
- Administrator
-
- Posts: 22010
- Thank you received: 3
rodw wrote: Todd, thanks, I would prefer to keep it all in hal. I seem to be doing a Tommy as its 1:30am here so I'll play in the morning. I did try hard along the lines you suggest.
Did someone mention me???? What horendous deed did i do mow?
Please Log in to join the conversation.
- Todd Zuercher
- Offline
- Platinum Member
-
- Posts: 4739
- Thank you received: 2
Please Log in to join the conversation.
Todd, thanks for your hal example. I was able to fold it into the run/step pause/resume example on the forum here and it now works perfect! The green light remains flashing when single stepping which is also how it should be. I've shot a quick video of the lights so when I' get it up on youtube, I'll post a link here. It is very cool so thanks guys.
Please Log in to join the conversation.
Todd Zuercher wrote: One small note, you might want to tie the red light to a not from halui.machine.is-on, rather than to halui.estop.is-activated. That way the red light will turn on for an alarm shut down rather than only for e-stops.)
That would cause the red light to be on when the machine is off. You could put other alarms in parrallel with the estop contact on the estop rung and label the red light Alarm.
Please Log in to join the conversation.
Todd Zuercher wrote: One small note, you might want to tie the red light to a not from halui.machine.is-on, rather than to halui.estop.is-activated. That way the red light will turn on for an alarm shut down rather than only for e-stops.)
I did actually try Todds suggestion and it did not work as expected so I reverted to my old code for the red light. There are several signals I've found that show the estop conditon.
Please Log in to join the conversation.
rodw wrote:
Todd Zuercher wrote: One small note, you might want to tie the red light to a not from halui.machine.is-on, rather than to halui.estop.is-activated. That way the red light will turn on for an alarm shut down rather than only for e-stops.)
I did actually try Todds suggestion and it did not work as expected so I reverted to my old code for the red light. There are several signals I've found that show the estop conditon.
I dont know how to do it in HAL but in classic ladder, just put the extra alarms in parrallel with the estop N/O so any of the alarms will cause the red light to come on.
Please Log in to join the conversation.
Todd Zuercher wrote: halui.program.is-running, goes false when the machine is paused (using the pause button or by an M0/M1 in the file).
Regardless, I believe that the hal example I posted would flash the green light anyway (probably on opposite sides of the stepgen pulse though.)
Todd, as I said in my earlier post, you are correct as the light flashes in a pause or single step situation.
Bevins, I have been ignoring Classic Ladder as so far, HAL has done what I want. I think what complicates HAL is that to implement a simple and clear example like Todd posted, there is a bit of work to get it folded in to existing code. Eg, changing and2.0 to and2.4 and setting the logic inputs elsewhere in the code because the pins are alredy in use.
Please Log in to join the conversation.
Please Log in to join the conversation.
- racedirector
- Offline
- Elite Member
-
- Posts: 218
- Thank you received: 0
Please Log in to join the conversation.
