Question about using DMA to generate clock from GPIO output

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi all

   

I create a table in flash just '0' and '1' and use DMA transferring to GPIO.  I expect to generate 5MHz clock output from GPIO, but the maximum clock output always is 3MHz.  I use a clock as a DMA hardware request (rising edge). Although increasing triggering clock to 24MHz, the clock output from GPIO is the same 3MHz clock output. How to increase output clock to 5MHz or higher?? Is there a speed limitation??

   


   

Device: CY8CKIT-050 PSoC 5LP

   

BUS CLOCK: 48MHz

   

 

   

Thanks

0 Likes
2 Replies
HeLi_263931
Level 8
Level 8
100 solutions authored 50 solutions authored 25 solutions authored

Read the architecture TRM, and the respective AppNotes about DMA. There is a setup time for each DMA transfer.In your case, its most likely 6 clock cycles, which would end up in the 3MHz you observer.

   

But what do you want to achieve? Wouldn't it be easier to connect a clock to the output directly? Or do you want, in the end, write complete bit patterns to a PGIO port?

0 Likes
Anonymous
Not applicable

DMA approach of course potentially will create a lot of jitter.

   

 

   

Also, maybe not relevant, but take a look at info in this ap note about

   

faster toggling of GPIO (non DMA) -

   

 

   

    

   

          

   

http://www.cypress.com/?rID=57571     AN72382

   

 

   

Regards, Dana.

0 Likes