Filament runout detection
thingiverse
Finally got around to build something to deal with running out of filament when printing from Octoprint (not direct from SD card) on my Ender 3 Pro. I created this bracket to use with the following switches: https://www.amazon.com/gp/product/B00MFRMFS6/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 I connected the two outer most connections to my raspberry pi as you can see in the pickture. The housing for the pi is: https://www.amazon.com/gp/product/B081N3V6BH/ref=ppx_yo_dt_b_asin_image_o06_s01?ie=UTF8&psc=1 Connect it to physical pins of the pi (4B) as shown in the picture. The wire guide STL is a nice to have if you want to guide the wire to the side of the frame. I use the filament sensor reloaded plugin for Octoprint and have included a screenshot for the settings for the plugin. You will also have to tell Octoprint what to do when a print is paused (for you to change filament): {% if pause_position.x is not none %} ; relative XYZE G91 M83 ; Lower extruder temp M104 180 ; retract filament, move Z slightly upwards G1 Z+5 E-5 F4500 ; absolute XYZE M82 G90 ; move to a safe rest position (use X0 and Y0 depending on your printer) G1 X220 Y220 {% endif %} And what to do when resuming a print: {% if pause_position.x is not none %} ; relative extruder M83 ; prime nozzle G1 E-5 F4500 G1 E5 F4500 G1 E5 F4500 ; absolute E M82 ; absolute XYZ G90 ; reset E G92 E{{ pause_position.e }} ; move back to pause position XYZ G1 X{{ pause_position.x }} Y{{ pause_position.y }} Z{{ pause_position.z }} F4500 ; reset to feed rate before pause if available {% if pause_position.f is not none %}G1 F{{ pause_position.f }}{% endif %} {% endif %} You configure these settings in the GCODE Scripts section of the Octoprint settings. It all works like a charm as can be seen from the example picture where I switch from black to grey filament. Seamless.
With this file you will be able to print Filament runout detection with your 3D printer. Click on the button and save the file on your computer to work, edit or customize your design. You can also find more 3D designs for printers on Filament runout detection.