Jump to content
aggertroll

Custom abort routine for UMO / Cura 15.04.3?

Recommended Posts

Posted · Custom abort routine for UMO / Cura 15.04.3?

I run my UMO with Cura 15.04.3 (Mac) via USB and everything works great.

But: When I hit "Abort print", buffer empties and then the printer simply stops.

Right now I disable steppers, lower Z stage by hand, return print head to front left by hand.

(Not sure if it switches off nozzle heater; filament oozes out for a while and I had the nozzle clogged on the next print run once or twice)

I would much rather that "Abort" would

- retract standard end-of-print amount

- switch off nozzle heater

- lower bed 15mm

- return print head to 0,0

I found this great thread describing customization of the Pronterface print UI.

Can I implement the abort routine described above using this customization?

(I don't know a thing about Python and programming, but I begin to understand what these scripts do.)

Any advice / help would be highly appreciated.

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

Technically it should suffice to let abort do the same thing that it does now and once that is completed execute a certain g-code that does all of these operations.

I have no idea how the customization of pronterface works, so I can't help you there.

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

I am not sure how to "execute a certain g-code".

Load model, but instead of loading an stl-file, load a g-code, and then just print?

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

That is what the code you need to write to get this to work should do.

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

That is what the code you need to write to get this to work should do.

 

Sorry, I wanted to know: How do I print a g-code file? I usually input stl files and Cura does the rest.

I just tried it - load a g-code file and print that. Duh.

Share this post


Link to post
Share on other sites
Posted (edited) · Custom abort routine for UMO / Cura 15.04.3?

Solved.

First lesson learned: Don't edit code with a text editor. Not even with saving as txt. Anytime I tried to edit the script the interface would not load. Got a python editor. Works.

Picked a nice interface script, re-appropriated an existing button to execute my abort routine.

So if you are looking for a way to

- lower the platform,

- retract,

- return to home,

- switch off heater, bed and fan

- and say 'Aborted' on the little screen

at the click of a button when you cancel/abort a print, this is one way: Pick one of the Pronterfan print interfaces in the thread mentioned in the first post, open it with one of the many script editors available for free and do some tweaking. Its fun, actually.

Edited by Guest

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

Not even with saving as txt. Anytime I tried to edit the script the interface would not load. Got a python editor. Works.

 

This is probably caused due to spaces and tabs. Some text editors set tabs to two spaces, some to four. Python is quite particular in this regard.

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

... Python is quite particular in this regard.

Yes, now I know. I kept looking at my changes searching for the error there. A few hours of frustration, but I learned something in return.

Share this post


Link to post
Share on other sites
Posted (edited) · Custom abort routine for UMO / Cura 15.04.3?

Can someone help me with a Python question please?

Right now I changed an existing button in a Pronterfan UI to send some gcode commands after I cancel a print, i.e. click cancel in the Ui, then click the changed button.

The cancel part of the code says:

     if id == 140:

     # cancel

      self.frame._printerConnection.cancelPrint()

Can I somehow attach the gcode commands to this cancel command so that they are triggered on cancel? I always want those commands to be sent when I cancel a print.

Edited by Guest

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

So you should either change the function printerConnection.cancelPrint() to send the right g-codes before the connection is actually terminated, or you add the g-code sending before;

if id == 140:

#send g-code here

self.frame._printerConnection.cancelPrint()

Share this post


Link to post
Share on other sites
Posted · Custom abort routine for UMO / Cura 15.04.3?

So you should either change the function printerConnection.cancelPrint() to send the right g-codes before the connection is actually terminated, or you add the g-code sending before;

    if id == 140:

         #send g-code here

         self.frame._printerConnection.cancelPrint()

 

Brilliant - thanks!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Welcome to the Ultimaker Community of 3D printing experts. Visit the following links to read more about our Terms of Use or our Privacy Policy. Thank you!