HARDWARE ManualSCU User's Manual
BackForward
SCU User's Manual / Chapter 2 Operation Explanation

■ 2.3 DSP

◆ DSP control from the main CPU

You can control the DSP from the main CPU. The DSP control items that can be performed from the CPU are as follows.
  1. DSP program loading
  2. DSP data access
  3. Start execution of DSP program
  4. Forced stop of DSP program

● Load DSP program

One way to load a DSP program is to use the DSP's DMA instructions, but another way is to write directly from the main CPU to the DSP's program RAM area. Program data can be loaded by controlling from the main CPU in the following order.
  1. Set bit16 and bit17 of the program control port to 0.
  2. Write the transfer start address to the program RAM address on the same port. It cannot be set unless the DSP is stopped.
  3. Program data is sequentially written to the program RAM data port in longword units.
Figures 2.15 to 2.17 show the control method from the CPU step by step.

Figure 2.15 Loading the DSP program Step1

Figure 2.16 Loading the DSP program Step2

Figure 2.17 Loading the DSP program Step3

● DSP data access

To access the DSP data, you can use the DSP DMA instructions, or you can access the DSP data RAM area from the main CPU. Data can be accessed by controlling from the main CPU in the following order.
  1. Set bit16 and bit17 of the program control port to 0.
  2. Write the access start address to the data RAM address port. It cannot be set unless the DSP is stopped.
  3. Data RAM Sequentially access data in longword units through the data port.
Figures 2.18 to 2.20 show the control method from the CPU step by step.

Figure 2.18 DSP data access step1

Figure 2.19 DSP data access step2

Figure 2.20 DSP data access step3

● Start execution of DSP program

To start executing a DSP program, write 1 to bit16 of the program control port (see Figure 2.21). When the DSP recognizes that it has been written, it starts execution from the address stored in the program RAM address of the program control port. Therefore, the execution start address must be set before writing 1 to bit16 of the program control port.

Figure 2.21 Control to start execution of DSP program from CPU

● Forced stop of DSP program

To forcibly stop the execution of the DSP program, write 0 to bit16 of the program control port, which is the opposite of starting execution. Figure 2.22 shows the forced stop control.

Figure 2.22 Forced stop control of DSP program from CPU


BackForward
HARDWARE ManualSCU User's Manual
Copyright SEGA ENTERPRISES, LTD., 1997