2015-05-07 02:17 AM
I am experimenting STM32F429 on a discovery board.
After creating set board settings with STM32CubeMX, I created a few lines to generate a wave on DAC channel 2 using DMA. Everything seems correct in the registers, but I see no changing values. On the other hand, if I push directly the values calling HAL_DMA_SetValue() everything works fine. Any hints?2015-05-07 04:00 AM
Perhaps the problem was a misinterpretation of the datasheet.
In facts, it seems that the DMA needs an external trigger, for example from a timer, to feed new values to the DAC. This peripheral itself cannot control the DMA transfer, so setting PFCTRL bit has no effect.2015-05-07 04:31 AM
> This peripheral itself cannot control the DMA transfer, so setting PFCTRL bit has no effect.
''control'' is a misleading term here (as in naming of PFCTRL as well). I'd prefer to clearly distinguish in terminology the ''DMA request'' signal (which DAC is capable to, but only after being triggered as you said above) from ''DMA external stop'' or something similar, which is what PFCTRL is gating at the DMA side. We all know that the documentation suc^H^H^Hleaves a lot to be desired. That Cube/CubeMX/SPL introduces further terminology pearls is just an added malus, and a well-deserved punishment for those who use them... ;) JW