This Digital-to-Analog Converter (DAC) driver provides an interface for the conversion of digital values to analog voltage.
The following driver variants are available:
DAC Synchronous Driver: The driver supports polling for hardware changes. The functionality is synchronous to the main clock of the MCU.
DAC Asynchronous Driver: The driver supports a callback handler for the IRQ caused by hardware state changes. The functionality is asynchronous to the main clock of the MCU.
DAC RTOS Driver: The driver is intended for using functions in a Real-Time operating system, i.e. is thread safe.
A Digital-to-Analog Converter (DAC) converts a digital value to an analog voltage. The digital from 0 to the highest value represents the output voltage value. The highest digital value is possible with the bit resolution supported by the DAC. For example, for a 10-bit resolution DAC hardware, the highest value is 1024. The highest output voltage is possible with the reference voltage.
A common use of DAC is to generate audio signals by connecting the DAC output to a speaker, or to generate a reference voltage; either for an external circuit or an internal peripheral, such as the Analog Comparator.