Remote Start/Hold Circuit

More
13 Sep 2011 23:53 #13189 by BigJohnT
Even better I asked him here on the forum.

John

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

More
14 Sep 2011 14:00 - 14 Sep 2011 14:51 #13200 by fgauder
I have to say,it is nice to be able to tell your machine how to run instead of having to learn to or get used to running a machine someone else has configured. I am sold on EMC.

In the original post on this thread, I proposed 2 buttons, one a Run/Step and the other a Pause/Resume. The controller I converted from had those 2 buttons close to an e-stop and until a program was proved out, 2 fingers stayed on them.

Thanks to John and Andy, I got my Pause/Resume button. I did a little work on my own and was able to get the Run/Step button (admittedly the far easier). So, for what it's worth, here is the program for both buttons:

loadrt and2 count=4
loadrt or2 count=1
loadrt toggle count=1
loadrt toggle2nist count=1

addf and2.0 servo-thread
addf and2.1 servo-thread
addf and2.2 servo-thread
addf and2.3 servo-thread
addf or2.0 servo-thread
addf toggle.0 servo-thread
addf toggle2nist.0 servo-thread

# External Program Pause/Resume and Run/Step Buttons
# Pause/Resume Section
net pause-resume-btn and2.0.in0 and2.1.in0 <= hm2_5i20.0.gpio.027.in_not (this is your input)
net pause-on toggle2nist.0.is-on and2.0.in1 and2.3.in1 <= halui.program.is-paused
net run-on and2.1.in1 <= halui.program.is-running
net pause-sig or2.0.in0 <= and2.0.out
net resume-sig or2.0.in1 <= and2.1.out
net toggle-ok toggle.0.in <= or2.0.out
net togglesig toggle2nist.0.in <= toggle.0.out
net toggleon halui.program.pause <= toggle2nist.0.on
net toggleoff halui.program.resume <= toggle2nist.0.off
# Run/Step Section
net run-step-btn and2.2.in0 and2.3.in0 <= hm2_5i20.0.gpio.026.in_not (this is your input)
net idle-on and2.2.in1 <= halui.program.is-idle
# net pause.on and 2.3.in1 <= halui.program.is-paused
# and2.3.in1 was added in the net pause-on statement in Pause/Resume Section
net run-sig halui.mode.auto halui.program.run <= and2.2.out
net step-sig halui.program.step <= and2.3.out

This is how they function:

Pressing Run/Step will begin executing a program.

Pressing Hold/Resume while a program is running will pause the program.

Pressing Run/Step while a program is paused will single step the program.

Pressing Hold/Resume while a program is paused will return it to normal run mode.

I hope this thread is of some help to someone.

Frank
Last edit: 14 Sep 2011 14:51 by fgauder. Reason: typo

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

More
14 Sep 2011 14:36 #13202 by BigJohnT
Frank,

Thanks for sharing your results. I placed a copy of this in the HAL Examples.

BTW, is that a typo Run/Hold?

John

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

More
14 Sep 2011 14:50 #13203 by fgauder
Yes, it should be Run/Step. I'll edit it.

Frank

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

Time to create page: 0.120 seconds
Powered by Kunena Forum