Recent Articles



































Universal Serial Bus



         


Note: USB may also mean upper sideband in radio.

Universal Serial Bus (USB) provides a serial bus standard for connecting devices, usually to a computer, but it also is in use on other devices such as set-top boxes, game consoles and PDAs. USB types are type A USB (host), Type B USB (slave) and USB OTG (On-The-GO, can act as a slave and host).

[Top]

Overview

A USB system has an asymmetric design, consisting of a single host and multiple devices connected in a tree-like fashion using special hub devices. Up to 127 devices may be connected to a single host, but the count must include the hub devices as well, so the total useful number of connected devices diminishes somewhat. There is no need for a terminator on any USB bus, as there is for SCSI and some others.

The standard includes provision for power to the connected device. Some devices draw minimal power, so several may connect without needing extra power sources. Most hubs include power supplies which will power devices connected through them, but some devices draw enough that they need their own power. Powered hubs supply power to downstream devices (within prescribed limits, usually 500mA) without draining power from the upstream connection.

The design of USB aimed to remove the need for adding separate expansion cards into the computer's ISA or PCI bus, and improve plug-and-play capabilities by allowing devices to be hot swapped or added to the system without rebooting the computer. When the new device first plugs in, the host enumerates it and loads the device driver necessary to run it. USB can connect peripherals such as mice, keyboards, scanners, digital cameras, printers, hard drives, and networking components. For multimedia devices such as scanners and digital cameras, USB has become the standard connection method. For printers, USB has also grown in popularity and started displacing parallel ports because USB makes it simple to add more than one printer to a computer. As of 2004 there were about 1 billion USB devices in the world.


[Top]

Compared to other standards

[Top]

Storage

In the case of hard drives, USB seems unlikely to completely replace buses such as ATA (IDE) and SCSI because USB performs somewhat more slowly than those standards. However, USB has one important advantage in making it possible to install and remove devices without opening the computer case, making it useful for external drives. Today, a number of manufacturers offer portable USB hard drives that offer performance nearly indistinguishable from conventional ATA (IDE) drives. These external drives are often composed of translating devices that connect to USB on one side and to conventional IDE, ATA, ATAPI, or SCSI drives on the other. When a drive is available from a manufacturer only as an "internal" drive, it is sometimes possible to purchase an inexpensive (or non-functioning) USB drive and swap the device. This makes it possible to use an "internal" drive with a laptop computer.

Firewire technology is also commonly used with portable hard drives, and while USB 2.0 boasts 480mbps throughput (versus Firewire's 400mbps), Firewire connections tend to perform better in speed benchmarks . USB ports are more common on consumer-level computers however, which enhances the portability of a USB drive. Some portable drive enclosures provide both types of ports.

[Top]

Peripherals

USB has not completely replaced AT keyboard connections and PS/2 mouse connections, but virtually all PC motherboards today have one or more USB ports. As of 2004, most new motherboards have multiple USB 2.0 high-speed ports, though some are internal, and require a "header" connection to be accessible from the front or rear of the computer case.

[Top]

USB standards

USB 1.0 supports two data rates of 1.5 Mbit/s for keyboards, mice, joysticks and the like, and a full speed mode at 12 Mbit/s.

USB 1.1 standard adds interrupt OUT transfers. See http://www.mindshare.com/pdf/usb10to11.doc for details.

The major feature of the USB 2.0 standard is the addition of a high-speed rate of 480 Mbit/s. It also clarifies minor technical errata. At its highest speed USB competes directly with FireWire, except in the area of digital camcorders, where USB has technological limitations that prevent it from being viable.

Confusingly, the IBM UltraPort is a proprietary USB connector located on the top of IBM's notebook LCDs. It uses a different mechanical connector while preserving the USB signaling and protocol. Other manufacturers of small items also developed their own small form factor connector, and a wide variety of these has appeared. For specification purposes, these devices were treated as having a captive cable.

An extension to USB called USB-On-The-Go allows a single port to act as either a host or a device - chosen by which end of the cable plugs into the socket on the unit. Even after the cable is hooked up and the units are talking, the two units may "swap" ends under program control. This facility targets units such as PDAs where the USB link might connect to a PC's host port as a device in one instance, yet connect as a host itself to a keyboard and mouse device in another instance. USB-On-The-Go has therefore defined two small form factor connectors, the mini-A and mini-B, and a hermaphroditic socket, which should stop the proliferation of proprietary designs.

round-robin fashion, so no device can transfer any data on the bus without explicit request from the host controller.

To access an endpoint, an hierarchical configuration must be obtained. The device connected to the bus has one (and only one) device descriptor which in turn has one or more configuration descriptors. These configurations often correspond to states, e.g. active vs. low power mode. Each configuration descriptor in turn has one or more interface descriptors, which describe certain aspects of the device, so that it may be used for different purposes: for example, a camera may have both audio and video interfaces. These interface descriptors in turn have one default interface setting and possibly more alternate interface settings which in turn have endpoint descriptors, as outlined above. An endpoint may however be reused among several interfaces and alternate interface settings.

The hardware that contains the host controller and the root hub has an interface toward the programmer which is called Host Controller Device (HCD) and is defined by the hardware implementer. Compaq created the first such public specification and named it Open Host Controller Interface (OHCI). Intel subsequently created specifications for two such standard interfaces named Universal Host Controller Interface (UHCI) and Extended Host Controller Interface (EHCI). In practice, these are hardware registers (ports) in the computer. These are the only interfaces found in practice on desktop computers. Only EHCI can support high-speed transfers.

Devices that attach to the bus can be full-custom devices requiring a full-custom device driver to be used, or may belong to a device class. These classes define an expected behaviour in terms of device and interface descriptors so that the same device driver may be used for any device that claims to be a member of a certain class.

[Top]

USB adapters

Some USB adapters allow the connection of "devices" simply to get power (car lighter USB adapter), such as to recharge a small device (like a keychain digital camera), or to power a small LED-light lamp for reading.

[Top]

See also

[Top]




  View Live Article   This article is from Wikipedia. All text is available under the terms of the GNU Free Documentation License