ttichy said:
You find yourself with some choices, two of which are:
a)detune the servo controller and probably get acceptable performance
b)crave a derivative gain and think of all its possibilities
These are poor choices.
The key to auto tuning is system identification. That is procedure that calculates the system gain, frequencies, offsets and dead times. Once these are known there are formulas like below that can calculate the controller gains.
Most auto tuning systems only support one model. If the system doesn't match the model the auto tuning will not work. Also, models are linear. Auto tuning an non-linear system will not work. It is possible to auto tune for one particular position or operating point but those gains will not work well over the range of travel. On swing arm type of systems we recommend auto tuning at multiple places along the travel and then use a cam table or what we call curves that will change the gains smoothy and continuously on-the-fly throughout the stroke.
I am not a fan of the pulse method of exciting a system. In fact I can't use the pulse method when tuning a 100 ton system because the ground would shake, welds would break and I would be thrown out. The pulse method has its limitations in that it usually only records the peak velocity obtained, the time of peak velocity and the time it takes to reach 0 speed. From this one can calculate the system gain and time constant or the inverse of the time constant, the corner frequency. From there it is simple. For a simple first order position model the gains are calculated as follows
Ki=λ³/(K*α)
Kp=2*λ²/(K*α)
Kd=(3*λ-α)/(K*α)
Where λ is the location of the 3 closed loop poles at -λ. The larger or more negative λ is the faster or hotter the system is. This is operator selected. If one wants to use only a PI control then λ=α/3 so Kd=0 but this limits the response.
K is the system gain with units of velocity/control output
α is the corner frequency in rad/sec. This is the inverse of the time constant or 1/τ
Rockwell allow one to get a slightly faster response with lower gains by allowing an slightly under damped response. This is done by allowing the closed loop poles to be imaginary. If you look in the parameters there is a place where you set the closed loop damping factor. A closed loop damping factor of 0.8 doesn't result in to much over shoot to a step change in the set point and step changes should never occur anyway.
The real problem is depending on measuring just two points. The peak velocity and the time the velocity reaches 0. Any small error can make a big difference to the results.
We use a different method to calculate the system gain and corner frequency. We excite the plant with a wave form that provides more information. We don't need to use square waves but can ramp the excitation up and down to lessen the shock. We use a fancy non-linear regression that adjusts the coefficients for several models to the recorded data. This requires good graphing/logging tools. We may be using 1000s of points to do this. The result is that we get a statistically better fit than just using two points. We also use more than on model. If you try to auto tune a compliant system to a simple model it will not work. It is that simple. We have a model for a compliant system and a simple first order model like the one most motor people use. If the system is compliant the compliant model will fit the data better. We can tell because data fitting model returns a sum of squared error or norm. The smaller the sum of square error or norm the better the fit. I have an example of how we did this about 5 years ago. We have improved since then.
http://deltamotion.com/peter/Mathcad/Mathcad - Sysid T1P2 ODE.pdf
You can see we use our logged graph data. The thing to notice is that our model predicts the position data almost exactly. The actual velocity data shown on page 4/5 is using pretty much the same techniques that people use here to calculate velocity. However one can see that the estimated or modeled velocity is accurate and smooth. This is key to using the derivative gain on a motion controller. As an added bonus notice that there is an estimated acceleration too!!! Accelerations can not be calculated by simply differentiating positions twice as the quantizing error is significant.
Generating accurate models is the first step and the difficult part of auto tuning. Once there is an accurate model the gains can be CALCULATED!
We have notice that some companies say they have 'auto tuning' just to say they have it for marketing purposes. We have auto tuning that really works because our engineers and I go out into the field and we want to look like heros and not embarrassed chumps.
OkiePC you can see that in the graph the actuator moved 2 inches that is not far but the actuator must really be moved to get an accurate model. This requires a setup page like you mentioned. We have one too. Nothing is idiot proof. We have a sanity check your parameters disclaimer.