USB 1.1 had only Low and Full speed, USB 2.0 introduces High speed. There are plans to double the speed of USB 3.0 to 10 Gb/s sometime in 2013.
A device that is limited only by the USB bus itself might be expected to transfer data at 60 percent of the bus clock rate. Design limitations in the device itself often are the limiting factor. Some sources say you might expect 53 MB/s for high speed and 1.2 MB/s for full speed (doing bulk transfers, which are the fastest).
As an example, an Arduino Uno can communicate no faster than 115200 baud (115.2 Kbit/second), even though it is a full speed device. (All AVR devices I have yet examined identify themselves as full speed devices, including several 32u4 based devices and the 90USB1286 "teensy++ 2.0).
USB devices indicate their speed (and their presence on the bus) by pull up resistors to 3.3 volts on the D- and D+ lines.
The USB standard says that a device is either a hub or a function. This can lead to some pedantic silliness, but just comfort yourself knowing that your mouse is both a device and in particular a function.
The standard says that the topology can only have 7 levels. The host "root hub" uses one of these levels, and you cannot put a hub at the end with any useful effect. This means that you can have only 5 hubs chained together between the root hub in your computer and whatever device is at the end. I have never seen anyone crazy enough to do anything like this.
Note that software is blissfully unaware of any hubs between the host controller and the target device.
Note that cable length is limited to 5 meters, so if you did the absurd thing of getting 5 hubs and stringing things out as far as you could, you could reach to 30 meters away. I would be a gigantic pain in the ass and why would you do it?
There are 3 kinds of USB host controllers, each with their own specification! USB 3 adds a fourth, but we weren't going to talk about that. You can tell that a committee couldn't agree on things.
Each USB device identifies itself with a pair of numbers (vendor and device ID). This allows "plug and play" (oh, how we hate this phrase), wherein the host operating system can dynamically decide what device driver to delegate to handle each USB device that appears on the bus.
A USB cable consists of 4 conductors:
Note that there is only one data pair (in contrast to ethernet which has two pairs). This implies that USB uses some kind of half duplex protocol where first one side talks and then another side replies and there is some orderly control over who is sending and who is receiving at any given point in time. We will get to all this in due time.
A USB cable is limited to a length of 5 meters (about 16 feet). To reach out further than this, you have to use USB hubs (see above).
A USB 3.0 cable has the exact same four conductors just described, for compatibility with USB 2.0. It also adds 5 new conductors (a ground and two twisted pairs) to support the new higher speed transfers with different signalling.
Cables have distinct upstream and downstream ends.
Interestingly, a standard male USB A plug is rated for only 1500 insertions, at which point it is expected to get "sloppy" and require replacement. The delicate looking micro USB plug is actually more durable than the mini plug, being rated for 10,000 insertions. The trick with the mini is to build the device to solidly reinforce the connector within the device. It is often a surface mount connector that easily can be popped off of a circuit board.
The familiar big flat end of a cable that you plug into your computer is called a standard "A" receptacle.
At one point I needed to repair a device with a broken micro USB connector. I replaced it with a standard "B" female connector, and needed to figure out the pinout for the female "B". It looked like this, viewed from the underside (the copy I obtained had 4 pins on 0.1 inch centers on the bottom:
Vcc D- Gnd D+ ^^^ Insert cable from here
Tom's Computer Info / [email protected]