![]() |
LPCOpen Platform
v1.03
LPCOpen Platform for NXP LPC Microcontrollers
|
Data Structures | |
| struct | CHIP_SPI_CONFIG_FORMAT_T |
| struct | CHIP_SPI_DATA_SETUP_T |
| SPI data setup structure. More... | |
Macros | |
| #define | CHIP_SPI_CLOCK_MODE_T IP_SPI_CLOCK_MODE_T |
| #define | CHIP_SPI_MODE_T IP_SPI_MODE_T |
| #define | CHIP_SPI_DATA_ORDER_T IP_SPI_DATA_ORDER_T |
| #define | CHIP_SPI_BITS_T IP_SPI_BITS_T |
Typedefs | |
| typedef void(* | CHIP_SPI_CALLBACK_T )(void) |
Functions | |
| STATIC INLINE uint32_t | Chip_SPI_GetStatus (LPC_SPI_T *pSPI) |
| Get the current status of SPI controller. | |
| void | Chip_SPI_Int_FlushData (LPC_SPI_T *pSPI) |
| Clean all data in RX FIFO of SPI. | |
| Status | Chip_SPI_Int_RWFrames8Bits (LPC_SPI_T *pSPI, CHIP_SPI_DATA_SETUP_T *xf_setup) |
| SPI Interrupt Read/Write with 8-bit frame width. | |
| Status | Chip_SPI_Int_RWFrames16Bits (LPC_SPI_T *pSPI, CHIP_SPI_DATA_SETUP_T *xf_setup) |
| SPI Interrupt Read/Write with 16-bit frame width. | |
| uint32_t | Chip_SPI_RWFrames_Blocking (LPC_SPI_T *pSPI, CHIP_SPI_DATA_SETUP_T *pXfSetup) |
| SPI Polling Read/Write in blocking mode. | |
| uint32_t | Chip_SPI_WriteFrames_Blocking (LPC_SPI_T *pSPI, uint8_t *buffer, uint32_t buffer_len) |
| SPI Polling Write in blocking mode. | |
| uint32_t | Chip_SPI_ReadFrames_Blocking (LPC_SPI_T *pSPI, uint8_t *buffer, uint32_t buffer_len) |
| SPI Polling Read in blocking mode. | |
| void | Chip_SPI_Init (LPC_SPI_T *pSPI) |
| Initialize the SPI. | |
| void | Chip_SPI_DeInit (LPC_SPI_T *pSPI) |
| Deinitialise the SPI. | |
| STATIC INLINE void | Chip_SPI_SetMode (LPC_SPI_T *pSPI, CHIP_SPI_MODE_T mode) |
| Set the SPI operating modes, master or slave. | |
| void | Chip_SPI_SetBitRate (LPC_SPI_T *pSPI, uint32_t bitRate) |
| Set the clock frequency for SPI interface. | |
| STATIC INLINE void | Chip_SPI_SetFormat (LPC_SPI_T *pSPI, CHIP_SPI_CONFIG_FORMAT_T *format) |
| Set up the SPI frame format. | |
| STATIC INLINE void | Chip_SPI_Int_Enable (LPC_SPI_T *pSPI) |
| Enable SPI interrupt. | |
| STATIC INLINE void | Chip_SPI_Int_Disable (LPC_SPI_T *pSPI) |
| Disable SPI interrupt. | |
| #define CHIP_SPI_BITS_T IP_SPI_BITS_T |
Definition at line 47 of file spi_17xx_40xx.h.
| #define CHIP_SPI_CLOCK_MODE_T IP_SPI_CLOCK_MODE_T |
Definition at line 44 of file spi_17xx_40xx.h.
| #define CHIP_SPI_DATA_ORDER_T IP_SPI_DATA_ORDER_T |
Definition at line 46 of file spi_17xx_40xx.h.
| #define CHIP_SPI_MODE_T IP_SPI_MODE_T |
Definition at line 45 of file spi_17xx_40xx.h.
| typedef void(* CHIP_SPI_CALLBACK_T)(void) |
SPI callback function type
Definition at line 50 of file spi_17xx_40xx.h.
| void Chip_SPI_DeInit | ( | LPC_SPI_T * | pSPI | ) |
Get the current status of SPI controller.
Definition at line 78 of file spi_17xx_40xx.h.
| void Chip_SPI_Init | ( | LPC_SPI_T * | pSPI | ) |
Initialize the SPI.
| pSPI | : The base SPI peripheral on the chip |
Disable SPI interrupt.
| pSPI | : The base SPI peripheral on the chip |
Definition at line 205 of file spi_17xx_40xx.h.
Enable SPI interrupt.
| pSPI | : The base SPI peripheral on the chip |
Definition at line 195 of file spi_17xx_40xx.h.
| void Chip_SPI_Int_FlushData | ( | LPC_SPI_T * | pSPI | ) |
Clean all data in RX FIFO of SPI.
| pSPI | : The base SPI peripheral on the chip |
| Status Chip_SPI_Int_RWFrames16Bits | ( | LPC_SPI_T * | pSPI, |
| CHIP_SPI_DATA_SETUP_T * | xf_setup | ||
| ) |
SPI Interrupt Read/Write with 16-bit frame width.
| pSPI | : The base SPI peripheral on the chip |
| xf_setup | : Pointer to a SPI_DATA_SETUP_T structure that contains specified information about transmit/receive data configuration |
| Status Chip_SPI_Int_RWFrames8Bits | ( | LPC_SPI_T * | pSPI, |
| CHIP_SPI_DATA_SETUP_T * | xf_setup | ||
| ) |
SPI Interrupt Read/Write with 8-bit frame width.
| pSPI | : The base SPI peripheral on the chip |
| xf_setup | : Pointer to a SPI_DATA_SETUP_T structure that contains specified information about transmit/receive data configuration |
SPI Polling Read in blocking mode.
| pSPI | : The base SPI peripheral on the chip |
| buffer | : Buffer address |
| buffer_len | : The length of buffer |
| uint32_t Chip_SPI_RWFrames_Blocking | ( | LPC_SPI_T * | pSPI, |
| CHIP_SPI_DATA_SETUP_T * | pXfSetup | ||
| ) |
SPI Polling Read/Write in blocking mode.
| pSPI | : The base SPI peripheral on the chip |
| pXfSetup | : Pointer to a SPI_DATA_SETUP_T structure that contains specified information about transmit/receive data configuration |
Set the clock frequency for SPI interface.
| pSPI | : The base SPI peripheral on the chip |
| bitRate | : The SPI bit rate |
| STATIC INLINE void Chip_SPI_SetFormat | ( | LPC_SPI_T * | pSPI, |
| CHIP_SPI_CONFIG_FORMAT_T * | format | ||
| ) |
Set up the SPI frame format.
| pSPI | : The base SPI peripheral on the chip |
| format | : Pointer to Frame format structure |
Definition at line 185 of file spi_17xx_40xx.h.
| STATIC INLINE void Chip_SPI_SetMode | ( | LPC_SPI_T * | pSPI, |
| CHIP_SPI_MODE_T | mode | ||
| ) |
Set the SPI operating modes, master or slave.
| pSPI | : The base SPI peripheral on the chip |
| mode | : master mode/slave mode |
Definition at line 166 of file spi_17xx_40xx.h.
SPI Polling Write in blocking mode.
| pSPI | : The base SPI peripheral on the chip |
| buffer | : Buffer address |
| buffer_len | : Buffer length |