5.14.4 Dsp To Host - Host Processor Procedure; Host Port Usage - General Considerations; 5.15.1 Host Programmer Considerations - Motorola DSP56156 Manual

Table of Contents

Advertisement

The transfer of data from the HTX register to the RXH:RXL registers automatically
loads the DMA address counter from the HM1 and HM0 bits when in DMA DSP to
HOST mode.
5.14.4 DSP To Host – Host Processor Procedure
The following procedure outlines the typical steps that the host processor must take to set-
up and terminate a DSP to Host DMA transfer.
1. Setup the DMA controller destination address, direction, byte count and other control
registers. Enable the DMA controller channel.
2. Set HTDE and clear RXDF. This can be done with the appropriate INIT function.
3. The DSP's source pointer used in the DMA exception handler (an address register for
example) must be initialized and HTIE must be set to enable the DSP host transmit
interrupt. This could be done by the host with a Host Command exception routine. The
DSP host transmit exception will be activated immediately by DSP hardware which be-
gins the DMA transfer.
4. Perform other tasks until interrupted by the DMA controller DMA Complete interrupt.
The DSP Interrupt Control Register (ICR), the Interrupt Status Register (ISR), and
TXH:TXL may be accessed at any time by the host processor (using HA0-HA2, HR/
W, and HEN) but the Receive Byte Registers (RXH and RXL) may not be accessed
until the DMA mode is disabled.
5. Terminate the DMA controller channel to disable DMA transfers.
6. Terminate the DSP HI DMA mode by clearing the HM1 and HM0 bits and clearing
RREQ in the Interrupt Control Register (ICR).
5.15
HOST PORT USAGE – GENERAL CONSIDERATIONS
Careful synchronization is required when reading multi-bit registers that are written by an-
other asynchronous system. This is a common problem when two asynchronous systems
are connected. The situation exists in the host port. However, if the port is used in the way
it was designed, proper operation is guaranteed. The considerations for proper operation
are discussed below.

5.15.1 Host Programmer Considerations

1. Unsynchronized Reading of Receive Byte Registers.
When reading receive byte registers, RXH or RXL, the host programmer should use
interrupts or poll the RXDF flag which indicates that data is available. This guarantees
that the data in the receive byte registers will be stable.
MOTOROLA
HOST PORT USAGE – GENERAL CONSIDERATIONS
HOST INTERFACE
5 - 21

Advertisement

Table of Contents
loading

Table of Contents