Premium Content

New Signal Chain Resources from Texas Instruments:

Quickly And Easily Automate Test Systems With USB

Achieve bus speeds of up to 480 Mbits/s while benefiting from a multitude of readily available cables, hubs, and converters.

Date Posted: October 28, 2002 12:00 AM
Author: Andy Purcell

For large transfers, full-speed implementations realistically provide about a 1-Mbyte/s transfer rate. High-speed implementations will offer anywhere from 6 to 40 Mbytes/s, depending on the device's architecture and firmware—and the USB software on the computer. Data will burst at 480 Mbits/s (60 Mbytes/s), but sustained data rates are lower due to USB, computer software, and device overhead. After picking full- or high-speed, the choice of USB device silicon still depends on several other criteria:

  • Device class: Some USB silicon is built for specific device classes. For example, a USB chip may be targeted to mass-storage devices, and therefore be optimized for the mass-storage device class. Others are general-purpose. Firmware can determine the device class that gets reported to the OS when the device is enumerated. To implement USBTMC specification, use a general-purpose chip. No matter the device class to be implemented, consult the class specification to understand any extra requirements or opportunities for optimization.
  • Number of endpoints: Most general-purpose USB chips supply the required control endpoint and two or more configurable endpoints. Firmware configures the endpoints to be bulk, interrupt, or isochronous. USBTMC requires three endpoints (Control, Bulk-OUT, Bulk-IN). A fourth endpoint (interrupt-IN) is necessary for the device to communicate interrupt conditions (similar to GPIB service requests) when measurement results are ready, or when an error occurs. Most USB silicon will run with at least this number of endpoints.
  • Amount of endpoint FIFO memory: When the computer sends data to the device, the data is stored in Bulk-OUT endpoint FIFO memory until device firmware reads it. While the computer reads data from a device, the data is read from Bulk-IN endpoint FIFO memory. The more FIFO memory provided, the more efficient the data flow.
  • Endpoint FIFO memory access method: Some USB silicon will provide both programmed I/O and DMA (direct memory access) methods. DMA relieves the device processor from moving all bytes, so it can perform other tasks. The most efficient designs will DMA multiple bytes at a time.
  • On-the-go (OTG) support: The new OTG USB specification lets a device temporarily act as a USB host. This is a great idea for many applications, like a USB digital camera sending pictures directly to a USB printer. Test-and-measurement equipment frequently produces images. It would be nice to send them directly to a printer. But OTG silicon and the necessary OTG software infrastructure must mature in the consumer market before adoption by OTG in test-and-measurement equipment, which frequently requires support for a long time.

Another design decision involves how users will connect the device. A USB device can be designed to use a captive cable, a standard-B plug, a mini-B plug, or an alternative plug (Fig. 3).

In a captive cable design, the cable is an integral part of the device. USB mice and keyboards are designed this way. The free and unattached end of the cable has a standard-A connector plugged directly into the computer USB port. One disadvantage of a captive cable design is that an assumption must be made about the optimal cable length.

Many devices use the original standard-B plug. The benefit to standard-B is that most cables today use standard-B. Size is the disadvantage.

The mini-B connector and plug were created to meet the needs of small portable devices. Therefore, it has a much smaller footprint. Also, mini-B is specified to last through 5000 insert/remove cycles, while the standard-B is specified at only 1500.

An alternative plug is the last option to consider. This makes sense if the USB device will be used in a harsh environment and must withstand vibration and shock, or if it's important to prevent accidental disconnect of the device. Alternative plugs can provide latching capability. Any device with an alternate plug should be shipped with a suitable cable.

Because USB provides power on the bus, a choice must be made whether a product will be self-powered or bus-powered. Of course, there's a limited amount of bus power available. Typically, only smaller, portable, less complex test equipment could be bus-powered.

Finally, every device requires a 16-bit vendor identification and 16-bit product identification. The USB-IF currently supports two options for getting the vendor identification (see www.usb.org). The vendor manages the product ID values.

The bottom line is that supplying USB as an additional or alternative I/O on test-and-measurement equipment will give test engineers an easier and faster path to measurement results. USB is simpler to use because it's pervasive, and cables, hubs, and converters are readily available. Plus, USB is faster than other interfaces thanks to the 480-Mbit/s speed supported in USB 2.0—which is ready now. Also, most computer users have now gone through the experience of connecting a USB peripheral of some kind. The experience with test-and-measurement equipment shouldn't be any different.

For large transfers, full-speed implementations realistically provide about a 1-Mbyte/s transfer rate. High-speed implementations will offer anywhere from 6 to 40 Mbytes/s, depending on the device's architecture and firmware—and the USB software on the computer. Data will burst at 480 Mbits/s (60 Mbytes/s), but sustained data rates are lower due to USB, computer software, and device overhead. After picking full- or high-speed, the choice of USB device silicon still depends on several other criteria:

  • Device class: Some USB silicon is built for specific device classes. For example, a USB chip may be targeted to mass-storage devices, and therefore be optimized for the mass-storage device class. Others are general-purpose. Firmware can determine the device class that gets reported to the OS when the device is enumerated. To implement USBTMC specification, use a general-purpose chip. No matter the device class to be implemented, consult the class specification to understand any extra requirements or opportunities for optimization.
  • Number of endpoints: Most general-purpose USB chips supply the required control endpoint and two or more configurable endpoints. Firmware configures the endpoints to be bulk, interrupt, or isochronous. USBTMC requires three endpoints (Control, Bulk-OUT, Bulk-IN). A fourth endpoint (interrupt-IN) is necessary for the device to communicate interrupt conditions (similar to GPIB service requests) when measurement results are ready, or when an error occurs. Most USB silicon will run with at least this number of endpoints.
  • Amount of endpoint FIFO memory: When the computer sends data to the device, the data is stored in Bulk-OUT endpoint FIFO memory until device firmware reads it. While the computer reads data from a device, the data is read from Bulk-IN endpoint FIFO memory. The more FIFO memory provided, the more efficient the data flow.
  • Endpoint FIFO memory access method: Some USB silicon will provide both programmed I/O and DMA (direct memory access) methods. DMA relieves the device processor from moving all bytes, so it can perform other tasks. The most efficient designs will DMA multiple bytes at a time.
  • On-the-go (OTG) support: The new OTG USB specification lets a device temporarily act as a USB host. This is a great idea for many applications, like a USB digital camera sending pictures directly to a USB printer. Test-and-measurement equipment frequently produces images. It would be nice to send them directly to a printer. But OTG silicon and the necessary OTG software infrastructure must mature in the consumer market before adoption by OTG in test-and-measurement equipment, which frequently requires support for a long time.

Another design decision involves how users will connect the device. A USB device can be designed to use a captive cable, a standard-B plug, a mini-B plug, or an alternative plug (Fig. 3).

In a captive cable design, the cable is an integral part of the device. USB mice and keyboards are designed this way. The free and unattached end of the cable has a standard-A connector plugged directly into the computer USB port. One disadvantage of a captive cable design is that an assumption must be made about the optimal cable length.

Many devices use the original standard-B plug. The benefit to standard-B is that most cables today use standard-B. Size is the disadvantage.

The mini-B connector and plug were created to meet the needs of small portable devices. Therefore, it has a much smaller footprint. Also, mini-B is specified to last through 5000 insert/remove cycles, while the standard-B is specified at only 1500.

An alternative plug is the last option to consider. This makes sense if the USB device will be used in a harsh environment and must withstand vibration and shock, or if it's important to prevent accidental disconnect of the device. Alternative plugs can provide latching capability. Any device with an alternate plug should be shipped with a suitable cable.

Because USB provides power on the bus, a choice must be made whether a product will be self-powered or bus-powered. Of course, there's a limited amount of bus power available. Typically, only smaller, portable, less complex test equipment could be bus-powered.

Finally, every device requires a 16-bit vendor identification and 16-bit product identification. The USB-IF currently supports two options for getting the vendor identification (see www.usb.org). The vendor manages the product ID values.

The bottom line is that supplying USB as an additional or alternative I/O on test-and-measurement equipment will give test engineers an easier and faster path to measurement results. USB is simpler to use because it's pervasive, and cables, hubs, and converters are readily available. Plus, USB is faster than other interfaces thanks to the 480-Mbit/s speed supported in USB 2.0—which is ready now. Also, most computer users have now gone through the experience of connecting a USB peripheral of some kind. The experience with test-and-measurement equipment shouldn't be any different.

Part Inventory
Go
powered by:
 

 
You must log on before posting a comment.

Are you a new visitor? Register Here
    There are no comments to display. Be the first one!