I'm helping programming a FLL LEGO robot (two motorized wheels and a ballpoint in the back are the contacts with the ground), experimenting with a PID control to make it turn. It may seem overkill, but everything else, including a pure proportional control can't account well for the "not so precise" motors and sensors.
That said, what is a good exiting condition for a PID algorithm? Of course just waiting some time until the oscillation becomes imperceptible is good, but I wonder what the literature has to say, since in my application I need control back to the main program asap to do other things.
My guesses:
- fine tune the number of iterations with the derivative and proportional therms arbitrarily close to the setpoint
- a parallel control loop that "pulls the brake" after the setpoint has been reached a certain number of times (and fine tune it too)
If this is not the right place to ask this question feel free to move it wherever you want.