GD32F3x0 User Manual
178
11.4.9. External trigger configuration
The conversion of routine sequence can be triggered by rising edge of external trigger inputs.
The external trigger source of routine sequence is controlled by the ETSRC [2:0] bits in the
ADC_CTL1 register.
Table 11-3. External trigger source for ADC
11.4.10. DMA request
The DMA request, which is enabled by the DMA bit in ADC_CTL1 register, is used to transfer
data of routine sequence for conversion of more than one channel. The ADC generates a
DMA request at the end of conversion of a routine channel. When this request is received,
the DMA will transfer the converted data from the ADC_RDATA register to the destination
which is specified by the user.
11.4.11. ADC internal channels
When the TSVREN bit in ADC_CTL1 register is set, the temperature sensor channel
(ADC_IN16) and V
REFINT
channel (ADC_IN17) are enabled. The temperature sensor can be
used to measure the ambient temperature of the device. The sensor output voltage can be
converted into a digital value by ADC. The sampling time for the temperature sensor is
recommended to be set to at least t
s_temp
µs (please refer to the datasheet). When this sensor
is not in use, it can be set in power down mode by resetting the TSVREN bit.
The output voltage of the temperature sensor changes linearly with temperature. Because
there is an offset, which is up to 45°C and varies from chip to chip due to the chip production
process variation, the internal temperature sensor is more appropriate to detect temperature
variations than absolute temperature. When it is used to detect accurate temperature, an
external temperature sensor part should be used to calibrate the offset error.
The internal voltage reference (V
REFINT
) provides a stable (bandgap) voltage output for the
ADC and Comparators. V
REFINT
is internally connected to the ADC_IN17 input channel.
To use the temperature sensor:
1. Configure the conversion sequence (ADC_IN16) and the sampling time(17.1μs) for
the channel.