EasyManuals Logo
Home>ST>Microcontrollers>STM32G473

ST STM32G473 User Manual

ST STM32G473
2126 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #743 background imageLoading...
Page #743 background image
RM0440 Rev 4 743/2126
RM0440 Digital-to-analog converter (DAC)
773
Sample and hold mode
In Sample and hold mode, the DAC core converts data on a triggered conversion, and then
holds the converted voltage on a capacitor. When not converting, the DAC cores and buffer
are completely turned off between samples and the DAC output is tri-stated, therefore
reducing the overall power consumption. A stabilization period, which value depends on the
buffer state, is required before each new conversion.
In this mode, the DAC core and all corresponding logic and registers are driven by the LSI
or LSE low-speed clock (dac_hold_ck) in addition to the dac_hclk clock, allowing to use the
DAC channels in deep low power modes such as Stop mode.
The LSI or LSE low-speed clock (dac_hold_ck) must not be stopped on-the-fly when the
Sample and hold mode is enabled.
The sample/hold mode operations can be divided into 3 phases:
1. Sample phase: the sample/hold element is charged to the desired voltage. The
charging time depends on capacitor value (internal or external, selected by the user).
The sampling time is configured with the TSAMPLEx[9:0] bits in DAC_SHSRx register.
During the write of the TSAMPLEx[9:0] bits, the BWSTx bit in DAC_SR register is set to
1 to synchronize between both clocks domains (AHB and low speed clock) and
allowing the software to change the value of sample phase during the DAC channel
operation
2. Hold phase: the DAC output channel is tri-stated, the DAC core and the buffer are
turned off, to reduce the current consumption. The hold time is configured with the
THOLDx[9:0] bits in DAC_SHHR register
3. Refresh phase: the refresh time is configured with the TREFRESHx[7:0] bits in
DAC_SHRR register
The timings for the three phases above are in units of LSI/LSE clock periods. As an
example, to configure a sample time of 350 µs, a hold time of 2 ms and a refresh time of
100 µs assuming LSI/LSE ~32 KHz is selected:
12 cycles are required for sample phase: TSAMPLEx[9:0] = 11,
62 cycles are required for hold phase: THOLDx[9:0] = 62,
and 4 cycles are required for refresh period: TREFRESHx[7:0] = 4.
In this example, the power consumption is reduced by almost a factor of 15 versus Normal
modes.
The formulas to compute the right sample and refresh timings are described in the table
below, the Hold time depends on the leakage current.
Table 188. Sample and refresh timings
Buffer
State
t
SAMP
(1)(2)
1. In the above formula the settling to the desired code value with ½ LSB or accuracy requires 10 constant
time for 12 bits resolution. For 8 bits resolution, the settling time is 7 constant time.
2. C
SH
is the capacitor in Sample and hold mode.
t
REFRESH
(2)(3)
3. The tolerated voltage drop during the hold phase “Vd” is represented by the number of LSBs after the
capacitor discharging with the output leakage current. The settling back to the desired value with ½ LSB
error accuracy requires ln(2*Nlsb) constant time of the DAC.
Enable 7 μs + (10*R
BON
*C
SH
) 7 μs + (R
BON
*C
SH
)*ln(2*N
LSB
)
Disable 3 μs + (10*R
BOFF
*C
SH
) 3 μs + (R
BOFF
*C
SH
)*ln(2*N
LSB
)

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the ST STM32G473 and is the answer not in the manual?

ST STM32G473 Specifications

General IconGeneral
BrandST
ModelSTM32G473
CategoryMicrocontrollers
LanguageEnglish

Related product manuals