Hi,
Start with pid_Ki set to 0. Increase pid_Kp and "bump" the regulator (change the setpoint) do this a couple of times until you see it begin to overshoot or a tendency to oscillate.
Increase pid_Kd in order to damp out the overshoot.
Now you can try to increase pid_Kp even further, once again it will overshoot or start to osciallate, follow with pid_Kd.
This should give you a stable loop but it will most likely never hit the actual setpoint. Slowly increase i pid_Ki to bring the value right up to the setpoint. Increasing pid_Ki will introduce an overshoot which you might should be able to reduce by further increasing pid_Kd.
With that said it's crucial that you run the PID (read input, run PID, update output) at a constant interval. If the time between updates varies you won't get a stable output.
/Henrik.
Bookmarks