cancel
Showing results for 
Search instead for 
Did you mean: 

Why CubeMX not allow ADC DMAContinuousRequests

MM..1
Chief III

I define two channels scan mode ADC and need it leave run alltime over DMA.

CubeMX have this settings only disabled.

I overwrite init and it works, then i dont understand why CubeMX block this ?

ADC i need dma hw based and RTOS calculate over memory buffer .

Now i use 1024 samples per channel and ADC_SAMPLETIME_112CYCLES

3 REPLIES 3
S.Ma
Principal

check the adc dma interrupt enable bits and decide what you want. seems hal adc dma function always enable interrupt for half and full transfer even in cyclic mode. at 1msps with 2 channels, it might make the core sluggish....

MM..1
Chief III

I start with HAL_ADC_Start_DMA(&hadc1, (uint32_t*)adc_buf, 2048);

then i mean half and full dma interrupts is on 1024 (2ch x 512) and on full DMA. I dont see sluggish

prain
Senior III

Unfortunately, cubemx can not setup for all the features of MCU. For professional firmware development, I recommend not to use cubemx.