CN111478841A - Data transmission system and method adopting special coding mode - Google Patents

Data transmission system and method adopting special coding mode Download PDF

Info

Publication number
CN111478841A
CN111478841A CN202010293916.6A CN202010293916A CN111478841A CN 111478841 A CN111478841 A CN 111478841A CN 202010293916 A CN202010293916 A CN 202010293916A CN 111478841 A CN111478841 A CN 111478841A
Authority
CN
China
Prior art keywords
arbitration
symbol
data
bus
identifier
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.)
Pending
Application number
CN202010293916.6A
Other languages
Chinese (zh)
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.)
United Huaxin Electronics Co Ltd
Original Assignee
United Huaxin Electronics 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 United Huaxin Electronics Co Ltd filed Critical United Huaxin Electronics Co Ltd
Priority to CN202010293916.6A priority Critical patent/CN111478841A/en
Publication of CN111478841A publication Critical patent/CN111478841A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L12/4013Management of data rate on the bus
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L12/40143Bus networks involving priority mechanisms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L2012/40208Bus networks characterized by the use of a particular bus standard
    • H04L2012/40215Controller Area Network CAN

Abstract

The invention provides a data transmission system and a method adopting a special coding mode, which comprises the following steps: at least two pairs of data buses, one pair of arbitration buses and a plurality of communication nodes; the arbitration bus is used for arbitrating the data bus and transmitting by taking an arbitration frame as a unit, each arbitration frame comprises at least two arbitration time periods, each arbitration time period selects a winning communication node, and the winning communication node obtains the use right of the next data frame of the target data bus; when the same symbol is continuously transmitted in the process of transmitting the identifier consisting of a plurality of symbols to the arbitration bus, each communication node alternately transmits the identifier by adopting different encoding results of the symbol under different encoding modes. The invention can improve the reliability of decoding, improve the anti-interference capability and the clock recovery capability of the system and realize the requirements of high-speed, reliable and real-time communication among a plurality of communication nodes.

Description

Data transmission system and method adopting special coding mode
Technical Field
The present invention relates to the field of data transmission, and more particularly, to a data transmission system and method using a special coding scheme.
Background
A CAN (Controller Area Network) bus has been widely used in the fields of automobile application, industrial automation, and the like because of its advantages of high reliability, real-time performance, and the like.
The CAN bus only comprises a pair of differential signal lines, adopts serial data transmission and has simple structure; the method supports multi-master communication, namely each node device can actively initiate data communication to other node devices on the network at any time, and the communication sequence is determined according to the priority of the identifier of each node device; when a plurality of node devices simultaneously initiate communication, the avoidance priority with low priority is high. However, the bus rate is limited, and is up to 1Mbps (the communication distance is less than 40 meters), and the data frame of the CAN bus CAN transmit at most 8 bytes of effective data each time, which cannot meet the design requirement of large data volume high-speed communication among a plurality of node devices. In addition, when there are many node devices hanging on the bus, communication conflicts are easy to occur, only one node device is allowed to obtain the right of use of the bus for data transmission by arbitration each time, and other node devices have to wait, so that the bus rate is limited.
Disclosure of Invention
The invention aims to provide a data transmission system and a method adopting a special coding mode, which adopt the coding results of the same symbol under different coding modes to be alternately sent when the same symbol is continuously sent, improve the reliability of decoding, improve the anti-interference capability of the system, realize the requirements of high-speed and real-time communication among a plurality of communication nodes by utilizing a high-speed bus under the multipoint interconnection application occasion, and have high transmission efficiency and high reliability.
The technical scheme provided by the invention is as follows:
a data transmission system adopting a special coding mode comprises: at least two pairs of data buses, wherein all the data buses transmit by taking a data frame as a unit; the arbitration buses transmit by taking arbitration frames as units, the transmission time of the arbitration frames is the same as that of the data frames, each arbitration frame comprises at least two arbitration time periods, and each arbitration time period arbitrates a winner communication node of the time period; the communication nodes are respectively connected in parallel and hung on the data buses and the arbitration bus; each communication node includes: the arbitration interface module is used for sending an identifier consisting of a plurality of symbols to the arbitration bus so as to participate in data transmission right competition of the data bus, wherein when the sent symbol is not the first symbol and is the same as the previous symbol, the coding result generated by a coding mode different from the previous symbol is adopted for sending; the data sending module is used for sending own data to a target data bus; the control module is used for controlling the arbitration interface module to send the identifier of the arbitration interface module to the arbitration bus in the current arbitration time period of the current arbitration frame when the data sending requirement of the arbitration interface module is detected; when detecting that the identifier is successfully sent, the communication node is a winning communication node in the time period, and controls the data sending module to send own data to a target data bus in the next data frame, and meanwhile, the identifier is not sent in the current arbitration frame; when the identifier transmission failure is detected and the current arbitration time period is not the last arbitration time period of the current arbitration frame, controlling the arbitration interface module to retransmit the identifier to the arbitration bus in the next arbitration time period of the current arbitration frame until the identifier transmission is successful or the last arbitration time period of the current arbitration frame is reached.
It is further preferred that the number of arbitration periods per arbitration frame is equal to the number of data buses.
Further preferably, the arbitration interface module is further configured to, in the process of sending the identifier to the arbitration bus, send the identifier using a coding result generated by a coding method different from that of the previous symbol when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an even number.
Further preferably, the arbitration interface module is further configured to, in the process of sending the identifier to the arbitration bus, send the identifier using an encoding result generated in the same encoding manner as the previous symbol when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an odd number.
Further preferably, the encoding results of the same symbol in different encoding modes are reflected on the arbitration bus, and the voltage difference of at least one arbitration line reaches the preset threshold.
The invention also provides a data transmission method adopting a special coding mode, which comprises the following steps: in the current arbitration time period of the current arbitration frame, a communication node with a data transmission requirement sends an identifier consisting of a plurality of symbols to the arbitration bus to participate in data transmission right competition selection of the data bus, wherein when the sent symbol is not the first symbol and is the same as the previous symbol, the coding result generated by a coding mode different from the previous symbol is adopted for sending; the communication node detects whether the identifier of the communication node is successfully sent; when the identifier is detected to be successfully sent, the communication node is a winner communication node of the time period, and sends own data to a target data bus in the next data frame, and meanwhile, the identifier is not sent in the current arbitration frame; when the identifier transmission failure is detected and the current arbitration period is not the last arbitration period of the current arbitration frame, the communication node retransmits the identifier onto the arbitration bus in the next arbitration period of the current arbitration frame until the identifier transmission is successful or the last arbitration period of the current arbitration frame has been reached.
It is further preferred that the number of arbitration periods per arbitration frame is equal to the number of data buses.
Further preferably, the sending an identifier composed of a plurality of symbols to the arbitration bus to participate in data transmission right election of the data bus further includes: and in the process of sending the identifier to the arbitration bus, when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an even number, sending the identifier by adopting a coding result generated by a coding mode different from the previous symbol.
Further preferably, the sending an identifier composed of a plurality of symbols to the arbitration bus to participate in data transmission right election of the data bus further includes: and in the process of sending the identifier to the arbitration bus, when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an odd number, the coding result generated by adopting the same coding mode as the previous symbol is sent.
Further preferably, the encoding results of the same symbol in different encoding modes are reflected on the arbitration bus, and the voltage difference of at least one arbitration line reaches the preset threshold.
The data transmission system adopting the special coding mode and the data transmission method adopting the special coding mode provided by the invention can bring at least one of the following beneficial effects:
1. the arbitration bus is separated from the data bus, so that the transmission rate of the data bus can be improved, and the transmission rate of the arbitration bus is reduced on the premise of ensuring the transmission rate of the data bus, so that the reliability of the system is improved;
2. the invention can reduce the transmission delay caused by collision and improve the transmission efficiency of the bus by providing a plurality of pairs of data buses and a plurality of arbitration opportunities in an arbitration frame;
3. the invention adopts the alternate sending of the coding results of the symbols under different coding modes when the same symbol is continuously sent, thereby improving the reliability of decoding and improving the anti-interference capability of the system.
Drawings
The above features, technical features, advantages and implementations of a data transmission system using a special coding scheme and a data transmission method using a special coding scheme will be further described in the following preferred embodiments in a clearly understandable manner with reference to the accompanying drawings.
FIG. 1 is a schematic diagram of an embodiment of a data transmission system using special coding according to the present invention;
FIG. 2 is a flow chart of one embodiment of a method for data transmission using special coding in accordance with the present invention;
fig. 3 is a flowchart of another embodiment of a data transmission method using a special coding scheme according to the present invention.
The reference numbers illustrate:
100. the system comprises an arbitration interface module, a control module and a data sending module, wherein the arbitration interface module comprises 200.
Detailed Description
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following description will be made with reference to the accompanying drawings. It is obvious that the drawings in the following description are only some examples of the invention, and that for a person skilled in the art, other drawings and embodiments can be derived from them without inventive effort.
For the sake of simplicity, the drawings only schematically show the parts relevant to the present invention, and they do not represent the actual structure as a product. In addition, in order to make the drawings concise and understandable, components having the same structure or function in some of the drawings are only schematically illustrated or only labeled. In this document, "one" means not only "only one" but also a case of "more than one".
In an embodiment of the present invention, as shown in fig. 1, a data transmission system using a special coding scheme includes: at least two pairs of data buses, wherein all the data buses transmit by taking a data frame as a unit; the arbitration buses transmit by taking arbitration frames as units, the transmission time of the arbitration frames is the same as that of the data frames, each arbitration frame comprises at least two arbitration time periods, and each arbitration time period arbitrates a winner communication node of the time period; and the communication nodes are respectively connected in parallel and hung on the data buses and the arbitration bus.
Specifically, an arbitration frame and a data frame on the CAN bus are multiplexed on the same bus in a time-sharing manner, and the arbitration frame limits the transmission rate of the data frame. In order to increase the transmission rate of the data bus, the arbitration bus is separated from the data bus in the present invention. Arbitration information is sent on an arbitration bus, data information is sent on a data bus, the data bus can adopt a completely different high-speed channel coding transmission scheme from the arbitration bus, the data bus has a higher symbol modulation rate to meet the high-speed transmission requirement, and the arbitration bus has a lower symbol modulation rate to ensure the arbitration reliability.
The bus structure shown in fig. 1 includes two pairs of data buses and one pair of arbitration buses, where the data bus 1 is formed by one pair of conductors, the data bus 2 is formed by the other pair of conductors, and the arbitration bus is formed by one pair of conductors. Fig. 1 is only an example of a bus structure, and the bus structure according to the present invention may also include three or more pairs of data buses, and increasing the number of data buses may improve the bus transmission rate and efficiency, and reduce the transmission delay due to collision; however, too many pairs of data buses increase the manufacturing cost, and in practical applications, a compromise between transmission efficiency and manufacturing cost is required.
The arbitration bus is transmitted according to arbitration frames, one arbitration frame comprises a plurality of arbitration time periods, each arbitration time period is the identifier sending time of each communication node, the communication nodes are arbitrated according to the priority of the identifiers when colliding, the arbitration bus arbitrates the identifiers of the communication nodes participating in data sending right competition in the arbitration time period, only the identifiers with high priority are presented on the arbitration bus, and the communication node corresponding to the identifier with high priority is the winner communication node of the arbitration time period.
The data bus is transmitted according to data frames, the transmission time of one data frame is the same as that of one arbitration frame, but the data volume transmitted in the same time is different, and the data volume of the data frame is larger than that of the arbitration frame, so that the transmission rate of the data bus is high. The arbitration frame with the same frame number may have the same start time as the data frame, or may have a fixed time offset, for example, the frame header of the data frame is delayed by a fixed time offset relative to the frame header of the arbitration frame with the same frame number.
Since there are at least 2 pairs of data buses, an arbitration frame contains at least 2 arbitration time periods for at least the 2-bit winning communication node to decide on data transmission for the next data frame. The number of arbitration periods contained in each arbitration frame is not less than the number of data buses, and may be equal to or greater than, if less than, the data buses are easily wasted.
During each arbitration period of each arbitration frame, the winning communication node will obtain the transmission right of the next data frame for transmitting one frame of data. The data frame comprises an identifier of the receiving equipment, so that the receiving equipment can identify whether the data is sent to the receiving equipment, and if so, the data is received; otherwise, the process is abandoned.
Each communication node includes:
the arbitration interface module 100 is configured to send an identifier composed of a plurality of symbols to the arbitration bus to participate in data transmission right competition of the data bus, where when the sent symbol is not the first symbol and is the same as the previous symbol, a coding result generated by a coding method different from that of the previous symbol is used for sending;
a data sending module 300, configured to send data of itself to a target data bus;
the control module 200 is used for controlling the arbitration interface module to send the identifier of the arbitration interface module to the arbitration bus in the current arbitration time period of the current arbitration frame when the data sending requirement of the arbitration interface module is detected; when detecting that the identifier is successfully sent, the communication node is a winning communication node in the time period, and controls the data sending module to send own data to a target data bus in the next data frame, and meanwhile, the identifier is not sent in the current arbitration frame; when the identifier transmission failure is detected and the current arbitration time period is not the last arbitration time period of the current arbitration frame, controlling the arbitration interface module to retransmit the identifier to the arbitration bus in the next arbitration time period of the current arbitration frame until the identifier transmission is successful or the last arbitration time period of the current arbitration frame is reached.
Specifically, each communication node has a unique identifier for identifying itself, and the identifier is composed of a plurality of symbols. Before sending data, each communication node must first send its own identifier on the arbitration bus, and after the own identifier is successfully sent on the arbitration bus, the communication node obtains the use authority of the target data bus, and then can send data on the next frame of the target data bus. The arbitration bus is transmitted according to arbitration frames, one arbitration frame at least comprises 2 arbitration time periods, and the arbitration time periods are used for the communication nodes to send identifiers. During each arbitration period, a communication node having a data transmission requirement can transmit each symbol of its own identifier onto the arbitration bus in bits before not obtaining the data transmission right.
For example, for a twisted pair with a bus voltage fluctuating between 0V and 7V, a level 0 is defined as below 0.5V, a level 1 is defined as between 0.5V and 1.5V, a level 2 is defined as between 1.5V and 2.5V, a level 3 is defined as between 2.5V and 3.5V, a level 4 is defined as between 3.5V and 4.5V, a level 5 is defined as between 4.5V and 5.5V, a level 6 is defined as between 5.5V and 6.5V, and a level 7 is defined as above 6.5V, and the pair of driving voltages (1,2) indicates that the driving voltage on the arbitration line 1 is level 1 and the driving voltage on the arbitration line 2 is level 2.
Each symbol of the identifier is a logical number, and each symbol is encoded to result in a corresponding drive voltage pair on the arbitration bus. Assuming that the voltage pair corresponding to the symbol 1 is (1,2), when the communication node transmits the symbol 1, the symbol 1 is encoded, the corresponding driving voltage pair (1,2) is found according to the mapping table of the symbol-driving voltage pair, and then the driving voltage pair is converted into corresponding driving voltages, such as (1v, 2v), through the arbitration interface module, the driving voltages are amplified respectively, and under the condition that the interface is turned on, the amplified voltages are conducted onto two arbitration lines, that is, the symbol 1 is successfully transmitted onto the arbitration bus. When judging whether the symbol is successfully sent to the arbitration bus, the communication node inquires actual voltages on two arbitration lines of the arbitration bus, removes a fixed amplification factor to obtain a driving voltage pair, and decodes the driving voltage pair to obtain a corresponding symbol, for example, a symbol 1 is obtained according to the driving voltage pair (1, 2).
In general, only one encoding method is used to convert symbols into driving voltage pairs, each symbol corresponds to a driving voltage pair, and different symbols correspond to different driving voltage pairs. When the same symbol is continuously transmitted, a symbol voltmeter different from the symbol voltmeter in which the previous symbol selects the driving voltage is selected, and the driving voltage is selected.
The coding mode is adopted to ensure that the voltage on at least one arbitration line has large fluctuation, the end of the transmission of an old symbol and the start of the transmission of a new symbol can be easily identified according to the fluctuation, and the functions of clock recovery and clock positioning can be realized according to the symbol jump. If only one coding mode is adopted, when the same symbols are continuously transmitted, because the coding results transmitted before and after are the same, the voltage on the corresponding arbitration line is not changed, when each communication node receives the symbols on the arbitration bus, the communication node cannot easily distinguish whether the communication node corresponds to one symbol or two same symbols, and the judgment error of the communication node is easily caused, and the competition of the data transmission right is influenced. The foregoing problems can be avoided and optimized by using two encoding schemes.
After the communication node sends a bit symbol of the identifier, monitoring the symbol on the arbitration bus; when the symbol on the arbitration bus is different from the symbol sent by the communication node, the sending of the identifier is considered to be failed, and the sending of the subsequent symbol of the identifier is stopped; when the symbol on the arbitration bus is the same as the symbol sent by the communication node, indicating that the communication node successfully sends the one-bit symbol of the identifier; if there are more symbols to send, continuing to send the next symbol of the identifier; when the communication node successfully transmits all symbols of the identifier, the transmission of the identifier is considered successful.
When a plurality of communication nodes send identifiers simultaneously, the communication nodes which can correctly send the identifiers to the arbitration bus obtain the wins of the arbitration at this time, become the wining communication nodes, obtain the use right of the next data frame of the target data bus, and stop sending own identifiers in the arbitration frame.
If the identifier transmission failure is detected and the current arbitration time period is not the last arbitration time period of the current arbitration frame, the communication node can continue to participate in subsequent arbitration, and continues to transmit the identifier to participate in data transmission right election of the data bus when the next arbitration time period of the current arbitration frame comes, namely continues to transmit the identifier to strive for obtaining the use right of the target data bus when the next arbitration time period becomes the current arbitration time period.
Example (c): the bus structure comprises 1 pair of arbitration buses and 3 pairs of data buses, each arbitration frame comprises 3 arbitration time periods, the winning communication node of each arbitration time period obtains the data transmission right of the target data bus corresponding to the arbitration time period, for example, the target data bus of the 1 st arbitration time period is the 1 st pair of data bus, the target data bus of the 2 nd arbitration time period is the 2 nd pair of data bus, the target data bus of the 3 rd arbitration time period is the 3 rd pair of data bus, the winning communication node of the 1 st arbitration period of the current arbitration frame obtains the transmission of the 1 st data frame to the data bus, the winning communication node of the 2 nd arbitration period obtains the transmission of the 2 nd data frame to the data bus, and the winning communication node of the 3 rd arbitration period obtains the transmission of the 3 rd data frame to the data bus.
If the communication node obtains arbitration success in the 1 st arbitration time period of the current arbitration frame, the communication node is the winning communication node of the arbitration time period, and obtains data transmission of the next data frame of the data bus in the 1 st arbitration time period, and meanwhile, the communication node stops continuously transmitting the identifier of the communication node in the current arbitration frame, namely, the communication node does not participate in arbitration of the 2 nd and 3 rd arbitration time periods of the current arbitration frame. In the arbitration frame, the communication node obtains the data sending opportunity and does not participate in the subsequent competition of the data bus, so that the opportunity can be given to other equipment, the fairness is increased, the utilization rate of the data line is increased, and the flexibility of the system is increased.
If the communication node does not obtain arbitration wins in the 1 st arbitration period of the current arbitration frame, the communication node can continue to participate in the 2 nd arbitration of the current arbitration frame, and resend its own identifier in the 2 nd arbitration period. If the 2 nd arbitration fails, the 3 rd arbitration of the current arbitration frame can also be participated. If the 2 nd arbitration is successful, the communication node obtains to send data in the 2 nd data frame of the data bus while not participating in the 3 rd arbitration.
Devices that do not contend successfully have multiple arbitration opportunities in one arbitration frame and can continue to transmit identifiers, and once contention succeeds, no identifiers are transmitted in the current arbitration frame for the purpose of giving other devices opportunities. At the next arbitration frame, all devices are again participating in arbitration.
Due to the fact that multiple pairs of data buses exist, multiple communication nodes can compete out to obtain the use right of the data buses in each arbitration frame, and therefore the transmission rate of the data buses is improved.
In another embodiment of the present invention, as shown in fig. 1, a data transmission system using a special coding scheme includes:
on the basis of the previous embodiment, the function of the arbitration interface module is added as follows:
the arbitration interface module 100 is further configured to, in the process of sending the identifier to the arbitration bus, send a coding result generated by a coding mode different from that of a previous symbol when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an even number; and when the transmitted symbol is not the first symbol and the sum of the transmitted symbol and the previous symbol is an odd number, the transmitted symbol is transmitted by adopting the coding result generated by the same coding mode as the previous symbol.
The coding results of the same symbol in different coding modes are reflected on the arbitration bus, and the voltage difference of at least one arbitration line reaches a preset threshold value.
Specifically, for example, assuming that the driving voltages have 8 levels, each corresponding to a level 0 to 7, as shown in table 1 (arbitration line driving voltage encoding table), a preferred encoding method is to select two groups of 16 voltage combinations from 64 voltage combinations, each corresponding to 16 symbols. The symbol transmission rule is as follows: if the sum of the current symbol and the previous symbol is an even number, the corresponding voltage in a group different from the previous symbol is output, namely if the last code uses the voltage value in the first group, the current code uses the corresponding voltage in the second group instead. If the sum of the current symbol and the previous symbol is odd, the corresponding voltage in the same group as the previous symbol is used, that is, if the last code uses the voltage value in the first group, the current code continues to use the corresponding voltage in the first group. Assuming that the previous symbol is 5, the first encoding method shown in table 1 is used, and the corresponding driving voltage pairs are (4,4), the driving voltage pairs corresponding to the current symbols sequentially 0 to 15 according to the symbol transmission rule of the present embodiment are shown in table 2.
By adopting the symbol sending rule in the embodiment, continuous sending of any two symbols corresponds to obvious voltage fluctuation on the arbitration bus, so that clock signals can be recovered in an asynchronous mode of each communication node, the symbols on the arbitration bus can be correctly identified, the decoding complexity is reduced, the decoding success rate is improved, and the anti-interference capability of a system is enhanced. The symbol sending rule is realized in a software mode on the conventional arbitration interface, and the cost is reduced compared with a hardware realization mode.
In an embodiment of the present invention, as shown in fig. 2, a data transmission method using a special coding scheme, the method is based on the data transmission system using a special coding scheme described in any of the foregoing embodiments, and includes:
step S100, in the current arbitration period of the current arbitration frame, a communication node having a data transmission requirement sends an identifier composed of a plurality of symbols to the arbitration bus to participate in data transmission right election of the data bus, wherein when the sent symbol is not the first symbol and is the same as the previous symbol, a coding result generated by a coding mode different from the previous symbol is used for sending.
Specifically, each communication node has a unique identifier for identifying itself, and the identifier is composed of one or more symbols. Before sending data, each communication node must first send its own identifier on the arbitration bus, and after the own identifier is successfully sent on the arbitration bus, the communication node obtains the use authority of the target data bus, and then can send data on the next frame of the target data bus. The arbitration bus is transmitted according to arbitration frames, one arbitration frame at least comprises 2 arbitration time periods, and the arbitration time periods are used for the communication nodes to send identifiers. During each arbitration period, the communication node having a data transmission request can transmit its identifier to the arbitration bus in bits before the communication node does not obtain the data transmission right.
For example, for a twisted pair with a bus voltage fluctuating between 0V and 7V, a level 0 is defined as below 0.5V, a level 1 is defined as between 0.5V and 1.5V, a level 2 is defined as between 1.5V and 2.5V, a level 3 is defined as between 2.5V and 3.5V, a level 4 is defined as between 3.5V and 4.5V, a level 5 is defined as between 4.5V and 5.5V, a level 6 is defined as between 5.5V and 6.5V, and a level 7 is defined as above 6.5V, and the pair of driving voltages (1,2) indicates that the driving voltage on the arbitration line 1 is level 1 and the driving voltage on the arbitration line 2 is level 2.
Each symbol of the identifier is a logical number, and each symbol is encoded to result in a corresponding drive voltage pair on the arbitration bus. Assuming that the voltage pair corresponding to the symbol 1 is (1,2), when the communication node transmits the symbol 1, the symbol 1 is encoded, the corresponding driving voltage pair (1,2) is found according to the mapping table of the symbol-driving voltage pair, and then the driving voltage pair is converted into corresponding driving voltages, such as (1v, 2v), through the arbitration interface module, the driving voltages are amplified respectively, and under the condition that the interface is turned on, the amplified voltages are conducted onto two arbitration lines, that is, the symbol 1 is successfully transmitted onto the arbitration bus. When judging whether the symbol is successfully sent to the arbitration bus, the communication node inquires actual voltages on two arbitration lines of the arbitration bus, removes a fixed amplification factor to obtain a driving voltage pair, and decodes the driving voltage pair to obtain a corresponding symbol, for example, a symbol 1 is obtained according to the driving voltage pair (1, 2).
In general, only one coding mode in the system converts symbols into driving voltage pairs, each symbol corresponds to a driving voltage pair one by one, and different symbols correspond to different driving voltage pairs. If only one coding mode is adopted, when the same symbols are continuously transmitted, because the coding results transmitted before and after are the same, the voltage on the corresponding arbitration line is not changed, when each communication node receives the symbols on the arbitration bus, the communication node cannot easily distinguish whether the communication node corresponds to one symbol or two same symbols, and the judgment error of the communication node is easily caused, and the competition of the data transmission right is influenced. The foregoing problems can be avoided by using two encoding schemes.
Step S200, the communication node detects whether the identifier of the communication node is successfully transmitted.
Specifically, after the communication node sends a bit symbol of the identifier, the communication node monitors the symbol on the arbitration bus; when the symbol on the arbitration bus is different from the symbol sent by the communication node, the sending of the identifier is considered to be failed, and the sending of the subsequent symbol of the identifier is stopped; when the symbol on the arbitration bus is the same as the symbol sent by the communication node, indicating that the communication node successfully sends the one-bit symbol of the identifier; if there are more symbols to send, continuing to send the next symbol of the identifier; when the communication node successfully transmits all symbols of the identifier, the transmission of the identifier is considered successful.
Step S300, when detecting that the identifier is successfully transmitted, the communication node is the winning communication node in the time period, and transmits its own data to the target data bus in the next data frame, while no longer transmitting the identifier in the current arbitration frame.
Step S400, when the identifier is detected to be failed to be sent, judging whether the current arbitration time period is the last arbitration time period of the current arbitration frame;
step S500 waits for the next arbitration period of the current arbitration frame to arrive when the current arbitration period is not the last arbitration period of the current arbitration frame, and then goes to step S100 until the identifier is successfully transmitted or the current arbitration period is the last arbitration period of the current arbitration frame.
Specifically, when a plurality of communication nodes simultaneously transmit identifiers, the communication node capable of correctly transmitting the identifiers to the arbitration bus obtains arbitration wins of the current arbitration time period, becomes a wining communication node, obtains the use right of the next data frame of the target data bus, and stops transmitting the identifier of the communication node in the arbitration frame.
If the identifier transmission failure is detected and the current arbitration time period is not the last arbitration time period of the current arbitration frame, the communication node can continue to participate in subsequent arbitration, and continues to transmit the identifier to participate in data transmission right election of the data bus when the next arbitration time period of the current arbitration frame comes, namely continues to transmit the identifier to strive for obtaining the use right of the target data bus when the next arbitration time period becomes the current arbitration time period.
Example (c): the bus structure comprises 1 pair of arbitration buses and 3 pairs of data buses, each arbitration frame comprises 3 arbitration time periods, the winning communication node of each arbitration time period obtains the data transmission right of the target data bus corresponding to the arbitration time period, for example, the target data bus of the 1 st arbitration time period is the 1 st pair of data bus, the target data bus of the 2 nd arbitration time period is the 2 nd pair of data bus, the target data bus of the 3 rd arbitration time period is the 3 rd pair of data bus, the winning communication node of the 1 st arbitration period of the current arbitration frame obtains the transmission of the 1 st data frame to the data bus, the winning communication node of the 2 nd arbitration period obtains the transmission of the 2 nd data frame to the data bus, and the winning communication node of the 3 rd arbitration period obtains the transmission of the 3 rd data frame to the data bus.
If the communication node obtains arbitration success in the 1 st arbitration time period of the current arbitration frame, the communication node is the winning communication node of the arbitration time period, and obtains data transmission of the next data frame of the data bus in the 1 st arbitration time period, and meanwhile, the communication node stops continuously transmitting the identifier of the communication node in the current arbitration frame, namely, the communication node does not participate in arbitration of the 2 nd and 3 rd arbitration time periods of the current arbitration frame. In the arbitration frame, the communication node obtains the data sending opportunity and does not participate in the subsequent competition of the data bus, so that the opportunity can be given to other equipment, and the fairness is increased.
If the communication node does not obtain arbitration wins in the 1 st arbitration period of the current arbitration frame, the communication node can continue to participate in the 2 nd arbitration of the current arbitration frame, and resend its own identifier in the 2 nd arbitration period. If the 2 nd arbitration fails, the 3 rd arbitration of the current arbitration frame can also be participated. If the 2 nd arbitration is successful, the communication node obtains to send data in the 2 nd data frame of the data bus while not participating in the 3 rd arbitration.
Devices that do not contend successfully have multiple arbitration opportunities in one arbitration frame and can continue to transmit identifiers, and once contention succeeds, no identifiers are transmitted in the current arbitration frame for the purpose of giving other devices opportunities. At the next arbitration frame, all devices are again participating in arbitration.
Due to the fact that multiple pairs of data buses exist, multiple communication nodes can compete out to obtain the use right of the data buses in each arbitration frame, and therefore the transmission rate of the data buses is improved.
In another embodiment of the present invention, as shown in fig. 3, a data transmission method using a special coding scheme includes:
on the basis of the previous embodiment, step S100 is replaced by steps S110, S120.
Step S110, in the current arbitration time period of the current arbitration frame, when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an even number, the communication node with the data sending requirement sends the coding result generated by a coding mode different from the previous symbol;
step S120 is to transmit the coding result generated by the communication node having the data transmission requirement by using the same coding method as the previous symbol when the transmitted symbol is not the first symbol and the sum of the transmitted symbol and the previous symbol is an odd number.
The coding results of the same symbol in different coding modes are reflected on the arbitration bus, and the voltage difference of at least one arbitration line reaches a preset threshold value.
Specifically, for example, assuming that the driving voltages have 8 levels, which correspond to levels 0 to 7, two encoding methods are preferred as shown in table 1 (arbitration line driving voltage encoding table), and two groups of 16 voltage combinations are selected from 64 voltage combinations, and correspond to 16 symbols. The symbol transmission rule is as follows: if the sum of the current symbol and the previous symbol is an even number, the corresponding voltage in a group different from the previous symbol is output, namely if the last code uses the voltage value in the first group, the current code uses the corresponding voltage in the second group instead. If the sum of the current symbol and the previous symbol is odd, the corresponding voltage in the same group as the previous symbol is used, that is, if the last code uses the voltage value in the first group, the current code continues to use the corresponding voltage in the first group. Assuming that the previous symbol is 5, the first encoding method shown in table 1 is used, and the corresponding driving voltage pairs are (4,4), the driving voltage pairs corresponding to the current symbols sequentially 0 to 15 according to the symbol transmission rule of the present embodiment are shown in table 2.
By adopting the symbol sending rule in the embodiment, continuous sending of any two symbols corresponds to obvious voltage fluctuation on the arbitration bus, so that clock signals can be recovered in an asynchronous mode of each communication node, the symbols on the arbitration bus can be correctly identified, the decoding complexity is reduced, the decoding success rate is improved, and the anti-interference capability of a system is enhanced. The symbol sending rule is realized in a software mode on the conventional arbitration interface, and the cost is reduced compared with a hardware realization mode.
TABLE 1
Figure BDA0002451463980000151
Figure BDA0002451463980000161
TABLE 2
Previous symbol Current symbol Driving voltage pair Previous symbol Current symbol Driving voltage pair
5 0 (0,0) 5 8 (2,0)
5 1 (7,1) 5 9 (5,3)
5 2 (0,2) 5 10 (2,2)
5 3 (7,3) 5 11 (5,5)
5 4 (0,4) 5 12 (2,4)
5 5 (7,5) 5 13 (5,7)
5 6 (0,6) 5 14 (2,6)
5 7 (7,7) 5 15 (5,1)
It should be noted that the above embodiments can be freely combined as necessary. The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.

Claims (10)

1. A data transmission system using a special coding scheme, comprising:
at least two pairs of data buses, wherein all the data buses transmit by taking a data frame as a unit;
a pair of arbitration buses for arbitration of the data buses; the arbitration bus takes arbitration frames as a unit for transmission, the transmission time of the arbitration frames is the same as that of the data frames, each arbitration frame comprises at least two arbitration time periods, and each arbitration time period arbitrates a winning communication node of the time period;
the communication nodes are respectively connected in parallel and hung on the data buses and the arbitration bus;
each communication node includes:
the arbitration interface module is used for sending an identifier consisting of a plurality of symbols to the arbitration bus so as to participate in data transmission right competition of the data bus, wherein when the sent symbol is not the first symbol and is the same as the previous symbol, the coding result generated by a coding mode different from the previous symbol is adopted for sending;
the data sending module is used for sending own data to a target data bus;
the control module is used for controlling the arbitration interface module to send the identifier of the arbitration interface module to the arbitration bus in the current arbitration time period of the current arbitration frame when the data sending requirement of the arbitration interface module is detected; when detecting that the identifier is successfully sent, the communication node is a winning communication node in the time period, and controls the data sending module to send own data to a target data bus in the next data frame, and meanwhile, the identifier is not sent in the current arbitration frame; when the identifier transmission failure is detected and the current arbitration time period is not the last arbitration time period of the current arbitration frame, controlling the arbitration interface module to retransmit the identifier to the arbitration bus in the next arbitration time period of the current arbitration frame until the identifier transmission is successful or the last arbitration time period of the current arbitration frame is reached.
2. The data transmission system according to claim 1, wherein:
the number of arbitration periods per arbitration frame is equal to the number of data buses.
3. The data transmission system according to claim 1 or 2, wherein:
and the arbitration interface module is further used for transmitting a coding result generated by a coding mode different from the previous symbol when the transmitted symbol is not the first symbol and the sum of the transmitted symbol and the previous symbol is an even number in the process of transmitting the identifier to the arbitration bus.
4. The data transmission system according to claim 3, wherein:
and the arbitration interface module is further used for transmitting the coding result generated by adopting the same coding mode as the previous symbol when the transmitted symbol is not the first symbol and the sum of the transmitted symbol and the previous symbol is an odd number in the process of transmitting the identifier to the arbitration bus.
5. The data transmission system according to claim 1, wherein:
the coding results of the same symbol in different coding modes are reflected on the arbitration bus, and the voltage difference of at least one arbitration line reaches a preset threshold value.
6. A data transmission method using a special coding scheme, which is applied to the data transmission system using a special coding scheme of claim 1, and comprises:
in the current arbitration time period of the current arbitration frame, a communication node with a data transmission requirement sends an identifier consisting of a plurality of symbols to the arbitration bus to participate in data transmission right competition selection of the data bus, wherein when the sent symbol is not the first symbol and is the same as the previous symbol, the coding result generated by a coding mode different from the previous symbol is adopted for sending;
the communication node detects whether the identifier of the communication node is successfully sent;
when the identifier is detected to be successfully sent, the communication node is a winner communication node of the time period, and sends own data to a target data bus in the next data frame, and meanwhile, the identifier is not sent in the current arbitration frame;
when the identifier transmission failure is detected and the current arbitration period is not the last arbitration period of the current arbitration frame, the communication node retransmits the identifier onto the arbitration bus in the next arbitration period of the current arbitration frame until the identifier transmission is successful or the last arbitration period of the current arbitration frame has been reached.
7. The data transmission method using special coding scheme according to claim 6, further comprising:
the number of arbitration periods per arbitration frame is equal to the number of data buses.
8. The method for data transmission with special encoding according to claim 6 or 7, wherein the sending an identifier composed of a plurality of symbols to the arbitration bus to participate in data transmission right election of the data bus further comprises:
and in the process of sending the identifier to the arbitration bus, when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an even number, sending the identifier by adopting a coding result generated by a coding mode different from the previous symbol.
9. The method as claimed in claim 8, wherein the sending an identifier composed of a plurality of symbols to the arbitration bus to participate in data transmission right election of the data bus further comprises:
and in the process of sending the identifier to the arbitration bus, when the sent symbol is not the first symbol and the sum of the sent symbol and the previous symbol is an odd number, the coding result generated by adopting the same coding mode as the previous symbol is sent.
10. The data transmission method using special coding scheme of claim 6, wherein:
the coding results of the same symbol in different coding modes are reflected on the arbitration bus, and the voltage difference of at least one arbitration line reaches a preset threshold value.
CN202010293916.6A 2020-04-15 2020-04-15 Data transmission system and method adopting special coding mode Pending CN111478841A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010293916.6A CN111478841A (en) 2020-04-15 2020-04-15 Data transmission system and method adopting special coding mode

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010293916.6A CN111478841A (en) 2020-04-15 2020-04-15 Data transmission system and method adopting special coding mode

Publications (1)

Publication Number Publication Date
CN111478841A true CN111478841A (en) 2020-07-31

Family

ID=71752576

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010293916.6A Pending CN111478841A (en) 2020-04-15 2020-04-15 Data transmission system and method adopting special coding mode

Country Status (1)

Country Link
CN (1) CN111478841A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116094867A (en) * 2023-04-10 2023-05-09 湖南鲸瓴智联信息技术有限公司 Time-sensitive network control protocol design method based on MLVDS bus

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0137609B1 (en) * 1983-09-27 1990-07-25 Trw Inc. Multi-master communication bus
EP0679275A1 (en) * 1993-01-14 1995-11-02 Apple Computer, Inc. A communication node with a first bus configuration for arbitration and a second bus configuration for data transfer
US5805836A (en) * 1996-12-10 1998-09-08 International Business Machines Corporation Method and apparatus for equalizing grants of a data bus to primary and secondary devices
CN1329446A (en) * 2001-03-28 2002-01-02 深圳市中兴集成电路设计有限责任公司 Method for implementing internal switched network in base station system and its system mechanism
CN1442795A (en) * 1996-06-27 2003-09-17 交互数字技术公司 Method and equipment for transmitting data parallelly on high speed data bus
CN1758622A (en) * 2005-11-11 2006-04-12 哈尔滨工业大学 Heterogeneous multi-bus data transmission method between information processing device
CN103218331A (en) * 2012-12-07 2013-07-24 浙江大学 Bus device and method by adopting synchronous mode switching and automatic adjustment of frame priority
CN103546355A (en) * 2013-11-01 2014-01-29 成都信息工程学院 Multi-master lossless bus competition technology
CN109905306A (en) * 2019-01-30 2019-06-18 北京深蓝同创科技有限公司 A kind of low cost multi-master bus communication control system

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0137609B1 (en) * 1983-09-27 1990-07-25 Trw Inc. Multi-master communication bus
EP0679275A1 (en) * 1993-01-14 1995-11-02 Apple Computer, Inc. A communication node with a first bus configuration for arbitration and a second bus configuration for data transfer
CN1442795A (en) * 1996-06-27 2003-09-17 交互数字技术公司 Method and equipment for transmitting data parallelly on high speed data bus
US5805836A (en) * 1996-12-10 1998-09-08 International Business Machines Corporation Method and apparatus for equalizing grants of a data bus to primary and secondary devices
CN1329446A (en) * 2001-03-28 2002-01-02 深圳市中兴集成电路设计有限责任公司 Method for implementing internal switched network in base station system and its system mechanism
CN1758622A (en) * 2005-11-11 2006-04-12 哈尔滨工业大学 Heterogeneous multi-bus data transmission method between information processing device
CN103218331A (en) * 2012-12-07 2013-07-24 浙江大学 Bus device and method by adopting synchronous mode switching and automatic adjustment of frame priority
CN103546355A (en) * 2013-11-01 2014-01-29 成都信息工程学院 Multi-master lossless bus competition technology
CN109905306A (en) * 2019-01-30 2019-06-18 北京深蓝同创科技有限公司 A kind of low cost multi-master bus communication control system

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
刘峰,葛霁光: "共享总线多微处理器系统中分布式仲裁方案的研究及实现", 《浙江大学学报(工学版)》 *
张超: "VME总线多通道数据采集系统的实现", 《中国优秀硕士学位论文全文数据库(电子期刊)·信息科技辑》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116094867A (en) * 2023-04-10 2023-05-09 湖南鲸瓴智联信息技术有限公司 Time-sensitive network control protocol design method based on MLVDS bus
CN116094867B (en) * 2023-04-10 2023-06-16 湖南鲸瓴智联信息技术有限公司 Time-sensitive network control protocol design method based on MLVDS bus

Similar Documents

Publication Publication Date Title
RU2597467C2 (en) Method and device for adaptation of reliability of data transmission in serial bus system
CN103218331B (en) Synchronous mode is adopted to switch and the self-adjusting bus unit of frame priority and method
RU2620989C2 (en) Method and apparatus for increasing throughput capacity in data transmission in serial bus system
CN105282209B (en) Network system for vehicle and data transmission method of heterogeneous communication controller therein
US5768301A (en) Apparatus and method for detecting and correcting pair swap, and implementing a link integrity function in a packet-based data communications system
RU2597502C2 (en) Method and device for memory size adapted serial data transfer
RU2597501C2 (en) Method and device for serial transmission of data with flexible size and variable bit length
US4608700A (en) Serial multi-drop data link
FI82991C (en) VALMEKANISM FOER TILLDELNING AV STYRNINGEN AV EN KOMMUNIKATIONSVAEG I ETT DIGITALT DATORSYSTEM.
RU2603534C2 (en) Method and device for serial data transmission having a flexible message size and a variable bit length
CN1192566C (en) Electronic apparatus with a bus
TWI672021B (en) Method for communicating data using variable data rate control protocol
CN111314191A (en) Data transmission system and method
CN108234267B (en) Communication system based on M-LVDS real-time multi-master high-speed bus
US10331610B2 (en) UART with automated protocols
CN112887152A (en) Train communication network architecture and method based on Ethernet and rail train
CN104995874A (en) Data transmission protocol with protocol exception state
CN111478841A (en) Data transmission system and method adopting special coding mode
CN111478842A (en) High-speed data transmission system and method
CN111314194A (en) Data transmission system and method based on multi-level logical operation
CN111478840A (en) Double-rate arbitration relay device for bus system
EP0237839A2 (en) Serial data bus for intermodule data communications and method of data arbitration and collision detection on a data bus
RU2602353C2 (en) Method and device for serial transmission of data with flexible size and variable bit length
CN111314192A (en) Method for transmitting data between high-speed bus structure and communication node
CN111314190A (en) Data transmission system and method with arbitration interface having reset function

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
AD01 Patent right deemed abandoned
AD01 Patent right deemed abandoned

Effective date of abandoning: 20220830