CN111147264B - Two-wire sensor communication device and method - Google Patents

Two-wire sensor communication device and method Download PDF

Info

Publication number
CN111147264B
CN111147264B CN201911342772.2A CN201911342772A CN111147264B CN 111147264 B CN111147264 B CN 111147264B CN 201911342772 A CN201911342772 A CN 201911342772A CN 111147264 B CN111147264 B CN 111147264B
Authority
CN
China
Prior art keywords
sensor
communication line
mcu
communication
positive
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
CN201911342772.2A
Other languages
Chinese (zh)
Other versions
CN111147264A (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.)
Sensylink Microelectronics Co ltd
Original Assignee
Shanghai Sensylink Microelectronics 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 Shanghai Sensylink Microelectronics Co ltd filed Critical Shanghai Sensylink Microelectronics Co ltd
Priority to CN201911342772.2A priority Critical patent/CN111147264B/en
Publication of CN111147264A publication Critical patent/CN111147264A/en
Application granted granted Critical
Publication of CN111147264B publication Critical patent/CN111147264B/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
    • H04L12/00Data switching networks
    • H04L12/02Details

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Arrangements For Transmission Of Measured Signals (AREA)

Abstract

The invention provides a two-wire sensor communication device and a method, comprising the following steps: the system comprises an MCU (microprogrammed control unit), a series resistor, a plurality of leads and one or more sensors; one end of the sensor is connected with one end of the series resistor in series to form a common end; a common end formed by connecting the resistor and the sensor in series is connected with the MCU through a lead; the other end of the series resistor is connected with one end of the microcontroller through a lead; the other end of the sensor is connected with the other end of the microcontroller through another wire. The circuit is simple and effective, the cost is low, the anti-interference performance is strong, the signal of the sensor can be transmitted in a long distance, and the MCU microcontroller occupies less resources. By designing an interface communication protocol of the sensor, a single sensor mode or a multi-sensor mode can be realized. Meanwhile, the transmission communication mode is not limited to a certain type of sensor, and can be realized by adding a corresponding protocol circuit into a corresponding sensor.

Description

Two-wire sensor communication device and method
Technical Field
The invention relates to the technical field of communication, in particular to a two-wire sensor communication device and a two-wire sensor communication method.
Background
In many circuit applications today, it is necessary to communicate the physical information of the sensor's measurements to the master for analysis processing. The communication scheme has the advantages of simple and effective structure, strong anti-interference capability, capability of realizing longer distance and low cost. The invention realizes the transmission of control signals to the positive communication line and the negative communication line by programming the MCU, and simultaneously receives signal pulses which are transmitted to the positive communication line and the negative communication line by modulating the self impedance by the sensor, and obtains the information of the sensor so as to realize the interactive communication. For passive sensors, the sensor may be energized by a positive communication line and a negative communication line, whereas for active sensors, no energy need be energized by a positive communication line and a negative communication line.
Generally, a sensor has 2 terminals, namely a P terminal and an N terminal, wherein the potential of the P terminal is greater than that of the N terminal. The sensor and the passive resistor are connected in series to realize voltage division. At the stage that the sensor sends a signal to the MCU controller, the sensor changes the impedance of the sensor by pulse type, and because the sensor is connected with the passive resistor in series for voltage division, the potential of a voltage division point can realize pulse potential along with the change of the pulse impedance of the sensor, and the MCU controller can read the pulse potential signal to realize the communication from the sensor to the MCU controller. Similarly, the MCU controller can also send signals to the sensor through the signal line to realize the communication of the MCU controller to the sensor. In addition, the terminal of the sensor connected with the passive resistor in series can be a P terminal or an N terminal.
Furthermore, a plurality of sensors can be connected in parallel to measure physical quantities and perform time-sharing communication, and different sensors transmit signals to the MCU in a time-sharing mode. The method is characterized in that 2 communication lines are shared by a plurality of different sensors and even different types of sensors, and measurement and communication are respectively carried out on the positive communication lines and the negative communication lines. When the sensors are connected in parallel, the P end of the sensor can be connected in series with the passive resistor, and the N end of the sensor can also be connected in series with the passive resistor. The signal may be represented by the accumulated number of differential pressure pulses at the P terminal and the N terminal, the width of the differential pressure pulses, a modulation signal, a duty ratio, or the like. And may also be an analog signal representation.
Patent document CN109855746 mentions a temperature value transmission device and method thereof, the device includes: the temperature sensor, the controller and connect the data line of temperature sensor and controller, ground wire. The temperature sensor, the controller, the data line and the ground wire jointly form a loop, wherein the temperature sensor is used for acquiring a temperature value, the data line is used for transmitting a pulse signal to the controller, and the number of the pulse signals is used for representing the temperature value. This device requires a fixed ground potential at one end and can only be used to transmit the temperature by means of the number of pulses. Furthermore, the invention can realize the simultaneous measurement of the physical quantity by connecting a plurality of sensors in parallel, and is beneficial to the sensing measurement of the physical quantity of the space field. The CN109855746 is only suitable for measuring temperature values, and the invention can simultaneously sense and measure various physical quantities, including humidity measurement, temperature and humidity measurement, pressure measurement, flow measurement, gas concentration measurement, light sensation measurement and the like. In addition, the passive resistor can be connected with the P end or the N end of the sensor in series through a novel active impedance changing mode and technology, and the application mode of the sensor is expanded.
Disclosure of Invention
In view of the shortcomings in the prior art, it is an object of the present invention to provide a two-wire sensor communication device and method.
According to the two-wire sensor communication device and the method provided by the invention, the two-wire sensor communication device comprises the following steps:
the system comprises an MCU (microprogrammed control unit), a series resistor, a plurality of leads and one or more sensors;
one end of the sensor is connected with one end of the series resistor in series to form a common end;
a common end formed by connecting the resistor and the sensor in series is connected with the MCU through a lead;
the other end of the series resistor is connected with one end of the microcontroller through a lead;
the other end of the sensor is connected with the other end of the microcontroller through another wire.
Preferably, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
a common end formed by connecting one end of the series resistor and one end of the sensor in series is connected to the MCU through a positive communication line;
the other end of the series resistor is connected with one end of the MCU through a lead;
and the N end of the sensor is connected to the other end of the MCU through a negative communication line.
Preferably, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance through pulse type, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line through voltage division;
the MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform.
Preferably, the voltage difference waveform includes 2 modes:
one mode is that the sensor only carries out one-time measurement after being informed by the MCU microcontroller to carry out measurement, signals are transmitted to the MCU microcontroller through 2-wire communication voltage difference waveforms after the measurement is finished, and communication transmission signals are only carried out once, the sensor stops working and enters a sleep mode after the communication is finished, and the sensor waits for the MCU microcontroller to be informed again to carry out the second-time physical quantity measurement and communication transmission;
the other mode is that after the sensor is informed by the MCU microcontroller to measure, signals are transmitted to the MCU microcontroller through 2-wire communication voltage difference waveforms, after signal transmission is completed, the sensor actively measures and transmits physical quantity signals again at intervals of a preset time, and until the MCU microcontroller informs the sensor to restart to measure and transmit new physical quantity.
Preferably, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
a common end formed by connecting one end of the series resistor and one end of the sensor in series is connected to the MCU through a positive communication line;
the other end of the series resistor is connected with one end of the MCU through a lead;
and the P end of the sensor is connected to the other end of the MCU through a positive communication line.
Preferably, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance through pulse type, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line through voltage division;
the MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform.
Preferably, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
one end of the plurality of sensors which are connected in parallel and one end of the series resistor are connected in series to form a common end, and then the common end is connected to the MCU through the positive communication line;
and the N end of the sensor is connected to the other end of the MCU through a negative communication line.
Preferably, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance through pulse type, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line through voltage division;
the MCU receives a measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform;
because a plurality of sensors are connected in parallel on the communication line at the same time, different sensors modulate the impedance of the sensors in sequence by presetting the communication sequence of different sensors, and therefore the measured signal values are transmitted to the MCU microcontroller in a communication way.
Preferably, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
one end of the plurality of sensors which are connected in parallel and one end of the series resistor are connected in series to form a common end, and then the common end is connected to the MCU through the positive communication line;
and the N end of the sensor is connected to the other end of the MCU through a negative communication line.
Preferably, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance through pulse type, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line through voltage division;
the MCU receives a measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform;
because a plurality of sensors are connected in parallel on the communication line at the same time, different sensors modulate the impedance of the sensors in sequence by presetting the communication sequence of different sensors, and therefore the measured signal values are transmitted to the MCU microcontroller in a communication way.
Compared with the prior art, the invention has the following beneficial effects:
according to the invention, a new sensor communication interface is designed by definition, the MCU controller is programmed, and 2 communication lines are utilized to connect the sensor and the passive resistor in series, so that the 2 pulse pressure differences between the positive communication line and the negative communication line are controlled by the MCU controller and the sensor together, and the mutual communication between the MCU controller and the sensor is realized. The new 2-wire communication mode saves the number of wires, does not need capacitors, is simple in MCU programming, reduces the occupation of MCU resources, simplifies the design, reduces the cost, increases the anti-interference capacity of communication, and can realize longer-distance communication.
The circuit is simple and effective, the cost is low, the anti-interference performance is strong, the signal of the sensor can be transmitted in a long distance, and the MCU microcontroller occupies less resources. By designing an interface communication protocol of the sensor, a single sensor mode or a multi-sensor mode can be realized. Meanwhile, the transmission communication mode is not limited to a certain type of sensor, and can be realized by adding a corresponding protocol circuit into a corresponding sensor.
Drawings
Other features, objects and advantages of the invention will become more apparent upon reading of the detailed description of non-limiting embodiments with reference to the following drawings:
fig. 1 is a schematic diagram of a series connection mode of a resistor and a P-terminal of a single sensor provided by the present invention.
Fig. 2 is a schematic diagram of a series connection mode of a resistor and an N terminal of a single sensor according to the present invention.
Fig. 3 is a diagram of a specific single VP-VN voltage difference communication waveform according to the present invention.
Fig. 4 is a diagram of a specific multiple VP-VN voltage difference communication waveform according to the present invention.
FIG. 5 is a schematic diagram of a series connection of a resistor and a P-terminal of a multi-sensor according to the present invention.
Fig. 6 is a schematic diagram of a series connection mode of a resistor and an N-terminal of a multi-sensor according to the present invention.
Fig. 7 is a diagram illustrating VP-VN voltage difference communication waveforms for a specific multi-sensor parallel connection according to the present invention.
Detailed Description
The present invention will be described in detail with reference to specific examples. The following examples will assist those skilled in the art in further understanding the invention, but are not intended to limit the invention in any way. It should be noted that it would be obvious to those skilled in the art that various changes and modifications can be made without departing from the spirit of the invention. All falling within the scope of the invention.
According to the two-wire sensor communication device and the method provided by the invention, the two-wire sensor communication device comprises the following steps:
the system comprises an MCU (microprogrammed control unit), a series resistor, a plurality of leads and one or more sensors;
one end of the sensor is connected with one end of the series resistor in series to form a common end;
a common end formed by connecting the resistor and the sensor in series is connected with the MCU through a lead;
the other end of the series resistor is connected with one end of the microcontroller through a lead;
the other end of the sensor is connected with the other end of the microcontroller through another wire.
Specifically, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
a common end formed by connecting one end of the series resistor and one end of the sensor in series is connected to the MCU through a positive communication line;
the other end of the series resistor is connected with one end of the MCU through a lead;
and the N end of the sensor is connected to the other end of the MCU through a negative communication line.
Specifically, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance by pulse, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line by voltage division;
the MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform.
Specifically, the voltage difference waveform includes 2 modes:
one mode is that the sensor only carries out one-time measurement after being informed by the MCU microcontroller to carry out measurement, signals are transmitted to the MCU microcontroller through 2-wire communication voltage difference waveforms after the measurement is finished, and communication transmission signals are only carried out once, the sensor stops working and enters a sleep mode after the communication is finished, and the sensor waits for the MCU microcontroller to be informed again to carry out the second-time physical quantity measurement and communication transmission;
the other mode is that after the sensor is informed by the MCU microcontroller to measure, signals are transmitted to the MCU microcontroller through 2-wire communication voltage difference waveforms, after signal transmission is completed, the sensor actively measures and transmits physical quantity signals again at intervals of a preset time, and until the MCU microcontroller informs the sensor to restart to measure and transmit new physical quantity.
Specifically, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
a common end formed by connecting one end of the series resistor and one end of the sensor in series is connected to the MCU through a positive communication line;
the other end of the series resistor is connected with one end of the MCU through a lead;
and the P end of the sensor is connected to the other end of the MCU through a positive communication line.
Specifically, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance through pulse type, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line through voltage division;
the MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform.
Specifically, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
one end of the plurality of sensors after being connected in parallel and one end of the series resistor are connected in series to form a common end, and then the common end is connected to the MCU through the positive communication line;
and the N end of the sensor is connected to the other end of the MCU through a negative communication line.
Specifically, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance by pulse, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line by voltage division;
the MCU receives a measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform;
because a plurality of sensors are connected in parallel on the communication line at the same time, different sensors modulate the impedance of the sensors in sequence by presetting the communication sequence of different sensors, and therefore the measured signal values are transmitted to the MCU microcontroller in a communication way.
Specifically, the plurality of wires are respectively a positive communication line, a negative communication line and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
one end of the plurality of sensors after being connected in parallel and one end of the series resistor are connected in series to form a common end, and then the common end is connected to the MCU through the positive communication line;
and the N end of the sensor is connected to the other end of the MCU through a negative communication line.
Specifically, the MCU microcontroller transmits a signal to the sensor by varying the voltage between the positive and negative communication lines;
the sensor changes the self impedance through pulse type, and because the self impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line through voltage division;
the MCU receives a measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform;
because a plurality of sensors are connected in parallel on the communication line at the same time, different sensors modulate the impedance of the sensors in sequence by presetting the communication sequence of different sensors, and therefore the measured signal values are transmitted to the MCU microcontroller in a communication way.
The present invention will be described more specifically below with reference to preferred examples.
Preferred embodiment 1:
the mode of the resistor and the P end of the single sensor in series connection is shown in figure 1.
As shown in the serial connection mode of the resistor and the P end of the single sensor in FIG. 1, the serial connection mode comprises 3 elements and 3 leads, wherein the 3 elements are an MCU (microprogrammed control Unit) I11, a sensor I12 and a serial resistor R11 respectively. The 3 wires are a positive communication line N11, a negative communication line N12 and a resistance return line N13, respectively. The sensor has 2 terminals, P terminal and N terminal respectively. Fig. 1 shows the mode of operation of the series resistor at the P-terminal of the sensor. And the positive communication line N11 is connected with a common end formed by connecting a resistor and a sensor in series and is connected to the MCU. And the end N of the sensor is connected to the other end of the MCU through a negative communication line N12. The MCU microcontroller transmits a signal to the sensor by changing the voltage between the positive communication line N11 and the negative communication line N12, for example by informing the sensor of a measurement of a physical quantity. In addition, the sensor changes its own impedance by a pulse, and since the sensor impedance is connected in series with the resistor R11, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line by voltage division. The MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform. This enables 2-wire communication between the MCU microcontroller I11 and the sensor.
Further, the 2-wire communication voltage difference waveform may have 2 modes. One mode is that the sensor obtains MCU microcontroller notice and measures the back, only carries out once physical measurement, measures and transmits the signal to MCU microcontroller through 2 line communication voltage wave forms after accomplishing, and the communication transmission signal only carries out once, and the sensor stop work and enter the dormancy mode after the communication is accomplished, waits for MCU microcontroller's notice once more and carries out physical measurement and communication transmission once more. The other mode is that after the sensor is informed by the MCU microcontroller to measure, the signal is transmitted to the MCU microcontroller through the 2-wire communication voltage waveform, after the signal transmission is finished, the sensor actively measures and transmits the physical quantity signal again at intervals, and the process is repeated in this way until the MCU microcontroller informs the sensor to restart to measure and transmit new physical quantity. The transmission of such physical quantities is likewise effected by the sensor actively changing its own impedance.
By designing different sensors to change the mode of their own impedance, different voltage waveforms can be realized between the positive communication line and the negative communication line. The signal may be represented by the number of accumulated differential pressure pulses, the width of the differential pressure pulses, a modulated signal, a duty ratio, an analog signal, an analog pulse waveform, or the like.
One specific implementation of the voltage difference waveform is the single VP-VN voltage difference communication waveform shown in fig. 3. The MCU microcontroller reduces the differential pressure between the positive and negative communication lines by less than a threshold for more than a threshold time. The sensor reads that the signal is a signal for measuring the physical quantity, and after the MCU microcontroller releases the positive communication line and the negative communication line, the sensor obtains a command for measuring the physical quantity, and the physical quantity is measured by using the time of tcon. After the measurement is finished, the sensor modulates the impedance of the sensor and continuously transforms the impedance of the sensor so as to change the voltage difference waveform between the positive communication line and the negative communication line, and the MCU microcontroller reads and analyzes the voltage difference waveform between the positive communication line and the negative communication line so as to obtain the measurement value of the sensor. Fig. 3 shows a specific manner of modulating the self-impedance of the sensor, and specifically, the self-impedance is modulated to alternate between hundreds of K ohms and above and tens of ohms and below, so that the voltage difference between the positive communication line and the negative communication line can be in the form of a digital signal. The MCU micro-sensor reads the voltage difference waveform and then analyzes and processes the voltage difference waveform to obtain a measured physical quantity value of the sensor. More specifically, a simple implementation manner is that the sensor modulates its own impedance by a fixed period and a fixed width, so that the number of times of impedance transformation of the sensor is in direct proportion to the physical quantity to be tested, and thus, the physical quantity to be tested is in direct proportion to the number of pulses of the voltage difference waveform, and in this way, the MCU microcontroller can obtain the physical quantity measurement value of the sensor by accumulating and counting. In addition, the impedance of the sensor can be modulated in other orders, so that analog pulses can be realized by dividing voltage with the resistor, and in addition, the sensor can realize faster communication by modulating the self impedance through other non-fixed periods and non-fixed widths.
Another specific implementation of the voltage difference waveform is a multiple VP-VN voltage difference communication waveform shown in fig. 4. The MCU microcontroller reduces the differential pressure between the positive and negative communication lines by less than a threshold for more than a threshold time. The sensor reads that the signal is a signal for measuring the physical quantity, and after the MCU microcontroller releases the positive communication line and the negative communication line, the sensor obtains a command for measuring the physical quantity, and the physical quantity is measured by using the time of tcon. After the measurement is finished, the sensor continuously transforms the impedance of the sensor by modulating the impedance of the sensor, so that the voltage difference waveform between the positive communication line and the negative communication line is changed, and the MCU microcontroller reads and analyzes the voltage difference waveform between the positive communication line and the negative communication line, so that the measured value of the sensor is obtained. As shown in fig. 4, which is a specific continuous multiple VP-VN voltage difference communication waveform, the sensor performs 2-wire communication transmission by periodically measuring a physical quantity and modulating its own impedance, so that the sensor can continuously measure the physical quantity and transmit it to the MCU microprocessor for reading processing. More specifically, after the first measurement and communication transmission, the communication transmission may be disabled for one or more periods (2 null periods are shown in fig. 4), which may allow the MCU to better read and analyze the first measured physical quantity and allow more time for the MCU microprocessor to reset the counter.
The mode of the resistor and the N end of the single sensor in series connection is shown in figure 2.
Like the resistor and single sensor P end series mode, the resistor and single sensor N end series mode in fig. 2 also includes 3 elements and 3 wires, where the 3 elements are the MCU microcontroller I21, the sensor I22 and the series resistor R21, respectively. The 3 wires are a positive communication line N21, a negative communication line N22 and a resistance return line N23, respectively. The sensor has 2 terminals, P terminal and N terminal respectively. Fig. 2 is an operation mode of the N-terminal series resistor of the sensor. The negative communication line N22 is connected with a common end formed by connecting a resistor and a sensor in series and is connected to the MCU microcontroller. And the P end of the sensor is connected to the other end of the MCU through a positive communication line N21. The MCU microcontroller transmits a signal to the sensor by changing the voltage between the positive communication line N21 and the negative communication line N22, such as by informing the sensor to perform a test of the physical quantity once. In addition, the sensor changes its own impedance by a pulse, and since the sensor impedance is connected in series with the resistor R21, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line by voltage division. The MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform. This enables 2-wire communication between the MCU microcontroller I21 and the sensor I22.
The mode of the resistor and the P end of the multi-sensor in series connection is shown in figure 5.
Fig. 5 shows a resistor and multi-sensor P-terminal series mode, which includes a plurality of elements and 3 wires, wherein the plurality of elements are an MCU microcontroller I31, sensors I32 and even more sensors such as I33 and I34, and a series resistor R31. The 3 wires are a positive communication line N31, a negative communication line N32 and a resistance return line N33, respectively. The sensor has 2 terminals, P terminal and N terminal respectively. Fig. 5 is an operating mode of the series resistance of the P-terminal of the sensor. The positive communication line N31 is connected with a common end formed by connecting the plurality of sensors in parallel and then in series with the resistor and is connected to the MCU. And the end N of the sensor is connected to the other end of the MCU through a negative communication line N32. The MCU microcontroller transmits a signal to the sensor by changing the voltage between the positive communication line N31 and the negative communication line N32, such as by informing the sensor to perform a test of the physical quantity once through this signal. In addition, the sensor changes its own impedance in a pulse manner, and since the sensor impedance is connected in series with the resistor R31, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line by voltage division. The MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform. This enables 2-wire communication between the MCU microcontroller I31 and the sensor. Because a plurality of sensors are connected in parallel on the communication line at the same time, different sensors modulate the impedance of the sensors in sequence by presetting the communication sequence of different sensors, and therefore the measured signal values are transmitted to the MCU microcontroller in a communication way.
Similarly, fig. 6 shows a resistor and multi-sensor N-terminal series mode, which includes a plurality of elements and 3 wires, the plurality of elements are an MCU microcontroller I41, sensors I42 and I43 and I44, and even more sensors, respectively, and a series resistor R41. The 3 wires are a positive communication line N41, a negative communication line N42, and a resistive return line N43, respectively. The sensor has 2 terminals, P terminal and N terminal respectively. Fig. 6 is an operating mode of the N-terminal series resistance of the sensor. The negative communication line N42 is connected with a common end formed by connecting the multi-sensor in parallel and then connecting the multi-sensor in series with a resistor, and is connected to the MCU. The end P of the sensor is connected to the other end of the MCU through a positive communication line N41. The MCU microcontroller transmits a signal to the sensor by changing the voltage between the positive communication line N41 and the negative communication line N42, such as by informing the sensor to perform a test of the physical quantity once through this signal. In addition, the sensor changes its own impedance in a pulse manner, and since the sensor impedance is connected in series with the resistor R31, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line by voltage division. The MCU microcontroller receives the measuring signal transmitted by the sensor by reading and analyzing the voltage difference waveform. This enables 2-wire communication between the MCU microcontroller I41 and the sensor. Because a plurality of sensors are connected in parallel on the communication line at the same time, different sensors modulate the impedance of the sensors in sequence by presetting the communication sequence of different sensors, and therefore the measured signal values are transmitted to the MCU microcontroller in a communication way.
The invention relates to a specific VP-VN voltage difference communication waveform of a multi-sensor parallel connection, which is shown in figure 7.
Fig. 7 is a diagram of a specific multi-sensor parallel VP-VN voltage difference communication waveform. The MCU microcontroller reduces the differential pressure between the positive and negative communication lines by less than a threshold for more than a threshold time. The sensor reads that the signal is a signal for measuring the physical quantity, and after the MCU microcontroller releases the positive communication line and the negative communication line, the sensor obtains a command for measuring the physical quantity, and the physical quantity is measured by using the time of tcon. Thereafter, the different sensors sequentially modulate their own impedances, and the transformed impedances form a transformed voltage difference waveform due to the series voltage division relationship with the resistors. Each sensor occupies different communication transmission time intervals for transmission respectively, the transmission sequence is preset in the sensor, if the sensors in a certain sequence are absent, even other sensors are absent and only one sensor is connected between the positive and negative communication lines, the positive and negative communication lines do not carry out communication transmission in the corresponding time intervals and wait for the transmission of communication to the sensors existing on the communication lines. Thus, the MCU microcontroller can respectively judge the physical quantity transmitted by each sensor.
Specifically, fig. 7 is a specific case of implementing a transmission in which the physical value is proportional to the value of the pulse whose amplitude value is related to the value of the sensor modulation impedance, and when the sensor modulation self impedance amplitude is large, the voltage difference waveform on the communication line can be regarded as a digital signal, and the MCU microsensor reads and counts the digital signal, thereby reading out the measured physical value. When the self impedance amplitude modulated by the sensor is close to the resistance value of the passive resistor in magnitude, the transmission communication can be realized by simulating pulse voltage difference waveform.
Another implementation could be that different sensors do not measure simultaneously, but rather one sensor measures and communicates sequentially, followed by a second sensor, followed by a third people sensor, followed by other sensors.
Preferred example 2:
the sensor communication device comprises a sensor, an MCU controller, 2 communication data lines and a passive resistor. The device realizes bidirectional communication by mutually transmitting and receiving differential pressure pulses between the MCU and the sensor, and the specific differential pressure signal is realized by pulling the MCU and modulating the self impedance of the sensor. Specifically, the 2 communication lines are a positive communication line and a negative communication line respectively, generally, the voltage of the positive communication line is greater than that of the negative communication line, and the pressure difference signal of the positive communication line and the negative communication line carries communication information to be transmitted along with the change of time. The communication information may be simply expressed by the number of accumulated differential pressure pulses, expressed by the width of the differential pressure pulses, expressed by a modulation signal, expressed by a duty ratio, or the like. The amplitude of the difference voltage pulse may be a pulse consisting of 0V and the amplitude of the MCU supply voltage representing 0 or 1, or may be an intermediate analog voltage pulse between 0V and the MCU supply voltage. The sensor also has 2 ends, namely a P end and an N end, wherein the P end is connected with the positive communication line, and the N end is connected with the negative communication line. The sensor can be powered without a power supply or can be powered by a power supply. In addition, the sensor can be applied to measurement of various physical quantities, such as measurement of humidity, measurement of temperature and humidity, measurement of pressure, measurement of flow rate, measurement of gas concentration, measurement of light sensation, and the like. The passive resistor and the sensor form voltage division, and the voltage waveform of a voltage division node is read and controlled by the MCU controller, so that the communication information of the sensor is controlled and read. The invention has simple and effective structure, strong anti-interference capability, capability of realizing long-distance communication and low cost.
In the description of the present application, it is to be understood that the terms "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", and the like indicate orientations or positional relationships based on those shown in the drawings, and are only for convenience in describing the present application and simplifying the description, but do not indicate or imply that the referred device or element must have a specific orientation, be constructed in a specific orientation, and be operated, and thus, should not be construed as limiting the present application.
Those skilled in the art will appreciate that, in addition to implementing the systems, apparatus, and various modules thereof provided by the present invention in purely computer readable program code, the same procedures can be implemented entirely by logically programming method steps such that the systems, apparatus, and various modules thereof are provided in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Therefore, the system, the device and the modules thereof provided by the present invention can be considered as a hardware component, and the modules included in the system, the device and the modules thereof for implementing various programs can also be considered as structures in the hardware component; modules for performing various functions may also be considered to be both software programs for performing the methods and structures within hardware components.
The foregoing description has described specific embodiments of the present invention. It is to be understood that the present invention is not limited to the specific embodiments described above, and that various changes or modifications may be made by one skilled in the art within the scope of the appended claims without departing from the spirit of the invention. The embodiments and features of the embodiments of the present application may be combined with each other arbitrarily without conflict.

Claims (2)

1. A two-wire sensor communication device, comprising:
the system comprises an MCU (microprogrammed control unit), a series resistor, a plurality of leads and one or more sensors;
the plurality of conducting wires are respectively a positive communication wire, a negative communication wire and a resistance return line;
the sensor is provided with 2 terminals, namely a P terminal and an N terminal;
one end of the plurality of sensors after being connected in parallel and one end of the series resistor are connected in series to form a common end;
the other end of the series resistor is connected with one end of the MCU through a resistor loop line;
the public end is connected to the other end of the MCU through a positive communication line, and the N end of the sensor is connected to the other end of the MCU through a negative communication line; or
The public end is connected to the other end of the MCU through a negative communication line, and the P end of the sensor is connected to the other end of the MCU through a positive communication line;
the MCU microcontroller transmits signals to the sensor by changing the voltage between the positive communication line and the negative communication line;
the sensor changes the impedance of the sensor in a pulse mode to be alternately changed between hundreds of K ohms and above and dozens of ohms and below, and because the impedance of the sensor is connected with the series resistor in series, a voltage difference waveform carrying information is formed between the positive communication line and the negative communication line through voltage division; the MCU receives a measuring signal transmitted by the sensor by reading and analyzing a voltage difference waveform, and obtains a physical quantity measuring value of the sensor by accumulating and counting;
the sensor modulates the self impedance through a fixed period and a fixed width, the times of self impedance transformation is in direct proportion to the tested physical quantity, and the tested physical quantity is in direct proportion to the number of pulses of the voltage difference waveform;
the MCU microcontroller reads a signal for carrying out physical quantity measurement by reducing the pressure difference between the positive communication line and the negative communication line to be smaller than a threshold value and continuously exceed a threshold value for a time, and after the MCU microcontroller releases the positive communication line and the negative communication line, the sensor obtains a command for carrying out physical quantity measurement and uses the time of tcon to carry out physical quantity measurement;
different sensors modulate own impedance in sequence, due to the series voltage division relation with the resistor, the transformed impedance forms a transformed voltage difference waveform, each sensor occupies different communication transmission time periods to transmit respectively, the transmission sequence is preset in the sensor, other sensors are all absent, only one sensor is connected between a positive communication line and a negative communication line, the positive communication line and the negative communication line do not carry out communication transmission in the corresponding time period but wait for the transmission communication of the sensor existing on the communication line, and therefore the MCU microcontroller can judge the physical quantity value transmitted by each sensor respectively.
2. The two-wire sensor communication device of claim 1, wherein the voltage difference waveform includes 2 modes:
one mode is that the sensor only carries out one-time measurement after being informed by the MCU microcontroller to carry out measurement, signals are transmitted to the MCU microcontroller through 2-wire communication voltage difference waveforms after the measurement is finished, and communication transmission signals are only carried out once, the sensor stops working and enters a sleep mode after the communication is finished, and the sensor waits for the MCU microcontroller to be informed again to carry out the second-time physical quantity measurement and communication transmission;
the other mode is that after the sensor is informed by the MCU microcontroller to measure, the signal is transmitted to the MCU microcontroller through 2-wire communication voltage difference waveform, after the signal transmission is finished, the sensor actively measures and transmits the physical quantity signal again at intervals of a preset time until the MCU microcontroller informs the sensor to restart to measure and transmit new physical quantity.
CN201911342772.2A 2019-12-23 2019-12-23 Two-wire sensor communication device and method Active CN111147264B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911342772.2A CN111147264B (en) 2019-12-23 2019-12-23 Two-wire sensor communication device and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911342772.2A CN111147264B (en) 2019-12-23 2019-12-23 Two-wire sensor communication device and method

Publications (2)

Publication Number Publication Date
CN111147264A CN111147264A (en) 2020-05-12
CN111147264B true CN111147264B (en) 2022-10-25

Family

ID=70519531

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911342772.2A Active CN111147264B (en) 2019-12-23 2019-12-23 Two-wire sensor communication device and method

Country Status (1)

Country Link
CN (1) CN111147264B (en)

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW200530566A (en) * 2004-03-05 2005-09-16 Hitachi Ind Equipment Sys Method for detecting temperature of semiconductor element and semiconductor power converter
WO2009052616A1 (en) * 2007-10-23 2009-04-30 Magna International Inc. Two wire digital ultrasonic sensor using bi-directional power line communication
CN201697690U (en) * 2009-07-31 2011-01-05 佛山市中协电器有限公司 Capacitive sensing liquid level sensor
CN102169029B (en) * 2011-05-04 2014-02-26 山西中谷科贸有限公司 Two-wire system digital sensing device for online measuring temperature and water of multi-layer grains of grain pile
CN202119466U (en) * 2011-06-15 2012-01-18 基康仪器(北京)有限公司 Measuring device of differential resistance type sensor
CN102288337B (en) * 2011-06-15 2013-03-13 基康仪器(北京)有限公司 Method and device for measuring differential resistance type sensor
CN102928109A (en) * 2012-10-25 2013-02-13 重庆长安汽车股份有限公司 Signal collecting circuit
CN105737861A (en) * 2016-02-01 2016-07-06 上海交通大学 Resistive sensor detection circuit
CN108923738B (en) * 2018-08-09 2020-04-07 上海电力学院 Control method of dual-tracking photovoltaic power generation system based on weather type judgment
CN209617354U (en) * 2018-12-04 2019-11-12 杭州骑客智能科技有限公司 Pressure acquisition circuit and human-computer interaction body-sensing vehicle
CN109696936A (en) * 2018-12-21 2019-04-30 益和电气集团股份有限公司 A kind of temperature and humidity controller, temperature and humidity control device and control method
CN109489850A (en) * 2018-12-29 2019-03-19 深圳洲斯移动物联网技术有限公司 Humiture observation system and humiture monitoring device
CN209673250U (en) * 2019-04-02 2019-11-22 南京亚电电力自动化有限公司 A kind of passive and wireless temperature transducer

Also Published As

Publication number Publication date
CN111147264A (en) 2020-05-12

Similar Documents

Publication Publication Date Title
CN102959363A (en) Process variable transmitter with two-wire process control loop diagnostics
CN105571643A (en) Integrated general monitoring system for power transmission line
US5007042A (en) Method and apparatus for transmitting analog data embedded in a digital pulse train
CN101315361B (en) Detection system and method based on wireless network type salinity and temperature
CN110046140A (en) A kind of morning inspection information management system
JPS6239926A (en) Online type serial communication interface to current loop from computer
US4864274A (en) Remote reading thermostat
CN111147264B (en) Two-wire sensor communication device and method
CN206400004U (en) The single-phase 3 line intelligent electric meter of high current
CN103983856A (en) Automatic detection equipment and method of low voltage differential signal interface matched resistor
CN208488188U (en) Multichannel temperature sensor detecting device applied to nuclear power station
Kulkarni et al. Review on online monitoring of electrical machine using iot
CN104422837B (en) Identification system, entity device, identification device, and identification method for entity device
CN207502708U (en) A kind of Three Phase Alternating-current Electrical Energy Meters verification system
CN212133911U (en) Two-wire system temperature measurement system of daisy chain
CN205176246U (en) Conductivity meter self -calibration system
CN100451905C (en) Programmable controller for temperature and humidity
CN114257581A (en) Management system for intelligent sensing of internet of things and remote multimode transmission monitoring
CN107479020A (en) Single-phase measurement Fault Identification device and processing method
CN209246930U (en) A kind of sensor coding circuit based on partial pressure method
CN208476430U (en) Temperature polling instrument and temperature monitoring system
CN105371899A (en) Temperature-humidity sensor
JPS6239925A (en) Online type serial communication interface to computer and/or terminal from current loop
CN207366019U (en) Low-power consumption, multifactor measurement module and the device using the module
CN202650371U (en) Thermal resistor experiment module and engineering teaching experimental system

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
CP03 Change of name, title or address

Address after: 200241 Room 366, Building 2, No. 588 Zixing Road, Minhang District, Shanghai

Patentee after: Sensylink Microelectronics Co.,Ltd.

Country or region after: China

Address before: 201108 room A320, building 1, 2588 Hongmei South Road, Minhang District, Shanghai

Patentee before: SHANGHAI SENSYLINK MICROELECTRONICS Co.,Ltd.

Country or region before: China

CP03 Change of name, title or address