# PAUSE does not pause the print ("Printer not homed")

**URL:** <https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445>\
**Category:** General Discussion\
**Created:** [January 24, 2024, 3:28am UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445 "2024-01-24T03:28:48Z")\
**Posts on this page:** 18\
**Page:** 1

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 3:28am UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/1 "2024-01-24T03:28:48Z")

</div>

### Basic Information:

Printer Model: FLSUN QQ  
 MCU / Printerboard: MKS  
 [klippy.zip](https://klipper.discourse.group/uploads/short-url/aNnELkH0Ws23PM50a39KbAFGqt8.zip) (550.0 KB)

### Describe your issue:

I want to do “pause at layer”. I have added a postprocessing script in Cura to pause at a specific layer. This is what the script inserts into the gcode:

```gcode
;added code by post processing
;script: PauseAtHeight.py
;current layer: 230
M83 ; switch to relative E values for any needed retraction
M104 S0 ; standby temperature
M84 S3600 ; Keep steppers engaged for 1h
M0 ; Do the actual pause
M104 S205 ; resume temperature
G1 F5400 ; restore extrusion feedrate
M82 ; switch back to absolute E values
G92 E1692.45565

```

Because I read that M0 does not mean pause in Klipper, I have added this to my printer.cfg:

```auto
[gcode_macro M0]
gcode:
  PAUSE

```

This is supposed to trigger the `PAUSE` macro from fluidd.cfg (or mainsail.cfg, but I believe they are identical).

When I ran the job, it did indeed stop at the requested layer, but there was an error message:

> ```plaintext
> echo: Printer not homed
> 
> ```

When I tried to resume (using the `RESUME` macro) it said:

> ```plaintext
> !! Must home first: 0.121 -14.453 46.200 [22485.305]
> 
> ```

So I clicked the Home button and the printer homed. Then I tried to resume again and it said:

> ```plaintext
> echo: Extruder not hot enough
> // Print is not paused, resume aborted
> 
> ```

So it seems like the print was never actually paused, maybe because the `RESPOND` aborted macro execution? And why was that `RESPOND` even executed, it seems to depend on `printer.toolhead.homed_axes` not being `"xyz"`. I don’t quite understand what the issue is.

I read somewhere that this can happen if the print was paused for a long time and ran into the idle timeout but in my case everything happened within a couple of minutes.

I think as a workaround I will try to call `PAUSE_BASE` instead of `PAUSE` but that can hardly be the recommended solution.

---

<div class="post-metadata">

**Author:** ![jakep\_82](https://avatars.discourse-cdn.com/v4/letter/j/ea666f/32.png) [@jakep\_82](https://klipper.discourse.group/u/jakep_82)\
**Post date:** [January 24, 2024, 5:43am UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/2 "2024-01-24T05:43:05Z")

</div>

M84 turns off motors, and Klipper doesn’t support any delay variable for this gcode. It will simply turn off the motors and discard the rest of that line.

---

<div class="post-metadata">

**Author:** ![theophile](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/theophile/32/31_2.png) [@theophile](https://klipper.discourse.group/u/theophile)\
**Post date:** [January 24, 2024, 1:27pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/3 "2024-01-24T13:27:45Z")

</div>

What is the purpose of inserting all that code? Why not just insert `PAUSE`?

---

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 2:51pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/4 "2024-01-24T14:51:07Z")

</div>

> [@jakep\_82](#):
>
> M84 turns off motors, and Klipper doesn’t support any delay variable for this gcode. It will simply turn off the motors and discard the rest of that line.

💡

> [@theophile](#):
>
> What is the purpose of inserting all that code? Why not just insert `PAUSE`?

The script comes with Cura, it has a number of options and generates this code.

![image](https://global.discourse-cdn.com/free1/uploads/klipper/original/2X/9/96479bb3f321561e61c645bef36e87eb29e2335f.png)

Honestly injecting `M84 S3600` when the option says “Keep motors engaged” feels almost like a bug. I can see where they’re coming from, but still there should be another option to not generate `M84` _at all_.

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [January 24, 2024, 3:38pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/5 "2024-01-24T15:38:10Z")

</div>

Well, as you can see in “Method”, this functionality is tuned for Marlin and definitively does not care for Klipper or its requirements or capabilities.  
As pointed out by @theophile all these shenanigans that Cura inserts would not be needed for Klipper  
You might want to check and address this here: [Improving Cura for Klipper and Smooth Motion Firmware 🏃 · Ultimaker/Cura · Discussion #16012 · GitHub](https://github.com/Ultimaker/Cura/discussions/16012)

---

<div class="post-metadata">

**Author:** ![jakep\_82](https://avatars.discourse-cdn.com/v4/letter/j/ea666f/32.png) [@jakep\_82](https://klipper.discourse.group/u/jakep_82)\
**Post date:** [January 24, 2024, 3:38pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/6 "2024-01-24T15:38:24Z")

</div>

I’m sure it works fine with Marlin which is the method you’ve chosen, but Klipper doesn’t support all of the same gcodes as Marlin.

---

<div class="post-metadata">

**Author:** ![LifeOfBrian](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/lifeofbrian/32/2380_2.png) [@LifeOfBrian](https://klipper.discourse.group/u/LifeOfBrian)\
**Post date:** [January 24, 2024, 3:59pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/7 "2024-01-24T15:59:50Z")

</div>

You could maybe create a macro for that particular gcode and just call `PAUSE`.  
This keeps it compatible.

---

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 6:30pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/8 "2024-01-24T18:30:40Z")

</div>

> [@Sineos](#):
>
> Well, as you can see in “Method”, this functionality is tuned for Marlin and definitively does not care for Klipper or its requirements or capabilities.

These are the available methods, unfortunately no Klipper (although we might be able to get a pull request merged for that):  
 ![image](https://global.discourse-cdn.com/free1/uploads/klipper/original/2X/6/6d70507ecbbe2117171f0f35529369ce385f8c46.png)

Anyway, I have removed the `M84` from the gcode. Pausing works now, but resuming doesn’t.

```plaintext
19:22:45 $ RESUME
19:22:45 echo: Extruder not hot enough
19:22:45 !! Must home first: 0.200 -14.374 46.200 [44964.601]
19:22:45 !! Must home first: 0.200 -14.374 46.200 [44964.601]
19:22:45 !! Must home first: 0.200 -14.374 46.200 [44964.601]
19:23:17 $ G28 X Y
19:23:43 $ RESUME
19:23:43 echo: Extruder not hot enough
19:23:43 // Extrude below minimum temp
         // See the 'min_extrude_temp' config option for details
19:23:43 !! Extrude below minimum temp
19:23:43 echo: Extruder not hot enough

```

It appears to me that there are two issues, one is the temperature, which probably means I have to remove the `M104` lines as well.

But it also seems that the homing issue is not resolved. The PAUSE now works but the RESUME doesn’t, so it still loses its “homed” state at some point.

If I resolve the temperature issue and home manually before resume, it might work, I’m gonna try that now.

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [January 24, 2024, 6:48pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/9 "2024-01-24T18:48:26Z")

</div>

Cura inserts M104, which does not wait for the temperature and since you let it cool to 0 you run into this issue.

IMO, none of the inserted gcodes is needed if you are using the default macros that Mainsail or fluidd are providing. There you could even add a simple `SET_PAUSE_AT_LAYER LAYER=xxx` in your sliced gcode at the beginning and Klipper will do the rest.

> [@AndreKR](#):
>
> But it also seems that the homing issue is not resolved.

I do not see any indication of this in what you have posted. Also, I can confirm the a.m. macros are working as intended.

---

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 6:58pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/10 "2024-01-24T18:58:36Z")

</div>

> [@Sineos](#):
>
> There you could even add a simple `SET_PAUSE_AT_LAYER LAYER=xxx` in your sliced gcode at the beginning and Klipper will do the rest.

I read that this macro only works if you have SET\_PRINT\_STATS\_INFO in your gcode which I have not.

> [@Sineos](#):
>
> > [@AndreKR](#):
> >
> > But it also seems that the homing issue is not resolved.
> 
> I do not see any indication of this in what you have posted.

I think that because of `!! Must home first`.

---

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 7:04pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/11 "2024-01-24T19:04:31Z")

</div>

I can confirm that the issue was indeed the `M104` without that resuming works. As for the `Must home first` I believe I might have run into the idle timeout because I had to change the filament and the idle timeout is apparently 10 minutes.

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [January 24, 2024, 7:04pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/12 "2024-01-24T19:04:32Z")

</div>

> [@AndreKR](#):
>
> I think that because of `!! Must home first`.

Something is fishy here. A regular `PAUSE` does not invalidate homing unless you let it run into idle timeout.  
If this is the case, the macros also allow you to change this behavior.

> [@AndreKR](#):
>
> I read that this macro only works if you have SET\_PRINT\_STATS\_INFO in your gcode which I have not.

Well, if you rather fiddle around with a post-processor that does not produce Klipper compliant gcode. Your choice.

---

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 7:12pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/13 "2024-01-24T19:12:29Z")

</div>

> [@Sineos](#):
>
> > [@AndreKR](#):
> >
> > I read that this macro only works if you have SET\_PRINT\_STATS\_INFO in your gcode which I have not.
> 
> Well, if you rather fiddle around with a post-processor that does not produce Klipper compliant gcode. Your choice.

It’s not really by choice, I just assumed that making PauseAtHeight work is easier that making SET\_PRINT\_STATS\_INFO work because it _also_ requires fiddling with macros.

---

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 7:15pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/14 "2024-01-24T19:15:36Z")

</div>

Klipper’s PAUSE does not reduce the temperature, is that correct?

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [January 24, 2024, 7:23pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/15 "2024-01-24T19:23:35Z")

</div>

> [@AndreKR](#):
>
> because it _also_ requires fiddling with macros.

See [GitHub - pedrolamas/klipper-preprocessor: Klipper Preprocessor script for Cura](https://github.com/pedrolamas/klipper-preprocessor)

> [@AndreKR](#):
>
> Klipper’s PAUSE does not reduce the temperature, is that correct?

See [GitHub - fluidd-core/fluidd-config: Fluidd base configuration for Klipper](https://github.com/fluidd-core/fluidd-config/tree/master#new-feature-saverestore-extruder-temperature-on-pauseresume)

---

<div class="post-metadata">

**Author:** ![AndreKR](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/andrekr/32/6956_2.png) [@AndreKR](https://klipper.discourse.group/u/AndreKR)\
**Post date:** [January 24, 2024, 7:34pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/16 "2024-01-24T19:34:06Z")

</div>

> [@Sineos](#):
>
> > [@AndreKR](#):
> >
> > Klipper’s PAUSE does not reduce the temperature, is that correct?
> 
> See [GitHub - fluidd-core/fluidd-config: Fluidd base configuration for Klipper](https://github.com/fluidd-core/fluidd-config/tree/master#new-feature-saverestore-extruder-temperature-on-pauseresume)

Hm, am I understanding this correctly? The PAUSE/RESUME macros will _restore_ the temperature upon resume, but _I_ am responsible to reduce it. I can either do that by configuring `[idle_timeout]` (which has the additional advantage that I can remove the `M84` so I don’t lose homing state during pause) or I can reduce the temperature manually after calling `PAUSE`?

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [January 24, 2024, 9:41pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/17 "2024-01-24T21:41:20Z")

</div>

Never used this functionality, but as far as my understanding goes, yes.  
Also, you could probably use the

```auto
#variable_user_pause_macro : "" ; Everything insight the "" will be executed after the klipper base pause (PAUSE_BASE) function

```

function

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/free1/uploads/klipper/original/1X/64419bf2aac6639e6ef5cef200dcd456b0a01ac3.png) [@system](https://klipper.discourse.group/u/system)\
**Post date:** [March 24, 2024, 9:41pm UTC](https://klipper.discourse.group/t/pause-does-not-pause-the-print-printer-not-homed/13445/18 "2024-03-24T21:41:27Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
