Communication circuit adaptive to wide voltage range
By designing communication circuits with adaptive wide voltage ranges, and automatically identifying and configuring communication levels using driving circuits and level conversion circuits, the problems of narrow level range and manual operation switching of existing serial communication modules are solved, and extensive communication level support and equipment security are achieved.
Patent Information
- Application Number
- CN202510016510.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-06
- Publication Date
- 2025-04-25
AI Technical Summary
The existing serial communication module only supports single or dual communication levels, and the level range is narrow, so it requires manual operation of the cap jump switch, which can easily damage the equipment.
Design a communication circuit with an adaptive wide voltage range, and automatically identify and configure communication logic levels through the driving circuit and level conversion circuit to realize serial communication of different communication levels without manual operation of the cap.
It realizes adaptability of 1.2V~5V communication levels, supports any voltage value within the level range, avoids equipment damage, simple circuit, low cost, and wide versatility.
Smart Images

Figure CN119884001A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of serial port communication and level conversion, and in particular to a communication circuit with an adaptive wide voltage range. Background Art
[0002] Serial communication, as an asynchronous serial communication method, is widely used in data exchange between computers and external devices. The most commonly used serial communication module usually uses three wires to connect when using UART for communication: TXD serial data transmission, RXD serial data reception, and GND.
[0003] Existing serial port communication modules usually only support single communication level or dual communication level, that is, when the first serial port and the second serial port communicate, the data level of the first serial port must be consistent with the data level of the second serial port. If they are inconsistent, it is necessary to operate the jumper to jump the communication level on the serial port module. The supported level range is small, and usually only typical values such as 5V and 3.3V communication level are supported. In practical applications, it is necessary to operate the jumper. If the communication level of the first serial port and the second serial port is inconsistent due to improper operation, the device may be damaged. Summary of the invention
[0004] The purpose of the present invention is to provide a communication circuit with an adaptive wide voltage range to address the problems existing in the prior art, which can automatically identify and configure the logic level of communication, use a single power supply to achieve the communication requirements between two serial ports with different communication levels, and do not require manual operation of jumpers to select the communication level.
[0005] According to one aspect of the present invention, there is provided a communication circuit with an adaptive wide voltage range, comprising a driving circuit and a level conversion circuit arranged between two serial ports, wherein the first driving circuit is connected between the first serial port and the first level conversion circuit, the second driving circuit is connected between the second serial port and the second level conversion circuit, and the first level conversion circuit and the second level conversion circuit are respectively connected between the first serial port and the second serial port.
[0006] As a further technical solution, the first driving circuit and the second driving circuit have the same structure, both including a diode, an operational amplifier, a first capacitor, and a second capacitor; wherein the anode of the diode is connected to the transmitting end of the serial port, the cathode of the diode is connected to the first end of the first capacitor and the in-phase end of the operational amplifier, the reverse end of the operational amplifier is connected to the output end and the first end of the second capacitor, and the second end of the first capacitor and the second end of the second capacitor are grounded.
[0007] Specifically, the driving circuit charges the capacitor through a diode via the transmitting end of the serial port. The first capacitor has no discharge path. To be precise, the diode is reversely cut off and the impedance of the operational amplifier is large enough, and the leakage current is very small, so that the voltage on the first capacitor maintains the communication level of the serial port, and its driving capability is increased after passing through the operational amplifier.
[0008] As a further technical solution, the first level conversion circuit includes a first NMOS tube and a first resistor; wherein the gate of the first NMOS tube is connected to the output end of the operational amplifier of the first driving circuit, the source is connected to the transmitting end of the first serial port, and the drain is connected to the first end of the first resistor and the receiving end of the second serial port; the second end of the first resistor is connected to the output end of the operational amplifier of the second driving circuit.
[0009] As a further technical solution, the second level conversion circuit includes a third NMOS tube, a third resistor, a fifth capacitor, a second resistor, a second NMOS tube, a second resistor and a sixth capacitor; wherein the gate of the third NMOS tube is connected to the transmitting end of the second serial port, the source is grounded, and the drain is connected to the first end of the third resistor; the second end of the third resistor is connected to the first end of the fifth capacitor, the first end of the fourth resistor and the gate of the second NMOS tube, the second end of the fifth capacitor is grounded, and the second end of the fourth resistor is connected to the power supply of the operational amplifier of the second drive circuit; the source of the second NMOS tube is grounded, and the drain is connected to the first end of the second resistor, the first end of the sixth capacitor and the receiving end of the first serial port; the second end of the sixth capacitor is grounded, and the first end of the second resistor is connected to the output end of the operational amplifier of the second drive circuit.
[0010] Specifically, the level conversion circuit realizes high-low level data conversion by controlling the on-off of NMOS.
[0011] As a further technical solution, the power supply voltage of the operational amplifier is greater than or equal to the communication voltage of the second serial port, and the communication voltage of the second serial port is greater than or equal to the communication voltage of the first serial port.
[0012] As a further technical solution, the smaller the gate-source threshold voltage of the first NMOS tube is, the smaller the communication level allowed by the first serial port is.
[0013] As a further technical solution, the smaller the gate parasitic capacitance of the third NMOS tube and the second NMOS tube is, the smaller the signal delay and edge oscillation of the receiving end of the first serial port are.
[0014] As a further technical solution, the first level conversion circuit and the second level conversion circuit are implemented by using a level conversion integrated circuit chip.
[0015] According to one aspect of the present invention, a terminal is provided, which is equipped with the communication circuit with an adaptive wide voltage range.
[0016] According to one aspect of the present invention, a communication system is provided, including a first device and a second device, and the adaptive wide voltage range communication circuit configured between the first device and the second device.
[0017] Compared with the prior art, the present invention has the following beneficial effects: 1. The present invention can achieve 1.2V~5V communication level adaptation through simulation test. The communication level range is much larger than the working range of existing applications, and supports any voltage value within the level range, rather than certain specific voltage values of existing applications.
[0018] 2. The driving circuit of the present invention can directly obtain the communication level from the sending end of the serial port, without the need for manual operation to switch the communication level, thereby avoiding damage to the equipment.
[0019] 3. The present invention has a simple circuit, extremely low cost, wide versatility, and no need to add a specific power supply circuit to provide drive for the level conversion circuit. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 A block diagram of a communication circuit system with an adaptive wide voltage range provided by an embodiment of the present invention.
[0021] Figure 2 A schematic diagram of a communication circuit with an adaptive wide voltage range provided by an embodiment of the present invention.
[0022] Figure 3 A schematic diagram of a simulation circuit provided by an embodiment of the present invention.
[0023] Figure 4 A schematic diagram of simulation waveforms of a first serial port communication level of 1.2V, a second serial port communication level of 5V, and a communication rate of 100kHz provided in an embodiment of the present invention.
[0024] Figure 5 A schematic diagram of simulation waveforms of a first serial port communication level of 2.4V, a second serial port communication level of 3.5V, and a communication rate of 500kHz provided in an embodiment of the present invention.
[0025] Figure 6 A schematic diagram of the principle of a communication circuit with an adaptive wide voltage range is provided in accordance with another embodiment of the present invention. DETAILED DESCRIPTION
[0026] In view of the defects of the existing serial port communication module, the present invention provides a circuit solution that can automatically identify and configure the logic level of communication, use a single power supply to achieve the communication requirements between two serial ports with different communication levels, and do not need to manually operate jumpers to select communication levels.
[0027] It should be noted that: The lower limit of the wide voltage range referred to in the present invention is associated with the communication voltage of the first serial port, and the upper limit of the wide voltage range is associated with the power supply voltage of the operational amplifier. Since the solution provided by the present invention is to obtain the communication voltage of the serial port from the transmitting end of the serial port and use it to drive the level conversion circuit, the communication level of the present invention can select any value within the working voltage range, rather than certain specific values of existing market products.
[0028] Although the present invention provides simulation results of a wide voltage range of 1.2V to 5V, those skilled in the art should understand that the actual applicable voltage range of the present invention is not limited thereto, but is associated with the communication voltages of the first serial port and the second serial port.
[0029] The technical solution of the present invention will be described clearly and completely below in conjunction with the accompanying drawings of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0030] An embodiment of the present invention provides a communication circuit with an adaptive wide voltage range, including a driving circuit and a level conversion circuit arranged between two serial ports, wherein the first driving circuit is connected between the first serial port and the first level conversion circuit, the second driving circuit is connected between the second serial port and the second level conversion circuit, and the first level conversion circuit and the second level conversion circuit are connected between the first serial port and the second serial port.
[0031] As a preferred embodiment, Figure 1 As shown, a block diagram of a communication circuit with an adaptive wide voltage range provided by an embodiment of the present invention is applied to a scenario where any two serial ports communicate.
[0032] As a preferred embodiment, Figure 2 As shown, an embodiment of the present invention provides an adaptive wide voltage range communication circuit, including a first driving circuit, a second driving circuit, a first level conversion circuit, and a second level conversion circuit.
[0033] Specifically, the first drive circuit and the second drive circuit have the same structure and working principle, and only the working principle of the first drive circuit is described separately here. The first drive circuit includes a diode D1, an operational amplifier U1, a first capacitor C1, and a second capacitor C2. D1 is a Schottky diode, whose cathode is connected to the capacitor C1, and whose anode is connected to the sending end of the serial port. According to the serial port protocol, its idle state is high level, charging C1. Due to the unidirectional conductivity of the diode, C1 has no reverse discharge loop. Since the Schottky diode voltage drop is small enough, the voltage across C1 can be equivalent to the communication level of the serial port. U1 is a rail-to-rail operational amplifier, powered by a single power supply, its in-phase end is connected to the cathode of D1, and its inverting end is connected to the output to form a source follower, which is output after filtering by the C2 capacitor. The output voltage of the operational amplifier is the communication level of the serial port, and the source follower increases its driving capability.
[0034] Specifically, the first serial port sends data and the second serial port receives data. This process is called uplink data transmission, and the first level conversion circuit is required to perform communication level conversion. The working principle of uplink data transmission is that when data transmission starts, the sending end of the first serial port is connected to the source of the NMOS tube Q1, and its initial level is the communication high level of the first serial port. The receiving end of the second serial port is connected to the drain of the NMOS tube Q1, and its initial level is the communication high level of the second serial port. The gate of the NMOS tube Q1 is connected to the output of the operational amplifier of the first driving circuit, and its level always maintains the communication high level of the first serial port. At this time, the NMOS tube Q1 is in a cut-off state. When the sending end of the first serial port changes from a high level to a low level, the gate-source voltage difference of the NMOS tube Q1 is greater than the gate-source threshold voltage VTH (GS) of the NMOS tube Q1. At this time, the NMOS tube Q1 is turned on, and the receiving end of the second serial port is pulled down. At this time, the receiving end of the second serial port changes to a low level. When the transmitting end of the first serial port changes from a low level to a high level, the gate-source voltage difference of the NMOS tube Q1 is less than the gate-source threshold voltage VTH(GS) of the NMOS tube Q1. At this time, the NMOS tube Q1 is cut off, and the receiving end of the second serial port is pulled up through the resistor R1. At this time, the receiving end of the second serial port becomes a high level.
[0035] Specifically, the second serial port sends data and the first serial port receives data. This process is called downlink data transmission, and the second level conversion circuit is required to perform communication level conversion. The working principle of downlink data transmission is that when data transmission starts, the initial level of the sending end of the second serial port is high. At this time, the NMOS tube Q3 is in the on state, and the gate of the NMOS tube Q2 is pulled down to make it in the off state. At this time, the receiving end of the first serial port is pulled up by the resistor R2, so that its initial level is high. When the sending end of the second serial port changes from a high level to a low level, the NMOS tube Q3 is in the off state, and the gate of the NMOS tube Q2 is pulled up by the resistor R4 to make it in the on state. At this time, the receiving end of the first serial port is pulled down to a low level. When the sending end of the second serial port changes from a low level to a high level, the NMOS tube Q3 is in the on state, and the resistors R3 and C5 form an RC buffer circuit to absorb the ringing of the edge. At this time, the gate of the NMOS tube Q2 is pulled down to make it in the off state, and the receiving end of the first serial port is pulled up by the resistor R2, and its level is high.
[0036] In the embodiment of the present invention, to ensure normal communication, the power supply voltage of the operational amplifier is greater than or equal to the communication voltage of the second serial port, and the communication voltage of the second serial port is greater than or equal to the communication voltage of the first serial port.
[0037] In the embodiment of the present invention, the voltage range of uplink data transmission is from the gate-source threshold voltage of NMOS Q1 to the power supply voltage of the operational amplifier, and the voltage range of downlink data transmission is from the gate-source threshold voltage of NMOS Q3 to the power supply voltage of the operational amplifier. Usually, the NMOS in the circuit are selected the same, so in order to obtain a larger communication voltage range, the gate-source threshold voltage of NMOS needs to be small enough.
[0038] An adaptive wide voltage range communication circuit provided by an embodiment of the present invention is used to perform serial communication simulation at different levels and different rates. The simulation circuit is as follows: Figure 3 As shown, the simulation data is as follows Figure 4 and Figure 5 shown. Figure 4 This is a schematic diagram of the simulation waveform with the first serial port communication level of 1.2V, the second serial port communication level of 5V, and a communication rate of 100kHz. Figure 5 This is a schematic diagram of simulation waveforms with the first serial port communication level being 2.4V, the second serial port communication level being 3.5V, and the communication rate being 500kHz.
[0039] A communication circuit diagram of another embodiment of the present invention is shown in FIG. Figure 6As shown, different from the previous embodiment, the first level conversion circuit and the second level conversion circuit are directly implemented by the level conversion integrated chip. The working principle of this embodiment is that the first driving circuit obtains the communication level of the first serial port and provides it to one port voltage of the level conversion integrated chip, and the second driving circuit obtains the communication level of the second serial port and provides it to another port voltage of the level conversion integrated chip, thereby realizing the level conversion between the two serial ports.
[0040] This embodiment does not need to add two power supply chips to the level conversion integrated chip to supply power to it. The driving circuit can achieve this function, and the power supply range is more flexible than that of the power supply chip. Compared with the previous embodiment, this embodiment has fewer components and a simpler circuit.
[0041] In summary, the present invention discloses a communication circuit with an adaptive wide voltage range, including a driving circuit and a level conversion circuit arranged between two serial ports, wherein the first driving circuit is connected between the first serial port and the first level conversion circuit, the second driving circuit is connected between the second serial port and the second level conversion circuit, and the first level conversion circuit and the second level conversion circuit are connected between the first serial port and the second serial port; the driving circuit includes a diode, an operational amplifier, a first capacitor, and a second capacitor; the anode of the diode is connected to the transmitting end of the serial port, and the cathode is connected to the first capacitor and the in-phase end of the operational amplifier; the reverse end of the operational amplifier is connected to the output end. The present invention can automatically identify and configure the logic level of communication, use a single power supply to achieve the communication requirements between two serial ports with different communication levels, and can achieve level conversion between any two communication voltages in the communication level range, which can solve the problem that the existing serial communication solutions on the market only support certain specific communication voltages and require frequent manual operation to switch jumpers when switching communication levels.
[0042] It should be noted that the technical solution formed by combining the driving circuit provided by the embodiment of the present invention with other level conversion methods is also within the protection scope of the present invention.
[0043] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. A communication circuit with an adaptive wide voltage range, characterized in that: It includes a driving circuit and a level conversion circuit arranged between two serial ports, wherein the first driving circuit is connected between the first serial port and the first level conversion circuit, the second driving circuit is connected between the second serial port and the second level conversion circuit, and the first level conversion circuit and the second level conversion circuit are respectively connected between the first serial port and the second serial port.
2. The communication circuit with adaptive wide voltage range according to claim 1, characterized in that: The first driving circuit and the second driving circuit have the same structure, and both include a diode, an operational amplifier, a first capacitor, and a second capacitor; wherein the anode of the diode is connected to the transmitting end of the serial port, the cathode of the diode is connected to the first end of the first capacitor and the in-phase end of the operational amplifier, the reverse end of the operational amplifier is connected to the output end and the first end of the second capacitor, and the second end of the first capacitor and the second end of the second capacitor are grounded.
3. The communication circuit with adaptive wide voltage range according to claim 1, characterized in that: The first level conversion circuit includes a first NMOS tube and a first resistor; wherein the gate of the first NMOS tube is connected to the output end of the operational amplifier of the first driving circuit, the source is connected to the transmitting end of the first serial port, and the drain is connected to the first end of the first resistor and the receiving end of the second serial port; the second end of the first resistor is connected to the output end of the operational amplifier of the second driving circuit.
4. The communication circuit with adaptive wide voltage range according to claim 1, characterized in that: The second level conversion circuit includes a third NMOS transistor, a third resistor, a fifth capacitor, a second resistor, a second NMOS transistor, a second resistor and a sixth capacitor; The gate of the third NMOS transistor is connected to the transmitting end of the second serial port, the source is grounded, and the drain is connected to the first end of the third resistor; the second end of the third resistor is connected to the first end of the fifth capacitor, the first end of the fourth resistor, and the gate of the second NMOS transistor, the second end of the fifth capacitor is grounded, and the second end of the fourth resistor is connected to the power supply of the operational amplifier of the second driving circuit; The source of the second NMOS tube is grounded, and the drain is connected to the first end of the second resistor, the first end of the sixth capacitor and the receiving end of the first serial port; the second end of the sixth capacitor is grounded, and the first end of the second resistor is connected to the output end of the operational amplifier of the second driving circuit.
5. The communication circuit with adaptive wide voltage range according to claim 2, characterized in that: The power supply voltage of the operational amplifier is greater than or equal to the communication voltage of the second serial port, and the communication voltage of the second serial port is greater than or equal to the communication voltage of the first serial port.
6. The communication circuit with adaptive wide voltage range according to claim 3, characterized in that: The smaller the gate-source threshold voltage of the first NMOS tube is, the smaller the communication level allowed by the first serial port is.
7. The communication circuit with adaptive wide voltage range according to claim 4, characterized in that: The smaller the gate parasitic capacitance of the third NMOS tube and the second NMOS tube is, the smaller the signal delay and edge oscillation of the receiving end of the first serial port are.
8. The communication circuit with adaptive wide voltage range according to claim 1, characterized in that: The first level conversion circuit and the second level conversion circuit are implemented by using a level conversion integrated circuit chip.
9. A terminal, characterized in that: A communication circuit with an adaptive wide voltage range as claimed in any one of claims 1 to 8 is provided.
10. A communication system, characterized in that: The invention comprises a first device and a second device, and a communication circuit with an adaptive wide voltage range as claimed in any one of claims 1 to 8 arranged between the first device and the second device.