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

cross mob
Anonymous
Not applicable

Hi all,

   

I do have a (most likely) trivial question for you guys :

   

I need to catch data from a microprocessor bus and hence I want to utilize DMA transfers in order to address the latency requirements.

   

The input for the microprocessor bus is realized with 8 digital pins (with  contiguous setup)  and the question is how to supply the source address (pointer) to CyDmaTdSetAddress ?

   

We have :

   

DMA1_DmaInitialize(DMA_BYTES_PER_BURST, DMA_REQUEST_PER_BURST, 
                                    HI16(DMA_SRC_BASE), HI16(DMA_DST_BASE));

   

In there DMA_SRC_BASE is defined as CYDEV_PERIPH_BASE and DMA_DST_BASE as CYDEV_SRAM_BASE

   

What I am missing is the correct source address setup for :

   

CyDmaTdSetAddress(DMA_TD[0], LO16((uint32)DTA__PS), LO16((uint32)da));

   

( da is the receiving char array ... no problem with that)

   

DTA is the group of digital input pins and the the header file suggest that DTA__PS will give me the address of the pin state register 

   

/* Main Port Registers */
/* Pin State */
#define DTA_PS                     (* (reg8 *) DTA__PS)

   

But this doesn't seem to work.

   

Any suggestions ?

   

 

   

Thanks in advance, regards Achim

0 Likes
1 Reply
odissey1
Level 9
Level 9
First comment on KBA 1000 replies posted 750 replies posted

Copy address from this project (RAM-DMA-GPIO)

   

http://www.cypress.com/comment/405841#comment-405841

0 Likes