The USB Process

When the host powers up, it queries all of the devices connected to the bus and assigns each one an address. This process is called enumeration , The host also finds out from each device what type of data transfer it wishes to
perform:

  • Interrupt – A device like a mouse or a keyboard, which will be sending very little data, would choose the interrupt mode.

  • Bulk – A device like a printer, which receives data in one big packet, uses the bulk transfer mode. A block

    of data is sent to the printer (in 64-byte chunks) and verified to make sure it is correct.

  • Isochronous – A streaming device (such as speakers) uses the isochronous mode. Data streams between the device and the host in real-time, and there is no error correction.

The host can also send commands or query parameters with control packets.

The devices connected to a USB port rely on the USB cable to carry power and data.

The Universal Serial Bus divides the available bandwidth into frames, and the host controls the frames. Frames contain 1,500 bytes, and a new frame starts every millisecond. During a frame, isochronous and interrupt devices get a slot so they are guaranteed the bandwidth they need. Bulk and control transfers use whatever space is left.