Duet Pid Auto Tune

Dc42 wrote:That's why in RepRapFirmware, we don't to conventional PID auto tuning. Instead we use auto tuning to develop a first-order-plus-dead=time model of the heater, and from that we calculate two sets of PID parameters. One is used when the setpoint is changed by a large amount. PID auto tune works differently. The firmware models each heater as a first order process with dead time, and measures the corresponding model parameters for your heater. It uses these parameters to compute two sets of PID values. One is designed to minimise overshoot when heating up to operating temperature. Hotend PID Tuning. Now that we have the 3D Printer connected to the computer, we can start the Hotend PID Calibration. Get the current PID settings using the M503 command. Your printer will return the current PID settings. Run the M106 S255 command in order to set your cooling fan to 100%. Run the M303 E0 S215 C8 command and wait for the. M303 – PID autotune, used to pid tune heaters for a more consistent heat, M303 E0 S200 C10 would PID tune the hotend at 200c for 10 cycles; See our PID Auto Guide for more deatils; M122 – TMC debugging – returns current settings for all installed and supported drivers; M106 – Set fan speeds between 0 and 255. Test AUTO TUNE: output cannot be used. Test with Auto tune generated PID from this version: FAIL c. Test with Previously Established known good value: FAIL. With known good PID values, after warm up if the temp reaches peak, it will drop say from 200 to 185 before then ramping back up. There was no thermal event despite the massive.

RepRapFirmware supports a chamber heater, but by default no chamber heater is configured. To use a chamber heater, you will need a spare heater channel, and either the thermistor channel associated with that heater or another temperature sensing channel.

Connecting the chamber heater

Chamber heaters are typically AC mains powered, so you will need a Solid State Relay (SSR) to drive one. Use a zero-crossing DC/AC SSR such as Fotek SSR-25DA + safety cover, or Crydom D2425 + safety cover KS101. If your chamber heater draws more than about 5A then the SSR may need a heatsink.

Connecting a SSR to a heater output on the Duet, or Duex 2/ 5

SSRs generally accept anywhere between 3V and 32V input voltage, so you can connect the SSR to the heater terminal block. Make sure you connect the + and - terminals the right way round. The + terminal on the SSR goes to the heater terminal marked + or VIN, and the - terminal pin the SSR goes to the heater terminal marked -.

Connect the thermistor that measures chamber temperature to the associated thermistor input.

Connecting a SSR directly to the expansion connector

If you have a Duet without an expansion board and no spare heater channels, you can connect the input of the SSR directly to the expansion connector. The heater outputs of the Duet are active low, so connect the SSR - input terminal to the appropriate expansion connector pin, and connect the SSR + input terminal to +3.3V (pin 3 on the expansion connector).

You will also need a thermistor input channel to monitor the chamber temperature. If you are using a PT100 or thermocouple sensor for a hot end, then you can use the thermistor input pins that would otherwise be used for that hot end. The following applies to all Duet versions.

Configuring the chamber heater

RepRapFirmware 3.x and later

Add the following commands to your config.g. Define the thermistor that will control the chamber heater with M308. Define the heater, or SSR that controls the heater, with M950. You can set the PWM frequency with the Q parameter. Set the heater parameters with M307. Once connected, tune the chamber heater with M303, and update the M307 parameters with the new settings. Use M141 to define this heater as a chamber heater. Set a temperature limit for chamber heater with M143. Example:

Duet

RepRapFirmware 2.x and earlier

You will need to add a M141 command to config.g to tell the firmware that you have a chamber heater and which heater channel it uses. You will also need a M305 command to configure the temperature sensor, and a M301 command to configure the PID parameters. Here is an example:

To use a different thermistor channel form the heater channel, add a suitable XS parameter to the M305 command. For example, X1 would tell the firmware to use the thermistor channel associated with heater 1 (which is normally the first extruder heater).

You can use PID control of the chamber heater if you wish. RepRapFirmware uses low frequency (10Hz) PWM on the chamber heater channel so as to be compatible with most SSRs.

How To Pid Tune

Using the chamber heater

Add the command M141 S### to your slicer start gcode, where ### is the required chamber temperature at the start. Also make sure there is a M116 command somewhere after the M141 command, to wait for all temperatures to reach their assigned values.

Duet Pid Auto Tune Kit

In your end gcode, either use the command M0 (which normally switches all heaters off), or the command M141 S0 to turn the chamber heater off.

Using multiple temp sensors for a single heater

Duet Pid Auto Tune Software

There are three ways of using two thermistors to control one heater:

Duet Pid Auto Tune Pro

  1. Connect them in series. The temperature readings will be averaged with a bias in favor of the colder one. If any wire breaks, you will get the usual -273C reading and the heater will fault.
  2. Connect them in parallel. The temperature readings will be averaged with a bias in favor of the hotter one. If one of the thermistor wires breaks, the temperature will under-read, so you will end up heating too much.
  3. Use one to control the temperature, and the other as an over-temperature cutout, configured using M143.

Pid Tune

Note: if connecting 2 in series, the resistance of the thermistors needs to be combined in config.g. So if each thermistor is 100k at room temperature, they need to be set as 200k when declaring the sensor with M308. And if connecting in parallel, the resistances need to be half their combined average (or just half of one if both are the same).

Duet Pid Autotune

However, when connecting thermistors in series or in parallel, although the B value remains the same, the effective C value changes. So it's easier to adjust the R parameter instead. For example, on a Duet 3 the normal R value is 2200. Acrobat distiller 4.0 for windows 8. If you connect two identical thermistors in parallel, you can specify the usual T, B and C parameters for the thermistors, but double R to 4400. Likewise, if connecting two thermistors in series, halve the R value.