The invention discloses a method and
system for improving
timestamp precision, and relates to the field of
time synchronization, and the method comprises the steps: sending a second pulse
signal or a frame positioning identification
signal outputted by an OTN business
processing chip to an LVDS
SERDES interface of an FPGA; obtaining the rising edge position of the frame positioning identification
signal through an LVDS
SERDES interface, generating a real-time time sampling indication signal at the same time, and taking the current real-time time as an initial
timestamp T; generating a sampling error compensation value [
delta]t1 based on a non-zero sampling value corresponding to the real-time time sampling indication signal; and obtaining the current
oversampling state based on the statistical result, wherein different
oversampling states correspond to different
oversampling error compensation values [
delta]t2, and the final
timestamp is equal to the sum of the initial timestamp T, the sampling error compensation value [
delta]t1 and the oversampling error compensation value [delta]t2. The method is easy to implement, and the requirement for the
time sequence of the FPGA device is low.