This design is a work in progress. Here is a list of current issues / todos:
By inserting custom gcode into PrusaSlicer, we can press a virtual button input to an ESP8266 running WLED. This gives us the benefits of WLED (wifi smartphone app and lots of animation options) with very little overhead.
A typical print will follow the following animation routine:
No raspberry pi needed. If you are running OctoPrint, you can still follow this build. Do not wire the ESP8266 into your einsy. Instead, use the WLED OctoPrint Plugin.
Optional:
We are a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for us to earn fees by linking to Amazon.com and affiliated sites.
This is a remix of Prusa Multi-Color Unit | RGB Individually Addressable LED Light Bar by Mew. Go there for additional 3D parts and assembly notes. Come back here for wiring and WLED setup.
Changes from Mew's Version:
Installation
Installation is all done from your browser. No tools needed.
Settings
After connecting to your WLED installation, set the config options:
Config > LED Preferences:
Config > Time & Macros:
Optional: If you have a tactile button, you can also setup Button 2’s input and Macros.
Presets
THIS SECTION IS A WORK IN PROGRESS!!! USE PRESETS FROM APPENDIX
Using WLED's file explorer, we can enter all the presets in one go.
Tips:
Wiring
THIS SECTION IS A WORK IN PROGRESS!!!
Now that WLED is configured, you can wire your ESP8266 into the neopixel strip and Prusa.
THIS SECTION IS A WORK IN PROGRESS!!!
Do not just copy and paste these. Compare them to your own Custom G-code in your PrusaSlicer > Printer Settings. Copy only the animation parts for toggling the P73 without erasing your existing G-Code.
When done, save your new printer profile in PrusaSlicer.
Start G-code:
M862.3 P "[printer_model]" ; printer model check
M862.1 P[nozzle_diameter] ; nozzle diameter check
M115 U3.11.0 ; tell printer latest fw version
G90 ; use absolute coordinates
M83 ; extruder relative mode
M42 P73 S255 ; Heating Up Animation
G4 P500
M42 P73 S0
G4 P150
M42 P73 S255
G4 P150
M42 P73 S0
G4 P150
M42 P73 S255
M104 S[first_layer_temperature] ; set extruder temp
M140 S[first_layer_bed_temperature] ; set bed temp
M190 S[first_layer_bed_temperature] ; wait for bed temp
M109 S[first_layer_temperature] ; wait for extruder temp
M42 P73 S255 ; Auto Bed Leveling Animation
G4 P500
M42 P73 S0
G4 P150
M42 P73 S255
G28 W ; home all without mesh bed level
G80 ; mesh bed leveling
M42 P73 S255 ; Active Print Animation
G4 P500
M42 P73 S0
G4 P150
M42 P73 S255
G1 Z0.2 F720
G1 Y-3 F1000 ; go outside print area
G92 E0
G1 X60 E9 F1000 ; intro line
G1 X100 E12.5 F1000 ; intro line
G92 E0
M221 S{if layer_height<0.075}100{else}95{endif}
; Don't change E values below. Excessive value can damage the printer.
{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3).*/}M907 E430 ; set extruder motor current{endif}
{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
End G-code:
{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}
G1 X0 Y200 F3600 ; park
{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}
G4 ; wait
M221 S100 ; reset flow
M900 K0 ; reset LA
{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}
M104 S0 ; turn off temperature
M140 S0 ; turn off heatbed
M107 ; turn off fan
M84 ; disable motors
M42 P73 S255 ; Idle Animation
G4 P500
M42 P73 S0
G4 P1000
M42 P73 S255
WLED is expecting button presses with specific timings.
Short Press
M42 P73 S255 //clear previous
G4 P500
M42 P73 S0 //short press
G4 P150
M42 P73 S255 //clear press
Long Press
M42 P73 S255 //clear previous
G4 P500
M42 P73 S0 //long press
// no need to wait to clear
Double Press
M42 P73 S255 //clear previous
G4 P500
M42 P73 S0 //short press
G4 P150
M42 P73 S255
G4 P150
M42 P73 S0 //double press
G4 P150
M42 P73 S255 //clear press
This is for reference only. Uploading the presets.json will set these for you. Or make your own :D the app is very easy to use with lots of youtube tutorials.
Preset 1 Idle
This needs to be a static non-animation. Holding the button after the print can re-trigger the animation to start over and cause flickering of a moving animation.
{"on":true,"bri":255,"transition":7,"mainseg":0,"seg":[{"id":0,"start":0,"stop":20,"grp":1,"spc":0,"of":0,"on":true,"frz":false,"bri":255,"cct":127,"col":[[255,224,160],[0,0,0],[0,0,0]],"fx":115,"sx":187,"ix":0,"pal":0,"sel":true,"rev":false,"mi":false},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0}]}
Preset 2 Heating
{"on":true,"bri":128,"transition":7,"mainseg":0,"seg":[{"id":0,"start":0,"stop":20,"grp":1,"spc":0,"of":0,"on":true,"frz":false,"bri":255,"cct":127,"col":[[255,4,0],[255,180,82],[0,0,0]],"fx":2,"sx":128,"ix":128,"pal":0,"sel":true,"rev":false,"mi":false},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0}]}
Preset 3 Bed Leveling
{"on":true,"bri":128,"transition":7,"mainseg":0,"seg":[{"id":0,"start":0,"stop":20,"grp":1,"spc":0,"of":0,"on":true,"frz":false,"bri":255,"cct":127,"col":[[0,0,255],[255,180,82],[0,0,0]],"fx":27,"sx":128,"ix":128,"pal":0,"sel":true,"rev":false,"mi":false},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0}]}
Preset 4 Printing
{"on":true,"bri":128,"transition":7,"mainseg":0,"seg":[{"id":0,"start":0,"stop":20,"grp":1,"spc":0,"of":0,"on":true,"frz":false,"bri":255,"cct":127,"col":[[179,0,255],[0,26,255],[0,0,0]],"fx":9,"sx":128,"ix":128,"pal":0,"sel":true,"rev":false,"mi":false},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0},{"stop":0}]}
Preset 99 Next Preset
Preset selection loop must start at 1 so WLED can track the currently selected preset and always increment to the next preset. More info
win&P1=1&P2=5PL=~
The author remixed this model.