kliment / Printrun

Pronterface, Pronsole, and Printcore - Pure Python 3d printing host software
GNU General Public License v3.0
2.34k stars 995 forks source link

Add "cancel" command in order to cancel print on Prusa / Marlin based Printers #1414

Closed bkerler closed 4 months ago

bkerler commented 4 months ago

On printing via Printrun on Prusa and Marlin based printers, if the user stops the print on the printer, Printrun will continue to print and doesn't recognize that the print run was canceled. The Prusa / Marlin based printers are sending the "action:cancel" (see here and here) command via serial port, but Printcore seems to expect "!!". This commit adds the "action:cancel" command support.

I'm not sure if pause is the right command, but I couldn't see any stop implementation.

rockstorm101 commented 4 months ago

I'm not sure if pause is the right command, but I couldn't see any stop implementation.

Agreed, I don't think there is a do_cancel function or similar so re-using do_pause sounds fair. I'm happy to merge this. Even if it is just for Prusa firmware, it seems harmless for everyone else anyway. Any objections @DivingDuck?

DivingDuck commented 4 months ago

Hi @bkerler and @rockstorm101, I totally forgot to answer this PR. I'm happy with this too.