USB CDC

From Bobs Projects
Jump to: navigation, search

Communication Device Class (CDC) is a class of USB devices that offer some sort of serial-like communications functionality, such as modems etc.

In Linux, CDC devices typically appear as /dev/ttyACMx in the file-system, where 'x' is a digit starting at 0 and incrementing for each device connected.

This allows application code to simply open /dev/ttyACMx for read/write and the CDC device should just appear to work as if it were any other serial-port connected device.

Use with V-USB

V-USB is a software-only implementation of the USB peripheral side specifically designed to run on a range of Atmel AVR micro-controllers. It is limited to only support the 1.5MB/sec low-speed mode of USB communications and can run on AVR CPUs running as slow as 12MHz (8 clock cycles per bit of low-speed USB).

However, CDC uses bulk transfer endpoints and such endpoints are not compliant with the standard for USB low-speed mode.

Nonetheless, experience has shown that CDC does, in fact, work on a number of USB host controllers in low-speed mode running a variety of Linux kernels, but not all.

As Osamu Tamura writes: "The back door to the low-speed bulk transfer is gradually closing on the newer OS. After enjoying this USB technology, switch to the HID protocol or to MCU having on-chip USB controller."

Projects

USB CDC on V-USB is used on the following projects:

External links