EFR32 Mighty Gecko 1 Software Documentation  efr32mg1-doc-5.1.2
dmactrl.c
Go to the documentation of this file.
1 /***************************************************************************/
19 #include "em_device.h"
20 #include "em_common.h"
21 #include "dmactrl.h"
22 
23 #if ( ( DMA_CHAN_COUNT > 0 ) && ( DMA_CHAN_COUNT <= 4 ) )
24 #define DMACTRL_CH_CNT 4
25 #define DMACTRL_ALIGNMENT 128
26 
27 #elif ( ( DMA_CHAN_COUNT > 4 ) && ( DMA_CHAN_COUNT <= 8 ) )
28 #define DMACTRL_CH_CNT 8
29 #define DMACTRL_ALIGNMENT 256
30 
31 #elif ( ( DMA_CHAN_COUNT > 8 ) && ( DMA_CHAN_COUNT <= 12 ) )
32 #define DMACTRL_CH_CNT 16
33 #define DMACTRL_ALIGNMENT 256
34 
35 #else
36 #error "Unsupported DMA channel count (dmactrl.c)."
37 #endif
38 
39 
41 SL_ALIGN(DMACTRL_ALIGNMENT)
42 DMA_DESCRIPTOR_TypeDef dmaControlBlock[DMACTRL_CH_CNT * 2] SL_ATTRIBUTE_ALIGN(DMACTRL_ALIGNMENT);
CMSIS Cortex-M Peripheral Access Layer for Silicon Laboratories microcontroller devices.
#define SL_ALIGN(X)
Macro for aligning a variable. Use this macro before the variable definition. X denotes the stora...
Definition: em_common.h:168
General purpose utilities.
DMA_DESCRIPTOR_TypeDef dmaControlBlock[DMACTRL_CH_CNT *2] SL_ATTRIBUTE_ALIGN(DMACTRL_ALIGNMENT)
DMA control data block.