Forum Discussion
Altera_Forum
Honored Contributor
15 years agoSGDMA debug
Hello, I am trying to learn how to use SGDMA to transfer data to memory. First of all, I am trying to connect SGDMA TX directly to SGDMA RX and check results. You can find the source code ->here<-...
Altera_Forum
Honored Contributor
15 years ago --- Quote Start --- Are you also allowing for any cpu cache? The DMA won't snoop the cache. --- Quote End --- The system is left as default when added, so yes: Instruction cache = 4kbytes, Data cache = 2kbytes, data cache line size=32bytes. --- Quote Start --- ------------------- --- Quote End --- Ok, so I've placed heap into onchip memory and it works now, I can see contents in the memory content editor. Contents a bit strange, I've not done any investigations on that. I've found more interesting thing (->output log here<- (http://www.codeupload.com/4059)). I create random 32bit pattern data using rand()&0xFFFFFFFF. This creates correct random data as it is seen in log lines 6 to 70. Now when I try to read the data, it is read the same for 4 times: lines 117-120, 121-124, 125-128 etc. Why is this happening? Wrong memory address increase step?