CN115225423B - Two-wire system device-to-device communication method based on polar Manchester code - Google Patents

Two-wire system device-to-device communication method based on polar Manchester code Download PDF

Info

Publication number
CN115225423B
CN115225423B CN202210870651.0A CN202210870651A CN115225423B CN 115225423 B CN115225423 B CN 115225423B CN 202210870651 A CN202210870651 A CN 202210870651A CN 115225423 B CN115225423 B CN 115225423B
Authority
CN
China
Prior art keywords
data
jump
polar
slave
bit
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
CN202210870651.0A
Other languages
Chinese (zh)
Other versions
CN115225423A (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.)
Sichuan Netop Telecom Co ltd
Original Assignee
Sichuan Netop Telecom 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 Sichuan Netop Telecom Co ltd filed Critical Sichuan Netop Telecom Co ltd
Priority to CN202210870651.0A priority Critical patent/CN115225423B/en
Publication of CN115225423A publication Critical patent/CN115225423A/en
Application granted granted Critical
Publication of CN115225423B publication Critical patent/CN115225423B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

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
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M5/00Conversion of the form of the representation of individual digits
    • H03M5/02Conversion to or from representation by pulses
    • H03M5/04Conversion to or from representation by pulses the pulses having two levels
    • H03M5/06Code representation, e.g. transition, for a given bit cell depending only on the information in that bit cell
    • H03M5/12Biphase level code, e.g. split phase code, Manchester code; Biphase space or mark code, e.g. double frequency code
    • 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/403Bus networks with centralised control, e.g. polling

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Theoretical Computer Science (AREA)
  • Dc Digital Transmission (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Abstract

The invention discloses a two-wire system inter-device communication method based on polar Manchester codes, which comprises the following steps: step one, sending query information with a head position zone bit to slave equipment at a master equipment; step two, after receiving the inquiry information, if the flag bit is detected and the data is 01, the slave device replies the data to the master device and stores the replied data information; and thirdly, the master equipment transmits broadcast data, and each slave equipment determines whether to decode the broadcast data by adopting improved polar Manchester encoding based on whether query information with a flag bit is received or not, so that corresponding data information is obtained, and further data communication of any two slave equipment is realized. The invention provides a two-wire system device-to-device communication method based on polar Manchester codes, which can enable one section of code to decode two groups of data through the improved polar Manchester codes, expand the application range and simplify the communication steps when two-wire system devices are in communication.

Description

Two-wire system device-to-device communication method based on polar Manchester code
Technical Field
The present invention relates to the field of data communications. More particularly, the invention relates to a two-wire system device-to-device communication method based on polar Manchester codes.
Background
Polar manchester encoding is a coding scheme that uses bit transitions to time, with data represented by a transition at the beginning of a data bit. The polar Manchester code has a level transition in the middle of each clock cycle, and the transition is used for synchronization. The data bit is indicated as "0" if the level transitions at the beginning of the data bit, and is indicated as "1" if the level does not transition at the beginning of the data bit. The detailed decoding rule is shown in table 1, and jump data in the truth table are data before and after the beginning of the data bit.
TABLE 1
One polarity Manchester encoding is shown in FIG. 4, and data 10011 is decoded according to the contents of the truth table. The advantage of polar Manchester encoding is that the receiving and transmitting parties can keep synchronous according to the clock signal of the encoding party, and a special circuit for transmitting the synchronous signal is not needed, so that the cost is low. Polar Manchester encoding is widely used in broadband high-speed networks at present, and a token local area network is the polar Manchester encoding, as shown in fig. 5, for standard communication between a master device and a plurality of slave devices, communication between a slave device A and a slave device B needs to be performed through a master device C, and the interaction flow is as follows:
s11, the master device sends a reset signal, and during the period, the master device judges whether a slave device is hung on a current bus;
s12, performing bus read operation, and the master device C reads data (a, alpha) from the slave device A from the bus 1 );
S13, performing bus write operation, writing data into the slave device B by the master device C, and receiving data alpha by the slave device B 1
S14, the master device sends a reset signal, and during the period, the master device judges whether a slave device is hung on the current bus;
s15, performing bus read operation, and the master device C reads the data (B, beta) from the slave device B from the bus 1 );
S16, performing bus write operation, writing data into the slave device A by the master device C, and receiving data beta from the slave device A 1
As shown in fig. 6, taking the interaction of the standard two-wire system by using the polar manchester code as an example, the interaction content includes:
1. data of the query slave a issued by the master C includes a command code and a device ID of a: 10011100; |
2. The data of the reply host C sent by the slave device a includes a command code and a device ID of a and a data packet to be transmitted: 1011110000101101;
3. writing data sent from the slave a to the slave B by the host C, including a command code and a slave ID of B and a packet: 1010001100101101;
4. data of the query slave B issued by the master C includes a command code and a device ID of B: 10010011;
5. the data of the reply host C sent by the slave device B, including the command code and the device ID of B and the data packet to be transmitted: 1011001111011001;
6. writing, by the host C, data sent from the slave B to the slave a, including a command code and a slave ID of a and a packet: 1010110011011001.
from the above, the message transmission between the slave devices needs to be performed 6 times by using the polar Manchester code, which increases the time cost of network communication, increases the data volume of transmission, and limits the efficiency and the speed.
Disclosure of Invention
It is an object of the present invention to address at least the above problems and/or disadvantages and to provide at least the advantages described below.
To achieve these objects and other advantages and in accordance with the purpose of the invention, a two-wire system device-to-device communication method based on a polar manchester code is provided, comprising:
step one, sending query information with a head position zone bit to slave equipment at a master equipment;
step two, after receiving the inquiry information, if the flag bit is detected and the data is 01, the slave device replies the data to the master device and stores the replied data information;
and thirdly, the master equipment transmits broadcast data, and each slave equipment determines whether to decode the broadcast data by adopting improved polar Manchester encoding based on whether query information with a flag bit is received or not, so that corresponding data information is obtained, and further data communication of any two slave equipment is realized.
Preferably, in the second step, the query information is configured to include a command code, a flag bit, and an ID of a corresponding slave device;
the reply data command code, the slave device ID and the data packet to be transmitted;
the broadcast information is configured to include a command code, a received data length, an ID of the interaction slave device, and a corresponding data packet.
Preferably, in the third step, if the decoding result is 1, the data of the transmitting-end slave device is determined, and if the decoding result is 2, the data of the receiving-end slave device is determined;
each slave device derives data information of other slave devices based on the decoding order and the data stored by itself.
Preferably, in the third step, the modified polar manchester code defines the transition data as the front and back levels at the beginning of the data bit, the intermediate transition data is the intermediate one-time level transition of each clock cycle, and the intermediate transition of the previous data refers to the intermediate level transition of the previous data clock cycle;
the three polarities of positive level, 0 level and negative level in the levels are marked by '1', '0', '1', and the modified polar Manchester encoding rule is that;
for decoding of the receiving end, different two-bit data exist, the decoding result 1 is provided as a result directly obtained according to the jump data, and the decoding result 2 is obtained by inverting the decoding data 1 according to the jump result;
when the data bit starts without level jump and the middle jump is 0-1 or 1-0, the decoding result 1 and the decoding result 1 are both 1;
when the data bit starts to have level jump and the intermediate jump is not 0-1 and 1-0, the decoding result 1 and the decoding result 1 are both 0;
when the data bit starts to be 0-1, the middle jump is 1-1, and the previous data middle jump is-1-0, the decoding result 1 is 1, and the decoding result 2 is 0;
when the data bit starts to be 0-1, the middle jump is-1, and the middle jump of the previous bit data is 1-0, the decoding result 1 is 1, and the decoding result 2 is 0.
The invention at least comprises the following beneficial effects: the communication method provided by the invention is based on the improved polar Manchester coding, so that two slave devices can communicate with each other under the condition of one master device and multiple slave devices.
Additional advantages, objects, and features of the invention will be set forth in part in the description which follows and in part will become apparent to those having ordinary skill in the art upon examination of the following or may be learned from practice of the invention.
Drawings
FIG. 1 is a schematic diagram showing the interaction of a two-wire system by modified polar Manchester encoding in accordance with one embodiment of the present invention;
FIG. 2 is a schematic diagram of the encoded data and decoding of FIG. 1;
FIG. 3 is a schematic diagram of a communication flow of the improved two-wire system of the present invention;
FIG. 4 is a schematic diagram of a polar Manchester encoding scheme in the prior art;
FIG. 5 is a schematic diagram of a standard two-wire system interaction flow in the prior art;
FIG. 6 is a schematic diagram showing the interaction of a two-wire system by polar Manchester encoding in the prior art.
Detailed Description
The present invention is described in further detail below with reference to the drawings to enable those skilled in the art to practice the invention by referring to the description.
The modified polar manchester code may represent three polarities, "0", "1", and "-1", with the levels being positive, 0, and negative in order. Hardware circuitry is currently supported to identify three levels, but this is not the subject of the present invention and is not described.
The improved differential Manchester encoding can obtain different two-bit data by decoding at a receiving end, the decoding result 1 is provided as a result directly obtained according to the jump data, and the decoding result 2 is obtained by inverting the decoding data 1 according to the jump result.
The improved polar Manchester code decoding truth table is shown in the following table, wherein jump data in the truth table are the front and back levels at the beginning of a data bit, and middle jump data are one level jump in the middle of each clock cycle. The intermediate transition of the previous bit data refers to the intermediate level transition of the previous bit data clock period, and two groups of decoding results can be obtained according to the transition data as shown in table 2.
TABLE 2
When there is no level jump at the beginning of the data bit and the intermediate jump is 0 to 1 or 1 to 0, the decoding result is 1, and when there is level jump at the beginning of the data bit and the intermediate jump is not 0 to 1 and 1 to 0, the decoding result is 0. There are two special cases, when the data bit starts to be 0 to 1, the middle jump is 1 to-1, and the previous data middle jump is-1 to 0, the decoding result 1 is 1, and the decoding result 2 is 0.
The invention further realizes the communication between the slave device and the slave device based on the improved polar Manchester encoding method on the basis that the master device and the slave device adopt polar Manchester encoding communication, and finally realizes the communication between any two devices, and the interaction flow is shown in the following figure 3.
In fig. 3, G is a master device, E and F are slave devices, in order to realize communication between specific devices, a flag bit is added to the transmission data at the head position of the transmission data, and when the data of the flag bit is 01 when the master device communicates with the slave device, the slave device will locally store the data transmitted to the master device in this communication and perform decoding of the modified polar manchester code when the next master device communicates with it. The decoding result 1 is specified as data of the equipment E, the decoding result 2 is specified as data of the equipment F, and the slave equipment can obtain data of other slave equipment according to the decoding sequence and the data stored by the slave equipment. In the figure, step 1-4 is the same as in the previous figure, step 5 is to send broadcast data to the master device G, and when E, F receives the data of the broadcast message, the data is received and decoded to obtain corresponding data, while other slave devices do not decode the data because the data with the flag bit is not received before.
Taking fig. 1 as an example, the interaction content after the modification by using the modified polar manchester code includes:
1. the data of the query slave E sent by the master device G includes a command code flag bit and a device ID of E: 10011100;
2. the data of the reply host G sent by the slave E, including the command code and the device ID of E and the data packet to be transmitted: 1011110000101101;
3. data of the query slave F issued by the master G includes a command code and a device ID of F: 10010011;
4. the data of the reply host G sent by the slave device F, including the command code and the device ID of F and the data packet to be transmitted: 1011001111011001;
5. the step uses modified polar Manchester encoding, the broadcast message sent by the main device G comprises a command code, a received data length, data sent by the device and the device G, and device IDs of the device E and the device F, and the decoding operation is carried out by the slave device E and the slave device F:
in step 5, improved polar Manchester encoding is applied, and the encoding in step 5 shown in FIG. 2 and two sets of digital signals obtained after decoding the encoded data are shown in Table 3 by the decoding process and decoding results obtained by the code hopping data in FIG. 2 and the truth table in the summary:
TABLE 3 Table 3
The slave a and the slave B can derive decoded data 1 and decoded data 2 according to the decoding order. After obtaining the decoded data 1 and the decoded data 2, comparing the two decoded results with the self-stored data, and discarding the decoded data results identical to the self-stored data to obtain the data transmitted from other slave devices except the self-stored data. After decoding the data sent from the slave device, this communication between the two slave devices is completed. Through the above interaction mode and interaction content, communication between the slave devices A, B is realized, which specifically includes obtaining address information of the opposite party and message content of the opposite party.
The invention improves the data coding method, the improved polar Manchester coding carries more information than one Byte of data of the polar Manchester coding, the improved polar Manchester coding changes the information interaction process between devices from 6 steps to 5 steps, and the improved polar Manchester coding carries more information, for example, when the data transmitted by the polar Manchester coding is 1Byte, the actually transmitted information is only 1Byte; and when the data transmitted by the modified polar Manchester code is 1Byte, the information actually transmitted is equivalent to 2 bytes. This reduces the number of interactions, saves the amount of transmission data, and improves the communication efficiency.
The above is merely illustrative of a preferred embodiment, but is not limited thereto. In practicing the present invention, appropriate substitutions and/or modifications may be made according to the needs of the user.
The number of equipment and the scale of processing described herein are intended to simplify the description of the present invention. Applications, modifications and variations of the present invention will be readily apparent to those skilled in the art.
Although embodiments of the invention have been disclosed above, they are not limited to the use listed in the specification and embodiments. It can be applied to various fields suitable for the present invention. Additional modifications will readily occur to those skilled in the art. Therefore, the invention is not to be limited to the specific details and illustrations shown and described herein, without departing from the general concepts defined in the claims and their equivalents.

Claims (3)

1. A two-wire system inter-device communication method based on polar manchester codes, comprising:
step one, sending query information with a head position zone bit to slave equipment at a master equipment;
step two, after receiving the inquiry information, if the flag bit is detected and the data is 01, the slave device replies the data to the master device and stores the replied data information;
step three, the main equipment sends broadcast data, and each slave equipment determines whether to decode the broadcast data by adopting improved polar Manchester encoding based on whether query information with a flag bit is received or not, so as to obtain corresponding data information, and further realize data communication of any two slave equipment;
in the third step, the modified polar manchester code defines the jump data as the front and back level of the beginning of the data bit, the middle jump data is the middle one level jump of each clock period, the middle jump of the previous bit data refers to the middle level jump of the previous bit data clock period;
the three polarities of positive level, 0 level and negative level in the levels are marked by '1', '0', '1', and the modified polar Manchester encoding rule is that;
for decoding of the receiving end, different two-bit data exist, the decoding result 1 is provided as a result directly obtained according to the jump data, and the decoding result 2 is obtained by inverting the decoding data 1 according to the jump result;
when the data bit starts without level jump and the middle jump is 0-1 or 1-0, the decoding result 1 and the decoding result 2 are both 1;
when the data bit starts to have level jump and the intermediate jump is not 0-1 and 1-0, the decoding result 1 and the decoding result 2 are both 0;
when the data bit starts to be 0-1, the middle jump is 1-1, and the middle jump of the previous bit data is-1-0, the decoding result 1 is 1, and the decoding result 2 is 0;
when the data bit starts to be 0-1, the middle jump is-1, and the middle jump of the previous bit data is 1-0, the decoding result 1 is 1, and the decoding result 2 is 0.
2. The two-wire system inter-device communication method based on the polar manchester code according to claim 1, wherein in the second step, the inquiry information is configured to include a command code, a flag bit, and an ID of a corresponding slave device;
the reply data is configured to include a command code, a slave device ID, and a data packet to be transmitted;
the broadcast information is configured to include a command code, a received data length, an ID of the interaction slave device, and a corresponding data packet.
3. The two-wire system inter-device communication method based on the polar manchester code according to claim 1, wherein in the third step, if the decoding result is 1, the data of the transmitting-end slave device is determined, and if the decoding result is 2, the data of the receiving-end slave device is determined;
each slave device derives data information of other slave devices based on the decoding order and the data stored by itself.
CN202210870651.0A 2022-07-22 2022-07-22 Two-wire system device-to-device communication method based on polar Manchester code Active CN115225423B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210870651.0A CN115225423B (en) 2022-07-22 2022-07-22 Two-wire system device-to-device communication method based on polar Manchester code

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210870651.0A CN115225423B (en) 2022-07-22 2022-07-22 Two-wire system device-to-device communication method based on polar Manchester code

Publications (2)

Publication Number Publication Date
CN115225423A CN115225423A (en) 2022-10-21
CN115225423B true CN115225423B (en) 2023-09-26

Family

ID=83613722

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210870651.0A Active CN115225423B (en) 2022-07-22 2022-07-22 Two-wire system device-to-device communication method based on polar Manchester code

Country Status (1)

Country Link
CN (1) CN115225423B (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5475818A (en) * 1992-03-18 1995-12-12 Aeg Transportation Systems, Inc. Communications controller central processing unit board
JPH11243405A (en) * 1998-02-26 1999-09-07 Nec Ic Microcomput Syst Ltd Asynchronous serial communication system
CN102761389A (en) * 2011-04-29 2012-10-31 财团法人工业技术研究院 Asynchronous master-slave serial communication system, data transmission method and control module
CN103823776A (en) * 2014-02-28 2014-05-28 上海晟矽微电子股份有限公司 Unibus in communication with master equipment and slave equipment and communication method
CN105099596A (en) * 2015-08-26 2015-11-25 武汉中元华电科技股份有限公司 In-system high-precision time synchronization method and device
CN109756303A (en) * 2019-03-04 2019-05-14 北方天穹信息技术(西安)有限公司 A kind of asynchronous Manchester code reception coding/decoding method of either simplex
CN110188581A (en) * 2019-05-31 2019-08-30 成都航空职业技术学院 Based on the multi-fork query tree RFID anti-collision method for improving Manchester's code
DE202019106055U1 (en) * 2018-11-13 2019-12-10 Semiconductor Components Industries, Llc Slave device for improving the data rate of a DSI3 bus
CN110753381A (en) * 2019-10-28 2020-02-04 南京邮电大学 Wireless multi-hop network coding-aware routing based on improved coding conditions and gain guarantee
CN114402576A (en) * 2019-09-24 2022-04-26 开利公司 System and method for transmitting and receiving Ethernet signals

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5475818A (en) * 1992-03-18 1995-12-12 Aeg Transportation Systems, Inc. Communications controller central processing unit board
JPH11243405A (en) * 1998-02-26 1999-09-07 Nec Ic Microcomput Syst Ltd Asynchronous serial communication system
CN102761389A (en) * 2011-04-29 2012-10-31 财团法人工业技术研究院 Asynchronous master-slave serial communication system, data transmission method and control module
CN103823776A (en) * 2014-02-28 2014-05-28 上海晟矽微电子股份有限公司 Unibus in communication with master equipment and slave equipment and communication method
CN105099596A (en) * 2015-08-26 2015-11-25 武汉中元华电科技股份有限公司 In-system high-precision time synchronization method and device
DE202019106055U1 (en) * 2018-11-13 2019-12-10 Semiconductor Components Industries, Llc Slave device for improving the data rate of a DSI3 bus
CN109756303A (en) * 2019-03-04 2019-05-14 北方天穹信息技术(西安)有限公司 A kind of asynchronous Manchester code reception coding/decoding method of either simplex
CN110188581A (en) * 2019-05-31 2019-08-30 成都航空职业技术学院 Based on the multi-fork query tree RFID anti-collision method for improving Manchester's code
CN114402576A (en) * 2019-09-24 2022-04-26 开利公司 System and method for transmitting and receiving Ethernet signals
CN110753381A (en) * 2019-10-28 2020-02-04 南京邮电大学 Wireless multi-hop network coding-aware routing based on improved coding conditions and gain guarantee

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于FPGA的MVBC帧收发器设计;丁青锋;朱其新;幸柒荣;魏耀南;;华东交通大学学报(第06期);全文 *

Also Published As

Publication number Publication date
CN115225423A (en) 2022-10-21

Similar Documents

Publication Publication Date Title
JPH0654912B2 (en) Coding method
US8724614B2 (en) Radio network communication system and protocol
CN104995873B (en) Data transmission using protocol exception state
KR100792772B1 (en) Data transmission method and apparatus
TWI251540B (en) System, method and device for autonegotiation
AU595437B2 (en) Universal protocol data receiver
JP5563165B2 (en) Method and apparatus for serial data transmission with switchable data rate
EP2966823A1 (en) Encoding and decoding methods and apparatuses of ethernet physical layer
CN105915311B (en) Subscriber station of a bus system and method for time-optimized transmission of data in a bus system
JPS6139744A (en) Optical data bus
CN115225423B (en) Two-wire system device-to-device communication method based on polar Manchester code
US4471485A (en) Method of protection against errors in transmission of radiotelegraph messages and a device for the application of said method
CN109756293B (en) Method for processing data in Ethernet and physical layer chip
CN113220607A (en) Data processing method based on FIFO
US4454383A (en) Asynchronous data transmission method and circuitry
CN109347605B (en) Encoding method, decoding method and device, and computer readable storage medium
CN114257334A (en) Data encoding method, data decoding method and communication device
US7180886B2 (en) Synchronized data communication on a one-wired bus
CN100385887C (en) Method and device for coding, transmitting and decoding digital data
US5128935A (en) Byte-wide repeat filter
US8687743B2 (en) Methods and apparatus for detecting and decoding adaptive equalization training frames
EP0923209B1 (en) Device and method for transmitting digital data
KR20110020205A (en) System and method for detection of multiple timing masters in a network
TW201310246A (en) Method and device for serial data transmission which is adapted to memory sizes
JP3516998B2 (en) Address information reading device

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
GR01 Patent grant
GR01 Patent grant