2021-04-27 05:08 AM
I have 8 GPIO pins where I want to read the state of the pin. I want to do this with a DMA controller. My guess is that this should be done with perhipipal to memory. The code is shown in the txt. file.
When the DMA is finished it goes into an interrupt where I just have a breakpoint. The DMA does not transfer anything from the GPIO pins but gives the interrupt like it is done. I cant understand why it does not read the state of the GPIO pins.
I have btw tried this with Mem2Mem, but this does not allow me to read the GPIO pins state when the timer overflows and restart.
Every help will be well appreciated.
2021-04-30 09:21 AM
> HAL_DMA_Start_IT(&hdma_tim1_ch3, (uint8_t)&(GPIOA->IDR), (uint32_t)cameraData, (uint32_t)640);
Should be:
> HAL_DMA_Start_IT(&hdma_tim1_ch3, (uint32_t)&(GPIOA->IDR), (uint32_t)cameraData, (uint32_t)640);
Potentially other stuff.