PID tuning
How to calibrate the PID temperature controller for each of the G1’s heating zones. Run this after any hardware change affecting temperature stability (new fan, different nozzle, different material airflow).
When to do it
Section titled “When to do it”- After installing a new cooling fan or changing fan position
- After replacing a heater cartridge or thermistor
- When a heating zone consistently overshoots or oscillates instead of holding steady
- After a major Klipper firmware update (if temperature behavior changes)
- When printing in a very different ambient temperature (e.g. outdoor/cold workshop vs. heated studio)
Prerequisites
Section titled “Prerequisites”- Printer powered on, G1OS dashboard accessible at
http://g1os.local - Extruder clear of material (or with material loaded — both work)
- Cooling fans running at the speed you use during printing (see note below)
1 — Open the Mainsail Console
Section titled “1 — Open the Mainsail Console”Go to http://g1os.local → Console in the left sidebar.
2 — (Optional) Start the cooling fans first
Section titled “2 — (Optional) Start the cooling fans first”If you want to calibrate with fans running, send:
M106 S128 # fans at ~50%Adjust the value (0–255) to match your typical print fan speed.
3 — Run PID calibration for each zone
Section titled “3 — Run PID calibration for each zone”Run calibration one zone at a time. Replace TARGET with your typical printing temperature for that zone.
Feeding Zone (Extruder 0 / T0):
PID_CALIBRATE HEATER=extruder TARGET=200Melting Zone (Extruder 1 / T1):
PID_CALIBRATE HEATER=extruder1 TARGET=220Nozzle Zone (Extruder 2 / T2):
PID_CALIBRATE HEATER=extruder2 TARGET=220Each calibration takes 3–8 minutes. Klipper cycles the heater on and off multiple times and computes optimal P/I/D values automatically. Wait for the message:
PID parameters: pid_Kp=... pid_Ki=... pid_Kd=...4 — Calibrate the bed (optional)
Section titled “4 — Calibrate the bed (optional)”If the bed temperature also oscillates:
PID_CALIBRATE HEATER=heater_bed TARGET=655 — Save the results
Section titled “5 — Save the results”After all zones are calibrated:
SAVE_CONFIGThe printer restarts automatically. New PID values are written to the [extruder], [extruder1], [extruder2] sections in printer.cfg.
Verifying the result
Section titled “Verifying the result”After the printer restarts:
- Heat all zones to printing temperature
- Watch the temperature graph in G1OS (click the temperature display to expand)
- Good PID: temperature reaches target and holds within ±2°C with no oscillation
- If oscillation continues: re-run PID calibration, ensuring fans are on during calibration
- The Feeding Zone (Extruder 0) tends to overshoot by 10–15°C on first heating — PID calibration corrects this
- If Nozzle Zone (Extruder 2) drops 20–30°C when the fan turns on, see Heater not reaching temperature for the fan-on-sensor diagnosis first
- Use the same
TARGETtemperature you actually print at — PID values tuned at 200°C may not be optimal at 250°C