-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pause plot programmatically #75
Comments
Can you please clarify your question? What is it that you are trying to pause, and how do you want to pause it? Are you plotting from Inkscape, or from the CLI, or "via GPIO"? Also: The document that you have linked is (as it says there) deprecated in its entirety. Please refer to the current EBB documentation, hosted at: http://evil-mad.github.io/EggBot/ebb.html |
Sure... I can try. When a file is being plotted, one can push the pause button and it will pause and store the appropriate resume data. Is there a way to pause a currently running plot without pushing the button? (And not by changing the layer name to have a preceding I'm happy with any method you can provide. If it's possible using the CLI I can do that, if it's possible by using some combo of GPIO and the RB0 (?) pin, I can do that. I've read that there is an alternate pause functionality, from the documentation you linked:
I'm not sure how to use that though. Since it's on by default, if I hit the RB0 pin (wherever that is) with a HIGH, will the axidraw pause itself (and store the resume data) as if the physical button was pressed? Hope that's clearer. Thanks |
Are you plotting from the AxiDraw CLI or from Inkscape, or something else? |
CLI |
And you would like to provide an externally-generated I/O signal to control initiate a pause? |
I can if that's the only way! Ideally I'd like to signal the running process itself with e.g. SIGINT, as that'd be easier. But if that's not possible an I/O signal to the board is fine. |
😂 Haha way less interesting than that, SIGINT like My ideal would be starting a process via CLI and then sending an interrupt signal would pause the process, allowing the axidraw to be sent back to home position. Currently if I need to stop a plot I send I'll take a look into the CLI code and see if I can find where the button press code is and perhaps weasel a solution in there. I don't know python very well, but it can't be too difficult to read it. Thanks for the info on the B0 pin, that's really helpful. I'm running the whole thing off a Pi so I may look at wiring one of the Pi's GPIO pins to the B0 and then I can gracefully pause it that way. Those are the things I needed to know, I appreciate the help! |
Great. We'll look into adding a software-controlled pause in the future. The hardest part from my perspective is to see how it would be initiated-- what the interface would look like. |
https://stackoverflow.com/a/1112350/1408651 This is how I envision it:
|
Last question! I'm trying to add an option I've tried this in
and this in
and I see there is also Ultimately, I'm trying to add
in Thanks! |
Any reason not to just use two files there, one to enable the option, the other to assert pause? |
I'm controlling multiple units from the Pi so I need them to be
individually paused.
I tried using the named port to generate the pause file filename but it's
nulled out by that point
…On Thu, Feb 6, 2020 at 6:22 PM Windell Oskay ***@***.***> wrote:
Any reason not to just use two files there, one to enable the option, the
other to assert pause?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#75?email_source=notifications&email_token=AAGXKC42MKSDMJ4VET5A2TLRBSSVJA5CNFSM4KRB3RI2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOELBJAAQ#issuecomment-583176194>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGXKC6MAPREFEVRXQUJODDRBSSVJANCNFSM4KRB3RIQ>
.
|
There are a few layers deep that you need to feed those options, including the CLI core, axidraw_control, and axidraw. As an alternative, I think that you might be able to use different configuration files to specify this. If you use a different config file per machine -- identical except for port name -- that should work, and I expect that axidraw_conf.port is not nulled out. We've often seen driving one AxiDraw per Pi, but it's new for us seeing multiple AxiDraws per Pi. |
Interesting. I will try that tomorrow morning. Thanks! |
Solved it! I thought that adding a param would be the easiest option, but as you said there are so many layers to get that to work. It turns out the SIGINT was trivial. Here's what I ended up adding (along with a few imports at the top) Not sure if this is PR worthy, as I'm unsure how common the use-case is. Regardless, it's working for me now! I can send a Thanks for all your help! |
Thanks-- we'll think about this and see if something like that fits in with our general plans. |
Hey there,
Is there a way to pause a plot via GPIO or the CLI as if the physical button had just been pressed?
I see that there is some sort of "alternate pause" available
but am not quite sure how to use it. I'm not sure where the RB2 pin is either.
Thanks in advance for any help!
The text was updated successfully, but these errors were encountered: