<< 点击显示目录 >> 主页 exOS使用助手 > exOS Automation Help > Development > Programming > Data communication > Time synchronization > Simulation |
在使用TCP/IP套接字的模拟环境中,根据Linux和AR系统的总体负载情况,系统通常会实现几毫秒的时间同步,而在这里,同步的重要性并不高。
众所周知,PredictionError有时会跳动几毫秒,不过这些波动通常对时间同步的影响很小。
可以通过ExSyncInfo功能块中的TimeSync结构监控NETTIME同步。
▪在该结构中,可以通过TargetResponsive和PrecisionReached标志访问当前的同步状态。
▪PrecisionReached表示Linux时间估计的PredictionError已在预定义的30秒GuardTime内达到配置的精度,而精度默认设置为1秒,需要在系统平均PredicionError之后进行调整。
In a simulation environment using TCP/IP sockets, the system will typically achieve a few millisecond time synchronization depending on the overall load of the Linux and AR system, whereas here the synchronization is not assumed to be of high importance.
The PredictionError is known to jump some milliseconds at occasions, although those fluctuations usually have very little effect on the time synchronization.
The NETTIME synchronization can be monitored via the TimeSync structure in the ExSyncInfo function block.
•In this structure, the current synchronization state can be accessed via the TargetResponsive and PrecisionReached flags.
•PrecisionReached means that the PredictionError of the Linux time estimate has reached the configured Precision within a predefined GuardTime of 30 seconds, whereas the Precision is is set to 1 second as default, and needs to be adjusted after the mean PredicionError of the system.