2.1 CDC Overview
This section will give an overview of the CDC USB class.
The USB Communications Device Class is a USB class that provides a standardized way for computer systems to communicate with various types of communication devices like modems, telephones, and networking devices that use serial data streams. The USB Implementers Forum defines the CDC class. The CDC class is helpful because it allows devices to be connected to a computer and behave like a standard serial port, making it easier to send and receive data over USB without the need for proprietary drivers, achieved through standard protocols and device descriptors that define how the device communicates with the host.
Communicating with a computer is often done through a stand-alone device that can convert one or more serial connections like USART to USB communication. The AVR DU family with built-in USB support can eliminate the need for this extra conversion, simplifying the design process with fewer parts and making the setup more configurable. To this end, the AVR device can use the Communication Device Class (CDC) serial driver. This CDC driver provides a ‘UART-like’ interface, allowing the application designer to use USB for serial communication without needing to manage low-level USB details, such as enumeration, device discovery, and data transfer framing.
While USB has become one of the standard communication connections between a device and a computer, several other communication protocols are still in use. The RS-485 standard is still one of the go-to communication methods in several industrial settings, and the older RS-232 and RS-422 are still prevalent in older setups. Adding a computer to these setups happened through a serial port hardware interface that is no longer common. However, all these standards use serial communication and can therefore be interfaced using an AVR DU microcontroller and the USART peripheral.