Re: [Linuxptp-devel] Optimal P, I constants
PTP IEEE 1588 stack for Linux
Brought to you by:
rcochran
From: Miroslav L. <mli...@re...> - 2013-05-03 16:17:51
|
On Wed, May 01, 2013 at 07:52:03AM +0200, Richard Cochran wrote: > 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. I tried to find which PI constant give the best RMS time error in the simulation results when the jitter/wander ratio and update interval change and run lines through the points. I guess it could be done accurately by mathematical analysis, but that would be much more difficult, at least for me. Similarly, it should be possible to get constants which minimize the RMS frequency error or a combination of the two. Here is what I found, u is the update interval in seconds, a is the Allan intercept in seconds and jw is the jitter/wander ratio. The clamping constants were chosen so P+I ≈ 1/u and P*u ≈ (I*u)^0.5. jw ≈ (a / 2)^1.5 P_min_rms_time ≈ min(10^0.2 / (u^0.3 * jw^0.5), 0.62 / u) I_min_rms_time ≈ min(10^0.1 / (u^-0.4 * jw), 0.38 / u) Here are calculated constants for some selected Allan intercepts and update intervals. u\a | 1 | 10 | 100 | 1000 | 2^+4 | 3.9e-02 2.4e-02 | 3.9e-02 2.4e-02 | 3.7e-02 1.1e-02 | 6.5e-03 3.4e-04 | 2^+3 | 7.7e-02 4.8e-02 | 7.7e-02 4.8e-02 | 4.5e-02 8.2e-03 | 8.0e-03 2.6e-04 | 2^+2 | 1.5e-01 9.5e-02 | 1.5e-01 9.5e-02 | 5.6e-02 6.2e-03 | 9.9e-03 2.0e-04 | 2^+1 | 3.1e-01 1.9e-01 | 3.1e-01 1.5e-01 | 6.8e-02 4.7e-03 | 1.2e-02 1.5e-04 | 2^-0 | 6.2e-01 3.8e-01 | 4.7e-01 1.1e-01 | 8.4e-02 3.6e-03 | 1.5e-02 1.1e-04 | 2^-1 | 1.2e+00 7.6e-01 | 5.8e-01 8.5e-02 | 1.0e-01 2.7e-03 | 1.8e-02 8.5e-05 | 2^-2 | 2.5e+00 1.5e+00 | 7.2e-01 6.5e-02 | 1.3e-01 2.0e-03 | 2.3e-02 6.5e-05 | 2^-3 | 5.0e+00 1.5e+00 | 8.8e-01 4.9e-02 | 1.6e-01 1.5e-03 | 2.8e-02 4.9e-05 | 2^-4 | 6.1e+00 1.2e+00 | 1.1e+00 3.7e-02 | 1.9e-01 1.2e-03 | 3.4e-02 3.7e-05 | What do you think? -- Miroslav Lichvar |