8
$\begingroup$

I have a spool of translucent PLA filament that doesn't work well with the filament sensor on my Prusa i3 MK3. The translucency trips up the sensor, making it think the filament ran out. I thought I'd create a filament profile in Slic3r and disable the sensor in the "Start G-code" block that gets inserted at the beginning of the exported gcode file.

I've got the following code:

M900 K{if printer_notes=~/.*PRINTER_HAS_BOWDEN.*/}200{else}30{endif}; Filament gcode
M406 ; Disable filament sensor
M117 Filament sensor OFF

The first line is provided by Prusa's default PLA profile. The second line should disable the sensor, and the third line should print the "Filament sensor OFF" message. If I look in the gcode, it's there:

G92 E0.0
M221 S95
M900 K30; Filament gcode
M406 ; Disable filament sensor
M117 Filament sensor OFF
G21 ; set units to millimeters
G90 ; use absolute coordinates
M83 ; use relative distances for extrusion
;BEFORE_LAYER_CHANGE

But if I print this gcode file, I see no message, and when checking the sensor in the "Tune" menu while printing, the sensor is still on.

I thought I might have a problem with line endings, but looking at the file in a hex editor, all the lines seem to end with a 0A line feed character, including mine.

Why isn't my printer doing anything with the M406 and M117 messages? Full gcode file here.

$\endgroup$
1
$\begingroup$

When you download the latest version of your firmware you find the implementation of all the codes in Marlin_main.cpp. Here you see that the M406 is not implemented! Hence it does not work.

$\endgroup$
  • $\begingroup$ this is original Prusa - so marlin is not used! $\endgroup$ – profesor79 May 15 '18 at 14:01
  • 1
    $\begingroup$ @profesor79 Download the software from Prusa itself and you will see that it does have the Marlin_main.cpp file! github.com/prusa3d/Prusa-Firmware/blob/MK3/Firmware/… $\endgroup$ – 0scar May 15 '18 at 14:15
  • $\begingroup$ ok got that, another bit it the puzzles sorted :) $\endgroup$ – profesor79 May 15 '18 at 14:16
  • 1
    $\begingroup$ @profesor79 Always glad to teach the professor ;) $\endgroup$ – 0scar May 15 '18 at 14:17
  • 1
    $\begingroup$ @Bas I can't tell for sure, Prusa has implemented M117 differently (with a higher priority?). Maybe this does not work flawlessly. $\endgroup$ – 0scar May 15 '18 at 19:35
1
$\begingroup$

As per github PR this is not implemented - see this PR for details Please check if your printer is processing M406 by issuing it manually.

In meantime, a sticker on the sensor will help you to print :)

$\endgroup$
  • $\begingroup$ Professor79 Could you give a little more detail on how to use a sticker to stop the filament sensor issue? Maybe a photograph or specific placement advice? Left to my own devices I will continue to avoid the issue by printing my shiny filaments in total darkness. There has to be a better way. Thanks, from the peanut gallery $\endgroup$ – Winky42 May 8 at 14:59
  • $\begingroup$ @Winky42 that depends if you have a mechanical or optical sensor. if is optical then just cover the lenses, if is mechanical put down the lever. $\endgroup$ – profesor79 May 9 at 11:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.