Timestamp information transmission method, device, equipment and storage medium

文档序号:346366 发布日期:2021-12-03 浏览:7次 中文

阅读说明:本技术 一种时间戳信息传输方法、装置、设备和存储介质 (Timestamp information transmission method, device, equipment and storage medium ) 是由 高睿 于 2020-05-29 设计创作,主要内容包括:本申请公开了一种时间戳信息传输方法、装置、设备和存储介质,其中,该方法包括:将OTUw-RS帧头插入并行数据流,并产生帧头脉冲;根据所述帧头脉冲和采样时钟确定发送时间戳信息;将所述发送时间戳信息通过时戳数据帧发送到接收端。本申请实施例,通过采样时钟和帧头脉冲准确获取时间戳信息,并将时间戳信息发送,实现了时间戳信息在OTUw-RS协议设备中的传输,可提高时间戳信息的准确性,降低通信网络中不同设备间的时间误差。(The application discloses a timestamp information transmission method, a timestamp information transmission device, timestamp information transmission equipment and a storage medium, wherein the method comprises the following steps: inserting an OTUw-RS frame header into the parallel data stream and generating a frame header pulse; determining to send timestamp information according to the frame header pulse and the sampling clock; and sending the sending timestamp information to a receiving end through a timestamp data frame. According to the embodiment of the application, the timestamp information is accurately acquired through the sampling clock and the frame header pulse, and is sent, so that the transmission of the timestamp information in OTUw-RS protocol equipment is realized, the accuracy of the timestamp information can be improved, and the time error among different equipment in a communication network is reduced.)

1. A timestamp information transmission method is applied to a sending end, and comprises the following steps:

inserting an OTUw-RS frame header into the parallel data stream and generating a frame header pulse;

determining to send timestamp information according to the frame header pulse and the sampling clock;

and sending the sending timestamp information to a receiving end through a timestamp data frame.

2. The method of claim 1, wherein determining the transmission timestamp information according to the frame header pulse and the sampling clock comprises:

respectively collecting the frame header pulse according to the rising edge and the falling edge of the sampling clock, and locking the time of a timer of the sampling clock;

determining a minimum value of the timer times corresponding to the same clock period as transmission time stamp information.

3. The method of claim 2, wherein the frequency of the sampling clock is 1GHz and the step of the sampling clock is 1 nanosecond.

4. The method of claim 2, wherein the transmitting the transmission time stamp information to a receiving end through a time stamp data frame comprises:

packaging the sending timestamp information into a high-precision time synchronization protocol packet;

inserting the high-precision time synchronization protocol packet into an overhead reserved field of the timestamp data frame;

and sending the time stamp data frame to a receiving end before the next frame header pulse.

5. The method according to any of claims 1-4, wherein the baud rate of the frame header pulses is configured to be at least 4 times the corresponding clock period of the sampling clock.

6. A timestamp information transmission method is applied to a receiving end, and the method comprises the following steps:

searching an OTUw-RS frame header in the parallel data stream, and generating a frame header pulse;

determining to receive timestamp information according to the frame header pulse and the sampling clock;

and acquiring the sending time stamp information sent by the sending end through the time stamp data frame.

7. The method according to claim 6, wherein the determining the receiving time stamp information according to the frame header pulse and the sampling clock comprises:

respectively sampling the frame header pulse according to the rising edge and the falling edge of the sampling clock, and locking the time of a timer corresponding to the sampling clock;

determining a minimum value of the timer times corresponding to the same clock cycle as reception timestamp information.

8. The method of claim 7, wherein the frequency of the sampling clock is 1GHz and the step of the sampling clock is 1 nanosecond.

9. The method of claim 8, wherein the obtaining of the transmission time stamp information transmitted by the transmitting end through the time stamp data frame comprises:

extracting a high-precision time synchronization protocol packet in an overhead reserved field of the timestamp data frame;

extracting sending timestamp information in the high-precision time synchronization protocol packet;

and determining the corresponding relation between the sending timestamp information and the OTUw-RS frame header.

10. The method according to any of claims 6-9, wherein the baud rate of the frame header pulses configures at least 4 times the corresponding clock period of the sampling clock.

11. A timestamp information transmission apparatus, applied to a transmitting end, the apparatus comprising:

the first pulse module is used for inserting the OTUw-RS frame head into the parallel data stream and generating a frame head pulse;

the time determining module is used for determining and sending the timestamp information according to the frame header pulse and the sampling clock;

and the information sending module is used for sending the sending timestamp information to a receiving end through a timestamp data frame.

12. A timestamp information transmission apparatus, applied to a receiving end, the apparatus comprising:

the second pulse module is used for searching an OTUw-RS frame header in the parallel data stream and generating a frame header pulse;

the receiving time module is used for determining receiving time stamp information according to the frame header pulse and the sampling clock;

and the sending time module is used for obtaining sending time stamp information sent by the sending end through the time stamp data frame.

13. An apparatus, characterized in that the apparatus comprises:

one or more processors;

a memory for storing one or more programs,

when executed by the one or more processors, cause the one or more processors to implement the timestamp information transmission method of any of claims 1-10.

14. A computer-readable storage medium on which a computer program is stored, the program, when being executed by a processor, implementing the time stamp information transmission method according to any one of claims 1 to 10.

Technical Field

The present invention relates to the field of communications network technologies, and in particular, to a timestamp information transmission method, apparatus, device, and storage medium.

Background

In a communication network, time synchronization between devices has a high requirement, for example, when a base station is switched in a wireless communication process, communication is disconnected when a time error between the base stations of the base station is not within a certain range. OTN optical transmission equipment based on an OTUw-RS protocol in a communication network has wide application scenes in a forward network, and can provide two bit rates of 25G or 50G by respectively using KR4/KP4 coding. The OTN optical transmission equipment based on the OTUw-RS protocol better meets the requirements of low delay, low cost, high reliability and high bandwidth in a fronthaul network.

However, in the OTUw-RS protocol, how to acquire timestamp information and how to transmit the timestamp information by the device are not specified, and if a GPS signal receiving device is additionally installed in the device, a time synchronization signal sent by a satellite is received by the GPS signal receiving device, so that time synchronization between the devices is realized, which increases construction cost and threatens the security of the OTN optical transmission device based on the OTUw-RS protocol.

Disclosure of Invention

The embodiment of the application provides a timestamp information transmission method, a timestamp information transmission device, timestamp information transmission equipment and a storage medium, so that the timestamp information of OTN optical transmission equipment based on an OTUw-RS protocol is determined and sent, and the accuracy of time synchronization of the OTN equipment is improved.

The embodiment of the application provides a timestamp information transmission method, which is applied to a sending end and comprises the following steps:

inserting an OTUw-RS frame header into the parallel data stream and generating a frame header pulse; determining to send timestamp information according to the frame header pulse and the sampling clock; and sending the sending timestamp information to a receiving end through a timestamp data frame.

The embodiment of the application provides a timestamp information transmission method, which is applied to a sending end and comprises the following steps:

searching an OTUw-RS frame header in the parallel data stream, and generating a frame header pulse; determining to receive timestamp information according to the frame header pulse and the sampling clock; and acquiring the sending time stamp information sent by the sending end through the time stamp data frame.

The embodiment of the application provides a timestamp information transmission device, is applied to the sending end, and the device includes:

the first pulse module is used for inserting the OTUw-RS frame head into the parallel data stream and generating a frame head pulse;

the time determining module is used for determining and sending the timestamp information according to the frame header pulse and the sampling clock;

and the information sending module is used for sending the sending timestamp information to a receiving end through a timestamp data frame.

The embodiment of the application provides a timestamp information transmission device, is applied to the receiving end, and the device includes:

the second pulse module is used for searching an OTUw-RS frame header in the parallel data stream and generating a frame header pulse;

the receiving time module is used for determining receiving time stamp information according to the frame header pulse and the sampling clock;

and the sending time module is used for obtaining sending time stamp information sent by the sending end through the time stamp data frame.

An embodiment of the present application further provides an apparatus, including:

one or more processors;

a memory for storing one or more programs,

when the one or more programs are executed by the one or more processors, the one or more processors implement the timestamp information transmission method according to any of the embodiments of the present application.

Embodiments of the present application also provide a computer-readable storage medium, on which a computer program is stored, and the computer program, when executed by a processor, implements the timestamp information transmission method according to any of the embodiments of the present application.

According to the embodiment of the application, the frame header pulse is generated when the OTUw-RS frame header is inserted into the parallel data stream, the timestamp information is determined to be sent based on the sampling clock and the frame header pulse, and the sent timestamp information is sent to the receiving end through the timestamp data frame, so that the time information transmission of the OTUw-RS equipment is realized, the accuracy of the timestamp information can be improved, and the time error among different equipment in a communication network is reduced.

Drawings

Fig. 1 is a flowchart of a timestamp information transmission method provided in an embodiment of the present application;

fig. 2 is a flowchart of another timestamp information transmission method provided by an embodiment of the present application;

fig. 3 is a flowchart of a timestamp information transmission method according to an embodiment of the present application;

fig. 4 is a flowchart of another timestamp information transmission method provided by an embodiment of the present application;

fig. 5 is an exemplary diagram of a timestamp information transmission method provided in an embodiment of the present application;

fig. 6 is a schematic structural diagram of a timestamp information transmission apparatus according to an embodiment of the present application;

fig. 7 is a schematic structural diagram of another timestamp information transmission apparatus according to an embodiment of the present application;

FIG. 8 is a schematic structural diagram of an apparatus provided in an embodiment of the present application;

fig. 9 is a diagram illustrating an implementation example of an optical transmission device according to an embodiment of the present application;

fig. 10 is an exemplary diagram of time synchronization provided in an embodiment of the present application.

Detailed Description

To make the objects, technical solutions and advantages of the present application more apparent, embodiments of the present application will be described in detail below with reference to the accompanying drawings. It should be noted that the embodiments and features of the embodiments in the present application may be arbitrarily combined with each other without conflict.

The OTN optical transmission equipment based on the OTUw-RS protocol has a wide application scene in a forward network due to the characteristics of low delay, low cost, high reliability and high bandwidth, but because the OTUw-RS protocol does not set the determination and sending mode of the timestamp information, the OTN optical transmission network applying the OTUw-RS protocol cannot carry out time synchronization, and the problem of large time error among the equipment is caused.

Fig. 1 is a flowchart of a timestamp information transmission method provided in an embodiment of the present application, where the embodiment of the present application is applicable to a case where an OTN optical transmission network applying an OTUw-RS protocol transmits timestamp information in a fronthaul network, and the method may be executed by a timestamp information transmission device in the embodiment of the present application, where the device may be implemented in a software and/or hardware manner, and the device is generally integrated at a transmitting end of the OTN optical transmission network, referring to fig. 1, where the timestamp information transmission method provided in the embodiment of the present application specifically includes the following steps:

step 110, inserting the OTUw-RS frame header into the parallel data stream, and generating a frame header pulse.

The OTUw-RS frame header is a message frame header meeting the requirements of the OTUw-RS protocol, and may include AM and CWM frame headers, etc., the parallel data stream may be a carrier for transmitting information in the OTN optical transmission network, and the parallel data stream may be an optical signal adjusted by different wavelengths. The frame header pulse may be a pulse signal generated after the OTUw-RS frame header is inserted into the parallel data stream, and may indicate that the OTUw-RS frame header is transmitted through the parallel data.

Specifically, a message frame header conforming to the format of the OTUw-RS protocol is constructed, the constructed OTUw-RS frame header is inserted into the parallel data stream and sent to a receiving end, and frame header pulses corresponding to the OTUw-RS frame header are monitored and can be generated at the sending time of the OTUw-RS frame header.

And step 120, determining to send the timestamp information according to the frame header pulse and the sampling clock.

The sampling clock is a timing clock with preset frequency in the OTN optical transmission network equipment, the sampling clock can collect frame header pulse signals according to clock time edges in a clock period, and the collected frame header pulse signals can correspond to different clock times.

In this embodiment of the present invention, the sending timestamp information may represent sending time of the OTUw-RS frame header, where the sending timestamp information specifically refers to a total number of seconds 00 minutes 00 seconds from 1 month 1 day 00 hour by 1970 of greenwich mean time, a pulse signal of a frame header pulse is collected according to a clock edge of a sampling clock, and time when the signal is collected is locked, and the sending timestamp information may be determined according to the collected time, for example, an average value of all locked times is determined as the sending timestamp information or a minimum value of time is selected as the sending timestamp information, and each collected time may be used as the sending timestamp information.

And step 130, sending the sending time stamp information to a receiving end through a time stamp data frame.

The table below shows a structure data structure of the timestamp data frame, and the timestamp data frame may be composed of fields such as a start bit, a frame header synchronization byte 1, a frame header synchronization byte 2, a timestamp byte, a check byte, and a stop bit.

Time stamp data frame example table

Start bit Frame header synchronization byte 1 Frame header synchronization byte 2 Time stamp byte Check byte Stop position
8 bits 8 bits 8 bits 80 bits of 8 bits 1bit

According to the embodiment of the application, the sending time stamp information is packaged into the time stamp bytes of the time stamp data frames, other component fields of the time stamp data frames are generated, the packaged time stamp data frames can be sent to the receiving end of the OTN optical transmission network through parallel data, and it can be understood that the number of the time stamp data frames sent by the sending end can be one or more according to the number of the determined sending time stamp information.

This application embodiment is through inserting parallel data stream with OTUw-RS frame head to produce the frame head pulse, confirm through sampling clock and frame head pulse and send the timestamp, will send timestamp information transmission receiving terminal through the timestamp data frame, realized the timestamp information transmission in the OTN optical transmission network, improved the accuracy of timestamp information, reducible time error between the different equipment.

Fig. 2 is a flowchart of another timestamp information transmission method according to an embodiment of the present application, which is embodied based on the foregoing application embodiment, and the embodiment of the present application determines sending timestamp information of frame header pulses at a rising edge and a falling edge of a collection clock respectively, and determines a sending format of the sending timestamp information according to a high-precision time synchronization protocol packet, referring to fig. 2, where the timestamp information transmission method according to the embodiment of the present application specifically includes the following steps:

step 210, inserting the OTUw-RS frame header into the parallel data stream, and generating a frame header pulse.

And step 220, respectively collecting frame header pulses according to the rising edge and the falling edge of the sampling clock, and locking the time of a timer of the sampling clock.

The sampling clock may include a plurality of clock cycles, a position where a level signal of the sampling clock rises in each clock cycle may be a rising edge, and a position where the level signal falls may be a falling edge.

In the embodiment of the present application, frame header pulses are acquired twice in each clock cycle of the sampling clock, corresponding frame header pulses may be acquired at a rising edge and a falling edge of the sampling clock, respectively, and timer times corresponding to the rising edge and the falling edge may be determined as timer times at which the frame header pulses are acquired. Furthermore, as the sampling clock has a plurality of clock cycles, a plurality of timer times are locked by the rising edge and the falling edge of the sampling clock at the time when the pulse signal exists in the frame header pulse, the more clock cycles of the sampling clock are, the more the acquired timer time is, and correspondingly, the higher the accuracy of sending the timestamp information can be.

Further, on the basis of the embodiment of the above application, the frequency of the sampling clock is 1GHz, and the step of the sampling clock is 1 nanosecond.

In an exemplary embodiment, to improve the accuracy of time, the frequency of the sampling clock is set to 1GHz, and the corresponding step is 1 ns, so that there may be a rising edge and a falling edge of the sampling clock within 1 ns, and the length of one clock period of the sampling clock may be 1 ns.

Step 230, determining the minimum value of the timer times corresponding to the same clock cycle as the sending timestamp information.

In this embodiment of the present application, the acquisition clock includes a plurality of clock cycles, and a corresponding timer time exists on a rising edge and a falling edge of each clock cycle, and a smaller timer time may be selected as the transmission timestamp information from two timer times belonging to the same clock cycle.

And step 240, packaging the sending timestamp information into a high-precision time synchronization protocol packet.

The Precision Time Protocol (PTP) packet is a data packet of high Precision Time, and the Time Precision can reach sub-microsecond Precision.

Specifically, the sending timestamp information is encapsulated according to the format of the high-precision time synchronization protocol packet, so that the sending of the high-precision time information is realized.

And step 250, inserting the high-precision time synchronization protocol packet into an overhead reserved field of the timestamp data frame.

In the embodiment of the application, the overhead reserved field may be a reserved field specified by an OTUw-RS protocol, and the encapsulated high-precision time synchronization protocol packet may be inserted into a corresponding position.

And step 260, sending the timestamp data frame to the receiving end before the next frame header pulse.

Specifically, the timestamp data frame transmitted in the parallel data stream corresponds to the OTUw-RS frame header, and after one OTUw-RS frame header is sent, the timestamp data frame corresponding to the frame header needs to be sent to the receiving end before the next OTUw-RS frame header is sent.

This application embodiment, through inserting the parallel data flow with OTUw-RS frame head, and produce the frame head pulse, the rising edge and the falling edge through the sampling clock gather the frame head pulse respectively and lock the corresponding timer time, minimum in the timer time that will correspond the same clock cycle is confirmed to sending timestamp information, it packs to high accuracy time synchronization protocol package to send timestamp information, insert the overhead of timestamp data frame with this high accuracy time synchronization protocol package and keep the field, and send timestamp data frame to the receiving terminal before next frame head pulse, timestamp information transmission in the OTN optical transmission network has been realized, the accuracy of timestamp information has been improved, time error between the reducible different equipment.

Fig. 3 is a flowchart of a timestamp information transmission method provided in an embodiment of the present application, where the embodiment of the present application is applicable to a case where an OTN optical transmission network applying an OTUw-RS protocol transmits timestamp information in a fronthaul network, and the method may be executed by a timestamp information transmission device in the embodiment of the present application, where the device may be implemented in a software and/or hardware manner, and the device is generally integrated at a receiving end of the OTN optical transmission network, referring to fig. 3, where the timestamp information transmission method provided in the embodiment of the present application specifically includes the following steps:

step 310, searching an OTUw-RS frame header in the parallel data stream, and generating a frame header pulse.

Specifically, the receiving end searches the OTUw-RS frame header in the parallel data stream, for example, searches the AM frame header in the parallel data stream on the parallel interface in the receiving direction, where the AM frame header may meet the requirement of the OTUw-RS protocol, and may output a frame header pulse after searching the OTUw-RS frame header.

And step 320, determining the receiving time stamp information according to the frame header pulse and the sampling clock.

The receiving time stamp information may be the time of receiving the OTUw-RS frame header, and the receiving time stamp information may specifically be the total number of seconds from 1970, 1 month, 1 day, 00 hour, 00 minutes and 00 seconds.

In this embodiment of the present application, the pulse signal of the frame header pulse is collected and the collected time information is determined according to the collection clock, and the time information may be used as the receiving time stamp information, for example, the frame header pulse is collected according to each clock edge of the collection clock, each clock edge may correspond to one time information, and an average value of all collected time information may be used as the receiving time stamp information, or each time information is used as the receiving time stamp information, respectively.

And step 330, acquiring the sending time stamp information sent by the sending end through the time stamp data frame.

In an exemplary embodiment, the receiving end may obtain a transmission timestamp in the received timestamp data frame, and may directly extract information of a timestamp field position as transmission timestamp information according to a frame structure of the timestamp time frame.

According to the embodiment of the application, the OTUw-RS frame head is searched in the parallel data stream, the frame head pulse is generated, the receiving timestamp information is determined according to the frame head pulse and the sampling clock, the sending timestamp information sent by the sending end through the timestamp data frame is extracted, the time information transmission of the OTUw-RS equipment is realized, the accuracy of the timestamp information is improved, and the time error among different equipment in a communication network is reduced.

Further, on the basis of the embodiment of the above application, the baud rate of the frame header pulse is configured to be at least 4 times of the corresponding clock period of the sampling clock.

Specifically, in order to ensure that the frame header pulse is correctly sampled at a low speed clock and improve the accuracy of obtaining the timestamp information, the baud rate of the frame header pulse is at least configured to be 4 times of the clock period of the sampling clock, wherein the baud rate may refer to the 1-bit holding duration of the frame header pulse. Further, the baud rate of the frame header pulses may be configured to 16 or 32 clock periods of the sampling clock.

Fig. 4 is a flowchart of another timestamp information transmission method according to an embodiment of the present application, which is embodied based on the foregoing application embodiment, and the embodiment of the present application determines the receiving timestamp information of the frame header pulse at the rising edge and the falling edge of the acquisition clock respectively, and determines the sending format of the receiving timestamp information according to the high-precision time synchronization protocol packet, referring to fig. 4, the timestamp information transmission method according to the embodiment of the present application specifically includes the following steps:

step 410, searching OTUw-RS frame headers in the parallel data stream, and generating frame header pulses.

And step 420, respectively sampling frame head pulses according to the rising edge and the falling edge of the sampling clock, and locking the time of a timer corresponding to the sampling clock.

Specifically, the receiving end collects frame header pulses twice in each clock cycle of the sampling clock, and can collect the frame header pulses once at a rising edge and collect the frame header pulses once at a falling edge, and the receiving end locks the time of a timer for collecting the frame header pulses at the rising edge and the falling edge respectively. The clock period of the sampling clock of the receiving end may be the same as the clock period of the sampling clock of the transmitting end.

Further, on the basis of the embodiment of the above application, the frequency of the sampling clock is 1GHz, and the step of the sampling clock is 1 nanosecond.

Step 430, determining the minimum value of the timer times corresponding to the same clock period as the receiving timestamp information.

And the receiving time stamp information is the time information of the OTUw-RS frame header received by the receiving end.

Specifically, the acquisition clock may include a plurality of clock cycles, each clock cycle may correspond to two timer times, and the two timer times are compared in the same clock cycle, where the minimum timer time is used as the receiving timestamp information.

Step 440, extracting the high-precision time synchronization protocol packet in the overhead reserved field of the timestamp data frame.

In the embodiment of the application, the receiving end sends the sending timestamp information through the timestamp data frame, and acquires the high-precision time synchronization protocol packet in the timestamp data frame according to the position of the pre-agreed overhead reserved field.

And 450, extracting the sending time stamp information in the high-precision time synchronization protocol packet.

Specifically, the transmission time stamp information may be extracted in a data format of a high-precision time synchronization protocol packet.

Step 460, determining the corresponding relationship between the sending timestamp information and the OTUw-RS frame header.

In the embodiment of the invention, the sent OTUw-RS frame header and the sending timestamp information have a corresponding relationship, and the sending timestamp information within the threshold time after the receiving end receives the OTUw-RS frame header can be used as the sending timestamp corresponding to the OTUw-RS frame header, wherein the preset time can be the clock period corresponding to one or more acquisition clocks.

The embodiment of the application searches OTUw-RS frame headers in parallel data flow, and generates frame header pulses, the frame header pulses are collected according to the rising edge and the falling edge of a sampling clock, corresponding timer time is locked, the minimum value in the timer time corresponding to the same clock period is determined as receiving timestamp information, a high-precision time synchronization protocol packet is extracted from an overhead reserved field of a timestamp data frame, sending timestamp information in the timestamp information is extracted, the corresponding relation between the sending timestamp information and the OTUw-RS frame headers is determined, time information transmission of OTUw-RS equipment is realized, the accuracy of the timestamp information is improved, and time errors among different devices in a communication network are reduced.

Further, on the basis of the embodiment of the above application, the baud rate of the frame header pulses is configured to be at least 4 times of the corresponding clock period of the sampling clock.

In an exemplary implementation, fig. 5 is an exemplary diagram of a timestamp information transmission method provided in an embodiment of the present application, where a frame header of an OTUw-RS protocol AM/CWM is used to collect a timestamp of a PTP packet, and an overhead reserved field is used to transmit the PTP packet, referring to fig. 5, timestamp information transmission may include two flows of transmission and reception, where the transmission flow includes: firstly, inserting an OTUw-RS frame header into a parallel data stream at a sending party, and generating a frame header pulse. And secondly, acquiring the time stamp of the OTUw-RS frame header in the sending direction based on the rising edge and the falling edge of the sampling clock by using the frame header pulse. And thirdly, packaging the timestamp into a PTP (precision time protocol) packet and inserting the PTP packet into an overhead reserved field. The receiving process comprises the following steps: and searching an OTUw-RS frame header in the parallel data stream in the receiving direction, and generating a frame header pulse. And secondly, acquiring the time stamp of the OTUw-RS frame header in the receiving direction based on the rising edge and the falling edge of the sampling clock by using the frame header pulse.

Fig. 6 is a schematic structural diagram of a timestamp information transmission apparatus according to an embodiment of the present application, which is capable of executing a timestamp information transmission method according to any embodiment of the present application, and includes functional modules corresponding to the execution method and beneficial effects. The apparatus can be implemented by software and/or hardware, and in a sending end of a general integrated optical transmission network, the apparatus specifically includes: a first pulse module 51, a time determination module 52 and an information transmission module 53.

A first pulse module 51, configured to insert an OTUw-RS frame header into the parallel data stream, and generate a frame header pulse.

And a time determining module 52, configured to determine to send timestamp information according to the frame header pulse and the sampling clock.

And an information sending module 53, configured to send the sending timestamp information to a receiving end through a timestamp data frame.

This application embodiment, insert parallel data flow with OTUw-RS frame head through first pulse module to produce the frame head pulse, the time is confirmed the module and is confirmed the transmission time stamp through sampling clock and frame head pulse, and information transmission module will send time stamp information transmission receiving terminal through the time stamp data frame, has realized the time stamp information transmission in the OTN optical transmission network, has improved the accuracy of time stamp information, reducible time error between the different equipment.

Further, on the basis of the embodiment of the above application, the time determination module 52 includes:

the time locking unit is used for respectively collecting the frame header pulse according to the rising edge and the falling edge of the sampling clock and locking the timer time of the sampling clock;

and the time stamp determining unit is used for determining the minimum value in the timer time corresponding to the same clock period as the sending time stamp information.

Further, on the basis of the embodiment of the above application, the frequency of the sampling clock in the time determination module 52 is 1GHz, and the step of the sampling clock is 1 nanosecond.

Further, on the basis of the above-mentioned application embodiment, the information sending module 53 includes:

a packet encapsulation unit, configured to encapsulate the sending timestamp information into a high-precision time synchronization protocol packet;

a packet inserting unit, configured to insert the high-precision time synchronization protocol packet into an overhead reserved field of the timestamp data frame;

and the frame sending unit is used for sending the timestamp data frame to a receiving end before the next frame header pulse.

Further, on the basis of the embodiment of the above application, the baud rate of the frame header pulses in the apparatus is configured to be at least 4 times of the corresponding clock period of the sampling clock.

Fig. 7 is a schematic structural diagram of another timestamp information transmission apparatus provided in an embodiment of the present application, which is capable of executing a timestamp information transmission method provided in any embodiment of the present application, and has corresponding functional modules and beneficial effects of the execution method. The apparatus can be implemented by software and/or hardware, and generally integrates in the receiving end of the optical transmission network, specifically including: a second pulse module 61, a receive time module 62 and a transmit time module 63.

And a second pulse module 61, configured to search for an OTUw-RS frame header in the parallel data stream, and generate a frame header pulse.

And a receiving time module 62 for determining the receiving time stamp information according to the frame header pulse and the sampling clock.

And a sending time module 63, configured to obtain sending time stamp information sent by the sending end through the time stamp data frame.

According to the embodiment of the application, the OTUw-RS frame head is searched in the parallel data stream through the second pulse module, the frame head pulse is generated, the receiving time module determines the receiving time stamp information according to the frame head pulse and the sampling clock, the sending time module extracts the sending time stamp information sent by the sending end through the time stamp data frame, the time information transmission of the OTUw-RS equipment is achieved, the accuracy of the time stamp information is improved, and the time error among different equipment in a communication network is reduced.

Further, on the basis of the embodiment of the above application, the receiving time module 62 includes:

and the time determining unit is used for respectively sampling the frame header pulse according to the rising edge and the falling edge of the sampling clock and locking the time of a timer corresponding to the sampling clock.

And the timestamp selection unit is used for determining the minimum value in the timer time corresponding to the same clock period as the receiving timestamp information.

Further, on the basis of the embodiment of the above application, the frequency of the sampling clock in the receiving time module 62 is 1GHz, and the step of the sampling clock is 1 nanosecond.

Further, on the basis of the embodiment of the above application, the sending time module 63 includes:

and the packet extraction unit is used for extracting the high-precision time synchronization protocol packet from the overhead reserved field of the timestamp data frame.

And the time stamp extraction unit is used for extracting the sending time stamp information in the high-precision time synchronization protocol packet.

And the frame header corresponding unit is used for determining the corresponding relation between the sending timestamp information and the OTUw-RS frame header.

Further, on the basis of the embodiment of the above application, the baud rate of the frame header pulse in the apparatus is configured to be at least 4 times of the corresponding clock period of the sampling clock.

Fig. 8 is a schematic structural diagram of an apparatus provided in an embodiment of the present application, and as shown in fig. 8, the apparatus includes a processor 70, a memory 71, an input device 72, and an output device 73; the number of processors 70 in the device may be one or more, and one processor 70 is taken as an example in fig. 8; the device processor 70, memory 71, input device 72 and output device 73 may be connected by a bus or other means, as exemplified by the bus connection in fig. 8.

The memory 71 is a computer-readable storage medium, and can be used for storing software programs, computer-executable programs, and modules, such as the modules corresponding to the timestamp information transmission apparatus provided in the embodiment of the present application (the first pulse module 51, the time determination module 52, and the information transmission module 53, and/or the second pulse module 61, the reception time module 62, and the transmission time module 63). The processor 70 executes various functional applications of the device and data processing by executing software programs, instructions, and modules stored in the memory 71, that is, implements the above-described time stamp information transmission method.

The memory 71 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to the use of the terminal, and the like. Further, the memory 71 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some examples, the memory 71 may further include memory located remotely from the processor 70, which may be connected to the device over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.

The input device 72 may be used to receive entered numeric or character information and to generate key signal inputs relating to user settings and function controls of the apparatus. The output device 73 may include a display device such as a display screen.

In an exemplary implementation manner, fig. 9 is a diagram of an implementation example of an optical transmission device provided in an embodiment of the present application, and referring to fig. 9, the optical transmission device includes an equalization module, a clock data recovery CDR module, a PLL module, a serial-to-parallel conversion module, a parallel-to-serial conversion module, an asynchronous FIFO module, an encoding/winding module, and a decoding/descrambling module, and further includes modules such as an OTUw-RS framing module, an OTUw overhead extraction module, an OTUw-RS frame header insertion module, an OTUw overhead insertion module, a timer and timestamp sampling module, and an off-chip processor. The timestamp information is determined and transmitted through an equalization module, a Clock Data Recovery (CDR) module, a phase-locked loop (PLL) module, a serial-parallel conversion module, a parallel-serial conversion module, an asynchronous FIFO module, an encoding/winding module, a decoding/descrambling module, an OTUw-RS framing module, an OTUw overhead extraction module, an OTUw-RS frame header insertion module and an OTUw overhead insertion module. The OTUw-RS framing module realizes the function of generating OTUw-RS frame header pulses in the receiving direction in real time, sends the frame header pulses to the timer and the time stamp sampling module to sample time stamps, and then sends the time stamps to the off-chip processor, meanwhile, the OTUw overhead extraction module sends the overhead corresponding to the OTUw-RS frame header to the off-chip processor, and the off-chip processor analyzes the PTP packets in the overhead retention field. The timer and the timestamp sampling module use the rising edge and the falling edge of a 1GHz clock to sample the frame head pulse signals, and compared with the method that only the rising edge sampling frame head pulse signals are used, the sampling precision is doubled. The pin supporting 1bit holding time length (namely the baud rate) output to the off-chip processor by the timer and the timestamp sampling module can be configured into 16 or 32 timing clock cycles, so that the off-chip processor can realize receiving side PTP packet analysis and transmitting side PTP packet packaging on the correct sampling off-chip processor loaded with the timestamp data frame under a low-speed clock. The receiving side PTP package analysis means that the expenses sent by the OTUw expense extraction module are recombined into a PTP package, and the used expense reservation field is in accordance with the negotiation of the opposite terminal equipment. The sending side PTP package group means that the time stamp information is packaged into a PTP package, and the time stamp information comes from a sending direction OTUw-RS frame header pulse sampled by the timer and the time stamp sampling module.

Fig. 10 is an exemplary diagram of time synchronization provided in an embodiment of the present application, and based on a timestamp transmission method implemented by the present application, time synchronization between devices is implemented as an example:

step one, according to the requirement of the G.709.4 protocol, the time publisher inserts an OTU25-RS protocol AM frame header on a parallel interface at the sending side and outputs a frame header pulse signal at the same time. The timing clock in the embodiment of the application uses 1GHz, and the stepping is 1 nanosecond. And respectively sampling the frame header pulse signals by using the rising edge and the falling edge of the timing clock, latching the time of the timer, and selecting the smaller value of the two timer times as the time stamp of the frame header, and marking as t 1. After the frame header pulse signal becomes low and a configurable integer number of timing clocks pass, a timestamp data frame Sync is sent to the off-chip processor through a timestamp pin at the sending side, and data transmission is finished before the next frame header pulse signal. To ensure that the off-chip processor correctly samples the loaded timestamp data frame at low speed, the 1bit hold duration, i.e., baud rate, may be configured to be 16 or 32 clock cycles. The timestamp data frame is totally 106 bits and comprises a 1-bit start bit, two 8-bit frame header synchronization bytes, a 80-bit timestamp byte, an 8-bit check byte and a 1-bit stop bit, wherein the start bit is a 1-bit high level and is used for marking the start of the timestamp data frame; the stop bit is 1bit low level and is used for marking the end of the time stamp data frame; the frame header synchronization byte is used for synchronizing the time stamp data frame; the timestamp bytes are used for storing timestamp information, 48-bit second data and 32-bit nanosecond data, and the second data can be sent first and then the nanosecond data can be sent; the check byte is used for verifying whether the data in the time stamp data frame is correct, and a 1PPS _ TOD standard TOD frame CRC check can be used, wherein the CRC check formula is as follows: x 8+ x 5+ x 4+1, the initial value of the check code is set to 0xFF, the input data does not need to be inverted, the check algorithm adopts right shift calculation, and the least significant bit0 is sent first when the check byte is sent.

And step two, the off-chip processor encapsulates the time stamp t1 in the time stamp data frame into an IEEE1588v2 PTP packet Follow _ Up message, appropriately adjusts the time delay, and inserts the message into an overhead reserved field of an OTU25 data packet in an OTU25-RS frame period.

And step three, searching an AM frame header of the OTU25-RS on a parallel interface in the receiving direction by a receiving side of the time receiving party according to the requirement of the G.709.4 protocol, and outputting a frame header pulse signal.

And step four, respectively sampling the frame header pulse signals by using the rising edge and the falling edge of the timing clock, latching the time of the timer, selecting the smaller value of the two as a frame header timestamp, and marking as t 2.

And step five, after the frame header pulse signal becomes low and a configurable integer number of timing clocks, sending a time stamp data frame to the off-chip processor through a time stamp pin at the receiving side, and ensuring that data is transmitted before the next frame header pulse signal.

And step six, the off-chip processor extracts the PTP packet in the overhead reserved field through an OTU25 overhead extraction module, corresponds to the timestamp in the last timestamp data frame, and obtains a sampling timestamp t1 of the PTP packet at a time release party.

And seventhly, the time receiving party sends the PTP package Delay _ Req message to the time issuing party, the time stamp is sent as t3, and the time issuing party receives the sampling time stamp of the message as t 4.

And step eight, the time issuing party encapsulates the t4 to the Delay _ Resp message and sends the message to the time receiving party.

And step nine, calculating a time difference value of the master device and the slave device by the off-chip processor based on an IEEE1588v2 protocol, and calibrating the local clock, wherein t2 is offset + delay + t1, and t4 is t3-offset + delay. From the above formula, one can calculate: delay ((t2-t1) + (t4-t3))/2, and time offset ((t2-t1) - (t4-t 3))/2), and time synchronization is performed based on the determined time offset.

Embodiments of the present application also provide a computer-readable storage medium, where computer-executable instructions, when executed by a computer processor, are configured to perform a method for remote customization of functionality, the method comprising:

embodiments of the present application also provide a computer-readable storage medium, where computer-executable instructions, when executed by a computer processor, are configured to perform a method for timestamp information transmission, the method comprising:

inserting an OTUw-RS frame header into the parallel data stream and generating a frame header pulse; determining to send timestamp information according to the frame header pulse and the sampling clock; and sending the sending timestamp information to a receiving end through a timestamp data frame. And/or

Searching an OTUw-RS frame header in the parallel data stream, and generating a frame header pulse; determining to receive timestamp information according to the frame header pulse and the sampling clock; and acquiring the sending time stamp information sent by the sending end through the time stamp data frame.

Of course, the storage medium provided in the embodiments of the present application contains computer-executable instructions, and the computer-executable instructions are not limited to the method operations described above, and may also perform related operations in the remote function customization method provided in any embodiment of the present application.

The above description is only exemplary embodiments of the present application, and is not intended to limit the scope of the present application.

It will be clear to a person skilled in the art that the term user terminal covers any suitable type of wireless user equipment, such as a mobile phone, a portable data processing device, a portable web browser or a car mounted mobile station.

In general, the various embodiments of the application may be implemented in hardware or special purpose circuits, software, logic or any combination thereof. For example, some aspects may be implemented in hardware, while other aspects may be implemented in firmware or software which may be executed by a controller, microprocessor or other computing device, although the application is not limited thereto.

Embodiments of the application may be implemented by a data processor of a mobile device executing computer program instructions, for example in a processor entity, or by hardware, or by a combination of software and hardware. The computer program instructions may be assembly instructions, Instruction Set Architecture (ISA) instructions, machine related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages.

Any logic flow block diagrams in the figures of this application may represent program steps, or may represent interconnected logic circuits, modules, and functions, or may represent a combination of program steps and logic circuits, modules, and functions. The computer program may be stored on a memory. The memory may be of any type suitable to the local technical environment and may be implemented using any suitable data storage technology, such as, but not limited to, Read Only Memory (ROM), Random Access Memory (RAM), optical storage devices and systems (digital versatile disks, DVDs, or CD discs), etc. The computer readable medium may include a non-transitory storage medium. The data processor may be of any type suitable to the local technical environment, such as but not limited to general purpose computers, special purpose computers, microprocessors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), programmable logic devices (FGPAs), and processors based on a multi-core processor architecture.

The foregoing has provided by way of exemplary and non-limiting examples a detailed description of exemplary embodiments of the present application. Various modifications and adaptations to the foregoing embodiments may become apparent to those skilled in the relevant arts in view of the following drawings and the appended claims without departing from the scope of the invention. Accordingly, the proper scope of the application is to be determined according to the claims.

20页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种基于以太网网络的设备时钟误差检测方法

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!