[etherlab-users] DC question: "Failed to get reference clock time: Input/Output error"?

Gavin Lambert gavinl at compacsort.com
Sun Jan 15 22:45:16 CET 2017


On 14 January 2017 06:02, quoth Jiarui Lian:
> I tried to synchronize master clock to a reference-slave-EK1100 (due to
> Master clock jitter):
> * Based on the example of "examples/rtai_rtdm_dc".
> * I modified the example, since I am using RT-Preempt instead of RTAI.
> * But I got error: "Failed to get reference clock time: Input/Output
error"?
> --- (And I found that the error message comes from function
> "ecrt_master_reference_clock_time()")
> 
> Graeme and Tommaso have some discussions on this issue before, but not
> sure if it is solved:
> http://lists.etherlab.org/pipermail/etherlab-users/2016/003026.html

This error is normal when using the user-mode library -- it takes a few
cycles for the master to locate and init the reference clock and the API
will return EIO or ENXIO during this time.  It should eventually stop doing
that (if a ref clock is indeed found), but in the meantime the user mode
library prints error messages to stderr.

The commit
https://sourceforge.net/p/etherlabmaster/code/ci/3affe9cd0b66fe55ef8e8060778
ef9461a8204a0/ (default branch) removes this logging to avoid the spam.
Alternately you could implement a "spin up time" where you don't try to sync
the master clock for the first few cycles (or until the slaves are all
configured and the network is stable), although this might complicate your
master application.





More information about the Etherlab-users mailing list