2.12 Digital-to-Analog Converter (CDAC)

The Control Digital-to-Analog Converter (CDAC) converts a digital value to a voltage. The CDAC has one channel with 12-bit resolution, and it is capable of converting up to 1,000,000 samples per second (1Msps).

Using The Library

The CDAC peripheral library provides an interface for the conversion of digital values to analog voltage.

uint16_t data = 0x800;
CDAC1_DataWrite(data);

Library Interface

Digital-to-Analog Converter peripheral library provides the following interfaces:

Functions

NameDescription
CDACx_InitializeInitializes given instance of the CDAC peripheral
CDACx_DataWriteThis function will write the specified value to the CDAC and start the conversion
Note: Not all APIs maybe implemented. See the specific device family section for available APIs.