CN105703875B - Method, equipment and system for transmitting message - Google Patents

Method, equipment and system for transmitting message Download PDF

Info

Publication number
CN105703875B
CN105703875B CN201410690020.6A CN201410690020A CN105703875B CN 105703875 B CN105703875 B CN 105703875B CN 201410690020 A CN201410690020 A CN 201410690020A CN 105703875 B CN105703875 B CN 105703875B
Authority
CN
China
Prior art keywords
message
transmitted
bit
data
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201410690020.6A
Other languages
Chinese (zh)
Other versions
CN105703875A (en
Inventor
陈杰
汪波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nanjing ZTE New Software Co Ltd
Original Assignee
Nanjing ZTE New Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nanjing ZTE New Software Co Ltd filed Critical Nanjing ZTE New Software Co Ltd
Priority to CN201410690020.6A priority Critical patent/CN105703875B/en
Priority to PCT/CN2015/074788 priority patent/WO2016082385A1/en
Publication of CN105703875A publication Critical patent/CN105703875A/en
Application granted granted Critical
Publication of CN105703875B publication Critical patent/CN105703875B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received

Abstract

The embodiment of the invention discloses a method, equipment and a system for transmitting messages, wherein the method comprises the following steps: a sending end sets synchronous head data of fixed number of bits; the synchronous head data is used for indicating the start of a message to be transmitted and the type of the message to be transmitted; the sending end carries out verification according to the data value of the message to be transmitted to obtain a verification value of the message to be transmitted; and the sending end sequentially forms the synchronous head data, the data value of the message to be transmitted and the check value of the message to be transmitted into serial data corresponding to the message to be transmitted, and transmits the serial data to a receiving end through a transmission line.

Description

Method, equipment and system for transmitting message
Technical Field
The present invention relates to data communication transmission technologies, and in particular, to a method, device, and system for transmitting a message.
Background
Serial communication refers to a communication mode in which message data is transmitted in a bit sequence on a single transmission line. Under the application scene that the requirement on the message transmission efficiency is not high, the serial communication can effectively save data transmission lines. Under the condition that respective clocks of the sending end and the receiving end do not have strict synchronization requirements, asynchronous serial communication is characterized in that data are formed into character frames, the character frames are sent by the sending end frame by frame, and the character frames are received by the receiving end frame by frame through a single transmission line. Therefore, the clock synchronization by setting clock lines at the transmitting end and the receiving end can be avoided.
However, at present, asynchronous serial communication is not only complicated in encoding and decoding, which requires too many information bits, i.e. extra overhead of message transmission, but also is generally only used for point-to-point message transmission.
Disclosure of Invention
To solve the above technical problem, embodiments of the present invention are directed to a method, device and system for message transmission, which can reduce the overhead of message transmission and can be used for point-to-multipoint message transmission.
The technical scheme of the invention is realized as follows:
in a first aspect, an embodiment of the present invention provides a message transmission method applied to a sending end, including:
the sending end sets synchronous head data of fixed number of bits; the synchronous head data is used for indicating the start of a message to be transmitted and the type of the message to be transmitted;
the sending end carries out verification according to the data value of the message to be transmitted to obtain a verification value of the message to be transmitted;
and the sending end sequentially forms the synchronous head data, the data value of the message to be transmitted and the check value of the message to be transmitted into serial data corresponding to the message to be transmitted, and transmits the serial data to a receiving end through a transmission line.
Further, the synchronization header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message which is supported to be transmitted by the transmitting end.
Further, the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
Further, the method further comprises:
and the transmitting end transmits idle bits opposite to the bit value of the start bits in the transmission interval between two serial data of data to be transmitted.
In a second aspect, an embodiment of the present invention provides a message transmission method applied to a receiving end, including:
when monitoring the synchronous head data of the serial data corresponding to the message to be transmitted, a receiving end determines that the message to be transmitted is the message required to be received according to the type of the message to be transmitted indicated by the synchronous head data; the serial data consists of the synchronous head data, the data value of the message to be transmitted and the check value sequence of the message to be transmitted;
after the receiving end determines that the message to be transmitted is a message which needs to be received, sampling a data value of the message to be transmitted and a check value of the message to be transmitted in the serial data;
the receiving end checks the data value of the message to be transmitted according to the check value of the message to be transmitted obtained by sampling;
and when the verification is successful, the receiving end determines that the data value of the message to be transmitted is an available data value.
Further, the synchronization header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; and, the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
Further, the frequency of the sampling clock of the receiving end is the same as the frequency of the transmission clock of the transmitting end;
correspondingly, the monitoring of the synchronization header data of the serial data corresponding to the message to be transmitted by the receiving end includes:
and when the receiving end continuously receives the initial bit values of M sampling clock periods, determining to monitor the synchronous head data of the serial data corresponding to the message to be transmitted.
Further, the determining, by the receiving end, that the message to be transmitted is a message that needs to be received by itself according to the type of the message to be transmitted indicated by the synchronization header data includes:
the receiving end samples the type bit value of the synchronous head data to obtain the type of the message to be transmitted;
the receiving end matches the type of the message to be transmitted according to the type of the message required to be received by the receiving end;
and when the matching is successful, the receiving end determines that the message to be transmitted is the message which needs to be received by the receiving end.
Further, the receiving end samples a type bit value of the synchronization header data to obtain a type of the message to be transmitted, including:
the receiving end selects a data value corresponding to the central beat in K sampling clock cycles in which each bit is continuous in the type bit of the synchronous head data as a value of a corresponding bit;
and the receiving end determines the type of the message to be transmitted according to the corresponding relation between the type bit value of the synchronization head data and the preset type bit value and the message type.
Further, the sampling, by the receiving end, the data value of the message to be transmitted and the check value of the message to be transmitted in the serial data includes:
and the receiving terminal selects the data value corresponding to the central beat in N sampling clock cycles in which each bit of the data value and the check value of the message to be transmitted is continuous as the value of the corresponding bit.
In a third aspect, an embodiment of the present invention provides a sending end, where the sending end includes: a setting unit, a checking unit, a composition unit and a transmission unit, wherein,
the setting unit is used for setting the synchronous head data of a fixed number of bits; the synchronous head data is used for indicating the start of a message to be transmitted and the type of the message to be transmitted;
the checking unit is used for checking according to the data value of the message to be transmitted to obtain a checking value of the message to be transmitted;
the composition unit is used for sequentially composing the synchronous head data set by the setting unit, the data value of the message to be transmitted and the check value of the message to be transmitted, which is obtained by the check unit, into serial data corresponding to the message to be transmitted;
and the transmission unit is used for transmitting the serial data formed by the composition units to a receiving end through a transmission line.
Further, the synchronization header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message which is supported to be transmitted by the transmitting end.
Further, the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
Further, the transmission unit is further configured to transmit idle bits opposite to the bit value of the start bit in a transmission interval between two serial data of the data to be transmitted.
In a fourth aspect, an embodiment of the present invention provides a receiving end, where the receiving end includes: a monitoring unit, a determining unit, a sampling unit and a checking unit, wherein,
the monitoring unit is used for monitoring the synchronous head data of the serial data corresponding to the message to be transmitted;
the determining unit is configured to determine, when the monitoring unit monitors synchronization header data of serial data corresponding to the message to be transmitted, that the message to be transmitted is a message that needs to be received by the receiving end according to the type of the message to be transmitted indicated by the synchronization header data; and after determining that the message to be transmitted is a message which needs to be received by the receiving end, triggering the sampling unit; the serial data consists of the synchronous head data, the data value of the message to be transmitted and the check value sequence of the message to be transmitted;
the sampling unit is used for sampling the data value of the message to be transmitted and the check value of the message to be transmitted in the serial data;
the checking unit is used for checking the data value of the message to be transmitted according to the checking value of the message to be transmitted, which is obtained by sampling by the sampling unit;
the determining unit is further configured to determine that the data value of the message to be transmitted is an available data value after the checking unit successfully checks the message.
Further, the synchronization header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; and, the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; wherein M, N is an integer greater than 1, and N is greater than M +2, and K is an integer greater than 2.
Further, the frequency of the sampling clock of the receiving end is the same as the frequency of the transmission clock of the transmitting end;
correspondingly, the monitoring unit is configured to determine to monitor the synchronization header data of the serial data corresponding to the message to be transmitted when the start bit values of M sampling clock cycles are continuously received.
Further, the determining unit is configured to:
instructing the sampling unit to sample the type bit value of the synchronous head data to obtain the type of the message to be transmitted;
matching the type of the message to be transmitted with the type of the message to be transmitted according to the type of the message to be received;
and when the matching is successful, determining that the message to be transmitted is a message which needs to be received by the message to be transmitted.
Further, the sampling unit is configured to select a data value corresponding to a central beat in K sampling clock cycles in which each bit continues in the type bit of the sync header data as a value of a corresponding bit;
and determining the type of the message to be transmitted according to the corresponding relation between the type bit value of the synchronization head data and the preset type bit value and the message type.
Further, the sampling unit is configured to select a data value corresponding to a central beat in N sampling clock cycles in which each bit continues in the data value and the check value of the message to be transmitted as a value of a corresponding bit.
In a fifth aspect, an embodiment of the present invention provides a message transmission system, which includes a sending end and a receiving end, wherein,
the transmitting end is used for setting the synchronous head data of fixed number of bits; the synchronous head data is used for indicating the start of a message to be transmitted and the type of the message to be transmitted;
checking according to the data value of the message to be transmitted to obtain a check value of the message to be transmitted;
sequentially forming serial data corresponding to the message to be transmitted by the synchronous head data, the data value of the message to be transmitted and the check value of the message to be transmitted, and transmitting the serial data to the receiving end through a transmission line;
the receiving end is used for determining the message to be transmitted as a message required to be received according to the type of the message to be transmitted indicated by the synchronization head data when the synchronization head data of the serial data corresponding to the message to be transmitted is monitored;
after the message to be transmitted is determined to be a message which needs to be received by the receiving end, sampling a data value of the message to be transmitted and a check value of the message to be transmitted in the serial data;
and verifying the data value of the message to be transmitted according to the verification value of the message to be transmitted obtained by sampling;
and after the verification is successful, determining that the data value of the message to be transmitted is an available data value.
Embodiments of the present invention provide a method, device, and system for message transmission, where in the process of asynchronous serial communication, a new coding and decoding method is used to process a message to be transmitted, so that in the process of message transmission, additional overhead is reduced, and the method, device, and system can also be used for point-to-multipoint message transmission.
Drawings
Fig. 1 is a schematic view of an application scenario provided in an embodiment of the present invention;
fig. 2 is a schematic flow chart of a method for transmitting a message according to an embodiment of the present invention;
FIG. 3 is a waveform of a serial data waveform according to an embodiment of the present invention;
fig. 4 is a schematic flowchart of another message transmission method according to an embodiment of the present invention;
FIG. 5 is a diagram of another serial data waveform provided by an embodiment of the present invention;
fig. 6 is a schematic structural diagram of a transmitting end according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of a receiving end according to an embodiment of the present invention;
fig. 8 is a schematic structural diagram of a message transmission system according to an embodiment of the present invention.
Detailed Description
The technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
The basic idea of the embodiment of the invention is as follows: in the process of asynchronous serial communication, a new coding and decoding method is used for processing a message to be transmitted, so that extra overhead is reduced in the process of message transmission, and the method can also be used for point-to-multipoint message transmission.
Based on the above basic ideas, referring to fig. 1, an application scenario provided by the embodiment of the present invention is shown, in which a sending end 10 and three receiving ends 20, 30, and 40 are connected through a single transmission line 50 and transmit data between the sending end 10 and each receiving end. The embodiment of the present invention only describes the technical solution by taking the case that the transmitting end 10 is connected with a single receiving end through a single transmission line 50 and transmits data as an example, it can be understood that the application scenario can be applied to data transmission between the transmitting end 10 and other receiving ends, and the application scenario is only used for describing the technical solution of the embodiment of the present invention, and is not used for any specific limitation on the embodiment of the present invention.
Referring to fig. 2, it shows a flow of a method for transmitting a message according to an embodiment of the present invention, where the method is applied to a sending end, and the method may include:
s201: a sending end sets synchronous head data of fixed number of bits; the synchronous head data is used for indicating the start of the message to be transmitted and the type of the message to be transmitted;
specifically, the sync header data may include: a start bit, a wait bit, and a type bit; wherein, the start bit and the waiting bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message supported by the sending end;
further, in the present embodiment, the start bit lasts for M transmission clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the waiting bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1 in order to allow the receiving end to have mis-sampling when detecting the start bit; also, to distinguish the start bit of the message, it is preferable that N is greater than M +2 and K is an integer greater than 2.
It should be noted that, because the type of the message to be transmitted is indicated by the type bit in the synchronization header data, the receiving end can determine whether the message is a message that the receiving end needs to receive according to the type of the message to be transmitted indicated by the type bit, and thus, data can be sent to multiple receiving ends on a single transmission line, so as to implement point-to-multipoint message transmission.
S202: the sending end carries out verification according to the data value of the message to be transmitted to obtain the verification value of the message to be transmitted;
it can be understood that the Check algorithm used by the sending end to Check according to the data value of the message to be transmitted may be Cyclic Redundancy Check (CRC) Check, or other Check algorithms such as sum Check and parity Check, and the embodiment of the present invention is not specifically limited to this; this embodiment is preferably a CRC check.
S203: the sending end sequentially forms serial data corresponding to the message to be transmitted by the synchronous head data, the data value of the message to be transmitted and the check value of the message to be transmitted, and transmits the serial data to the receiving end through the transmission line.
Preferably, when the message transmission rate is lower than the preset rate threshold, the sending end can set the transmission interval between the serial data of the data to be transmitted twice to be larger than the time for transmitting the serial data once, and the sending end can set the transmission interval between the serial data of the data to be transmitted twice to be idle time, so that the design of the receiving end for monitoring the synchronization head can be simplified, and the situation that the receiving end mistakenly takes the data in the message as the synchronization head can be avoided;
further, when there is idle time between two serial data transmissions by the sending end, in order to distinguish the serial data of two data to be transmitted sent by the sending end, preferably, the method provided in this embodiment may further include: the transmitting end transmits idle bits opposite to the bit value of the start bit in a transmission interval between two serial data of data to be transmitted. It is understood that when the transmitting end continuously transmits serial data, the transmitting end may not need to transmit the idle bit.
In detail, referring to fig. 3, which shows an exemplary waveform diagram of serial data transmitted by the transmitting end in the flow of the message transmission method shown in fig. 2, as shown in fig. 3, in the synchronization header data, the start bit is high level lasting for 2 transmission clock cycles, and is represented by logic 1 in this embodiment; the wait bit is low for 5 transmit clock cycles, represented in this embodiment by a logic 0; the number of bits of the type bit is 3, and the serial data shown in FIG. 3 can be used to indicate 23Each bit of the type bit also lasts for 5 transmit clock cycles, as well as 8 data types; each bit of the message to be transmitted and the check value likewise lasts for 5 transmission cycles.
Based on the same technical concept of the above embodiments, after the transmitting end transmits serial data to the receiving end through the transmission line, referring to fig. 4, it shows another message transmission method flow provided by the embodiment of the present invention, where the method is applied to the receiving end, and the method may include:
s401: when monitoring the synchronous head data of the serial data corresponding to the message to be transmitted, the receiving end determines the message to be transmitted as the message required to be received according to the type of the message to be transmitted indicated by the synchronous head data;
the serial data consists of synchronous head data, a data value of a message to be transmitted and a check value sequence of the message to be transmitted; further, consistent with the sync header data in the foregoing embodiments, the sync header data may include: a start bit, a wait bit, and a type bit; wherein, the start bit and the waiting bit are both 1 bit and have opposite bit values; and, the start bit lasts M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the waiting bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
Illustratively, the frequency of the sampling clock of the receiving end is the same as the frequency of the transmission clock; correspondingly, the receiving end monitors the synchronous head data of the serial data corresponding to the message to be transmitted, and the method comprises the following steps:
and when the receiving end continuously receives the initial bit values of M sampling clock periods, determining to monitor the synchronous head data of the serial data corresponding to the message to be transmitted.
Further, the receiving end determines the message to be transmitted as the message to be received according to the type of the message to be transmitted indicated by the synchronization header data, including:
the receiving end samples the type bit value of the synchronous head data to obtain the type of the message to be transmitted;
the receiving end matches the type of the message to be transmitted according to the type of the message required to be received by the receiving end;
when the matching is successful, the receiving end determines that the message to be transmitted is the message which needs to be received by the receiving end;
specifically, the sampling of the type bit value of the synchronization header data by the receiving end to obtain the type of the message to be transmitted may include: the receiving end can select the data value corresponding to the central beat in the continuous K sampling clock cycles of each bit in the type bits of the synchronous head data as the value of the corresponding bit; then, the receiving end determines the type of the message to be transmitted according to the corresponding relation between the type bit value of the synchronization head data and the preset type bit value and the message type; it can be understood that the receiving end selects the data value corresponding to the central beat in the K sampling clock periods with continuous bit as the value of the corresponding bit, so that the data can be correctly sampled even if the clocks of the transmitting end and the receiving end are non-homologous common-frequency clocks; when K is an even number, the central beat takes K/2 beats; when K is an odd number, the center beat takes the (K +1)/2 th beat.
It should be noted that, because the receiving end can determine whether the message to be transmitted in the serial data is a message that needs to be received by itself according to the type of the message to be transmitted in the serial data, the transmitting end can transmit the message to a plurality of receiving ends through a single transmission line, and the receiving ends determine whether to receive the message according to the type of the message to be transmitted, thereby implementing point-to-multipoint message transmission.
S402: after a receiving end determines that a message to be transmitted is a message which needs to be received, sampling a data value of the message to be transmitted in serial data and a check value of the message to be transmitted;
it can be understood that the serial data is directly discarded after the receiving end determines that the message to be transmitted is not a message that the receiving end needs to receive.
Further, the receiving end samples the data value of the message to be transmitted in the serial data and the check value of the message to be transmitted, which may specifically include:
the receiving end selects the data value corresponding to the central beat in N sampling clock cycles in which each bit continues in the data value and the check value of the message to be transmitted as the value of the corresponding bit; as can be understood, when N is an even number, the center beat takes N/2 beats; when N is an odd number, the central beat takes the (N +1)/2 th beat.
S403: the receiving end checks the data value of the message to be transmitted according to the check value of the message to be transmitted obtained by sampling;
s404: after the verification is successful, the receiving end determines that the data value of the message to be transmitted is an available data value;
it can be understood that if the verification is unsuccessful, the receiving end determines that the data value of the message to be transmitted in the serial data is not available, and discards the serial data.
In detail, referring to fig. 5, a method of message transmission shown in fig. 4 is illustratedIn the flow, an exemplary serial data waveform received by the receiving end, similar to fig. 3, in the synchronization header data, the sampling clock period of the sampling start bit of the receiving end is 2 sending clock periods; the sampling clock period of the sampling waiting bit of the receiving end is 5 sending clock periods; the number of bits of the type bit is 3, and the serial data shown in FIG. 3 can be used to indicate 23As for 8 data types, the sampling period of each bit of the type bit, the message to be transmitted, and the check value is also 5 transmission clock periods, and the data value corresponding to the center beat is the data value of the 3 rd beat in the 5 transmission periods, as shown by the dotted line in the figure.
The message transmission method provided by the above embodiment processes the message to be transmitted by a new coding and decoding method in the asynchronous serial communication process, so that the additional overhead is reduced in the message transmission process, and the method can also be used for point-to-multipoint message transmission.
Based on the same technical concept as the foregoing embodiment, referring to fig. 6, it shows a structure of a transmitting end 60 according to an embodiment of the present invention, which includes a setting unit 601, a checking unit 602, a forming unit 603, and a transmitting unit 604, wherein,
a setting unit 601 for setting synchronization header data of a fixed number of bits; the synchronous head data is used for indicating the start of the message to be transmitted and the type of the message to be transmitted;
a checking unit 602, configured to perform checking according to a data value of a message to be transmitted, to obtain a check value of the message to be transmitted;
a composing unit 603, configured to sequentially compose the synchronization header data set by the setting unit 601, the data value of the message to be transmitted, and the check value of the message to be transmitted, which is obtained by the checking unit 602, into serial data corresponding to the message to be transmitted;
a transmission unit 604 for transmitting the serial data composed by the composition unit 603 to a receiving end through a transmission line.
Illustratively, synchronizing the header data includes: a start bit, a wait bit, and a type bit; wherein, the start bit and the waiting bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the number of types of messages that the transmitting end supports transmitting.
Further, the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the waiting bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
Further, the transmission unit 604 is further configured to transmit idle bits opposite to the bit value of the start bit in a transmission interval between two serial data of the data to be transmitted.
In the asynchronous serial communication process, the sending end 60 provided in this embodiment encodes the message to be transmitted by a new encoding and decoding method, so that in the message transmission process, the extra overhead is reduced, and the sending end can also be used for point-to-multipoint message transmission.
Based on the same technical concept as the foregoing embodiment, referring to fig. 7, it shows a structure of a receiving end 70 provided by an embodiment of the present invention, including: a monitoring unit 701, a determination unit 702, a sampling unit 703 and a verification unit 704, wherein,
a monitoring unit 701, configured to monitor synchronization header data of serial data corresponding to a message to be transmitted;
a determining unit 702, configured to determine, when the monitoring unit 701 monitors synchronization header data of serial data corresponding to a message to be transmitted, that the message to be transmitted is a message that needs to be received by the receiving end 70 itself according to the type of the message to be transmitted indicated by the synchronization header data; and after determining that the message to be transmitted is a message that needs to be received by the receiving end 70 itself, triggering the sampling unit 703; the serial data consists of synchronous head data, a data value of a message to be transmitted and a check value sequence of the message to be transmitted;
a sampling unit 703, configured to sample a data value of a message to be transmitted in the serial data and a check value of the message to be transmitted;
the checking unit 704 is configured to check the data value of the message to be transmitted according to the check value of the message to be transmitted, which is obtained by sampling by the sampling unit 703;
the determining unit 702 is further configured to determine that the data value of the message to be transmitted is an available data value after the checking unit 704 successfully checks.
Illustratively, synchronizing the header data includes: a start bit, a wait bit, and a type bit; wherein, the start bit and the waiting bit are both 1 bit and have opposite bit values; and, the start bit lasts M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the waiting bit and the type bit lasts for K sending clock cycles; wherein M, N is an integer greater than 1, and N is greater than M +2, and K is an integer greater than 2.
Further, the frequency of the sampling clock of the receiving end is the same as the frequency of the sending clock of the sending end;
correspondingly, the monitoring unit 701 is configured to determine to monitor synchronization header data of serial data corresponding to a message to be transmitted when starting bit values of M sampling clock cycles are continuously received.
Further, a determining unit 702 is configured to:
the indication sampling unit 703 samples the type bit value of the synchronization header data to obtain the type of the message to be transmitted;
matching the type of the message to be transmitted with the type of the message to be transmitted according to the type of the message to be received;
and when the matching is successful, determining that the message to be transmitted is the message which needs to be received by the message to be transmitted.
Further, the sampling unit 703 is configured to select a data value corresponding to a central beat in K sampling clock cycles in which each bit continues in the type bit of the sync header data as a value of a corresponding bit;
and determining the type of the message to be transmitted according to the corresponding relation between the type bit value of the synchronization head data and the preset type bit value and the message type.
Further, the sampling unit 703 is configured to select a data value corresponding to a central beat in N sampling clock cycles in which each bit of the data value and the check value of the message to be transmitted lasts as a value of a corresponding bit.
In the asynchronous serial communication process, the receiving end 70 provided in this embodiment decodes the message to be transmitted by using a new coding and decoding method, so that in the message transmission process, the additional overhead is reduced, and the receiving end can also be used for point-to-multipoint message transmission.
Based on the same technical concept as the above-mentioned embodiment, referring to fig. 8, it shows a structure of a message transmission system 80 provided by the embodiment of the present invention, the system 80 may include a sending end 60 and a receiving end 70, wherein,
a transmitting end 60 for setting the synchronization header data of a fixed number of bits; the synchronous head data is used for indicating the start of the message to be transmitted and the type of the message to be transmitted;
checking according to the data value of the message to be transmitted to obtain a check value of the message to be transmitted;
and, make up the data value of the synchronous head data, message to be transmitted and check value of the message to be transmitted into the serial data that the message to be transmitted corresponds sequentially, and transmit the serial data to the receiving end 70 through the transmission line;
the receiving end 70 is configured to determine, when monitoring sync header data of serial data corresponding to a message to be transmitted, that the message to be transmitted is a message that needs to be received by itself according to a type of the message to be transmitted indicated by the sync header data;
and when the message to be transmitted is determined to be a message which needs to be received by the receiving terminal 70, sampling the data value of the message to be transmitted in the serial data and the check value of the message to be transmitted;
and verifying the data value of the message to be transmitted according to the verification value of the message to be transmitted obtained by sampling;
and after the verification is successful, determining that the data value of the message to be transmitted is an available data value.
The message transmission system 80 provided in this embodiment processes the message to be transmitted by a new codec method in the asynchronous serial communication process, so that the extra overhead is reduced in the message transmission process, and the message transmission system can also be used for point-to-multipoint message transmission.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of a hardware embodiment, a software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
The above description is only a preferred embodiment of the present invention, and is not intended to limit the scope of the present invention.

Claims (19)

1. A message transmission method is applied to a sending end, and the method comprises the following steps:
the sending end sets synchronous head data of fixed number of bits; the synchronous head data is used for indicating the start of a message to be transmitted and the type of the message to be transmitted;
the sending end carries out verification according to the data value of the message to be transmitted to obtain a verification value of the message to be transmitted;
the sending end sequentially forms the synchronous head data, the data value of the message to be transmitted and the check value of the message to be transmitted into serial data corresponding to the message to be transmitted, and transmits the serial data to a receiving end through a transmission line;
the sync header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message which is supported to be transmitted by the transmitting end.
2. The method of claim 1, wherein the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
3. The method of claim 1, further comprising:
and the transmitting end transmits idle bits opposite to the bit value of the start bits in the transmission interval between two serial data of data to be transmitted.
4. A message transmission method, wherein the method is applied to a receiving end, and the method comprises:
when monitoring the synchronous head data of the serial data corresponding to the message to be transmitted, a receiving end determines that the message to be transmitted is the message required to be received according to the type of the message to be transmitted indicated by the synchronous head data; the serial data consists of the synchronous head data, the data value of the message to be transmitted and the check value sequence of the message to be transmitted;
the sync header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message supported by the sending end;
after the receiving end determines that the message to be transmitted is a message which needs to be received, sampling a data value of the message to be transmitted and a check value of the message to be transmitted in the serial data;
the receiving end checks the data value of the message to be transmitted according to the check value of the message to be transmitted obtained by sampling;
and when the verification is successful, the receiving end determines that the data value of the message to be transmitted is an available data value.
5. The method of claim 4, wherein the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
6. The method of claim 5, wherein the frequency of the sampling clock of the receiving end is the same as the frequency of the transmission clock of the transmitting end;
correspondingly, the monitoring of the synchronization header data of the serial data corresponding to the message to be transmitted by the receiving end includes:
and when the receiving end continuously receives the initial bit values of M sampling clock periods, determining to monitor the synchronous head data of the serial data corresponding to the message to be transmitted.
7. The method according to claim 6, wherein the determining, by the receiving end, that the message to be transmitted is a message that needs to be received by itself according to the type of the message to be transmitted indicated by the synchronization header data comprises:
the receiving end samples the type bit value of the synchronous head data to obtain the type of the message to be transmitted;
the receiving end matches the type of the message to be transmitted according to the type of the message required to be received by the receiving end;
and when the matching is successful, the receiving end determines that the message to be transmitted is the message which needs to be received by the receiving end.
8. The method of claim 7, wherein the step of the receiving end sampling a type bit value of the synchronization header data to obtain the type of the message to be transmitted comprises:
the receiving end selects a data value corresponding to the central beat in K sampling clock cycles in which each bit is continuous in the type bit of the synchronous head data as a value of a corresponding bit;
and the receiving end determines the type of the message to be transmitted according to the corresponding relation between the type bit value of the synchronization head data and the preset type bit value and the message type.
9. The method of claim 6, wherein the receiving end samples the data value of the message to be transmitted and the check value of the message to be transmitted in the serial data, and comprises:
and the receiving terminal selects the data value corresponding to the central beat in N sampling clock cycles in which each bit of the data value and the check value of the message to be transmitted is continuous as the value of the corresponding bit.
10. A transmitting end, characterized in that the transmitting end comprises: a setting unit, a checking unit, a composition unit and a transmission unit, wherein,
the setting unit is used for setting the synchronous head data of a fixed number of bits; the synchronous head data is used for indicating the start of a message to be transmitted and the type of the message to be transmitted; the sync header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message which is supported to be sent by the sending end;
the checking unit is used for checking according to the data value of the message to be transmitted to obtain a checking value of the message to be transmitted;
the composition unit is used for sequentially composing the synchronous head data set by the setting unit, the data value of the message to be transmitted and the check value of the message to be transmitted, which is obtained by the check unit, into serial data corresponding to the message to be transmitted;
and the transmission unit is used for transmitting the serial data formed by the composition units to a receiving end through a transmission line.
11. The transmit end of claim 10, wherein the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; m, N are integers greater than 1, N is greater than M +2, and K is an integer greater than 2.
12. The transmitting end according to claim 10, wherein the transmitting unit is further configured to transmit a free bit opposite to a bit value of the start bit in a transmission interval between two serial data of data to be transmitted.
13. A receiving end, comprising: a monitoring unit, a determining unit, a sampling unit and a checking unit, wherein,
the monitoring unit is used for monitoring the synchronous head data of the serial data corresponding to the message to be transmitted; the sync header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message supported by the sending end;
the determining unit is configured to determine, when the monitoring unit monitors synchronization header data of serial data corresponding to the message to be transmitted, that the message to be transmitted is a message that needs to be received by the receiving end according to the type of the message to be transmitted indicated by the synchronization header data; and after determining that the message to be transmitted is a message which needs to be received by the receiving end, triggering the sampling unit; the serial data consists of the synchronous head data, the data value of the message to be transmitted and the check value sequence of the message to be transmitted;
the sampling unit is used for sampling the data value of the message to be transmitted and the check value of the message to be transmitted in the serial data;
the checking unit is used for checking the data value of the message to be transmitted according to the checking value of the message to be transmitted, which is obtained by sampling by the sampling unit;
the determining unit is further configured to determine that the data value of the message to be transmitted is an available data value after the checking unit successfully checks the message.
14. The receiver of claim 13, wherein the start bit lasts for M transmit clock cycles; each bit in the data value of the message to be transmitted and each bit in the check value lasts for N sending clock cycles; each bit of the wait bit and the type bit lasts for K sending clock cycles; wherein M, N is an integer greater than 1, and N is greater than M +2, and K is an integer greater than 2.
15. The receiving end according to claim 14, wherein the frequency of the sampling clock of the receiving end is the same as the frequency of the transmission clock of the transmitting end;
correspondingly, the monitoring unit is configured to determine to monitor the synchronization header data of the serial data corresponding to the message to be transmitted when the start bit values of M sampling clock cycles are continuously received.
16. The receiving end according to claim 15, wherein the determining unit is configured to:
instructing the sampling unit to sample the type bit value of the synchronous head data to obtain the type of the message to be transmitted;
matching the type of the message to be transmitted with the type of the message to be transmitted according to the type of the message to be received;
and when the matching is successful, determining that the message to be transmitted is a message which needs to be received by the message to be transmitted.
17. The receiving end according to claim 16, wherein the sampling unit is configured to select a data value corresponding to a central beat in K sampling clock cycles in which each bit continues in the type bit of the sync header data as a value of a corresponding bit;
and determining the type of the message to be transmitted according to the corresponding relation between the type bit value of the synchronization head data and the preset type bit value and the message type.
18. The receiving end according to claim 15, wherein the sampling unit is configured to select a data value corresponding to a central beat in N sampling clock cycles in which each bit lasts, as a value of a corresponding bit, in the data value and the check value of the message to be transmitted.
19. A message transmission system, characterized in that the system comprises a sending end and a receiving end, wherein,
the transmitting end is used for setting the synchronous head data of fixed number of bits; the synchronous head data is used for indicating the start of a message to be transmitted and the type of the message to be transmitted; the sync header data includes: a start bit, a wait bit, and a type bit; wherein the start bit and the wait bit are both 1 bit and have opposite bit values; the bit number of the type bit is determined by the type number of the message which is supported to be sent by the sending end;
checking according to the data value of the message to be transmitted to obtain a check value of the message to be transmitted;
sequentially forming serial data corresponding to the message to be transmitted by the synchronous head data, the data value of the message to be transmitted and the check value of the message to be transmitted, and transmitting the serial data to the receiving end through a transmission line;
the receiving end is used for determining the message to be transmitted as a message required to be received according to the type of the message to be transmitted indicated by the synchronization head data when the synchronization head data of the serial data corresponding to the message to be transmitted is monitored;
after the message to be transmitted is determined to be a message which needs to be received by the receiving end, sampling a data value of the message to be transmitted and a check value of the message to be transmitted in the serial data;
and verifying the data value of the message to be transmitted according to the verification value of the message to be transmitted obtained by sampling;
and after the verification is successful, determining that the data value of the message to be transmitted is an available data value.
CN201410690020.6A 2014-11-25 2014-11-25 Method, equipment and system for transmitting message Active CN105703875B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201410690020.6A CN105703875B (en) 2014-11-25 2014-11-25 Method, equipment and system for transmitting message
PCT/CN2015/074788 WO2016082385A1 (en) 2014-11-25 2015-03-20 Message transmission method, device, system and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410690020.6A CN105703875B (en) 2014-11-25 2014-11-25 Method, equipment and system for transmitting message

Publications (2)

Publication Number Publication Date
CN105703875A CN105703875A (en) 2016-06-22
CN105703875B true CN105703875B (en) 2020-08-07

Family

ID=56073453

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410690020.6A Active CN105703875B (en) 2014-11-25 2014-11-25 Method, equipment and system for transmitting message

Country Status (2)

Country Link
CN (1) CN105703875B (en)
WO (1) WO2016082385A1 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107957523A (en) * 2017-11-23 2018-04-24 苏州达方电子有限公司 Detection device
CN111475447B (en) * 2019-01-24 2021-10-22 广州彩熠灯光股份有限公司 High-speed serial transmission device based on LVDS and data transmission method
CN111722940B (en) * 2020-05-22 2024-04-16 百富计算机技术(深圳)有限公司 Message transmission method, terminal equipment and transmission system based on asynchronous serial port
WO2023087143A1 (en) * 2021-11-16 2023-05-25 华为技术有限公司 Video transmission method and apparatus
CN117221894B (en) * 2023-11-09 2024-01-12 湖南雷诺科技发展有限公司 Big data-based 5G communication transmission method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101014007A (en) * 2007-01-31 2007-08-08 华为技术有限公司 Data transmission method and transmitting apparatus and receiving apparatus
CN101364939A (en) * 2007-08-07 2009-02-11 华为技术有限公司 Data packet forwarding method and device, data packet generating device and communication system
CN102143073A (en) * 2011-03-23 2011-08-03 深圳创维数字技术股份有限公司 Data transmission method and system
CN102647252A (en) * 2012-03-26 2012-08-22 航天东方红卫星有限公司 Serial communication method

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2790147B2 (en) * 1987-06-03 1998-08-27 エリクソン ジーイー モービル コミュニケーションズ インコーポレーテッド Communication protocol between processors for public trunking.
US20050257117A1 (en) * 2004-05-12 2005-11-17 Weirong Chiang Method and circuit for determining an ending of an ethernet frame
CN101488825B (en) * 2008-01-16 2011-11-09 宏达国际电子股份有限公司 Error detection method and system for data transmission
AU2012277899B2 (en) * 2011-06-29 2017-06-29 Robert Bosch Gmbh Method and device for serial data transmission having a flexible message size and a variable bit length
CN102510323B (en) * 2011-09-22 2014-11-26 航天科工惯性技术有限公司 Frame identifying method for serial data
CN102394655B (en) * 2011-10-31 2013-12-11 中国兵器工业集团第二一四研究所苏州研发中心 Manchester code converting method on MIC bus

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101014007A (en) * 2007-01-31 2007-08-08 华为技术有限公司 Data transmission method and transmitting apparatus and receiving apparatus
CN101364939A (en) * 2007-08-07 2009-02-11 华为技术有限公司 Data packet forwarding method and device, data packet generating device and communication system
CN102143073A (en) * 2011-03-23 2011-08-03 深圳创维数字技术股份有限公司 Data transmission method and system
CN102647252A (en) * 2012-03-26 2012-08-22 航天东方红卫星有限公司 Serial communication method

Also Published As

Publication number Publication date
WO2016082385A1 (en) 2016-06-02
CN105703875A (en) 2016-06-22

Similar Documents

Publication Publication Date Title
CN105703875B (en) Method, equipment and system for transmitting message
CN106911426B (en) Method and equipment for transmitting data in flexible Ethernet
CN107888344B (en) Method, equipment and system for detecting error code
RU2597467C2 (en) Method and device for adaptation of reliability of data transmission in serial bus system
EP3675398B1 (en) Check code processing method, electronic device, and storage medium
RU2620989C2 (en) Method and apparatus for increasing throughput capacity in data transmission in serial bus system
CN102377521B (en) Systems and methods for performing forward error correction
US10396921B2 (en) Multi-lane synchronization method, synchronization apparatus and system, and computer storage medium
US20200334189A1 (en) Method and apparatus for decoding oscilloscope signal and oscilloscope
US11569923B2 (en) Method and apparatus for sending and receiving multiframe, and storage medium
CN110213017B (en) Data transmission method, device and system, storage medium and terminal equipment
CN106656424B (en) Data transmission verification method
AU2014227460B2 (en) Maximal transition hamming codes
CN108513701B (en) Data transmission method, device, machine readable storage medium and system
CN109167959B (en) Video acquisition equipment, system and video signal transmission method
EP3547577B1 (en) Data transmission method and terminal
CN104640216B (en) A kind of in advance wake-up processing method and processing device of discontinuous reception
CN109428676B (en) Method and device for synchronizing forward error correction coding and decoding modes
US20120124455A1 (en) Coding apparatus, coding method, decoding apparatus, decoding method, program and transmission system
US8681786B2 (en) Centralized recording and processing of received packet parameters
KR101208894B1 (en) Apparatus and method for transmitting and receiving for the body implantable medical devices
US20150365109A1 (en) Forward error correction codeword synchronization method, device, and system
CN107888326B (en) Data transmission method and device
CN108322298B (en) UART out-of-synchronization recovery method, equipment and system
CN108650047B (en) Serial data receiving real-time synchronous monitoring circuit and monitoring method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20200706

Address after: Yuhuatai District of Nanjing City, Jiangsu province 210012 Bauhinia Road No. 68

Applicant after: Nanjing Zhongxing New Software Co.,Ltd.

Address before: 518057 Nanshan District Guangdong high tech Industrial Park, South Road, science and technology, ZTE building, Ministry of Justice

Applicant before: ZTE Corp.

GR01 Patent grant
GR01 Patent grant