FlexIO3 With DMA

Status
Not open for further replies.

CollinK

Well-known member
I've run into an interesting predicament. I'm trying to test using FlexIO3 with DMA. But, it doesn't DMA. I'm pretty sure I'm doing it right. Looking into the DMAMUX documentation and header definitions, I see no actual mention of FlexIO3 being connected to the DMAMUX. Now, FlexIO3 shares some things with FlexIO2 such as the peripheral clock. I had hoped DMA was one of the shared things without any proof. The documentation doesn't say one word about DMA on FIO3. I can manually put data into the shift buffer and see it go out on the pins. So, I know FlexIO3 is set up and working and it is clocked at the proper rate too as the pulse I get when loading the shift register is the proper length.

But, setting up DMA I have to say I want to trigger like so:
Code:
flexioDMA.triggerAtHardwareEvent(DMAMUX_SOURCE_FLEXIO2_REQUEST0);

See how I'm using FLEXIO2_REQUEST0 as the source? That doesn't seem to work. For sure FlexIO1 and FlexIO2 have different DMAMUX values. But, FlexIO3 isn't in there so... How on Earth can I know for sure whether FlexIO3 really supports DMA or not? The SHIFTSDEN register for FlexIO3 is mapped in the header but it could have been copy pasta and not anything that really exists... I'm starting to think that there really is no DMAMUX at all for FlexIO3 and I'd have to load the shift register from an interrupt. That doesn't seem ideal when I'm blasting data out of the pins at 16MHz. Alternatively, would it make any sense to try to set up a timer that triggers DMA and does so at 16Mhz? It seems like this would be fraught with failure as I could never be sure that the timer was really in lock step with FlexIO3 so that it was always triggering and loading the shift register at the proper time.

I'm starting to think that I should redesign the hardware interface to use pins that are on FlexIO1 or FlexIO2 unless there's some sort of great idea I haven't thought of.
 
I should have googled that before posting here or wasting so much time trying to make it work. The official answer is "whoops, we didn't actually hook up DMA to FlexIO3. Sorry!" Grr....
 
How on Earth can I know for sure whether FlexIO3 really supports DMA or not?

FlexIO3 absolutely does not work with DMA.

Even if the DMAMUX had the request signals, it still couldn't work because NXP wired FlexIO3 (and GPIO6-9) to the Cortex M7's AHBP bus. On this chip, all addresses with 0x42 in their top byte are inaccessible to DMA.

I really wish there was a way, but sadly it just isn't possible. With FlexIO3 and GPIO6-9, you can use interrupts and CPU access, but DMA just can't reach anything on the AHBP bus.
 
Status
Not open for further replies.
Back
Top