Duet3D Logo

    Duet3D

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • Documentation
    • Order

    Auto Home and Power Down after canceled print?

    General Discussion
    8
    16
    1405
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • andino
      andino last edited by

      Hey,

      I was wondering if there were any way to auto home and power down the hot end and heated bed after a canceled print.

      For some reason my machine just sits in the pause position still hot.

      Thanks…

      1 Reply Last reply Reply Quote 0
      • Jackal
        Jackal last edited by

        Check these files
        https://duet3d.com/wiki/Configuring_RepRapFirmware_for_a_Cartesian_printer#Pause.2C_resume_and_cancel_files

        1 Reply Last reply Reply Quote 0
        • deckingman
          deckingman last edited by

          To auto home after a cancelled print is generally not a good idea as the print head is likely to crash into the (failed) printed part. Maybe home X and Y might be acceptable, but not Z (or simply move the head to a position at the side of the bed).

          Ian
          https://somei3deas.wordpress.com/
          https://www.youtube.com/@deckingman

          1 Reply Last reply Reply Quote 0
          • Whitewolf
            Whitewolf last edited by

            You can use the stop, pause g code files to first lift the Z then home…..

            Here are my files:

            ; stop.g
            ; called when M0 (Stop) is run (e.g. when a print from SD card is cancelled)
            
            M208 X-44 Y-18 Z0 S1 	  ; Home outside build area
            
            M83 			; Relative extruder moves
            G1 E-10 F3600 		; Retract 10mm of filament
            
            ; Return X and Y to home area
            G91 			; Relative positioning
            G1 Z50 F12000 		; Lift Z by 50mm
            G90 			; Absolute positioning
            G1 X-40 Y-15 F6000	; go to X=-40 Y=-15
            
            M208 X0 Y0 Z0 S1 	; Restrict movements to build area
            
            

            You dont have to use the G1 command if you do not want to alternatively you could send X and Y home with this command:

            G28 XZ ; Home the X and Z axes
            
            

            I just use the G1 command so I don't have to wait for the full homing sequence to complete.

            ; pause.g
            ; called when a print from SD card is paused
            
            M208 X-44 Y-18 Z0 S1 	; Home outside build area
            
            M83 			; Relative extruder moves
            G1 E-10 F3600 		; Retract 10mm of filament
            
            ; Return X and Y to home area
            G91 			; Relative positioning
            G1 Z50 F12000 		; Lift Z by 50mm
            G90 			; Absolute positioning
            G1 X-40 Y-15 F6000	; go to X=-40 Y=-15
            
            M208 X0 Y0 Z0 S1 	; Restrict movements to build area
            
            

            Exploring the universe wherever the tech blows

            1 Reply Last reply Reply Quote 0
            • dc42
              dc42 administrators last edited by

              @deckingman:

              To auto home after a cancelled print is generally not a good idea as the print head is likely to crash into the (failed) printed part.

              It is a good idea on a delta printer.

              Duet WiFi hardware designer and firmware engineer
              Please do not ask me for Duet support via PM or email, use the forum
              http://www.escher3d.com, https://miscsolutions.wordpress.com

              1 Reply Last reply Reply Quote 0
              • deckingman
                deckingman last edited by

                @dc42:

                @deckingman:

                To auto home after a cancelled print is generally not a good idea as the print head is likely to crash into the (failed) printed part.

                It is a good idea on a delta printer.

                Ahh… bugger. I keep forgetting about Deltas. Thanks for the correction.

                Ian
                https://somei3deas.wordpress.com/
                https://www.youtube.com/@deckingman

                1 Reply Last reply Reply Quote 0
                • njjn2020
                  njjn2020 last edited by

                  David, which macro is called when print is cancelled ?

                  1 Reply Last reply Reply Quote 0
                  • dc42
                    dc42 administrators last edited by

                    cancel.g is called.

                    Duet WiFi hardware designer and firmware engineer
                    Please do not ask me for Duet support via PM or email, use the forum
                    http://www.escher3d.com, https://miscsolutions.wordpress.com

                    1 Reply Last reply Reply Quote 0
                    • njjn2020
                      njjn2020 last edited by

                      thanks! is there a list of other files that might be of use?

                      1 Reply Last reply Reply Quote 0
                      • dc42
                        dc42 administrators last edited by

                        Yes, https://duet3d.com/wiki/SD_card_folder_structure

                        Duet WiFi hardware designer and firmware engineer
                        Please do not ask me for Duet support via PM or email, use the forum
                        http://www.escher3d.com, https://miscsolutions.wordpress.com

                        1 Reply Last reply Reply Quote 0
                        • c310
                          c310 last edited by

                          i created cancel.g and it does not run when i press emergency stop button on web interface.

                          and i cannot find 'cancel Print' button on web…

                          please advise how to link cancel.g to emergency stop or how to add cancel print button to web interface

                          thanks!

                          1 Reply Last reply Reply Quote 0
                          • dc42
                            dc42 administrators last edited by

                            The Cancel Print button appears after you use the Pause button to pause a print from SD card.

                            Duet WiFi hardware designer and firmware engineer
                            Please do not ask me for Duet support via PM or email, use the forum
                            http://www.escher3d.com, https://miscsolutions.wordpress.com

                            1 Reply Last reply Reply Quote 0
                            • hairy_kiwi
                              hairy_kiwi last edited by

                              Thanks for all the useful info, but I'm still a little confused after reading up on M0:

                              https://duet3d.com/wiki/G-code#M0:_Stop_or_Unconditional_stop says M0 H[non_zero_number] is sent by DWC to cancel a print job, keeping the heaters ON:
                              "M0: The optional 'H' parameter, whose value must be non-zero keeps all heaters active. This is what Duet Web Control sends to cancel a paused print."

                              Is it a correct assumption that if I have a sys/cancel.g file, that is called instead of DWC simply sending M0 H[non_zero_number]?

                              BTW, I can see how the default 'heaters remains on after cancelling print' may be useful behaviour for some cancelled print situations, however I'd like to suggest it is a less-safe default state in which to leave a machine after a print job is cancelled - especially for someone new to the hardware. I was recently caught out after cancelling a print, dashing out for an hour only to come back and discover the bed and extruder still hot - far from the safe state I expected it to be in. Would be interested to hear peoples thoughts.

                              I also discovered a possible bug in that after a print job is cancelled using the cancel button, the Control All > Turn everything off isn't functioning (in RRF v1.18beta2 - sorry I'm running a little behind the releases lately) - instead I need to turn off each heated device in turn.

                              1 Reply Last reply Reply Quote 0
                              • dc42
                                dc42 administrators last edited by

                                When M0 is received the firmware runs cancel.g if a print is currently paused, otherwise stop.g. If the file is missing and there is no nonzero H parameter, it turns off all heaters.

                                I presume your "Turn everything off" command is a macro. What do you have in the macro file?

                                Duet WiFi hardware designer and firmware engineer
                                Please do not ask me for Duet support via PM or email, use the forum
                                http://www.escher3d.com, https://miscsolutions.wordpress.com

                                1 Reply Last reply Reply Quote 0
                                • hairy_kiwi
                                  hairy_kiwi last edited by

                                  Many thanks for the clarification David.

                                  Sorry for the misunderstanding; I don't have a 'turn everything off' macro (am I missing it?) - I was referring to the 'Turn everything off' button in the following screen capture snippet:

                                  Maybe I broke that button's functionality when I hacked DWC to display a larger temperature graph - I don't see how, but it is a possibility.

                                  I've just played again with that button and notice it's completely non-functional (i.e. with and without first cancelling a print) - If I turn all heaters on manually, then click 'Turn everything off', it isn't functioning.

                                  Additionally, I just tried cancelling a print (with bed at set temp, extruder almost at set temp) and restarting the same print only to discover another problem: the extruder temperature is never re-set to printing temperature - the extruder head moves but cold extrusion protection is apparently kicking in to prevent extrusion. This probably needs more testing and verification, but will need to wait a week until I can play again.

                                  1 Reply Last reply Reply Quote 0
                                  • dc42
                                    dc42 administrators last edited by

                                    @hairy_kiwi:

                                    Additionally, I just tried cancelling a print (with bed at set temp, extruder almost at set temp) and restarting the same print only to discover another problem: the extruder temperature is never re-set to printing temperature - the extruder head moves but cold extrusion protection is apparently kicking in to prevent extrusion. This probably needs more testing and verification, but will need to wait a week until I can play again.

                                    That would be because you started the new print with no tool selected, and you didn't have a T0 or other tool selection command in your start gcode in the file you printed.

                                    Duet WiFi hardware designer and firmware engineer
                                    Please do not ask me for Duet support via PM or email, use the forum
                                    http://www.escher3d.com, https://miscsolutions.wordpress.com

                                    1 Reply Last reply Reply Quote 0
                                    • First post
                                      Last post
                                    Unless otherwise noted, all forum content is licensed under CC-BY-SA