Understand the basic principles of STM32DAC

Introduction

Only the high-capacity STM32F10x has DAC function

Features

① 2 DAC converters: each converter corresponds to 1 output channel
② 8-bit or 12-bit monotonic output
③ Left-aligned or right-aligned data in 12-bit mode
④ Synchronous update function
⑤ Noise waveform generation
⑥ Triangular waveform generation
⑦ Double DAC Channels are converted simultaneously or separately
⑧ Each channel has DMA function
Insert picture description here

DAC conversion principle

1. VDDA and VSSA are the power supply for the analog part of the DAC module.

2. Vref+ is the reference voltage of the DAC module.

3. DAC_OUTx is the output channel of the DAC (corresponding to the PA4 or PA5 pin)
Insert picture description here

DAC pin description

DAC_OUT1 ->PA4
DAC_OUT2 ->PA5
Insert picture description here

Conversion time

Insert picture description here

Data Format

Insert picture description here

Trigger method

Insert picture description here

Calculation formula

Explanation:
1. V_REF: is the voltage value we want to output
2. V_DOR: is the reference voltage (3.3V) 3.
2^12 = 4096;

DAC output = VREF ∗ (VDOR / 4096) DAC output =V_{REF}*(V_{DOR}/4096) D A C output an=VREFVD The R/4096

DAC output buffer

Insert picture description here

Guess you like

Origin blog.csdn.net/m0_46278925/article/details/107735075
Recommended