Re: [Linuxptp-devel] how PI controller work in linuxptp
thank you, but i still don't know how it work. i want to understand it totally, please help me 2015-02-09 16:26 GMT+08:00 Miroslav Lichvar mlich...@redhat.com: On Mon, Feb 09, 2015 at 03:51:32PM +0800, Arnold kang wrote: hi all, i'm reading the linuxptp code, and read pi.c many times, but i'm not sure PI work in code . please help me , thanks! ps, freq_est_interval = 0.016 / s-ki, why 0.016? It's an experimentally determined value. With smaller ki the servo is slower in ajdusting frequency, so the estimation interval is made longer to get a more accurate starting value and decrease the overall time needed to lock. -- Miroslav Lichvar -- Dive into the World of Parallel Programming. The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
Re: [Linuxptp-devel] how PI controller work in linuxptp
thank you! 2015-02-09 17:17 GMT+08:00 Miroslav Lichvar mlich...@redhat.com: On Mon, Feb 09, 2015 at 05:04:05PM +0800, Arnold kang wrote: thank you, but i still don't know how it work. i want to understand it totally, please help me How a PI controller works? I'm not sure that can be explained in a few paragraphs in an email. I'd suggest to start with the wikipedia entry on PID controllers. -- Miroslav Lichvar -- Dive into the World of Parallel Programming. The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
Re: [Linuxptp-devel] [PATCH] timemaster: set mode in ntp config to create private SHM segments.
On Mon, Feb 09, 2015 at 02:53:06PM +0100, Miroslav Lichvar wrote: In ntp-4.2.8p1 the segment access was made configurable with the refclock mode option. Set the mode to 1 to create all SHM segments with owner-only access. Applied. Thanks, Richard -- Dive into the World of Parallel Programming. The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
[Linuxptp-devel] [PATCH] timemaster: set mode in ntp config to create private SHM segments.
In ntp-4.2.8p1 the segment access was made configurable with the refclock mode option. Set the mode to 1 to create all SHM segments with owner-only access. --- timemaster.8 | 10 ++ timemaster.c | 3 ++- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/timemaster.8 b/timemaster.8 index 9a3ddb4..062322b 100644 --- a/timemaster.8 +++ b/timemaster.8 @@ -250,10 +250,12 @@ for PTP sources (\fBntp_poll\fR) to specify a subsecond interval. The \fBntpd\fR limitations are: .RS -Only the first two shared-memory segments created by the SHM refclock driver -in \fBntpd\fR have owner-only access. Other segments are created with world -access, possibly allowing any user on the system writing to the segments and -disrupting the synchronization. +In versions before 4.2.8p1, only the first two shared-memory segments created by +the \fBntpd\fR SHM refclock driver have owner-only access. Other segments +are created with world access, which allows any user on the system to write to +the segments and disrupt or take control over the synchronization of the clock. +In 4.2.8p1 the access was made configurable with the mode option, which is set +by \fBtimemaster\fR for owner-ownly access. The shortest polling interval for all sources is 3 (8 seconds). diff --git a/timemaster.c b/timemaster.c index 83a5b83..eec0d0d 100644 --- a/timemaster.c +++ b/timemaster.c @@ -623,7 +623,8 @@ static void add_shm_source(int shm_segment, int poll, int dpoll, double delay, break; case NTPD: string_appendf(ntp_config, - server 127.127.28.%d minpoll %d maxpoll %d\n + server 127.127.28.%d minpoll %d maxpoll %d + mode 1\n fudge 127.127.28.%d refid %s\n, shm_segment, poll, poll, shm_segment, refid); break; -- 2.1.0 -- Dive into the World of Parallel Programming. The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel