Heater PID Tuning



  • Hi all,

    I seem to be having more frequent heater faults than ever before.

    I've tried M303 H1 S*** PID tuning, which completes successfully.

    I've been doing it at S220 which is about the max I usually print at. Is that right, or should PID tuning be done up to a very high temp?

    Also, on Smoothieware, the PID tuning seems a bit more comprehensive. i.e. it will do multiple rises and falls around the target temp. probably upwards of 5 heating cycles…I guess this adds data points compared to the one time heat that RRF seems to do.

    Is this intentional, or is there room for improvement on PID tuning?


  • administrators

    You haven't said what type of heating fault you have been getting. See https://duet3d.dozuki.com/Wiki/Spurious_heater_faults_and_how_to_avoid_them if you haven't already.

    Smoothieware, Marlin and all other firmwares use a crude method called "relay auto tuning" to find some PID parameters that work, usually but not always tolerably well. The reason they do multiple cycles is that they need to measure the oscillation period and oscillation amplitude. Whereas RRF takes a large number of data points and uses them to construct a first-order-process-with-dead-time model, from which two separate sets of PID parameters are calculated, one for heating (optimised for low overshoot) and a separate one for maintaining temperature (optimised for fast response).

    The use of a FOPDT model in RRF allows us to make the heater fault detection better, because it is tuned to the behaviour of your heater. So it detects heater faults faster. However, certain things can make it too sensitive - the main one being a print cooling fan that blows too much air over the heater block. In time I intend to introduce a more sophisticated heater model that knows about the fan; but for now you may need to reduce the sensitivity of the heater fault detection.



  • I'm getting temperature deviations…typically way too low. I've just swapped cooling arrangement to the circular duct as posted in the Smart effector forum.

    Thanks for the detailed explanation...that all makes sense. Of course to the layman it seems as if the smoothieware process is "doing more" whereas the RRF method seems more simple.

    aUto-tuning always completes successfully, but I do always get the "over powered" warning on both the hot-end and the bed….I only ever get heater faults for the hot-end though.

    I should add, I'm not always there when the fault kicks in, but it seems to be on prints where there are very mixed processes. i.e. large top surface fill section, then some infill, some perimeters etc.


  • administrators

    If the temperature is generally stable then the most likely cause is that at certain points of the print, too much air from the print cooling fan gets directed at the heater block. This most often happens when the cooling fan first gets turned on (typically at the start of the second layer), but could happen later depending on the shape of the print.

    Remedies include:

    1. Use a silicone sock on the heater block if you are not using one already, and re-tune the heater after fitting it.

    2. Make sure the fan is directed at the print, not at the heater block.

    3. You may be able to tweak the PID parameters manually to get faster response. First check that with the hot end hot but the head not moving, the temperature is stable. If so, you can try reducing the dead time (D in the M307 command). Try 20%. Reducing D makes the PID respond faster to temperature changes; but if you make it too low then the temperature will oscillate. Test with and without the print cooling fan running. If the temperature shows signs of oscillating, increase D instead.

    4. If all else fails, use the M570 T parameter to increase the temperature variation tolerance above the default 15C. OTOH if you get temperature excursions of more than 15C, you are likely to get printing problems.

    HTH David


 

Looks like your connection to Duet3D was lost, please wait while we try to reconnect.