| Electronic Components Datasheet Search |
|
AN3023 Datasheet(PDF) 9 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN3023 Datasheet(HTML) 9 Page - STMicroelectronics |
|
9 / 23 page ![]() AN3023 Configuring ADC registers for conversion Doc ID 16113 Rev 1 9/23 3 Configuring ADC registers for conversion 3.1 ADC setup Before starting an ADC conversion, ADC setup is done using the following steps: ● ADC clock selection (define conversion speed) ● Channel selection ● Power on the ADC (set ADON bit) ● Wait for 14 ADC clock cycles (14 * tADC) ● Conversion mode selection (single or continuous) ● Trigger source selection and only after trigger enable ● Apply trigger source or set ADON bit 3.1.1 ADC clock The clock supplied to the ADC peripheral is the prescaled fMASTER clock. The prescaler is applied on bit SPSEL[2:0] in the ADC_CR1 register and it can be selected from fMASTER/2 to fMASTER/18. The prescaler selection must ensure a maximum 4 MHz ADC frequency. ADC conversion time depends on the ADC clock frequency, the sampling time duration and the ADC resolution. The minimum ADC conversion time is 3.5 µs @ 4 MHz ADC clock frequency. Note: It is recommended to change bits SPSEL[2:0] when the ADC is in power-down mode. This is because, internally, there may be a glitch in the clock during this change. If this change is made when ADC is not in power-down, the user is required to ignore the first converted result. 3.1.2 ADC on/off control (power on) The ADC can be powered on by setting the ADON bit in the ADC_CR1 register. When the ADON bit is set for the first time, it wakes up the ADC from power-down mode. After power ON, wait for stabilization time and then, to start a conversion, either set the ADON bit again in the ADC_CR1 register or use an external trigger source (timers or ADC_ETR pin). At the end of conversion, the ADC remains powered on and the ADON bit has to be set only once to start the next conversion. If the ADC is not used for a long time, it is recommended to switch it off to decrease power consumption. This is done by clearing the ADON bit. When the ADC is powered on, the output stage of the selected channel is disabled; therefore it is recommended to select the channel first before powering on the ADC. Note: If any bit of the ADC_CR1 register other than ADON is changed at the same time, the conversion is not triggered. This is to prevent triggering an erroneous conversion. Moreover, be aware that any bit manipulation instruction on the ADC_CR1 register can start a new conversion due to the fact that the ADON bit is read as ‘1’ and then written back as ‘1’ by this operation. |
|
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |