CoX Peripheral Interface V2.1
API Reference
SPI

Serial Peripheral Interface (SPI) Peripheral Driver. More...

Collaboration diagram for SPI:

Modules

 xSPI
 

CoX SPI Peripheral Interface.



Detailed Description

Serial Peripheral Interface (SPI) Peripheral Driver.

The Serial Peripheral Interface (SPI) is a synchronous serial data communication protocol which operates in full duplex mode. Devices communicate in master/slave mode with 4-wire bi-direction interface.


Contents


1. SPI Physical Block

spi_block.png


2. SPI Function Description


2.1 SPI device controller configuration

Configure the SPI controller as a master or a slave device. It should generate clock and chip-select signals if it is set as a master device.


2.2 SPI interrupt control

Each SPI controller can generate an individual interrupt when data transfer is finished and the respective interrupt event flag IF will be set. The interrupt event flag will generates an interrupt to CPU if the interrupt enable bit IE is set.


2.3 SPI Transfer and Receive data

Transfer and receive data.


3. SPI Applications

will be added in the future


Note:
Here are descriptions of the common functions of the SPI. The CoX SPI Interface is based on the functions above.