Figure 143. Dac Triangle Wave Generation; Figure 144. Dac Conversion (Sw Trigger Enabled) With Triangle Wave Generation - ST STM32L4 5 Series Reference Manual

Advanced arm-based 32-bit mcus
Table of Contents

Advertisement

Digital-to-analog converter (DAC)
maximum amplitude defined by the MAMPx[3:0] bits. Once the configured amplitude is
reached, the counter is decremented down to 0, then incremented again and so on.
It is possible to reset triangle wave generation by resetting the WAVEx[1:0] bits.

Figure 144. DAC conversion (SW trigger enabled) with triangle wave generation

Note:
1
The DAC trigger must be enabled for noise generation by setting the TENx bit in the
DAC_CR register.
2
The MAMPx[3:0] bits must be configured before enabling the DAC, otherwise they cannot
be changed.
19.3.10
DAC channel modes
Each DAC channel can be configured in normal mode or sample and hold mode. The output
buffer can be enabled to allow a high drive capability. Before enabling output buffer, the
voltage offset needs to be calibrated. This calibration is performed at the factory (loaded
after reset) and can be adjusted by software during application operation.
Normal mode
In normal mode, there are four combinations, by changing the buffer state and by changing
the DAC_OUTx pin interconnections.
To enable the output buffer, the MODEx[2:0] bits in DAC_MCR register should be:
000: DAC is connected to the external pin
001: DAC is connected to external pin and to on-chip peripherals
622/1830

Figure 143. DAC triangle wave generation

DocID024597 Rev 5
RM0351

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the STM32L4 5 Series and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents

Save PDF