CN1392480A - Method for detecting host controller transmission rate for USB device - Google Patents

Method for detecting host controller transmission rate for USB device Download PDF

Info

Publication number
CN1392480A
CN1392480A CN 02122739 CN02122739A CN1392480A CN 1392480 A CN1392480 A CN 1392480A CN 02122739 CN02122739 CN 02122739 CN 02122739 A CN02122739 A CN 02122739A CN 1392480 A CN1392480 A CN 1392480A
Authority
CN
China
Prior art keywords
transmission rate
usb device
host controller
signal
usb
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.)
Granted
Application number
CN 02122739
Other languages
Chinese (zh)
Other versions
CN1186721C (en
Inventor
许宏舟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Via Technologies Inc
Original Assignee
Via Technologies Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Via Technologies Inc filed Critical Via Technologies Inc
Priority to CNB02122739XA priority Critical patent/CN1186721C/en
Publication of CN1392480A publication Critical patent/CN1392480A/en
Application granted granted Critical
Publication of CN1186721C publication Critical patent/CN1186721C/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Images

Landscapes

  • Information Transfer Systems (AREA)
  • Communication Control (AREA)

Abstract

The present invention relates to a kind of USB device and especially the method of detecting host controller transmission rate of USB device. By using the program memory unit in the USB device, are executed the following steps: starting the interruption request of the timer in the program; detecting whether or not the host controller responses the signal of the high speed USB controller within preset time; setting the transmission rate in high speed mode if so; and setting the transmission rate in safet mode if not. The said method can complete the detection of transmission rate in host computer fast with the least program codes.

Description

The method of USB device detecting host controller transmission rate
Technical field
The invention relates to a kind of method of USB device detecting host controller transmission rate.
Background technology
In recent years, because the high development of information related industry and people increase day by day to the requirement of information product computing and transmission speed, make the bus-bar technology of USB1.1 (the Universal Serial Bus) specification that the dealer commonly used in the past apply use, under the continuous excelsior research and development improvement of dealer, there is the new spec that can improve transfer rate in a large number to emerge finally.
Because the USB specification has plug and play (Plug-And-play; Can contact PNP), at most 127 USB devices, the electric power of 5V can be provided, and only need take an advantage such as IRQ, and be subjected to liking of numerous users.The transfer rate of employed in the past USB1.1 specification comprises the 1.5Mbps of low speed (Low speed) and two kinds of speed of 12Mbps of full speed (Full speed), for general device at a slow speed such as keyboard, slide-mouse, and audio device etc. enough uses, yet then still dislike not enough for devices such as the accesses of handling picture, video signal and data, so transfer rate is promptly received ardent echoing up to high speed USB (USB2.0) specification of 480Mbps once releasing.
At the initial stage that the high speed USB specification is released, the product that can support the high speed USB specification on the market is actually rare, and old USB specification (USB1.1) also still has the value of its existence, so system manufacturer must be taken the compatibility with old lattice into account in the design of computer system, and also be an important topic to the identification that peripheral USB device can be supported transfer rate.
The computer that generally includes the high speed USB controller for the discrimination method of peripheral USB device transfer rate as shown in Figure 1, at first, in institute coupling arrangement USB port, the signal wire that pullup resistor (pull-up resistor) is connected detects whether hookup mechanism is low speed device 101; If then can only transmit 121 with low-speed mode; If not, show that then this device can support at full speed transmission mode at least, can proceed the detection of fast mode.At this moment, can send SE0 signal 103, wait for then and check this device whether in 3ms, to respond a K signal 105 by the USB controller; If not, represent that then this device is a USB device at full speed, transmit 125 as pattern at full speed; If then begin to carry out speeder detection process (chirpsequence) 107.Judge whether the speeder detection process finishes 109; If not, then at full speed pattern transmit 125; If, represent that then this device is the high speed USB device, can transmit 111 by fast mode.
Though above-mentioned method can solve the problem of high speed USB controller identification USB device transfer rate, yet, the dealer of relative production high speed USB device also faces same problem, its high speed USB device of producing also wants to be compatible to the USB1.1 controller of old specification, to improve its applicability, avoid the user when choosing, to produce puzzled and contradiction.
Therefore, the problem how to be taken place when judging and detect the USB controller transmission rate at the high speed USB device proposes a kind of novel solution, design a kind of high efficiency method for detecting, not only can effectively finish the detecting of transfer rate, and can shorten the program of detecting, reduce required procedure code, but and the result of duplicate acknowledgment detecting, be not to use for a long time the person eagerly to look forward to and difficulty place that human desires row of the present invention solves always, and the inventor is based on the correlative study of engaging in IT industry for many years, exploitation, and the practical experience of selling, the idea of thinking and improveing, through design in many ways, inquire into, after studying sample and improvement, finally work out a kind of method of USB device detecting host controller transmission rate, to solve the above problems.
Technical matters to be solved by this invention is, at the above-mentioned deficiency of prior art, and provides a kind of method of USB device detecting host controller transmission rate.
Above-mentioned technical matters of the present invention is realized by following technical scheme.
A kind of method of USB device detecting host controller transmission rate is characterized in that: this USB device includes at least one program storage device, and the main implementation step of its detecting host controller transmission rate is to include:
Start the interrupt request of timer;
Detect this main frame and whether in a schedule time, respond a signal corresponding to the high speed USB controller;
If transmission mode is set at fast mode; And
If not, then transmission mode is set at pattern at full speed.
Except that above-mentioned essential features, in specific implementation process, also can replenish following technology contents:
This schedule time is to be 3.0ms.
Should be one group of signal of representing KJKJKJ corresponding to the signal of high speed USB controller.
Between each K signal and J signal is less than 3.0ms at interval.
This main frame is to be chosen as one of them of computer and hub.
This program storage device is a storer.
This program storage device still includes a rate identification flag.
Still can include the following step:
Before sending interrupt request, earlier this identification flag is made zero;
Whether in the schedule time, respond and can replace by the following step and detect this main frame corresponding to the step behind the signal of high speed USB controller:
If identification flag is set at fast mode;
If not, then identification flag is set at pattern at full speed; And
The result sets transfer rate according to detecting.
Still can include the following step:
Reaffirm detecting result and identification flag scale value identical errorless after, set transfer rate according to the result again.
This rate identification flag target value is to represent pattern at full speed with 1.
The invention has the advantages that:
Utilize a program storage device in the USB device, detect its main frame that connects and whether in a schedule time, respond signal corresponding to the high speed USB controller, use and judge whether this main frame supports the high-speed transfer pattern, and procedure code that can be minimum is finished the detecting of host transfer rate fast.
Now for feature of the present invention, spirit and the effect reached are had further understanding and understanding, careful assistant describe in detail with preferred embodiment and conjunction with figs. as after:
Description of drawings
Fig. 1 is a process flow diagram of commonly using USB controller detecting USB device transfer rate.
Fig. 2 is the process flow diagram of a preferred embodiment of the present invention.
Fig. 3 is the process flow diagram of another embodiment of the present invention.
Embodiment
At first, seeing also Fig. 2, is the process flow diagram of a preferred embodiment of the present invention.As shown in the figure, method for detecting of the present invention is to be connected to a main frame when a high speed USB device, and during as computer or usb hub (hub), this USB device can be prior to starting interrupt request (the Interrupt Request of timer in the program; IRQ) signal 201, the USB controller of main frame then can reset (reset) action and send the SEO signal, because this USB device is a high speed USB device, thus receive the SEO signal after can send the K signal and enter detection process main frame USB controller transmission rate.Owing to stipulate that the controller of main frame need be responded the K signal and add J signal at least three times in the high speed USB interface specification, just can confirm as a high speed USB controller, pretend the industry flow process and at first check whether in 3ms, receive K signal 203; If then continue check and whether in 3ms, receive J signal 205; If then whether check receives K signal 207 in 3ms again; If whether check receives J signal 209 in 3ms again; If can check again whether in 3ms, to receive K signal 211; If whether check receives J signal 213 in 3ms again; If the result is still for being can determine that then this USB controller is a high speed USB controller, so transfer rate is set at fast mode 215; If the testing result that above-mentioned steps 203 to step 213 has any step for not, promptly has the situation that does not receive K signal or J signal above 3ms to take place, represent that then this USB controller do not support the high-speed transfer pattern, so transfer rate is set at full speed pattern 223.
Utilize the method for detecting of the above embodiment of the present invention, only need several judgement formulas and loop, can correctly finish the detecting of main frame USB controller transmission rate, can make that the required procedure code of detecting minimizes in the USB device, and detect required formality and time-histories also obtains maximum simplification and saving.
Secondly, seeing also Fig. 3, is the process flow diagram of another embodiment of the present invention.As shown in the figure, method for detecting of the present invention still can be set up a rate identification flag (flag), as the full speed flag of step 301 among the figure, uses the usefulness as the identification of transfer rate.Its method for detecting is that flag fills out 0 at first at full speed, then in program, start the irq signal 301 of timer, the USB controller for the treatment of main frame reset (reset) action and after sending the SEO signal, send the K signal and enter detection process main frame USB controller transmission rate.Whether check receives K signal 303 in 3ms; If then continue check and whether in 3ms, receive J signal 305; If then whether check receives K signal 307 in 3ms again; If whether check receives J signal 309 in 3ms again; If whether the check that can carry out the K signal again receives 311 in 3ms; If whether check receives J signal 313 in 3ms again.If the testing result that above-mentioned steps 303 to step 313 has any step for not, promptly has the situation that does not receive K signal or J signal above 3ms to take place, represent that then this USB controller do not support the high-speed transfer pattern, so should insert 323 with 1 by full speed flag target value; And transfer rate is set at full speed mode 3 25.If step 313 assay in order to determine not influenced by noise between detection period and make a mistake, still can carry out step 315 for being, check whether dehorn is 0 at full speed again; If, can confirm that then assay is correctly undisturbed, transfer rate can be set at fast mode; If not, then represent to make a mistake because of being subjected to the noise interference in the checkout procedure, so transfer rate must be set at mode 3 25 at full speed.So, can reach the purpose of duplicate acknowledgment.
The method for detecting of the various embodiments described above all can utilize the stored detection process of a program storage device in the high speed USB device to be finished.Rate identification flag in embodiment illustrated in fig. 3 can be located in this program storage device, can also be a field in the working storage, is 0 or 1 to come identification it is to be fast mode or pattern at full speed by the value of this field; In the above-described embodiments, be that to represent it with 1 be pattern at full speed.In addition, omnidistance preface storage device can be implemented by a storer in the USB device, and tolerable deviser or user are upgraded to its content or revise.
In sum, the invention relates to a kind of method of USB device detecting host controller transmission rate, it mainly is to utilize a program storage device in the USB device, detect its main frame that connects and whether in a schedule time, respond signal corresponding to the high speed USB controller, use and judge whether this main frame supports the high-speed transfer pattern, and procedure code that can be minimum is finished the detecting of host transfer rate fast.So the present invention one is rich in novelty, progressive, and can utilize effect for industry, meet the patented claim important document, submit application for a patent for invention in accordance with the law to, earnestly ask your juror and vouchsafe patent of the present invention early, the true feeling moral just.
All equalizations of doing by method of the present invention, structure, feature and spirit change and modify, and all should be included in the claim of the present invention.

Claims (10)

1, a kind of method of USB device detecting host controller transmission rate is characterized in that: this USB device includes at least one program storage device, and the main implementation step of its detecting host controller transmission rate is to include:
Start the interrupt request of timer;
Detect this main frame and whether in a schedule time, respond a signal corresponding to the high speed USB controller;
If transmission mode is set at fast mode; And
If not, then transmission mode is set at pattern at full speed.
2, the method for USB device detecting host controller transmission rate according to claim 1 is characterized in that: this schedule time is to be 3.0ms.
3, the method for USB device detecting host controller transmission rate according to claim 1 is characterized in that: should be one group of signal of representing KJKJKJ corresponding to the signal of high speed USB controller.
4, the method for USB device detecting host controller transmission rate according to claim 3 is characterized in that: between each K signal and J signal is less than 3.0ms at interval.
5, the method for USB device detecting host controller transmission rate according to claim 1 is characterized in that: this main frame is to be chosen as one of them of computer and hub.
6, the method for USB device detecting host controller transmission rate according to claim 1 is characterized in that: this program storage device is a storer.
7, the method for USB device detecting host controller transmission rate according to claim 1 is characterized in that: this program storage device still includes a rate identification flag.
8, the method for USB device detecting host controller transmission rate according to claim 7 is characterized in that: still can include the following step:
Before sending interrupt request, earlier this identification flag is made zero;
Whether in the schedule time, respond and can replace by the following step and detect this main frame corresponding to the step behind the signal of high speed USB controller:
If identification flag is set at fast mode;
If not, then identification flag is set at pattern at full speed; And
The result sets transfer rate according to detecting.
9, the method for USB device detecting host controller transmission rate according to claim 7 is characterized in that: still can include the following step:
Reaffirm detecting result and identification flag scale value identical errorless after, set transfer rate according to the result again.
10, the method for USB device detecting host controller transmission rate according to claim 7 is characterized in that: this rate identification flag target value is to represent pattern at full speed with 1.
CNB02122739XA 2002-06-07 2002-06-07 Method for detecting host controller transmission rate for USB device Expired - Lifetime CN1186721C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB02122739XA CN1186721C (en) 2002-06-07 2002-06-07 Method for detecting host controller transmission rate for USB device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB02122739XA CN1186721C (en) 2002-06-07 2002-06-07 Method for detecting host controller transmission rate for USB device

Publications (2)

Publication Number Publication Date
CN1392480A true CN1392480A (en) 2003-01-22
CN1186721C CN1186721C (en) 2005-01-26

Family

ID=4745082

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB02122739XA Expired - Lifetime CN1186721C (en) 2002-06-07 2002-06-07 Method for detecting host controller transmission rate for USB device

Country Status (1)

Country Link
CN (1) CN1186721C (en)

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1294494C (en) * 2003-06-05 2007-01-10 英业达股份有限公司 System for detecting master USB interface transfer rate and method thereof
CN1326059C (en) * 2003-09-24 2007-07-11 佳能株式会社 Image processing apparatus, and image processing method and program therefor
CN100533419C (en) * 2007-03-13 2009-08-26 威盛电子股份有限公司 USB peripheral equipment and mode detecting method thereof
CN101135985B (en) * 2006-09-01 2010-08-25 鸿富锦精密工业(深圳)有限公司 Computer data transmission speed testing system and method
CN102103562A (en) * 2009-12-17 2011-06-22 财团法人工业技术研究院 Multi-power mode serial interface architecture
CN102156618A (en) * 2010-02-11 2011-08-17 爱国者电子科技有限公司 Memory device with multiple connectors and method for transmitting data
US8527667B2 (en) 2009-09-24 2013-09-03 Maishi Electronic (Shanghai) Ltd Apparatuses and methods for transferring data
WO2019042421A1 (en) * 2017-08-31 2019-03-07 西安中兴新软件有限责任公司 Method, apparatus and device for rate adjustment of usb data transmission, and storage medium

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1294494C (en) * 2003-06-05 2007-01-10 英业达股份有限公司 System for detecting master USB interface transfer rate and method thereof
CN1326059C (en) * 2003-09-24 2007-07-11 佳能株式会社 Image processing apparatus, and image processing method and program therefor
CN101135985B (en) * 2006-09-01 2010-08-25 鸿富锦精密工业(深圳)有限公司 Computer data transmission speed testing system and method
CN100533419C (en) * 2007-03-13 2009-08-26 威盛电子股份有限公司 USB peripheral equipment and mode detecting method thereof
US8527667B2 (en) 2009-09-24 2013-09-03 Maishi Electronic (Shanghai) Ltd Apparatuses and methods for transferring data
CN102103562A (en) * 2009-12-17 2011-06-22 财团法人工业技术研究院 Multi-power mode serial interface architecture
CN102156618A (en) * 2010-02-11 2011-08-17 爱国者电子科技有限公司 Memory device with multiple connectors and method for transmitting data
CN102156618B (en) * 2010-02-11 2015-06-17 爱国者电子科技有限公司 Memory device with multiple connectors and method for transmitting data
WO2019042421A1 (en) * 2017-08-31 2019-03-07 西安中兴新软件有限责任公司 Method, apparatus and device for rate adjustment of usb data transmission, and storage medium

Also Published As

Publication number Publication date
CN1186721C (en) 2005-01-26

Similar Documents

Publication Publication Date Title
CN102749985B (en) Method and device for dynamically adjusting bus clock
CN101957807A (en) Method for USB device to recognize version type of Windows operating system
CN1186721C (en) Method for detecting host controller transmission rate for USB device
CN1804799A (en) SCM online loading and updating method and system
CN1251106C (en) Method of enabling a port in computing device
CN2888537Y (en) A digital communication interface conversion module
US7173964B2 (en) Method for detecting data transmission rate of USB controller by using USB device
CN112639755A (en) Slave-to-slave direct communication
EP1199641A3 (en) Data processing device used in serial communication system
US7979612B2 (en) Communication method and apparatus
CN1821986A (en) Control apparatus, information processing apparatus, and data transferring method
CN100343840C (en) Bus system, station for use in a bus system, and bus interface
US8074232B2 (en) Method for improving the communication of the human interface device
CN1229736C (en) Device for monitoring computer system resource and communicatin method of serial bus and said resource
CN2651843Y (en) Master realtime monitor
CN1316388C (en) USB control circuit suitable to computer-to-computer transmission and its operation method
CN1147774C (en) Computer device and its change method from power economizing mode into operation mode
CN101140552A (en) Control system of data-transmission through universal serial bus and method thereof
CN103207850B (en) The transmission system of heterogeneous device
CN1639701A (en) USB host controller
CN1959791A (en) Method for providing function of flash message, and mobile communication terminal
CN108363674B (en) Wireless USB data interaction system and method
US20150095540A1 (en) External device and a transmission system and the method of the heterogeneous device
CN200972508Y (en) Communication device between radar main control PC machine and receiver based on USB
CN1127019C (en) Method for hot switching of peripherals in single IDE interface

Legal Events

Date Code Title Description
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CX01 Expiry of patent term

Granted publication date: 20050126

CX01 Expiry of patent term