Download Print this page

ST STM32F301 6 Series Reference Manual page 241

Advanced arm-based 32-bit mcus

Advertisement

RM0366
1.
Select the ADC1_IN16 input channel (with the appropriate sampling time).
2.
Program with the appropriate sampling time (refer to electrical characteristics section of
the STM32F3xx datasheet).
3.
Set the TSEN bit in the ADC1_CCR register to wake up the temperature sensor from
power-down mode.
4.
Start the ADC conversion.
5.
Read the resulting V
6.
Calculate the actual temperature using the following formula:
Where:
Refer to the datasheet electrical characteristics section for the actual values of V
Avg_Slope.
Note:
The sensor has a startup time after waking from power-down mode before it can output V
at the correct level. The ADC also has a startup time after power-on, so to minimize the
delay, the ADEN and TSEN bits should be set at the same time.
12.3.30
V
supply monitoring
BAT
The VBATEN bit in the ADC12_CCR register is used to switch to the battery voltage. As the
V
voltage could be higher than V
BAT
V
pin is internally connected to a bridge divider by 2. This bridge is automatically enabled
BAT
when VBATEN is set, to connect V
consequence, the converted digital value is half the V
consumption on the battery, it is recommended to enable the bridge divider only when
needed, for ADC conversion.
Refer to the electrical characteristics of the STM32F3xx datasheet for the sampling time
value to be applied when converting the V
Figure 69
data in the ADC data register.
TS
Temperature (in °C) = {(V
V
= V
value for 25° C
25
TS
Avg_Slope = average slope of the temperature vs. V
µV/°C)
shows the block diagram of the V
Figure 69. V
Internal
VREFINT
Power block
– V
) / Avg_Slope} + 25
25
TS
, to ensure the correct operation of the ADC, the
DDA
/2 to the ADC1_IN17 input channel. As a
BAT
/2 voltage.
BAT
sensing feature.
BAT
channel block diagram
BAT
VREFEN control bit
RM0366 Rev 5
Analog-to-digital converters (ADC)
curve (given in mV/°C or
TS
voltage. To prevent any unwanted
BAT
ADC1
ADC1_IN18
and
25
TS
MSv35546V1
241/874
277

Advertisement

loading
Need help?

Need help?

Do you have a question about the STM32F301 6 Series and is the answer not in the manual?

This manual is also suitable for:

Stm32f301 8 seriesStm32f318 8 series