;# SYSTEM & GEOMETRY ############################################################################## M550 P"Voron3D" ; set printer and host name G21 ; millimeter units G90 ; absolute tool coordinates M83 ; relative extruder coordinates M669 K1 ; corexy mode M208 X0 Y0 Z-1.20 S1 ; S1 = set axes minima M208 X340 Y350 Z300 S0 ; S0 = set axes maxima ;-- Endstops -------------------------------------------------------------------------------------- M574 X2 S1 P"!io0.in" ; configure active-high endstop for high end on X via pin io0.in M574 Y2 S1 P"!io1.in" ; configure active-high endstop for high end on Y via pin io1.in M574 Z1 S1 P"io2.in" ; configure active-high endstop for low end on Z via pin io2.in ;-- Z drive positions ----------------------------------------------------------------------------- M671 X-72.0:-72.0:400.0:400.0 Y-10.0:410.0:411.0:-10.0 S10 M557 X30:310 Y50:310 S50 ; configure z probing grid for mesh compensation ;## MOVEMENT ###################################################################################### ; Motor layout: ; YB XA XY-axis ; Z1 Z2 Z-axis ; Z0 Z3 Z-axis ; TBE0 Tool board extruder M569 P0.0 D3 S0 ; physical drive XA goes backwards M569 P0.1 D3 S1 ; physical drive YB goes forwards M569 P0.2 S1 ; physical drive Z0 goes forwards M569 P0.3 S0 ; physical drive Z1 goes backwards M569 P0.4 S1 ; physical drive Z2 goes forwards M569 P0.5 S0 ; physical drive Z3 goes backwards M569 P121.0 S0 ; physical drive TBE0 goes forwards M584 X0.0 Y0.1 ; assign XA motor to Duet3 MB Driver_0, assign YB motor to Duet 3 MB Driver_1 M584 Z0.2:0.3:0.4:0.5 ; assign Z0, Z1, Z2 & Z3 motors to Duet3 MB Driver_2, _3, _4 & _5 M584 E121.0 ; assign extruder to Duet 3 Tool board M84 S60 ; motor idle timeout M906 I50 ; motor idle current percentage M350 X16 Y16 E16 I1 ; set microstepping for XY-axis and extruder, interpolation enabled M350 Z16 I1 ; set microstepping for Z-axis, interpolation disabled M92 X160.00 Y160.00 Z400 E415.00 ; set steps per mm; set microsteps per mm for 1.8-degree steppers ; Velocity, acceleration, and current settings are in these macros M98 P"/macros/Drive/xy_fullcurrent.g" M98 P"/macros/Drive/z_fullcurrent.g" M98 P"/macros/Drive/e_fullcurrent.g" ;-- Firmware retraction --------------------------------------------------------------------------- ; Choose one as default: ;M98 P"/macros/retraction/quiet_nozhop.g" ;M98 P"/macros/retraction/quiet_zhop.g" ;M98 P"/macros/retraction/pa_nozhop.g" ;M98 P"/macros/retraction/pa_zhop.g" ;## THERMAL ####################################################################################### ;-- Bed ------------------------------------------------------------------------------------------- M308 S0 P"temp0" Y"thermistor" T100000 B4267 ; configure sensor 0 as thermistor on pin temp0 M950 H0 C"out0" T0 ; create bed heater output on out0 and map it to sensor 0 M307 H0 A180.3 C257.4 D6.9 S1 V24.2 B0 ; disable bang-bang mode for the bed heater and set PWM limit (values after tuning) M140 H0 ; map heated bed to heater 0 M143 H0 S120 ; set temperature limit for heater 0 to 120C M570 H0 T10 S180 ; heater fault timeout ;-- Tool ------------------------------------------------------------------------------------------ M308 S1 P"121.temp0" Y"thermistor" T100000 B4725 C7.06e-8 ; configure sensor 1 as thermistor on pin 1.temp0 M950 H1 C"121.out0" T1 ; create nozzle heater output on 1.out0 and map it to sensor 1 M307 H1 B0 S1 ; disable bang-bang mode for heater and set PWM limit M570 H1 T10 S120 ; heater fault timeout ;## FANS ########################################################################################## ;-- Part cooling fan ------------------------------------------------------------------------------ M950 F0 C"121.out1" Q21000 ; create fan 0 on pin 1.out1 and set its frequency M106 P0 S0 H-1 C"MODEL FAN" ; set fan 0 value. Thermostatic control is turned off ;-- Hotend fan ------------------------------------------------------------------------------------ M950 F1 C"121.out2" Q21000 ; create fan 1 on pin 1.out2 and set its frequency M106 P1 S0 H1 T45 ; set fan 1 value. Thermostatic control is turned on ;-- Base compartment fans ------------------------------------------------------------------------- M950 F2 C"out7" Q21000 ; create fan 2 on pin out7 and set its frequency M106 P2 S0.95 H-1 C"RPi FAN" ; set fan 2 value. Thermostatic control is turned off M950 F3 C"out8" Q21000 ; create fan 3 on pin out8 and set its frequency M106 P3 S0 H-1 C"DUET FAN" ; set fan 3 value. Thermostatic control is turned off ;-- Exhaust fan ----------------------------------------------------------------------------------- M950 F4 C"out9" Q21000 ; create fan 3 on pin out8 and set its frequency M106 P4 S0 H-1 C"EXHAUST FAN" ; set fan 3 value. Thermostatic control is turned off ;## TOOL ########################################################################################## M563 P0 D0 H1 F0:1 S"Afterburner" ; define tool 0 G10 P0 X0 Y0 Z0 ; set tool 0 axis offsets G10 P0 R0 S0 ; set initial tool 0 active and standby temperatures to 0C T0 ;## Z-PPROBE ###################################################################################### M558 P8 C"!121.io0.in" A2 H5 F360 T18000 ; set Z probe type to switch and the dive height + speeds G31 P500 X0 Y25 Z2.25 ; set Z probe trigger value, offset and trigger height M557 X30:310 Y50:310 S50 ; define mesh grid ;# MISC ########################################################################################## M150 X1 Q2400000 ; set LED strip mode to NeoPixel, 2,4Mhz frequency M950 P3 C"io3.out" ; set camera trigger to GPIO3