Communication circuit, electronic equipment and communication system
By designing a communication circuit including a switching unit and a voltage generation unit, the problem of the existing three-wire serial communication is easily disturbed and a higher quality data transmission is achieved.
Patent Information
- Application Number
- CN202111235992.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-22
- Publication Date
- 2025-05-02
- Estimated Expiration
- 2041-10-22
AI Technical Summary
The existing three-wire serial communication methods are susceptible to external interference, resulting in problems such as low communication rate and hardware communication interruption conflicts.
A communication circuit is designed, including a communication transmitting unit, a communication receiving unit, a communication transmission unit, a control level output unit, a first switching unit, a second switching unit, a voltage generating unit, and a power supply unit. Through the control of the first switching unit and the second switching unit, the conversion and transmission of data between high and low levels is realized.
It reduces interference in three-wire communication and improves data transmission quality.
Smart Images

Figure CN114050836B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and more specifically, to a communication circuit, electronic equipment and a communication system. Background Art
[0002] In the traditional serial UART communication circuit, it will need to connect four signal lines, namely power supply, signal ground, data receiving and data sending, to achieve mutual communication. Four lines are required to complete the communication of the entire system. At present, in order to reduce costs, three-wire serial communication is adopted. However, some current three-wire serial communication methods are easily affected by external interference during data transmission because they directly connect to the MCU controller port through the serial port for data communication, which can easily cause problems such as low serial communication rate and hardware communication interruption conflict. Summary of the invention
[0003] The technical problem to be solved by the present invention is to provide a communication circuit, an electronic device and a communication system in view of the above-mentioned technical defects of the prior art.
[0004] The technical solution adopted by the present invention to solve the technical problem is: construct a communication circuit, including: a communication transmitting unit, a communication receiving unit, a communication transmission unit, a control level output unit, a first switch unit, a second switch unit, a voltage generating unit and a power supply unit;
[0005] A first end of the first switch unit is connected to the communication transmitting unit, a second end of the first switch unit is connected to the second end of the voltage generating unit, and a third end of the first switch unit is grounded;
[0006] The second end of the voltage generating unit is also connected to the second end of the second switch unit and the communication transmission unit, and the first end of the voltage generating unit is connected to the power supply unit;
[0007] A first end of the second switch unit is connected to the control level output unit, and a third end of the second switch unit is connected to the communication receiving unit;
[0008] Among them, the communication transmitting unit is used to generate communication data, the first switch unit is used to turn off when the communication data is at a high level and turn on when the communication data is at a low level; the control level output unit is used to output the control level, and the second switch unit receives the control level to turn on or off.
[0009] Preferably, in a communication circuit of the present invention, the first switch unit includes a first sub-switch and a second sub-switch;
[0010] The first end of the first sub-switch is connected to the communication transmitting unit, the second end of the first sub-switch is connected to the power supply unit, the third end of the first sub-switch is connected to the first end of the second sub-switch, the second end of the second sub-switch is connected to the communication transmission unit, and the third end of the second sub-switch is grounded.
[0011] Preferably, in a communication circuit of the present invention, the first sub-switch includes a first resistor, a second resistor and a first transistor; the base of the first transistor is connected to the first end of the first resistor and the first end of the second resistor, the second end of the first resistor is connected to the communication transmitting unit, the emitter of the first transistor is connected to the second end of the second resistor and the power supply unit, and the collector of the first transistor is connected to the second sub-switch; and / or
[0012] The second sub-switch includes a third resistor, a fourth resistor and a second transistor; the base of the second transistor is connected to the first end of the third resistor and the first end of the fourth resistor, the second end of the third resistor is connected to the third end of the first sub-switch, the second end of the fourth resistor and the emitter of the second transistor are grounded, and the collector of the second transistor is connected to the second end of the voltage generating unit.
[0013] Preferably, in a communication circuit of the present invention, the voltage generating unit includes a pull-up resistor, a first end of the pull-up resistor is connected to the power supply unit, and a second end of the pull-up resistor is connected to the second end of the first switch unit, the second end of the second switch unit and the communication transmission unit.
[0014] Preferably, in a communication circuit of the present invention, the second switch unit includes a third transistor, a fifth resistor, a sixth resistor and a seventh resistor;
[0015] The base of the third transistor is connected to the control level output unit via the fifth resistor, the emitter of the third transistor is connected to the second end of the voltage generating unit, the collector of the third transistor is connected to the first end of the sixth resistor and the first end of the seventh resistor, the second end of the sixth resistor is connected to the communication receiving unit, and the second end of the seventh resistor is grounded.
[0016] Preferably, in a communication circuit of the present invention, the communication transmission unit includes a connector;
[0017] The first pin of the connector is connected to the power supply unit, the second pin of the connector is connected to the first end of the voltage generating unit, the second end of the first switch unit and the second end of the second switch unit, and the third pin of the connector is grounded.
[0018] Preferably, in a communication circuit of the present invention, the communication transmission unit further includes an eighth resistor;
[0019] A first end of the eighth resistor is connected to a first end of the voltage generating unit, a second end of the first switch unit, and a second end of the second switch unit, and a second end of the eighth resistor is connected to a second pin of the connector.
[0020] Preferably, in a communication circuit of the present invention, the communication transmission unit further includes a diode and / or a TVS tube;
[0021] The anode of the diode is connected to the first end of the eighth resistor, and the cathode of the diode is connected to the power supply unit;
[0022] The first end of the TVS tube is connected to the first end of the eighth resistor, and the second end of the TVS tube is grounded.
[0023] Preferably, in a communication circuit of the present invention, a controller is further included, and the communication transmitting unit, the communication receiving unit and the control level output unit are integrated in the controller.
[0024] The present invention also constructs an electronic device, comprising the communication circuit as described in any one of the above items.
[0025] The present invention also constructs a communication system, including a first communication module and a second communication module, wherein the first communication module and the second communication module both include the communication circuit as described above, wherein the communication transmission unit in the first communication module is communicatively connected with the communication transmission unit in the second communication module.
[0026] Preferably, in the communication system of the present invention, the power supply unit of the second communication module is powered by the power supply unit of the first communication module.
[0027] A communication circuit, electronic equipment and communication system implementing the present invention have the following beneficial effects: reducing interference in three-wire communication and improving data transmission quality. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] The present invention will be further described below with reference to the accompanying drawings and embodiments, in which:
[0029] Figure 1 It is a structural schematic diagram of an embodiment of a communication circuit of the present invention;
[0030] Figure 2 It is a circuit principle diagram of an embodiment of a communication circuit of the present invention. DETAILED DESCRIPTION
[0031] In order to have a clearer understanding of the technical features, purposes and effects of the present invention, specific embodiments of the present invention are now described in detail with reference to the accompanying drawings.
[0032] like Figure 1As shown, in a first embodiment of a communication circuit of the present invention, it includes: a communication transmitting unit 110, a communication receiving unit 120, a communication transmission unit 180, a control level output unit 130, a first switch unit 140, a second switch unit 150, a voltage generating unit 160 and a power supply unit 170; a first end of the first switch unit 140 is connected to the communication transmitting unit 110, a second end of the first switch unit 140 is connected to a second end of the voltage generating unit 160, and a third end of the first switch unit 140 is grounded; a second end of the voltage generating unit 160 is also connected to a second end of the second switch unit 150 and the communication transmission unit 180, and a first end of the voltage generating unit 160 is connected to the power supply unit 170; a first end of the second switch unit 150 is connected to the control level output unit 130, and a third end of the second switch unit 150 is connected to the communication receiving unit 120; The communication transmitting unit 110 is used to generate communication data, the first switch unit 140 is used to turn off when the communication data is at a high level and turn on when the communication data is at a low level; the control level output unit 130 is used to output the control level, and the second switch unit 150 receives the control level to turn on or off. Specifically, the communication transmitting unit 110 is used to transmit communication data, and the communication receiving unit 120 is used to receive communication data. The control level output unit 130 is used to output the control level to control the second switch unit 150 to turn on or off. The communication receiving end and the communication transmission unit 180 can be turned on or off by turning on or off the second switch unit 150. When the second switch unit 150 is turned off, the communication transmission unit 180 is used as an output unit to output communication data to an external device, and when the second switch unit 150 is turned on, the communication transmission unit 180 is used as an input unit to receive communication data from an external device. The control level output unit 130 can output the control level according to the state of the communication transmitting unit 110. When the communication transmitting unit 110 has no communication data output, the control level output unit 130 is set to output the control level to control the second switch unit 150 to be turned on. When the communication transmitting unit 110 has communication data output, the control level output unit 130 is set to output the control level to control the second switch unit 150 to be turned off. Usually, the second switch unit 150 can be set to be turned off by default. When the communication transmitting unit 110 has communication data output, when the output communication data is a high level, the first switch unit 140 is turned off, and at this time, the voltage generating unit 160 generates a high level according to the output voltage of the power supply unit 170; when the communication data is a low level, the first switch unit 140 is turned on, and at this time, the voltage generating unit 160 is connected to the ground to generate a low level. The generated high and low levels correspond to the high and low levels of the communication data output by the communication transmitting unit 110, and finally the corresponding communication data is output to the external device through the communication transmission unit 180. The external device can receive the communication data according to the received high and low levels.When the communication transmitting unit 110 has no communication data output, the second switch unit 150 is turned on, and the high and low levels received by the communication transmission unit 180 are still the corresponding high and low levels due to the voltage stabilization effect of the voltage generating unit 160, that is, the communication receiving unit 120 receives the corresponding high and low levels to obtain the final communication data. By setting the communication transmitting unit 110 to the communication data transmitting state or setting the second switch unit 150 to the off state during the time when no data communication is performed when the communication receiving unit 120 is in other states other than the receiving state, it is possible to prevent signal interference on the external connection link and improve the anti-interference ability of the communication circuit.
[0033] Optional, such as Figure 2 As shown, the first switch unit 140 includes a first sub-switch 141 and a second sub-switch 142; the first end of the first sub-switch 141 is connected to the communication transmitting unit 110, the second end of the first sub-switch 141 is connected to the power supply unit 170, the third end of the first sub-switch 141 is connected to the first end of the second sub-switch 142, the second end of the second sub-switch 142 is connected to the communication transmission unit 180, and the third end of the second sub-switch 142 is grounded. That is, the first switch unit 140 can be composed of two-stage sub-switches. The first sub-switch 141 is connected to the communication transmitting unit 110, and it is turned on or off according to the high and low levels of the communication data of the communication transmitting unit 110. It is turned off when the communication data is at a high level, and the second sub-switch 142 is turned off when the first sub-switch 141 is turned off. Finally, the first switch unit 140 is in the off state. The first sub-switch 141 is turned on when the communication data is at a low level. At this time, the power supply of the power supply unit 170 drives the second sub-switch 142 to turn on, and finally the first switch unit 140 is in the on state.
[0034] Optionally, the first sub-switch 141 includes a first resistor, a second resistor and a first triode; the base of the first triode is connected to the first end of the first resistor and the first end of the second resistor, the second end of the first resistor is connected to the communication transmitting unit 110, the emitter of the first triode is connected to the second end of the second resistor and the power supply unit 170, and the collector of the first triode is connected to the second sub-switch 142; specifically, the first sub-switch 141 can be composed of a first triode and its peripheral circuit. The base of the first triode is connected to the communication transmitting unit 110, and it is driven to turn on or off according to the high and low levels of the communication data of the communication transmitting unit 110. In some embodiments, the triode can also be replaced by other switch tubes such as MOS tubes. In a specific embodiment, one end of the resistor R4 (corresponding to the first resistor) is connected to the communication transmitting unit 110, and the other end is connected to the base of the triode Q2 (corresponding to the first triode), and the triode Q2 is driven to turn on or off by the input level of the resistor R4. One end of the resistor R5 (corresponding to the second resistor) is connected to the base of the transistor Q2 , and the other end is connected to the power supply unit 170 .
[0035] Optionally, the second sub-switch 142 includes a third resistor, a fourth resistor, and a second triode; the base of the second triode is connected to the first end of the third resistor and the first end of the fourth resistor, the second end of the third resistor is connected to the third end of the first sub-switch 141, the second end of the fourth resistor and the emitter of the second triode are grounded, and the collector of the second triode is connected to the second end of the voltage generating unit 160. Specifically, the second sub-switch 142 can be composed of a second triode and its peripheral circuit. The base of the second triode is connected to the power supply unit 170 via the first sub-switch 141, which is turned on or off according to the on or off state of the first sub-switch 141. In some embodiments, the triode can also be replaced by other switch tubes such as MOS tubes. In a specific embodiment, one end of the resistor R6 (corresponding to the third resistor) is connected to the collector of the triode Q2, and the other end is connected to the base of the triode Q3 (corresponding to the second triode) and one end of the resistor R7 (corresponding to the fourth resistor). The other end of the resistor R7 and the emitter of the triode Q3 are grounded. The collector of the transistor Q3 is connected to the voltage generating unit 160 .
[0036] Optionally, the voltage generating unit 160 includes a pull-up resistor, the first end of the pull-up resistor is connected to the power supply unit 170, and the second end of the pull-up resistor is connected to the second end of the first switch unit 140, the second end of the second switch unit 150 and the communication transmission unit 180. Specifically, the high and low level output of the second end voltage of the second switch unit 150 can be realized with the pull-up resistor. When the second switch unit 150 is turned off, the pull-up resistor is connected to the power supply unit 170 at its second end, which is a high level, that is, the communication transmission unit 180 outputs a high level at this time. When the second switch unit 150 is turned on, the second end of the second switch unit 150 is grounded, and the second end of the pull-up resistor is grounded at a low level, that is, the communication transmission unit 180 outputs a low level at this time. The high and low level output of the communication transmission unit 180 is realized. In a specific embodiment, the pull-up resistor can be a resistor R8, one end of which is connected to the power supply unit 170, and the other end is connected to the second end of the first switch unit 140, the second end of the second switch unit 150 and the communication transmission unit 180.
[0037] Optionally, the second switch unit 150 includes a third transistor, a fifth resistor, a sixth resistor and a seventh resistor; the base of the third transistor is connected to the control level output unit 130 via the fifth resistor, the emitter of the third transistor is connected to the second end of the voltage generating unit 160, the collector of the third transistor is connected to the first end of the sixth resistor and the first end of the seventh resistor, the second end of the sixth resistor is connected to the communication receiving unit 120, and the second end of the seventh resistor is grounded. Specifically, the second switch unit 150 can be composed of a third transistor and its peripheral circuit. The base of the third transistor is used to receive the control level output by the control level unit, and is turned on or off according to the control level. When the third transistor of the communication receiving unit 120 is turned on, the high and low levels are received according to the voltage of the second end of the second voltage generating unit 160, and the high and low levels correspond to the communication data. In some embodiments, the transistor can also be replaced by other switch tubes such as MOS tubes. In a specific embodiment, the base of the transistor Q4 (corresponding to the third transistor) is connected to the control level output unit 130 via the resistor R9 (corresponding to the fifth resistor), and the collector of the transistor Q4 is connected to the communication receiving unit 120 via the resistor R10 (corresponding to the sixth resistor), and the collector of the transistor Q4 is grounded via the resistor R11 (corresponding to the seventh resistor).
[0038] Optionally, the first pin of the connector is connected to the power supply unit 170, the second pin of the connector is connected to the first end of the voltage generating unit 160, the second end of the first switch unit 140 and the second end of the second switch unit 150, and the third pin of the connector is grounded. Specifically, an external device can be connected through the connector to achieve the transmission of communication data with the external device. In a specific embodiment, the connector can adopt a commonly used serial port connector.
[0039] Optionally, the communication transmission unit 180 also includes an eighth resistor; the first end of the eighth resistor is connected to the first end of the voltage generating unit 160, the second end of the first switch unit 140 and the second end of the second switch unit 150, and the second end of the eighth resistor is connected to the second pin of the connector. The eighth resistor is connected to the second end of the voltage generating unit 160 and the second pin of the connector, which is used to improve the anti-interference ability of the communication circuit. In one embodiment, the transistor Q3, the transistor Q4 and the resistor R8 can all be connected to the connector CN3 through the resistor R12 (corresponding to the eighth resistor), and the resistor R12 is used to improve the anti-interference ability of the connector during signal transmission.
[0040] Optionally, the communication transmission unit 180 also includes a diode and / or a TVS tube; the anode of the diode is connected to the first end of the eighth resistor, and the cathode of the diode is connected to the power supply unit 170; the first end of the TVS tube is connected to the first end of the eighth resistor, and the second end of the TVS tube is grounded. Specifically, in the communication transmission unit 180, a diode is also provided to connect the second pin of the connector and the power supply unit 170 to improve the anti-interference capability of the communication circuit. A TVS tube can also be provided to be connected between the second pin of the connector and the ground to improve the anti-interference capability of the communication circuit. The diode and the TVS tube can also be provided at the same time.
[0041] Optionally, in one embodiment, the communication circuit of the present invention further includes a controller, and the communication transmitting unit 110, the communication receiving unit 120 and the control level output unit 130 are integrated in the controller. That is, the controller can be used to generate and output communication data, and can also receive communication data from an external device, and at the same time, it can generate a corresponding control level according to the output or receiving state of the communication output to control the second switch unit 150 to turn on or off. In a specific embodiment, the controller can use an MCU chip IC2.
[0042] In addition, an electronic device of the present invention includes any one of the communication circuits described above, that is, the above communication circuit is arranged in the electronic device to implement data communication between the electronic device and other electronic devices.
[0043] In addition, a communication system of the present invention includes a first communication module and a second communication module, and the first communication module and the second communication module both include a communication circuit as described above, wherein the communication transmission unit 180 in the first communication module is connected to the communication transmission unit 180 of the second communication module, and the power supply unit 170 of the second communication module can be powered by the power supply unit 170 of the first communication module. Specifically, the first communication module and the second communication module can be respectively formed by the communication circuit, and the first communication module and the second communication module can perform data communication with each other to form a communication system. In the communication system, the first communication module can be selected as the master device and the second communication module can be selected as the slave device, wherein the slave device can be powered by the master device.
[0044] It can be understood that the above embodiments only express the preferred implementation modes of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the patent scope of the present invention. It should be pointed out that, for ordinary technicians in this field, without departing from the concept of the present invention, the above technical features can be freely combined, and several deformations and improvements can be made, which all belong to the protection scope of the present invention. Therefore, all equivalent changes and modifications made to the scope of the claims of the present invention should belong to the scope covered by the claims of the present invention.
Claims
1. A communication circuit, characterized in that: include: A communication transmitting unit, a communication receiving unit, a communication transmission unit, a control level output unit, a first switch unit, a second switch unit, a voltage generating unit and a power supply unit; A first end of the first switch unit is connected to the communication transmitting unit, a second end of the first switch unit is connected to the second end of the voltage generating unit, and a third end of the first switch unit is grounded; The second end of the voltage generating unit is also connected to the second end of the second switch unit and the communication transmission unit, and the first end of the voltage generating unit is connected to the power supply unit; A first end of the second switch unit is connected to the control level output unit, and a third end of the second switch unit is connected to the communication receiving unit; Wherein, the communication transmitting unit is used to generate communication data, the first switch unit is used to turn off when the communication data is at a high level and to turn on when the communication data is at a low level; the control level output unit is used to output a control level, the second switch unit receives the control level to turn on or off, and when the communication transmitting unit is in a communication data sending state or the communication receiving unit is in a state other than a receiving state, the control level output unit outputs a control level to control the second switch unit to turn off; and when the second switch unit is turned off, the communication transmission unit is used as an output unit to output communication data to an external device; When the second switch unit is turned on, the communication transmission unit is used as an input unit to receive communication data from an external device; The voltage generating unit includes a pull-up resistor, a first end of the pull-up resistor is connected to the power supply unit, and a second end of the pull-up resistor is connected to a second end of the first switch unit, a second end of the second switch unit, and the communication transmission unit.
2. The communication circuit according to claim 1, characterized in that: The first switch unit includes a first sub-switch and a second sub-switch; The first end of the first sub-switch is connected to the communication transmitting unit, the second end of the first sub-switch is connected to the power supply unit, the third end of the first sub-switch is connected to the first end of the second sub-switch, the second end of the second sub-switch is connected to the communication transmission unit, and the third end of the second sub-switch is grounded.
3. The communication circuit according to claim 2, characterized in that: The first sub-switch includes a first resistor, a second resistor and a first transistor; the base of the first transistor is connected to the first end of the first resistor and the first end of the second resistor, the second end of the first resistor is connected to the communication transmitting unit, the emitter of the first transistor is connected to the second end of the second resistor and the power supply unit, and the collector of the first transistor is connected to the second sub-switch; and / or The second sub-switch includes a third resistor, a fourth resistor and a second transistor; the base of the second transistor is connected to the first end of the third resistor and the first end of the fourth resistor, the second end of the third resistor is connected to the third end of the first sub-switch, the second end of the fourth resistor and the emitter of the second transistor are grounded, and the collector of the second transistor is connected to the second end of the voltage generating unit.
4. The communication circuit according to claim 1, characterized in that: The second switch unit includes a third triode, a fifth resistor, a sixth resistor and a seventh resistor; The base of the third transistor is connected to the control level output unit via the fifth resistor, the emitter of the third transistor is connected to the second end of the voltage generating unit, the collector of the third transistor is connected to the first end of the sixth resistor and the first end of the seventh resistor, the second end of the sixth resistor is connected to the communication receiving unit, and the second end of the seventh resistor is grounded.
5. The communication circuit according to claim 1, characterized in that: The communication transmission unit includes a connector; The first pin of the connector is connected to the power supply unit, the second pin of the connector is connected to the first end of the voltage generating unit, the second end of the first switch unit and the second end of the second switch unit, and the third pin of the connector is grounded.
6. The communication circuit according to claim 5, characterized in that: The communication transmission unit also includes an eighth resistor; A first end of the eighth resistor is connected to a first end of the voltage generating unit, a second end of the first switch unit, and a second end of the second switch unit, and a second end of the eighth resistor is connected to a second pin of the connector.
7. The communication circuit according to claim 6, characterized in that: The communication transmission unit also includes a diode and / or a TVS tube; The anode of the diode is connected to the first end of the eighth resistor, and the cathode of the diode is connected to the power supply unit; The first end of the TVS tube is connected to the first end of the eighth resistor, and the second end of the TVS tube is grounded.
8. The communication circuit according to claim 1, characterized in that: It also includes a controller, in which the communication transmitting unit, the communication receiving unit and the control level output unit are integrated.
9. An electronic device, characterized in that: Comprising the communication circuit as claimed in any one of claims 1 to 8.
10. A communication system, characterized in that: It comprises a first communication module and a second communication module, wherein the first communication module and the second communication module both comprise the communication circuit according to any one of claims 1 to 8, wherein the communication transmission unit in the first communication module is communicatively connected with the communication transmission unit in the second communication module.
11. The communication system according to claim 10, characterized in that: The power supply unit of the second communication module is powered by the power supply unit of the first communication module.
Citation Information
Patent Citations
Communication signal transmission circuit and electronic equipment
CN113315535A
Communication circuit, electronic equipment and communication system
CN216599583U