M303
and M307
the temperature control loop can be tuned and changed. The default control variables supplied by M3D in the configuration files should allow you to print at a stable temperature. However, significant changes to the printing environment, such as room temperature, air-flow or humidity can impact your control loop effectiveness and stability. An improper control loop can cause problems listed below.M303
M303
will heat-up your hot-end to a set-point temperature and record data as it does so. Therefore, while your hot-end is undergoing it is important to replicate the conditions that your 3D printer prints in. For example, turning on your nozzle fans. First, the tuning process will heat the hot-end to your set temperature. It will likely overshoot the set-point. The nozzle will then cool-down to room temperature. If you instructed the control board to perform multiple cycles, it will repeat this process multiple times. Once complete, the firmware will return suggested control variable values.M303
Parameters:Hnnn
: Heater number (by default: 0 is bed, 1 & 2 hot-ends)Pnnn
: PWM percentage from 0 to 1.Snnn
: Set-point temperature in °CM307
Parameters:Hnnn
: Heater number (by default: 0 is bed, 1 & 2 hot-ends)Annn
: Gain constantCnnn
: Time constantDnnn
: Dead timeFnnn
: PWM frequencyBn
: Bang-bang control enable (1)Snnn
: Maximum PWMVnnn
: Vin at the time of calibration. Allows for compensation of power supply voltage variation.M303
command, this step is not necessary. We recommend removing filament as it can burn and char inside your hot-end if the tuning process reaches a high temperature.M303
command. Change the H
parameter to reflect the heater number. The PWM percentage can be changed with P
if the heater is heating up too fast, and the firmware is unable to present control variables. The S
parameter should be set to a typical printing temperature, such as 230°C. An example would be M303 H1 P0.5 S230
in order to run auto-tune on hot-end 1, with 50% PWM and to 230°C.M303
should also display the control variables.M307
command in order to set new control variables. Use the parameter list above to determine the proper syntax. M307
command in the configuration file config.g with the command you just entered in order for your changes to take effect upon a system restart.M301
in order to send enable and send these control variables. These control variables also can be found by running the M303
auto-tune as listed above. The command M301
will enable the legacy PID control loop.M301
Parameters:Hnnn
: Heater numberPnnn
: Proportional constant (Kp)Innn
: Integral constant (Ki)Dnnn
: Derivative constant (Kd)