V PERIPHERAL MODULES 3 (INTERFACE): SERIAL PERIPHERAL INTERFACE (SPI)
V-2-12
EPSON
S1C33E07 TECHNICAL MANUAL
Note: The SPI interrupt request signal is input to the port 8 input interrupt (FPT8) system. The port 8 in-
put interrupt circuit is configured by selecting a port (signal) to be used for generating an interrupt
from P90, INT_SPI, P80, and P70. When using the SPI interrupt, set SPT8[1:0] (D[1:0]/0x3003C4)
to 10 to select INT_SPI. This setting enables the INT_SPI signal to be sent to the ITC as the port
8 input interrupt signal. Furthermore, SPPT8 (D0/0x3003C6), which selects the polarity of the
FPT8 input signal, should be set to 1 (high level or rising edge).
SPT8[1:0]: FPT8 Interrupt Input Port Select Bits in the Port Input Interrupt Select Register 3 (D[1:0]/0x3003C4)
SPPT8: FPT8 Input Polarity Select Bit in the Port Input Interrupt Polarity Select Register 2 (D0/0x3003C6)
Intelligent DMA
The transmit DMA, receive DMA and SPI interrupt requests can be used to invoke intelligent DMA (IDMA).
This enables successive transmit/receive operations between memory and the transmit/receive-register to be
performed by means of a DMA transfer.
The following shows the IDMA channel numbers set for each cause of interrupt:
IDMA Ch.
Receive DMA interrupt:
0x24
Transmit DMA interrupt:
0x25
SPI interrupt (FPT8 interrupt): 0x26
The IDMA request and enable bits shown in Table V.2.6.2 must be set to 1 for IDMA to be invoked. Transfer
conditions, etc. on the IDMA side must also be set in advance.
Table V.2.6.2 Control Bits for IDMA Transfer
Interrupt
Transmit DMA interrupt
Receive DMA interrupt
SPI interrupt
IDMA request bit
RSPITX(D5/0x30029B)
RSPIRX(D4/0x30029B)
RP8(D0/0x3002AC)
IDMA enable bit
DESPITX(D5/0x30029C)
DESPIRX(D4/0x30029C)
DEP8(D0/0x3002AE)
If a cause of interrupt occurs when the IDMA request and enable bits are set to 1, IDMA is invoked. No inter-
rupt request is generated at that point. An interrupt request is generated upon completion of the DMA transfer.
The bits can also be set so as not to generate an interrupt, with only a DMA transfer performed.
For details on DMA transfer and how to control interrupts upon completion of DMA transfer, refer to Section
II.2, “Intelligent DMA (IDMA).”
High-speed DMA
Each interrupt can also invoke high-speed DMA (HSDMA).
The following shows the HSDMA channel number and trigger set-up bit corresponding to each interrupt:
Table V.2.6.3 HSDMA Trigger Set-up Bits
Interrupt
Transmit DMA interrupt
Receive DMA interrupt
SPI interrupt
HSDMA Ch.
2
3
0
Trigger set-up bits
HSD2S[3:0] (D[3:0]) / HSDMA Ch.2–3 Trigger Set-up Register (0x300299)
HSD3S[3:0] (D[7:4]) / HSDMA Ch.2–3 Trigger Set-up Register (0x300299)
HSD0S[3:0] (D[3:0]) / HSDMA Ch.0–1 Trigger Set-up Register (0x300298)
For HSDMA to be invoked by a transmit DMA interrupt request, the trigger set-up bits for HSDMA Ch.2
should be set to “1001.” For HSDMA to be invoked by a receive DMA interrupt request, the trigger set-up bits
for HSDMA Ch.3 should be set to “1001.” For HSDMA to be invoked by an SPI interrupt (FPT8 interrupt)
request, the trigger set-up bits for HSDMA Ch.0 should be set to “1101.” Transfer conditions, etc. must also be
set on the HSDMA side. The HSDMA channel is invoked through generation of the cause of interrupt.
For details on HSDMA transfer, refer to Section II.1, “High-Speed DMA (HSDMA).”
Trap vectors
The default trap-vector address of each cause of interrupt is set as follows:
Receive DMA interrupt:
0xC00144
Transmit DMA interrupt:
0xC00148
SPI interrupt (FPT8 interrupt): 0xC00150
The base address of the trap table can be changed using the TTBR register.