I don't currently have access to the actual motor setup that this is=20 for, so using a modified throttle-body for now to learn the concepts, as=20 it's relatively the same thing -- motor/pot feedback and spring pulling=20 it to one side, and I have a control pot to set the position. Not using any feed-forward yet, as my only thought for that so far is=20 really just proportional control). But speed (getting to the setpoint)=20 is not critical -- getting there accurately is more important. Not sure=20 yet if feed-forward would help that. *Basic* tuning (ie: no oscillation, chatter and getting pretty close to=20 setpoint) with the Ziegler-Nichols method was relatively easy, but it=20 seems a bit "sticky" -- ie: very small changes to my control pot don't=20 immediately take effect, and continuing to change the pot a bit more=20 suddenly makes it "jump" to the correct position. Also, just sitting=20 with a fixed setpoint, it will move a bit every once in a while (like=20 5-10 seconds). So far I'm using P & I. I tried tweaking these=20 constants a bit, but haven't noticed any difference. Also tried adding=20 some D to see if it helps, but nope. At this point, I need to go learn=20 more about tuning, and especially what the symptoms mean in terms of the=20 constants. Going to look into IMC also now. I do notice that the center of travel is a bit different than near the=20 ends, so I might try adding gain scheduling. Cheers, -Neil. On 12/31/2014 8:57 AM, Sean Breheny wrote: > Hi Neil, > > What you describe is a textbook case of a problem which integral control > solves. PID or still possibly just PI should work well for your > application, without special gain switching or anything. I would still > recommend a very simple feedforward control input to reduce the burden on > the integrator. > > Sean > > > On Wed, Dec 31, 2014 at 1:36 AM, Neil wrote: > >> Meaning that if the motor is say in the center of its travel and I set >> the speed to zero, it won't stay there. I need to keep some power on it >> to counter the spring pulling it off to one side. This raised the >> question of whether once I tune P,I (and possibly D), would it work for >> both directions, or would the difference in control input to the motor >> mean tuning differently for each direction. I don't have access to the >> system again for a bit, but I'll setup a similar test system so I can >> experiment. >> >> Cheers, >> -Neil. >> >> >> >> >> >> On 12/31/2014 12:20 AM, Sean Breheny wrote: >>> Neil, >>> >>> I don't understand what you mean by "with the spring force acting only >> one >>> way, the PID >>> parameters would be different from one side to the next. Essentially t= o >>> stay in a fixed position, I'd need a continuous non-zero speed on the >>> motor." >>> >>> >>> Can you please explain more about the setup? >>> >>> It is a standard technique, which works very well, to begin with a basi= c >>> model of your system and predict the control effort needed to achieve t= he >>> trajectory you desire, and then apply this pre-programmed control profi= le >>> and perform PID only on the deviation of the actual device from the >> planned >>> trajectory. This is called feedforward control can allow you to use >> higher >>> PID gains for more precise control without the large amount of overshoo= t >>> you would get otherwise. >>> >>> Based on your description, I suspect that this can be done with >> feedforward >>> and a simple PI controller (no D term needed). If so, tuning it is almo= st >>> trivial (iterative process where you first determine the highest integr= al >>> gain you can tolerate with P=3D0, then back off on that and increase P = to >>> gain response speed). >>> >>> Sean >>> >> --=20 http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .