CN110321310A - A method of realizing that serial ports and USB interface share - Google Patents
A method of realizing that serial ports and USB interface share Download PDFInfo
- Publication number
- CN110321310A CN110321310A CN201910517458.7A CN201910517458A CN110321310A CN 110321310 A CN110321310 A CN 110321310A CN 201910517458 A CN201910517458 A CN 201910517458A CN 110321310 A CN110321310 A CN 110321310A
- Authority
- CN
- China
- Prior art keywords
- usb
- pin
- realizing
- serial ports
- connects
- 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.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 21
- 239000004065 semiconductor Substances 0.000 claims description 22
- 239000003990 capacitor Substances 0.000 claims description 7
- 238000012360 testing method Methods 0.000 abstract description 14
- 238000012423 maintenance Methods 0.000 abstract description 12
- 230000009286 beneficial effect Effects 0.000 abstract description 2
- 101100451537 Caenorhabditis elegans hsd-1 gene Proteins 0.000 description 5
- 101100451536 Arabidopsis thaliana HSD2 gene Proteins 0.000 description 4
- 238000011161 development Methods 0.000 description 2
- 230000005611 electricity Effects 0.000 description 2
- 230000007423 decrease Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 238000003780 insertion Methods 0.000 description 1
- 230000037431 insertion Effects 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
- 230000008439 repair process Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/38—Information transfer, e.g. on bus
- G06F13/40—Bus structure
- G06F13/4063—Device-to-bus coupling
- G06F13/4068—Electrical coupling
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/38—Information transfer, e.g. on bus
- G06F13/42—Bus transfer protocol, e.g. handshake; Synchronisation
- G06F13/4282—Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2213/00—Indexing scheme relating to interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F2213/0042—Universal serial bus [USB]
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Computer Hardware Design (AREA)
- Debugging And Monitoring (AREA)
Abstract
The present invention relates to technical field of integrated circuits more particularly to a kind of method realizing serial ports and USB interface and sharing, including: a USB socket step S1, is provided, USB socket connects a USB and controls chip;Step S2, the USB connecting line of the subrack of the external USB connecting line being inserted into and outside is connected using USB socket, wherein the ID pin of subrack is grounded, and USB interface and serial ports is shared to control chip by USB.Technical solution of the present invention beneficial effect is: providing a kind of method realizing serial ports and USB interface and sharing, by USB interface and serial port, and only retain USB interface, four pin stands of serial ports are omitted, and software engineer is facilitated to debug the software fault of complete machine, it is also convenient for Test Engineer and Maintenance Engineer's capturing printing information, convenient for test and maintenance, and then promotes test and maintenance efficiency.
Description
Technical field
The present invention relates to technical field of integrated circuits more particularly to a kind of methods realizing serial ports and USB interface and sharing.
Background technique
With the fast development of integrated circuit, smart television, set-top box has serial ports involved in the electronic products such as intelligent sound box
With the design of USB.Just at present from the point of view of development, only one USB interface of the electronic products such as intelligent sound box, and one on machine shell
As there is no an interface position of reserved serial ports, but serial ports is required for exactly software engineer analyzes software issue again, in this way
After dressing up complete machine, machine failure needs to tear open machine again, in this way when producing in enormous quantities, will lead to production efficiency
Decline, inconvenient case study and maintenance after sale.
Solution in the prior art, (1) do not screw after dressing up complete machine, screw again after testing complete machine function,
It can save in this way and tear the machine time open;(2) test point or serial ports 4 needle stand, ground terminal and power supply of serial ports are reserved on mainboard
The extraction elsewhere from printed circuit board is held, this way needs to tear open machine, expends working hour, and be easy during tearing machine open
The line of the line and microphone that lead to loudspeaker is broken;Structure of need engineer in this way participates in, software engineer's inconvenience dismounting, this
Sample increases working hour and cost of labor, therefore is not easy to promote.
Summary of the invention
For the above-mentioned problems in the prior art, a kind of method realizing serial ports and USB interface and sharing now is provided.
Specific technical solution is as follows:
A method of realizing that serial ports and USB interface share, including:
Step S1, a USB socket is provided, the USB socket connects a USB and controls chip;
Step S2, the USB connection of the subrack of the external USB connecting line being inserted into and outside is connected using the USB socket
Line, wherein the ID pin of the subrack is grounded, and is total to the USB interface and the serial ports with controlling chip by the USB
With.
Preferably, the USB socket is Micro USB.
Preferably, in Yu Suoshu step S1, the USB socket is also connected with an operating circuit, and the operating circuit includes:
One first power end, for providing one first supply voltage;
One metal-oxide-semiconductor, the grid of the metal-oxide-semiconductor is connected to the ID pin of the USB socket by a first resistor, described
The drain electrode of metal-oxide-semiconductor is connected to ground terminal by a first capacitor, and the source electrode of the metal-oxide-semiconductor connects first power end;
One second resistance is connected between first power end and the ID pin of the USB socket;
One second capacitor is connected between the grid of the metal-oxide-semiconductor and first power end.
Preferably, the USB control chip includes:
One USB power source end connects first power end;
One selection input terminal, connects the ID pin of the USB socket;
One positive voltage terminal connects the positive voltage pin of the USB socket;
One negative voltage side connects the negative voltage pin of the USB socket;
One output enable end connects the ground terminal of the USB control chip.
Preferably, the USB socket further include:
One USB power source end, connects the drain electrode of the metal-oxide-semiconductor, for realizing USB OTG functional pin;
One end ID, for realizing USB ID pin.
Preferably, the USB controls chip further include:
One first positive multiplexing end, receives pin for realizing signal;
One first negative multiplexing end sends pin for realizing signal;
One second positive multiplexing end, for realizing USB OTG data positive signal pin;
One second negative multiplexing end, for realizing USBOTG data minus signal pins.
Preferably, the USB controls chip further include:
One 3rd resistor is connected between first power end and the selection input terminal;
One the 4th resistance connects the described first positive multiplexing end;
One the 5th resistance connects the first negative multiplexing end.
Preferably, the metal-oxide-semiconductor is P-channel metal-oxide-semiconductor.
Technical solution of the present invention beneficial effect is: a kind of method realizing serial ports and USB interface and sharing is provided, it will
USB interface and serial port, and only retain USB interface, four pin stands of serial ports are omitted, and facilitate soft project
Teacher debugs the software fault of complete machine, is also convenient for Test Engineer and Maintenance Engineer's capturing printing information, convenient for test and repairs,
And then promote test and maintenance efficiency.
Detailed description of the invention
With reference to appended attached drawing, more fully to describe the embodiment of the present invention.However, appended attached drawing be merely to illustrate and
It illustrates, and is not meant to limit the scope of the invention.
Fig. 1 is the step flow chart of the method for realizing that serial ports is shared with USB interface of the embodiment of the present invention;
Fig. 2 is the circuit connection of the operating circuit of the method for realizing that serial ports is shared with USB interface of the embodiment of the present invention
Figure.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete
Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on
Embodiment in the present invention, those of ordinary skill in the art without creative labor it is obtained it is all its
His embodiment, shall fall within the protection scope of the present invention.
It should be noted that in the absence of conflict, the feature in embodiment and embodiment in the present invention can phase
Mutually combination.
The present invention will be further explained below with reference to the attached drawings and specific examples, but not as the limitation of the invention.
The present invention includes a kind of method realizing serial ports and USB interface and sharing, including:
Step S1, a USB socket J1 is provided, one USB of USB socket J1 connection controls chip U1;
Step S2, the USB connecting line of the subrack for the USB connecting line and outside being inserted into using USB socket J1 connection outside,
Wherein, the ID pin ID ground connection of subrack, is shared USB interface and serial ports with controlling chip U1 by USB.
By the technical solution for the method that above-mentioned realization serial ports and USB interface share, as shown in Figure 1, in conjunction with USB socket J1
Chip U1 is controlled with USB, by USB interface and serial port, and only retains USB interface, four pin seats of serial ports is omitted
Son, and software engineer is facilitated to debug the software fault of complete machine, it is also convenient for Test Engineer and Maintenance Engineer grabs printing
Information convenient for test and maintenance, and then promotes test and maintenance efficiency.
In a kind of preferably embodiment, USB socket J1 is Micro USB, wherein Micro USB is 2.0 standard of USB
A portable version, it is smaller than the Mini USB interface that part mobile phone uses, have and save space, high intensity and high life
Feature.
In a kind of preferably embodiment, in step S1, USB socket J1 is also connected with an operating circuit, operating circuit packet
It includes:
One first power end V1, for providing one first supply voltage;
The grid of one metal-oxide-semiconductor Q1, metal-oxide-semiconductor Q1 are connected to ID the pin ID, MOS of USB socket J1 by a first resistor R1
The drain electrode of pipe Q1 is connected to ground terminal GND by a first capacitor C1, and the source electrode of metal-oxide-semiconductor Q1 connects the first power end V1;
One second resistance R2 is connected between the ID pin ID of the first power end V1 and USB socket J1;
One second capacitor C2 is connected between the grid of metal-oxide-semiconductor Q1 and the first power end V1.
In above-mentioned technical proposal, as shown in Fig. 2, the first supply voltage is 3.3V, metal-oxide-semiconductor Q1 is P-channel enhancement type MOS
Pipe, the resistance value of model WPM3401, first resistor R1 are 100K ohm, and the resistance value of second resistance R2 is 100K ohm, the first electricity
The capacitance for holding C1 is 22uF, and the capacitance of the second capacitor C2 is 0.1uF.
In a kind of preferably embodiment, USB control chip U1 includes:
One USB power source end VCC connects the first power end V1;
One selection input terminal S, connects the ID pin ID of USB socket J1;
One positive voltage terminal D+ connects the positive voltage pin D+ of USB socket J1;
One negative voltage side D- connects the negative voltage pin D- of USB socket J1;
One output enable end QE, the ground terminal GND of connection USB control chip U1.
Ground can be expanded, USB controls chip U1 further include:
One first positive multiplexing end HSD1+, receives pin Linux_RX for realizing signal;
One first negative multiplexing end HSD1- sends pin Linux_TX for realizing signal;
One second positive multiplexing end HSD2+, for realizing USB OTG data positive signal pin USB OTG_A_DP;
One second negative multiplexing end HSD2-, for realizing USBOTG data minus signal pins USB OTG_A_DM.
Ground can be expanded, USB controls chip U1 further include:
One 3rd resistor R3 is connected between the first power end V1 and selection input terminal S;
One the 4th resistance R4, the just multiplexing end HSD1+ of connection first;
One the 5th resistance R5 connects the first negative multiplexing end HSD1-.
In above-mentioned technical proposal, as shown in Fig. 2, the model SGM7227 of USB control chip U1, selects input terminal S to have
Two states, when selecting input terminal S=0, the first positive multiplexing negative multiplexing end HSD1- of end HSD1+ and first is on-state, the
The two positive multiplexing negative multiplexing end HSD2- of end HSD2+ and second are off-state;When selecting input terminal S=1, the first positive multiplexing end
HSD1+ is off-state with the first negative multiplexing end HSD1-, and the second positive multiplexing end HSD2+, is to connect with the second negative multiplexing end HSD2-
Logical state.
Further, in above-mentioned technical proposal, the resistance value of 3rd resistor R3 is 4.7K ohm, and the resistance value of the 4th resistance R4 is
0 ohm, the resistance value of the 5th resistance R5 is 0 ohm.
The USB socket J1 in a kind of preferably embodiment further include:
One USB power source end VBUS connects the drain electrode of metal-oxide-semiconductor Q1, for realizing USB OTG functional pin USBOTG_A_
VBUS;
One end ID ID, for realizing USB ID pin ID.
Specifically, as shown in Fig. 2, when USB socket J1 is inserted into USB connecting line, USB OTG functional pin USBOTG_A_
The voltage of VBUS is provided by external USB interface, due to not having to connect USB ID pin ID, USB ID pin ID pull-up for high electricity
Pressure, the second positive multiplexing end HSD2+ is connected to the second negative multiplexing end HSD2- at this time, is connected to the USB pin of USB control chip U1,
To realize that USB is communicated.
Further, when the USB connecting line of USB socket J1 insertion subrack, the ID foot ID ground connection of subrack, such ID
Foot ID is low level, and the first positive multiplexing end HSD1+ is connected to the first negative multiplexing end HSD1-, while metal-oxide-semiconductor Q1 is connected, and gives USB
OTG functional pin USBOTG_A_VBUS provides 3.3V voltage, and output is to subrack, since USB controls the end chip U1 USB OTG
Functional pin USBOTG_A_VBUS can support the supply voltage of 5V and 3.3V, thus it is unaffected, therefore, serial ports 3.3V, letter
Number receive pin Linux_RX, signal sends pin Linux TX, ground terminal GND and is just connected to.
Further, by USB interface and serial port, and only retain USB interface, four pin seats of serial ports are omitted
Son, and software engineer is facilitated to debug the software fault of complete machine, it is also convenient for Test Engineer and Maintenance Engineer grabs printing
Information convenient for test and maintenance, and then promotes test and maintenance efficiency.
The foregoing is merely preferred embodiments of the present invention, are not intended to limit embodiments of the present invention and protection model
It encloses, to those skilled in the art, should can appreciate that all with made by description of the invention and diagramatic content
Equivalent replacement and obviously change obtained scheme, should all be included within the scope of the present invention.
Claims (8)
1. a kind of method realizing serial ports and USB interface and sharing characterized by comprising
Step S1, a USB socket is provided, the USB socket connects a USB and controls chip;
Step S2, the USB connecting line of the subrack of the external USB connecting line being inserted into and outside is connected using the USB socket,
In, the ID pin of the subrack is grounded, and is shared the USB interface and the serial ports with controlling chip by the USB.
2. the method according to claim 1 realizing serial ports and USB interface and sharing, which is characterized in that the USB socket is
Micro USB。
3. the method according to claim 1 realizing serial ports and USB interface and sharing, which is characterized in that Yu Suoshu step S1
In, the USB socket is also connected with an operating circuit, and the operating circuit includes:
One first power end, for providing one first supply voltage;
One metal-oxide-semiconductor, the grid of the metal-oxide-semiconductor are connected to the ID pin of the USB socket, the metal-oxide-semiconductor by a first resistor
Drain electrode ground terminal is connected to by a first capacitor, the source electrode of the metal-oxide-semiconductor connects first power end;
One second resistance is connected between first power end and the ID pin of the USB socket;
One second capacitor is connected between the grid of the metal-oxide-semiconductor and first power end.
4. the method according to claim 1 realizing serial ports and USB interface and sharing, which is characterized in that the USB controls core
Piece includes:
One USB power source end connects first power end;
One selection input terminal, connects the ID pin of the USB socket;
One positive voltage terminal connects the positive voltage pin of the USB socket;
One negative voltage side connects the negative voltage pin of the USB socket;
One output enable end connects the ground terminal of the USB control chip.
5. the method according to claim 2 realizing serial ports and USB interface and sharing, which is characterized in that the USB socket is also
Include:
One USB power source end, connects the drain electrode of the metal-oxide-semiconductor, for realizing USB OTG functional pin;
One end ID, for realizing USB ID pin.
6. the method according to claim 1 realizing serial ports and USB interface and sharing, which is characterized in that the USB controls core
Piece further include:
One first positive multiplexing end, receives pin for realizing signal;
One first negative multiplexing end sends pin for realizing signal;
One second positive multiplexing end, for realizing USB OTG data positive signal pin;
One second negative multiplexing end, for realizing USBOTG data minus signal pins.
7. the method according to claim 1 realizing serial ports and USB interface and sharing, which is characterized in that the USB controls core
Piece further include:
One 3rd resistor is connected between the first voltage end and the selection input terminal;
One the 4th resistance connects the described first positive multiplexing end;
One the 5th resistance connects the first negative multiplexing end.
8. the method according to claim 3 realizing serial ports and USB interface and sharing, which is characterized in that the metal-oxide-semiconductor is P
Channel MOS tube.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910517458.7A CN110321310A (en) | 2019-06-14 | 2019-06-14 | A method of realizing that serial ports and USB interface share |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910517458.7A CN110321310A (en) | 2019-06-14 | 2019-06-14 | A method of realizing that serial ports and USB interface share |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110321310A true CN110321310A (en) | 2019-10-11 |
Family
ID=68119660
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910517458.7A Pending CN110321310A (en) | 2019-06-14 | 2019-06-14 | A method of realizing that serial ports and USB interface share |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110321310A (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102156681A (en) * | 2011-04-12 | 2011-08-17 | 惠州Tcl移动通信有限公司 | Mobile terminal and USB interface connection control device thereof |
CN102724339A (en) * | 2012-05-29 | 2012-10-10 | 惠州Tcl移动通信有限公司 | UART serial port and USB interface shared circuit and mobile phone |
CN204287813U (en) * | 2014-12-19 | 2015-04-22 | 西安Tcl软件开发有限公司 | Multifunctional interface circuit and development board |
CN107122319A (en) * | 2017-04-18 | 2017-09-01 | 深圳市菲菱科思通信技术股份有限公司 | One kind communication multiplex circuit |
CN207020661U (en) * | 2017-04-18 | 2018-02-16 | 深圳市菲菱科思通信技术股份有限公司 | One kind communication multiplex circuit |
-
2019
- 2019-06-14 CN CN201910517458.7A patent/CN110321310A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102156681A (en) * | 2011-04-12 | 2011-08-17 | 惠州Tcl移动通信有限公司 | Mobile terminal and USB interface connection control device thereof |
CN102724339A (en) * | 2012-05-29 | 2012-10-10 | 惠州Tcl移动通信有限公司 | UART serial port and USB interface shared circuit and mobile phone |
CN204287813U (en) * | 2014-12-19 | 2015-04-22 | 西安Tcl软件开发有限公司 | Multifunctional interface circuit and development board |
CN107122319A (en) * | 2017-04-18 | 2017-09-01 | 深圳市菲菱科思通信技术股份有限公司 | One kind communication multiplex circuit |
CN207020661U (en) * | 2017-04-18 | 2018-02-16 | 深圳市菲菱科思通信技术股份有限公司 | One kind communication multiplex circuit |
Non-Patent Citations (1)
Title |
---|
李元章等: "汇编语言与接口技术", 北京理工大学出版社, pages: 265 - 270 * |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3016363B1 (en) | Communication module and terminal for realizing hot plug | |
CN102750252B (en) | USB/UART interface multiplexing circuit and use the electronic equipment of this circuit | |
CN102064582B (en) | Terminal capable of supplying power for outside | |
CN110381273B (en) | Liquid crystal television circuit system and interface | |
CN105656471A (en) | System with USB-C type interface and multifunctional control circuit | |
CN101963949B (en) | Hot plug realization method, hot plug system and board card | |
CN103561369A (en) | Usb interface circuit and electronic equipment | |
CN104239169A (en) | Signal testing card and method | |
CN103208822A (en) | Universal serial bus (USB) charging control circuit | |
CN206133546U (en) | Storage device's break -make testing arrangement and system | |
CN102156681A (en) | Mobile terminal and USB interface connection control device thereof | |
CN105915898B (en) | The AccessPort device and its system of a kind of television set | |
CN103219042B (en) | Circuit and the memory circuitry of burning program is realized by USB interface | |
US20100070694A1 (en) | Computer system having ram slots with different specifications | |
KR20130106262A (en) | Processing device and processing system | |
CN110297789B (en) | Method for realizing USB OTG function | |
CN110321310A (en) | A method of realizing that serial ports and USB interface share | |
CN103092300A (en) | Internal storage power supply control circuit | |
CN116340220A (en) | USB communication interface adapter | |
CN211180806U (en) | Debugging serial port circuit based on HDMI interface, HDMI interface module and HDMI equipment | |
CN109388602B (en) | Electronic device, logic chip and communication method of logic chip | |
EP1869563B1 (en) | Configurable data port for i2c or single-wire broadcast interface | |
CN109960677B (en) | Extension circuit for USB interface | |
CN203760209U (en) | MHL cable and MHL cable hot plug detecting system | |
CN204697180U (en) | Chip main board and television set |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20191011 |
|
RJ01 | Rejection of invention patent application after publication |