USB interface multiplexing circuit
By designing a USB interface multiplexing circuit and using a control chip and MOS tube to realize the switching between USB and external sensors, the problem of limited USB interface connection in the existing technology is solved, the system stability is improved and the cost is reduced.
Patent Information
- Application Number
- CN202422619838.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-29
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2034-10-29
AI Technical Summary
Existing USB interfaces can only connect to a limited number of devices, increasing system complexity and cost, and cannot meet the communication needs of special devices or sensors.
A USB interface multiplexing circuit is designed, which includes a PC terminal, a USB interface, an external sensor interface, a conversion circuit module, a USB communication module, and a signal processing module. The switching between the USB and the external sensor is realized through a control chip and a MOS tube, and the circuit has a short-circuit anomaly detection function.
Flexible switching between the USB interface and external sensors is achieved, which improves the stability and security of the system and reduces the system complexity and cost.
Smart Images

Figure CN223308613U_ABST
Abstract
Description
Technical Field
[0001] The utility model relates to the technical field of electronic circuit design, in particular to a circuit for multiplexing a USB interface. Background Art
[0002] USB is a widely used interface technology for connecting computers and external devices. However, with the continuous development of technology, USB interfaces have gradually exposed some limitations. For example, USB interfaces can generally only connect to a limited number of devices; some specialized devices or sensors may require specialized interfaces or adapters to communicate with computers, which increases system complexity and cost.
[0003] Therefore, the existing technology has defects and needs to be improved. Utility Model Content
[0004] The purpose of the utility model is to overcome the deficiencies of the prior art and provide a circuit for multiplexing a USB interface.
[0005] The technical solution of the utility model is as follows: A circuit for multiplexing a USB interface is provided, comprising: a PC end, a USB interface, an external sensor interface, a conversion circuit module, a USB communication module, and a signal processing module. The USB interface is electrically connected to the external sensor interface, the conversion circuit module, and the PC end; the conversion circuit module is electrically connected to the signal processing module; the USB interface receives a data signal input from the PC end or the external sensor interface and transmits it to the conversion circuit; and the conversion circuit module selects an output channel for the signal after receiving the signal.
[0006] Furthermore, the conversion circuit module includes: a control chip U1, a resistor R1, a resistor R2, a resistor R3, a capacitor C1, a capacitor C4, and a MOS transistor Q2. The third pin of the control chip U1 is grounded, the eighth pin of the control chip U1 is connected to one end of the resistor R1, the ninth pin of the control chip U1 is connected to one end of the capacitor C1 and connected to VDD_SW, the tenth pin of the control chip U1 is connected to one end of the capacitor C4, one end of the resistor R2, one end of the resistor R3, and the drain of the MOS transistor Q2, the other end of the resistor R2 is connected to SW_OE, the gate of the MOS transistor Q2 is connected to VBUS, and the source of the MOS transistor Q2, the other end of the resistor R1, the other end of the resistor R3, the other end of the capacitor C1, and the other end of the capacitor C4 are grounded respectively.
[0007] Furthermore, the conversion circuit module is connected to a power supply circuit, which includes a field-effect transistor Q1, a voltage regulator D1, a resistor R6, and a resistor R7. The drain of the MOS transistor Q1 is connected to SW_OE, the gate of the MOS transistor and the positive terminal of the voltage regulator D1 are connected in parallel to VBUS, and the negative terminal of the voltage regulator D1 and the source of the MOS transistor are connected in parallel to the conversion circuit; one end of the resistor R6 is connected to VDD_TEMP_ADC, the other end of the resistor R6 and one end of the resistor R7 are connected in parallel to SW_OE, and the other end of the resistor R7 is connected to VDD_TEMP_EXT.
[0008] Using this solution, the present invention uses signal lines such as USB_DP and VDD_TEMP_EXT to switch between the USB and external sensors. When an external sensor is connected, the circuit switches to the external sensor interface; when connected to the USB, it switches to the USB interface. Based on instructions from the main controller, the circuit switches between the USB and external sensor using signal lines and control logic. The circuit also detects short-circuit anomalies in external sensors, ensuring system stability and safety. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] Figure 1 This is a connection block diagram of the circuit module of the present utility model.
[0010] Figure 2 This is a circuit connection diagram of the USB interface.
[0011] Figure 3 Schematic diagram of the circuit connection of the conversion circuit module.
[0012] Figure 4 Schematic diagram of the circuit connection of the power supply circuit. DETAILED DESCRIPTION
[0013] The present invention will be described in detail below with reference to the accompanying drawings and specific embodiments.
[0014] See also Figure 1 、 Figure 2 The utility model provides a USB interface multiplexing circuit, including: a PC end, a USB interface, an external sensor interface, a conversion circuit module, a USB communication module and a signal processing module. The USB interface is electrically connected to the external sensor interface, the conversion circuit module and the PC end. The conversion circuit module is electrically connected to the signal processing module. The USB interface receives a data signal input from the PC end or the external sensor interface and transmits it to the conversion circuit. After receiving the signal, the conversion circuit module selects the output channel of the signal.
[0015] The conversion circuit module controls switching between the PC and the external sensor interface; the signal processing module processes data signals input from the external sensor interface; and the USB communication module processes data signals input from the PC. The conversion circuit module receives control signals from the PC or the external sensor interface and, depending on the signal source, selects either the USB communication module or the signal processing module for data communication.
[0016] See also Figure 3 The conversion circuit module includes: a control chip U1, a resistor R1, a resistor R2, a resistor R3, a capacitor C1, a capacitor C4, and a MOS transistor Q2. The third pin of the control chip U1 is grounded, the eighth pin of the control chip U1 is connected to one end of the resistor R1, the ninth pin of the control chip U1 is connected to one end of the capacitor C1 and connected to VDD_SW, the tenth pin of the control chip U1 is connected to one end of the capacitor C4, one end of the resistor R2, one end of the resistor R3, and the drain of the MOS transistor Q2, the other end of the resistor R2 is connected to SW_OE, the gate of the MOS transistor Q2 is connected to VBUS, and the source of the MOS transistor Q2, the other end of the resistor R1, the other end of the resistor R3, the other end of the capacitor C1, and the other end of the capacitor C4 are grounded respectively.
[0017] See also Figure 4 The conversion circuit module is connected to a power supply circuit, which includes a field-effect transistor Q1, a voltage regulator D1, a resistor R6, and a resistor R7. The drain of the MOS transistor Q1 is connected to SW_OE, the gate of the MOS transistor and the positive terminal of the voltage regulator D1 are connected in parallel to VBUS, and the cathode of the voltage regulator D1 and the source of the MOS transistor are connected in parallel to the conversion circuit; one end of the resistor R6 is connected to VDD_TEMP_ADC, the other end of the resistor R6 and one end of the resistor R7 are connected in parallel to SW_OE, and the other end of the resistor R7 is connected to VDD_TEMP_EXT.
[0018] External power inputs include VBUS, VDD_SW, and VDD_TEMP_EXT. By controlling SW_OE, MOSFET Q1 is indirectly controlled to generate current that flows into VDD_SW, which then powers the USB interface. VDD_TEMP_EXT is used to power the external sensor interface. This external power input meets the power requirements of various circuit modules in the USB interface multiplexing circuit.
[0019] In the conversion circuit module, pin 6 of the control chip U1 is connected to SDA2, and pin 7 of the control chip U1 is connected to SCL2, thereby connecting to the I2C interface for communication with an external microcontroller. SDA2 is used for data transmission, and SCL2 is used for clock signal transmission. Through these two interfaces, the conversion circuit module can exchange data with the microcontroller, realizing the function of controlling or reading sensor data.
[0020] Pin 4 of the control chip U1 is connected to the USB_DM interface of the USB communication module, and pin 5 of the control chip U1 is connected to the USB_DP interface of the USB communication module, for effectively transmitting and communicating data received by the control chip U1 with the USB communication module. Pin 1 of the control chip U1 is connected to the USB_D+ pin of the USB interface, and pin 2 of the control chip U1 is connected to the USB_D- pin of the USB interface, for receiving data from the USB interface and transmitting and communicating the received data.
[0021] The VDD_TEMP-ADC port is used to detect whether the external sensor is short-circuited and take appropriate protection measures based on the detection results.
[0022] In summary, the present invention utilizes signal lines such as USB_DP and VDD_TEMP_EXT to enable switching between USB and external sensors. When an external sensor is connected, the circuit switches to the external sensor interface; when connected to USB, it switches to the USB interface. Based on instructions from the main controller, the circuit switches between the USB and external sensor using signal lines and control logic. Furthermore, the circuit can detect short-circuit anomalies in external sensors, ensuring system stability and safety.
[0023] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements and improvements made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A circuit for multiplexing a USB interface, characterized in that: include: A PC end, a USB interface, an external sensor interface, a conversion circuit module, a USB communication module and a signal processing module. The USB interface is electrically connected to the external sensor interface, the conversion circuit module and the PC end. The conversion circuit module is electrically connected to the signal processing module. The USB interface receives a data signal input from the PC end or the external sensor interface and transmits it to the conversion circuit. After receiving the signal, the conversion circuit module selects the output channel of the signal.
2. The USB interface multiplexing circuit according to claim 1, characterized in that: The conversion circuit module includes: a control chip U1, a resistor R1, a resistor R2, a resistor R3, a capacitor C1, a capacitor C4, and a MOS transistor Q2. The first pin of the control chip U1 is connected to the USB_D+ pin of the USB interface, the second pin of the control chip U1 is connected to the USB_D- pin of the USB interface, the third pin of the control chip U1 is grounded, the eighth pin of the control chip U1 is connected to one end of the resistor R1, the ninth pin of the control chip U1 is connected to one end of the capacitor C1 and connected to VDD_SW, the tenth pin of the control chip U1 is connected to one end of the capacitor C4, one end of the resistor R2, one end of the resistor R3, and the drain of the MOS transistor Q2, the other end of the resistor R2 is connected to SW_OE, the gate of the MOS transistor Q2 is connected to VBUS, and the source of the MOS transistor Q2, the other end of the resistor R1, the other end of the resistor R3, the other end of the capacitor C1, and the other end of the capacitor C4 are grounded respectively.
3. The USB interface multiplexing circuit according to claim 1, characterized in that: The conversion circuit module is connected to a power supply circuit, which includes a field-effect transistor Q1, a voltage-stabilizing transistor D1, a resistor R6, and a resistor R7. The drain of the field-effect transistor Q1 is connected to SW_OE, the gate of the field-effect transistor Q1 and the positive terminal of the voltage-stabilizing transistor D1 are connected in parallel to VBUS, and the negative terminal of the voltage-stabilizing transistor D1 and the source of the field-effect transistor Q1 are connected in parallel to the conversion circuit; one end of the resistor R6 is connected to VDD_TEMP_ADC, the other end of the resistor R6 and one end of the resistor R7 are connected in parallel to SW_OE, and the other end of the resistor R7 is connected to VDD_TEMP_EXT.