Re: [Linuxptp-devel] Optimal P, I constants
PTP IEEE 1588 stack for Linux
Brought to you by:
rcochran
From: Richard C. <ric...@gm...> - 2013-05-01 05:52:21
|
On Tue, Apr 30, 2013 at 09:29:28PM +0200, Miroslav Lichvar wrote: > On Tue, Apr 30, 2013 at 07:11:30PM +0200, Richard Cochran wrote: > > > > > http://linuxptp.sourceforge.net/pi_const/plot5.png > > I'm not sure what I should see in the plot. The 2^0 and scaled 2^-3 > curves are identical, just stretched differently. Why should be 100us > offset corrected at 100 ppm good and at 800 ppm bad? Are you > considering a situation with a typical wander? When designing a controller, one of the factors is amount of steering. Minimizing the magnitude of the steering is a good thing. In the car example, it saves gas and wear on the brakes. For a clock, time based applications prefer small frequency errors to larger ones. In the plot, you can see that there are better choices of constants for different sample rates than just scaling. The hand tuned constants converge in the same time, but without inducing so much frequency error. Finding these constants requires some analysis. > I believe there is a formula to calculate P for given intercept and > rate. Then the I constant can be calculated from P and the rate. The > constants will need to be clamped to not become unstable (in that case > a shorter update interval would give better results). I don't know the > formulas, but I don't think it will be very difficult to figure them > out from the simulations. I just didn't want to spend much time on it > if you are opposed to the idea. Please go ahead and see what you come up with. I am interested to see how you do it and what the results are. The servo parameters involve trade offs, and so there is no one right answer. Even if the software ends up with a tabular approach (one PI pair per sync rate), still we can always include your results in table form. Thanks, Richard |