# Fixing filament runout always causes XY shift in the print

**URL:** <https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969>\
**Category:** J1/J1s IDEX\
**Tags:** Gcode\
**Created:** [May 27, 2024, 5:29pm UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969 "2024-05-27T17:29:26Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![mikedeklerk](https://avatars.discourse-cdn.com/v4/letter/m/13edae/32.png) [@mikedeklerk](https://forum.snapmaker.com/u/mikedeklerk)\
**Post date:** [May 27, 2024, 5:29pm UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969/1 "2024-05-27T17:29:26Z")

</div>

When the filament runout sensor (or clog sensor) says something is wrong with the filament on my Snapmaker J1 printer, it always is the case. When I fix the issue and load the filament, the printer has already homed the XY axis (and Z probably too). Now when the printer continues with the print, there is always a shift in XY. And this shift always happens. I think this is due to the homing procedure in between. I already have the latest firmware installed.

For that I wish to disable the homing feature in the routine of resolving the filament run out. I understood this is embeded in the [M600 g-code command](https://snapmaker.github.io/Documentation/gcode/M600)?

I would very much appreciate it if there was a possibility to not home during the routine of fixing the filament runout.

I am a software developer myself. As a last resort I could remove it from the code and recompile the firmware myself if needed. Of course, if there is a more user friendly way to achieve resolving the XY shift I would be more happy with that 😄.

From [the M600 g-code implemetation here](https://github.com/Snapmaker/SnapmakerController-IDEX/blob/main/Marlin/src/gcode/feature/pause/M600.cpp#L119), I read the following:

```auto
  #if ENABLED(HOME_BEFORE_FILAMENT_CHANGE)
    // If needed, home before parking for filament change
    home_if_needed(true);
  #endif

```

What ways are there to set `HOME_BEFORE_FILAMENT_CHANGE` to `false`?

Thanks.

---

<div class="post-metadata">

**Author:** ![xchrisd](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.snapmaker.com/xchrisd/32/1503_2.png) [@xchrisd](https://forum.snapmaker.com/u/xchrisd)\
**Post date:** [May 27, 2024, 7:27pm UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969/2 "2024-05-27T19:27:43Z")

</div>

It would be good if you let it the snapmaker devs know and correct:  
[Support@snapmaker.com](mailto:Support@snapmaker.com) or  
[Support Ticket Form](https://snapmaker.formcrafts.com/support-ticket)

---

<div class="post-metadata">

**Author:** ![MarkA121](https://avatars.discourse-cdn.com/v4/letter/m/e9bcb4/32.png) [@MarkA121](https://forum.snapmaker.com/u/MarkA121)\
**Post date:** [October 12, 2024, 3:56pm UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969/3 "2024-10-12T15:56:00Z")

</div>

Your J1 has a filament runout sensor??? Mine does not, and I’m trying to figure out how to add one.

---

<div class="post-metadata">

**Author:** ![mehlawlarz](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.snapmaker.com/mehlawlarz/32/26828_2.png) [@mehlawlarz](https://forum.snapmaker.com/u/mehlawlarz)\
**Post date:** [October 18, 2024, 8:44am UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969/4 "2024-10-18T08:44:47Z")

</div>

All J1 models have a runout sensor, it is however very different from what normal runout sensors look like as it uses a extruder gear to drive a rotary encoder therefore it can detect not just filament runout but under extrusion as well.

Its the orange part above the extruder gears in this image:

 ![image](https://us1.discourse-cdn.com/flex022/uploads/snapmaker/original/3X/8/a/8a568c2694377641fd5188f7b6bee8679dd126aa.jpeg)

---

<div class="post-metadata">

**Author:** ![MarkA121](https://avatars.discourse-cdn.com/v4/letter/m/e9bcb4/32.png) [@MarkA121](https://forum.snapmaker.com/u/MarkA121)\
**Post date:** [October 21, 2024, 10:13pm UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969/5 "2024-10-21T22:13:22Z")

</div>

OK. I found the “Runout Sensor” setting in the Configuration screen, and they are both enabled, but, they don’t seem to do anything. I have had prints merrily continue printing after the filament has run out. Shouldn’t it pause and wait for more filament to be loaded?

---

<div class="post-metadata">

**Author:** ![mehlawlarz](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.snapmaker.com/mehlawlarz/32/26828_2.png) [@mehlawlarz](https://forum.snapmaker.com/u/mehlawlarz)\
**Post date:** [October 22, 2024, 8:53am UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969/6 "2024-10-22T08:53:39Z")

</div>

Yes it should, seems like you might have to contact Snapmaker support regarding this issue as I have not personally ran into any issues with the sensor on my unit.

Perhaps check your slicer settings as it may be overridden by G-code, check for [M412](https://marlinfw.org/docs/gcode/M412.html) in your sliced G-codes.

---

<div class="post-metadata">

**Author:** ![MarkA121](https://avatars.discourse-cdn.com/v4/letter/m/e9bcb4/32.png) [@MarkA121](https://forum.snapmaker.com/u/MarkA121)\
**Post date:** [November 3, 2024, 3:55am UTC](https://forum.snapmaker.com/t/fixing-filament-runout-always-causes-xy-shift-in-the-print/35969/7 "2024-11-03T03:55:27Z")

</div>

I have not done a thorough investigation, but it appears that the filament runout sensor does not communicate thru the USB-B connector in the back of the printer, which is how I use my printer. [Octoprint running on a Raspberry Pi connected to USB-B]. It seems that some of the J1’s functionality is actually in the front panel, not in the firmware.
