Hardware Reference
In-Depth Information
only one in the frame. The IN token packet is a poll, asking the device to return
certain data. Fields in the IN packet tell which bit pipe is being polled so the de-
vice knows which data to return (if it has multiple streams). The OUT token packet
announces that data for the device will follow. A fourth type of token packet,
SETUP (not shown in the figure), is used for configuration.
Besides the token packet, three other kinds exist. These are DATA (used to
transmit up to 64 bytes of information either way), handshake, and special packets.
The format of a DATA packet is shown in Fig. 3-58. It consists of an 8-bit syn-
chronization field, an 8-bit packet type ( PID ), the payload, and a 16-bit CRC
( Cyclic Redundancy Check ) to detect errors. Three kinds of handshake packets
are defined: ACK (the previous data packet was correctly received), NAK (a CRC
error was detected), and STALL (please wait—I am busy right now).
Now let us look at Fig. 3-58 again. Every 1.00 msec a frame must be sent
from the root hub, even if there is no work. Frames 0 and 2 consist of just an SOF
packet, indicating that there was no work. Frame 1 is a poll, so it starts out with
SOF and IN packets from the computer to the I/O device, followed by a DATA
packet from the device to the computer. The ACK packet tells the device that the
data were received correctly. In case of an error, a NAK would be sent back to the
device and the packet would be retransmitted for bulk data (but not for isochronous
data). Frame 3 is similar in structure to frame 1, except that now the data flow is
from the computer to the device.
After the USB standard was finalized in 1998, the USB designers had nothing
to do so they began working on a new high-speed version of USB, called USB 2.0 .
This standard is similar to the older USB 1.1 and backward compatible with it, ex-
cept that it adds a third speed, 480 Mbps, to the two existing speeds. There are
also some minor differences, such as the interface between the root hub and the
controller. With USB 1.1 two new interfaces were available. The first one, UHCI
( Universal Host Controller Interface ), was designed by Intel and put most of the
burden on the software designers (read: Microsoft). The second one, OHCI
( Open Host Controller Interface ), was designed by Microsoft and put most of
the burden on the hardware designers (read: Intel). In USB 2.0 everyone agreed to
a single new interface called EHCI ( Enhanced Host Controller Interface ).
With USB now operating at 480 Mbps, it clearly competes with the IEEE 1394
serial bus popularly called FireWire, which runs at 400 Mbps or 800 Mbps. Be-
cause virtually every new Intel-based PC now comes with USB 2.0 or USB 3.0
(see below) 1394 is likely to vanish in due course. This disappearance is not so
much due to obsolescence as to turf wars. USB is a product of the computer indus-
try whereas 1394 comes from the consumer electronics industry. When it came to
connecting cameras to computers, each industry wanted everyone to use its cable.
It looks like the computer folks won this one.
Eight years after the introduction of USB 2.0, the USB 3.0 interface standard
was announced. USB 3.0 supports a whopping 5-Gbps bandwidth over the cable,
although the link modulation is adaptive, and one is likely to achieve this top speed
 
Search WWH ::




Custom Search