2025-01-16 08:25 AM
DMA buffer 32 words, ADS converts 4 channels in scan mode.
So every 8 ADC-starts DMA will start at buffer[0] (circular buffer is ticked).
CubeIDE HAL is being used.
How do I find out / look up the buffer offset most recently written to?
2025-01-16 08:35 AM
Look into DMA registers, there is a counter
2025-01-16 08:00 PM
If you use DMA and the callbacks (for Half or Full) - you should know where you are (which buffer was filled recently).
Yes, you might be able to read back also DMA registers (e.g. address pointer). Easier is to use callbacks, double buffering and knowing when DMA INT comes which buffer was (completely) written...