stm32 /stm32wb0 /STM32WB05 /ADC /CONF

Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text

Interpret as CONF

31 2827 2423 2019 1615 1211 87 43 0 0 0 0 0 0 0 0 00 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 (CONT)CONT 0 (SEQUENCE)SEQUENCE 0SEQ_LEN0 (SMPS_SYNCHRO_ENA)SMPS_SYNCHRO_ENA 0SAMPLE_RATE_LSB 0SAMPLE_RATE 0 (DMA_DS_ENA)DMA_DS_ENA 0 (OVR_DS_CFG)OVR_DS_CFG 0 (BIT_INVERT_SN)BIT_INVERT_SN 0 (BIT_INVERT_DIFF)BIT_INVERT_DIFF 0 (ADC_CONT_1V2)ADC_CONT_1V2 0SAMPLE_RATE_MSB

Description

CONF register

Fields

CONT

CONT: regular sequence runs continuously when ADC mode is enabled:

0: enable the single conversion: when the sequence is over, the conversion stops

1: enable the continuous conversion: when the sequence is over, the sequence starts again

until the software sets the CTRL.STOP_OP_MODE bit.

SEQUENCE

SEQUENCE: enable the sequence mode (active by default):

0: sequence mode is disabled, only SEQ0 is selected

1: sequence mode is enabled, conversions from SEQ0 to SEQx with x=SEQ_LEN

Note: clearing this bit is equivalent to SEQUENCE=1 and SEQ_LEN=0000. Ideally, this bit can

be kept high as redundant with keeping high and setting SEQ_LEN=0000.

SEQ_LEN

SEQ_LEN[3:0]: number of conversions in a regular sequence:

0000: 1 conversion, starting from SEQ0

0001: 2 conversions, starting from SEQ0

1111: 16 conversions, starting from SEQ0

SMPS_SYNCHRO_ENA

SMPS_SYNCHRO_ENA: synchronize the ADC start conversion with a pulse generated by the

SMPS:

0: SMPS synchronization is disabled for all ADC clock frequencies

1: SMPS synchronization is enabled (only when ADC clock is 8 MHz or 16 MHz)

Note: SMPS_SYNCHRO_ENA must be 0 when the ADC analog clock is 32 MHz or when

PWRC_CR5.NOSMPS = 1.

SAMPLE_RATE_LSB

SAMPLE_RATE_LSB: Sample Rate LSB

This field is an extension of SAMPLE_RATE definition in bits 12,11 of CONF register. It

impacts the conversion rate of ADC (F_ADC). See SAMPLE_RATE bits for the full description.

When this field is set to a value different than 0, SMPS synchronization is not feasible.

This value is hidden to the user

SAMPLE_RATE

SAMPLE_RATE[1:0]: conversion rate of ADC (F_ADC):

F_ADC = F_ADC_CLK/(16 + 16SAMPLE_RATE_MSB + 4SAMPLE_RATE + SAMPLE_RATE_LSB),where

F_ADC_CLK is the analog ADC clock frequency. By default F_ADC_CLK is 16MHz frequency.

DMA_DS_ENA

DMA_DS_EN: enable the DMA mode for the Down Sampler data path:

0: DMA mode is disabled

1: DMA mode is enabled

OVR_DS_CFG

OVR_DS_CFG: Down Sampler overrun configuration:

0: the previous data is kept, the new one is lost

1: the previous data is lost, the new one is kept

BIT_INVERT_SN

BIT_INVERT_SN: invert bit to bit the ADC data output (1’s complement) when a single

negative input is connected to the ADC:

0: no inversion (default)

1: enable the inversion

BIT_INVERT_DIFF

BIT_INVERT_DIFF: invert bit to bit the ADC data output (1’s complement) when a differential

input is connected to the ADC:

0: no inversion (default)

1: enable the inversion

ADC_CONT_1V2

ADC_CONT_1V2: select the input sampling method:

0: sampling only at conversion start (default)

1: sampling starts at the end of conversion

SAMPLE_RATE_MSB

SAMPLE_RATE_MSB: Sample Rate MSB

This field is an extension of SAMPLE_RATE definition in bits 12,11 of CONF register. It

impacts the conversion rate of ADC (F_ADC). See SAMPLE_RATE bits for the full description

Links

()