On a LCP2378.
I am using PWM to toggle control lines of a a/d and start a ssp (master) transfer at a 5us
interval.
I've setup the DMA to move the (16bit) data to usbram.
DMACCONFIGURATION.E=1;
DMACC0CONTROL.TransferSize = 0x100;
.SBSize = 1;
.DBSize = 1;
.SWidth = 1;
.DWidth = 2;
.SI = 0;
.DI = 1;
DMACC0SRCADDR = 0xe0068008;
DMACC0DESTADDR = 0x7fd00000;
DMACC0CONFIGURATION.SRC = 1;
.DEST = 0;
.FLOWCNTRL = 2;
.E = 1;
This fills 0x200 bytes in usbram. Twice what I expect.
Next I set .FLOWCNTRL = 6 instead of 2
then I seem to get 0x4000 bytes in usbram filled.
When .DMACC0DESTADDR gets to 0x7fd04000 it seems to set the error status bit and turns off
the DMACC0CONIGURATION.E
This actually seems to do exactly what I want, which is to fill the entire memory with
data, then stop when filled, but there are some things I don't understand.
1. doco indicates usbram ends at 0x7fd01fff. 1/2 of what I see.
2. I don't quite understand what .SWidth and .DWidth do.
3. There is a note about 1kb address generation burst boundary limit. Is this relevant?
4. Is there anything wrong with using the dma in this way?
5. By the next time I enable the dma to transfer the ssp data to usbram the ssp fifo will
have overflowed. What now is the data in that fifo? is it most recent data? or did
accumulation stop once ssp was full?
------------------------------------

(You need to be a member of lpc2000 -- send a blank email to lpc2000-subscribe@yahoogroups.com )