ADDIS=B_0x0, DEEPPWD=B_0x0, CALINDEX=B_0x0, JADSTART=B_0x0, ADVREGEN=B_0x0, JADSTP=B_0x0, ADCAL=B_0x0, ADSTART=B_0x0, ADEN=B_0x0, ADSTP=B_0x0, ADCALLIN=B_0x0
ADC control register
ADEN | ADC enable control This bit is set by software to enable the ADC. The ADC is effectively ready to operate once the flag ADRDY has been set. It is cleared by hardware when the ADC is disabled, after the execution of the ADDIS command. Note: The software is allowed to set ADEN only when all bits of ADC_CR registers are 0 (ADCAL = 0, JADSTART = 0, ADSTART = 0, ADSTP = 0, ADDIS = 0 and ADEN = 0) except for bit ADVREGEN which must be 1 (and the software must have wait for the startup time of the voltage regulator) 0 (B_0x0): ADC is disabled (OFF state) 1 (B_0x1): Write 1 to enable the ADC. |
ADDIS | ADC disable command This bit is set by software to disable the ADC (ADDIS command) and put it into power-down state (OFF state). It is cleared by hardware once the ADC is effectively disabled (ADEN is also cleared by hardware at this time). Note: The software is allowed to set ADDIS only when ADEN = 1 and both ADSTART = 0 and JADSTART = 0 (which ensures that no conversion is ongoing) 0 (B_0x0): no ADDIS command ongoing 1 (B_0x1): Write 1 to disable the ADC. Read 1 means that an ADDIS command is in progress. |
ADSTART | ADC start of regular conversion This bit is set by software to start ADC conversion of regular channels. Depending on the configuration bits EXTEN[1:0], a conversion starts immediately (software trigger configuration) or once a regular hardware trigger event occurs (hardware trigger configuration). It is cleared by hardware: in Single conversion mode (CONT = 0, DISCEN = 0) when software trigger is selected (EXTEN[1:0] = 0x0): at the assertion of the end of regular conversion sequence (EOS) flag. In Discontinuous conversion mode (CONT = 0, DISCEN = 1), when the software trigger is selected (EXTEN[1:0] = 0x0): at the end of conversion (EOC) flag. in all other cases: after the execution of the ADSTP command, at the same time that ADSTP is cleared by hardware. Note: The software is allowed to set ADSTART only when ADEN = 1 and ADDIS = 0 (ADC is enabled and there is no pending request to disable the ADC) In Auto-injection mode (JAUTO = 1), regular and auto-injected conversions are started by setting bit ADSTART (JADSTART must be kept cleared) 0 (B_0x0): No ADC regular conversion is ongoing. 1 (B_0x1): Write 1 to start regular conversions. Read 1 means that the ADC is operating and eventually converting a regular channel. |
JADSTART | ADC start of injected conversion This bit is set by software to start ADC conversion of injected channels. Depending on the configuration bits JEXTEN[1:0], a conversion starts immediately (software trigger configuration) or once an injected hardware trigger event occurs (hardware trigger configuration). It is cleared by hardware: in Single conversion mode when software trigger is selected (JEXTSEL = 0x0): at the assertion of the end of injected conversion sequence (JEOS) flag. in all cases: after the execution of the JADSTP command, at the same time as JADSTP is cleared by hardware. Note: The software is allowed to set JADSTART only when ADEN = 1 and ADDIS = 0 (ADC is enabled and there is no pending request to disable the ADC). In Auto-injection mode (JAUTO = 1), regular and auto-injected conversions are started by setting bit ADSTART (JADSTART must be kept cleared) 0 (B_0x0): No ADC injected conversion is ongoing. 1 (B_0x1): Write 1 to start injected conversions. Read 1 means that the ADC is operating and eventually converting an injected channel. |
ADSTP | ADC stop of regular conversion command This bit is set by software to stop and discard an ongoing regular conversion (ADSTP Command). It is cleared by hardware when the conversion is effectively discarded and the ADC regular sequence and triggers can be re-configured. The ADC is then ready to accept a new start of regular conversions (ADSTART command). Note: The software is allowed to set ADSTP only when ADSTART = 1 and ADDIS = 0 (ADC is enabled and eventually converting a regular conversion and there is no pending request to disable the ADC). In Auto-injection mode (JAUTO = 1), setting ADSTP bit aborts both regular and injected conversions (do not use JADSTP). 0 (B_0x0): No ADC stop regular conversion command ongoing 1 (B_0x1): Write 1 to stop regular conversions ongoing. Read 1 means that an ADSTP command is in progress. |
JADSTP | ADC stop of injected conversion command This bit is set by software to stop and discard an ongoing injected conversion (JADSTP Command). It is cleared by hardware when the conversion is effectively discarded and the ADC injected sequence and triggers can be re-configured. The ADC is then ready to accept a new start of injected conversions (JADSTART command). Note: The software is allowed to set JADSTP only when JADSTART = 1 and ADDIS = 0 (ADC is enabled and eventually converting an injected conversion and there is no pending request to disable the ADC). In Auto-injection mode (JAUTO = 1), setting ADSTP bit aborts both regular and injected conversions (do not use JADSTP) 0 (B_0x0): No ADC stop injected conversion command ongoing 1 (B_0x1): Write 1 to stop injected conversions ongoing. Read 1 means that an ADSTP command is in progress. |
ADCALLIN | Linearity calibration This bit is set and cleared by software to enable the linearity calibration. Note: The software is allowed to write this bit only when the ADC is disabled and is not calibrating (ADCAL = 0, JADSTART = 0, JADSTP = 0, ADSTART = 0, ADSTP = 0, ADDIS = 0 and ADEN = 0). 0 (B_0x0): Writing ADCAL launches a calibration without the linearity calibration. 1 (B_0x1): Writing ADCAL launches a calibration with he linearity calibration. |
CALINDEX | Calibration factor This bitfield controls the calibration factor to be read or written. Calibration index 0 is dedicated to single-ended and differential offsets, calibration index 1 to 7 to the linearity calibration factors, and index 8 to the internal offset: Others: Reserved, must not be used Note: ADC_CALFACT2[31:0] correspond to the location of CALINDEX[3:0] calibration factor data (see for details). 0 (B_0x0): Offset calibration factor 1 (B_0x1): linearity calibration factor 1 2 (B_0x2): linearity calibration factor 2 3 (B_0x3): linearity calibration factor 3 4 (B_0x4): linearity calibration factor 4 5 (B_0x5): linearity calibration factor 5 6 (B_0x6): linearity calibration factor 6 7 (B_0x7): linearity calibration factor 7 and internal offset (write access only) 8 (B_0x8): internal offset (read access only) |
ADVREGEN | ADC voltage regulator enable This bits is set by software to enable the ADC voltage regulator. Before performing any operation such as launching a calibration or enabling the ADC, the ADC voltage regulator must first be enabled and the software must wait for the regulator start-up time. For more details about the ADC voltage regulator enable and disable sequences, refer to (ADVREGEN). The software can program this bit field only when the ADC is disabled (ADCAL = 0, JADSTART = 0, ADSTART = 0, ADSTP = 0, ADDIS = 0 and ADEN = 0). 0 (B_0x0): ADC Voltage regulator disabled 1 (B_0x1): ADC Voltage regulator enabled. |
DEEPPWD | Deep-power-down enable This bit is set and cleared by software to put the ADC in Deep-power-down mode. Note: The software is allowed to write this bit only when the ADC is disabled (ADCAL = 0, JADSTART = 0, JADSTP = 0, ADSTART = 0, ADSTP = 0, ADDIS = 0 and ADEN = 0). 0 (B_0x0): ADC not in deep-power down 1 (B_0x1): ADC in Deep-power-down (default reset state) |
ADCAL | ADC calibration This bit is set by software to start the ADC calibration. It is cleared by hardware after calibration is complete. Note: The software is allowed to launch a calibration by setting ADCAL only when ADEN = 0. 0 (B_0x0): Calibration complete 1 (B_0x1): Write 1 to calibrate the ADC. Read at 1 means that a calibration in progress. |