Hi, Tjaart van der Walt wrote: > > I optimised them according to Tjaart-Experiment! :-) > > The resetting of I compensates (among other things) for > the digital nature of the calculations. Running 16 bit > PID values in a PIC is not feasible, so I pulled a few > tricks out of the hat. Another, is to only accumulate > the I value every 10-50 (settable) samples. Effectively > this divides the I term which is always much smaller > than the P or D terms. I read once about this method, maybe you've already told about it some time ago. Also the number of samples/s and how often Y is recaluclated is still a big issue - had some nice effects due to my PID running faster then the inertia of the motor could follow. Kind regards, Stefan