> I have been reading about PID in depth from textbooks and on the web, > but am starting to feel more and more like tuning it is an art and not a > science. That's right. The equations will only take you so far, because most real world systems are not that well known or predictable. > My first problem is that I want to > have an operating depth of X meters and I know my current depth. To > move the AUV I have to set the voltage of the vertical thruster. How do > I relate the input to the plant (the desired depth) to the output of the > plant (the motor voltage)? All examples I have found assume there is a > magical sensor that changes the output of the plant to the same units as > the input. The PID algorithm is driven the by the error signal, which is (desired depth - actual depth), and which is a function of time. Process this error value according to the P, I and D formulas and add all the contributions. That's the output voltage. (That's at a high level. Real world useful PID algorithms have all kinds of subtle features built in.) Units don't matter because they represent only a proportionality constant to the actual calculations. The PID control values can be adjusted to any desired proportionality constant, of which unit conversions is only one anyway. ***************************************************************** Embed Inc, embedded system specialists in Littleton Massachusetts (978) 742-9014, http://www.embedinc.com -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.