Pci access – Sundance SMT335E User Manual

Page 31

Advertising
background image

Version 1.5

Page 31 of 53

SMT335E SMT375E User Manual

PCI access

You must make sure you know how to configure your carrier board for PCI transfers;
the following example is for the SMT320.

To configure the carrier board for PCI transfers you must write two words to the
global bus:

1

Write to the SMT320 control register (0xC0800000) to select burst
mode or not. In burst mode your transfer size must be a multiple of 16
words;

2

Write the address of your data in the PCI address space to the SMT320
address register (0xC0400000). This address will be incremented by 4
after each word has been transferred.

To start a DMA transfer you have to:

1. Set the DMA destination address to be the SMT320 Dual Port RAM.
2. In the Global bus control register, set auto restart mode if you are reading.
3. Set the DMA to synchronise on one of the INTn lines. For a write operation

you must set the synchronisation event in the DMA secondary control
register; for a read operation you must clear it.

4. Enable the global bus interrupt using the ICR corresponding to the interrupt

line used (see page 38).

5. Set the global bus trigger to be your frame size minus 1.
6. Set a DMA Global Index Register to:

(–(FRAME_SIZE<<16)) +

4

7. Start the DMA transfer using the Global Index Register selected above to

control indexing of accesses to the DPR.


The setting of the Global index register is important. With this setting every word
transfer will add 4 to the DMA’s address into the DPR. At the end of each frame, the
negative frame index will bring the address back to the first word of the DPR. This
allows the DMA to access words 0 to 255 of the DPR without ever passing out of the
C6000 address space allocated to it.

Advertising
This manual is related to the following products: