Regular Channels DMA Configuration functions.
More...
Regular Channels DMA Configuration functions.
===============================================================================
##### Regular Channels DMA Configuration functions #####
===============================================================================
[..] This section provides functions allowing to configure the DMA for ADC
regular channels.
Since converted regular channel values are stored into a unique data
register, it is useful to use DMA for conversion of more than one regular
channel. This avoids the loss of the data already stored in the ADC
Data register.
When the DMA mode is enabled (using the ADC_DMACmd() function), after each
conversion of a regular channel, a DMA request is generated.
[..] Depending on the "DMA disable selection for Independent ADC mode"
configuration (using the ADC_DMARequestAfterLastTransferCmd() function),
at the end of the last DMA transfer, two possibilities are allowed:
(+) No new DMA request is issued to the DMA controller (feature DISABLED)
(+) Requests can continue to be generated (feature ENABLED).
[..] Depending on the "DMA disable selection for multi ADC mode" configuration
(using the void ADC_MultiModeDMARequestAfterLastTransferCmd() function),
at the end of the last DMA transfer, two possibilities are allowed:
(+) No new DMA request is issued to the DMA controller (feature DISABLED)
(+) Requests can continue to be generated (feature ENABLED).
===============================================================================
##### Regular Channels DMA Configuration functions #####
===============================================================================
[..] This section provides functions allowing to configure the DMA for ADC regular
channels. Since converted regular channel values are stored into a unique data register,
it is useful to use DMA for conversion of more than one regular channel. This
avoids the loss of the data already stored in the ADC Data register.
(#) ADC_DMACmd() function is used to enable the ADC DMA mode, after each
conversion of a regular channel, a DMA request is generated.
(#) ADC_DMAConfig() function is used to select between the one shot DMA mode
or the circular DMA mode
Enables or disables the specified ADC DMA request.
- Parameters
-
ADCx | where x can be 1, 2 or 3 to select the ADC peripheral. |
NewState | new state of the selected ADC DMA transfer. This parameter can be: ENABLE or DISABLE. |
- Return values
-
- Parameters
-
ADCx | where x can be 1, 2, 3 or 4 to select the ADC peripheral. |
NewState | new state of the selected ADC DMA transfer. This parameter can be: ENABLE or DISABLE. |
- Return values
-
Definition at line 1048 of file stm32f4xx_adc.c.
void ADC_DMAConfig |
( |
ADC_TypeDef * |
ADCx, |
|
|
uint32_t |
ADC_DMAMode |
|
) |
| |
Configure ADC DMA mode.
- Parameters
-
ADCx | where x can be 1, 2, 3 or 4 to select the ADC peripheral. |
ADC_DMAMode | select the ADC DMA mode. This parameter can be one of the following values:
- ADC_DMAMode_OneShot: ADC DMA Oneshot mode
- ADC_DMAMode_Circular: ADC DMA circular mode
|
- Return values
-
Definition at line 1780 of file stm32f30x_adc.c.
Enables or disables the ADC DMA request after last transfer (Single-ADC mode)
- Parameters
-
ADCx | where x can be 1, 2 or 3 to select the ADC peripheral. |
NewState | new state of the selected ADC DMA request after last transfer. This parameter can be: ENABLE or DISABLE. |
- Return values
-
Definition at line 1072 of file stm32f4xx_adc.c.
void ADC_MultiModeDMARequestAfterLastTransferCmd |
( |
FunctionalState |
NewState | ) |
|
Enables or disables the ADC DMA request after last transfer in multi ADC mode.
- Parameters
-
NewState | new state of the selected ADC DMA request after last transfer. This parameter can be: ENABLE or DISABLE. |
- Note
- if Enabled, DMA requests are issued as long as data are converted and DMA mode for multi ADC mode (selected using ADC_CommonInit() function by ADC_CommonInitStruct.ADC_DMAAccessMode structure member) is ADC_DMAAccessMode_1, ADC_DMAAccessMode_2 or ADC_DMAAccessMode_3.
- Return values
-
Definition at line 1099 of file stm32f4xx_adc.c.