ADC DMA continous and FreeRTOS conflict
Hello,
I'm working on a NUCLEO-H743ZI2 Board.
I am attempting to record ADC samples on an SD card using a FreeRTOS CMSIS-V1 program. Below are the configurations for my ADC and Timer6:
ADC Configuration:

Timer6 Configuration, I try to have around a 7500Hz Frequency (APB Timer Clock = 64MHz):

I am acquiring a simple 30Hz sine wave generated with a Low-Frequency Signal Generator. I use HAL_ADC_ConvHalfCpltCallback() and HAL_ADC_ConvCpltCallback() to trigger a TaskNotify(). In my task, if the notification comes from HalfCplt, I write the first half of my adc_buffer (size = 10240) to the SD card. If the notification comes from Cplt, I write the second half of the adc_buffer (ping-pong mechanism).
Everything appears to work well, but there is an issue: when I examine the recorded file on my computer, I notice that some samples are missing between the first and second halves of my buffer, as seen in this screenshot:

The discontinuity occurs every 5120 samples (half the size of my adc_buffer). I suspect that this may be related to a FreeRTOS priority problem.
To eliminate the possibility that the issue arises from SD writing, I attempted to write 10240 * 10 samples with a single f_write(). However, the discontinuities persist.
Interestingly, when I implement the same program without FreeRTOS, everything works perfectly, as shown in this screenshot:

As I am still learning to implement FreeRTOS programs effectively, I am struggling to identify and resolve this problem. Your assistance in resolving this issue would be greatly appreciated!
Thanks
jm
