2020-04-05 05:12 AM
Using the CubeMX perspective in the CubeIDE (latest version) I configured the DMA2 to work with Timer1 in the memory to peripheral mode.
I am using the STM32 F4 Discovery board (STM32F407VG)
I need a Hello World on how to push one value of an array to the GPIO pins. The GPIO pins used are GPIOE pins 8 through 15.
If the array value is 1 (0xFF), the GPIO pins should have the values "1 1 1 1 1 1 1 1"
Configuration Tim1:
Configuration DMA:
The following code was used after initialization of the peripherals (initialization was done using auto generated code):
The GPIO pins are set high at initialization. When this code runs they should be set low, because the values in the array are all zeros (did not include that code for simplicity).
When the code runs, it does execute the functions. It does not throw an error, I checked it with the status return value of the functions. It jumps into the DMA2_Stream5_IRQHandler afterwards, so I'm guessing it did something. The GPIO pins are however never set low.
What am I doing wrong?
How do I get the values from an array onto some GPIO pins using the DMA2 peripheral?
Thanks in advance!
Solved! Go to Solution.
2020-04-06 01:14 PM
Thanks, I tested it and edited my post.
Broyildiz
2022-06-22 10:06 PM
is your code working perfectly?