![]() |
LPCOpen Platform
LPCOpen Platform for NXP LPC Microcontrollers
|
Data Structures | |
struct | Chip_I2S_Audio_Format_Type |
I2S Audio Format Structure. More... | |
Macros | |
#define | I2S_DMA_REQUEST_NUMBER_1 IP_I2S_DMA_REQUEST_NUMBER_1 |
#define | I2S_DMA_REQUEST_NUMBER_2 IP_I2S_DMA_REQUEST_NUMBER_2 |
Functions | |
STATIC INLINE void | Chip_I2S_Init (LPC_I2S_Type *pI2S) |
Initialize for I2S. | |
STATIC INLINE void | Chip_I2S_DeInit (LPC_I2S_Type *pI2S) |
Shutdown I2S. | |
STATIC INLINE void | Chip_I2S_Send (LPC_I2S_Type *pI2S, uint32_t data) |
Send a 32-bit data to TXFIFO for transmition. | |
STATIC INLINE uint32_t | Chip_I2S_Receive (LPC_I2S_Type *pI2S) |
Get received data from RXFIFO. | |
STATIC INLINE void | Chip_I2S_Start (LPC_I2S_Type *pI2S, uint8_t TRMode) |
Start the I2S. | |
STATIC INLINE void | Chip_I2S_Pause (LPC_I2S_Type *pI2S, uint8_t TRMode) |
Disables accesses on FIFOs, places the transmit channel in mute mode. | |
STATIC INLINE void | Chip_I2S_Mute (LPC_I2S_Type *pI2S, FunctionalState NewState) |
Transmit channel sends only zeroes. | |
STATIC INLINE void | Chip_I2S_Stop (LPC_I2S_Type *pI2S, uint8_t TRMode) |
Stop I2S asynchronously. | |
STATIC INLINE void | Chip_I2S_ModeConfig (LPC_I2S_Type *pI2S, uint8_t TRMode, uint32_t clksel, uint32_t fpin, uint32_t mcena) |
Set the I2S operating modes. | |
STATIC INLINE uint8_t | Chip_I2S_GetLevel (LPC_I2S_Type *pI2S, uint8_t TRMode) |
Get the current level of the Transmit/Receive FIFO. | |
Status | Chip_I2S_Config (LPC_I2S_Type *pI2S, uint8_t TRMode, Chip_I2S_Audio_Format_Type *audio_format) |
Configure I2S for Audio Format input. | |
void | Chip_I2S_Int_Cmd (LPC_I2S_Type *pI2S, uint8_t TRMode, FunctionalState NewState, uint8_t FIFO_Depth) |
Enable/Disable Interrupt with a specific FIFO depth. | |
void | Chip_I2S_DMA_Cmd (LPC_I2S_Type *pI2S, uint8_t TRMode, uint8_t DMANum, FunctionalState NewState, uint8_t FIFO_Depth) |
Enable/Disable DMA with a specific FIFO depth. | |
#define I2S_DMA_REQUEST_NUMBER_1 IP_I2S_DMA_REQUEST_NUMBER_1 |
Definition at line 46 of file i2s_18xx_43xx.h.
#define I2S_DMA_REQUEST_NUMBER_2 IP_I2S_DMA_REQUEST_NUMBER_2 |
Definition at line 47 of file i2s_18xx_43xx.h.
Status Chip_I2S_Config | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode, | ||
Chip_I2S_Audio_Format_Type * | audio_format | ||
) |
Configure I2S for Audio Format input.
pI2S | : The base I2S peripheral on the chip |
TRMode | : Mode Rx/Tx |
audio_format | : Audio Format |
Definition at line 52 of file i2s_18xx_43xx.c.
STATIC INLINE void Chip_I2S_DeInit | ( | LPC_I2S_Type * | pI2S | ) |
Shutdown I2S.
pI2S | : The base of I2S peripheral on the chip |
Definition at line 74 of file i2s_18xx_43xx.h.
void Chip_I2S_DMA_Cmd | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode, | ||
uint8_t | DMANum, | ||
FunctionalState | NewState, | ||
uint8_t | FIFO_Depth | ||
) |
Enable/Disable DMA with a specific FIFO depth.
pI2S | : The base I2S peripheral on the chip |
TRMode | : Mode Rx/Tx |
DMANum | : Should be
|
NewState | : ENABLE or DISABLE interrupt |
FIFO_Depth | : FIFO level creating an irq request |
Definition at line 130 of file i2s_18xx_43xx.c.
STATIC INLINE uint8_t Chip_I2S_GetLevel | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode | ||
) |
Get the current level of the Transmit/Receive FIFO.
pI2S | : The base of I2S peripheral on the chip |
TRMode | : Transmit/Receive mode, should be I2S_RX_MODE or I2S_TX_MODE |
Definition at line 176 of file i2s_18xx_43xx.h.
STATIC INLINE void Chip_I2S_Init | ( | LPC_I2S_Type * | pI2S | ) |
Initialize for I2S.
pI2S | : The base of I2S peripheral on the chip |
Definition at line 63 of file i2s_18xx_43xx.h.
void Chip_I2S_Int_Cmd | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode, | ||
FunctionalState | NewState, | ||
uint8_t | FIFO_Depth | ||
) |
Enable/Disable Interrupt with a specific FIFO depth.
pI2S | : The base I2S peripheral on the chip |
TRMode | : Mode Rx/Tx |
NewState | : ENABLE or DISABLE interrupt |
FIFO_Depth | : FIFO level creating an irq request |
Definition at line 123 of file i2s_18xx_43xx.c.
STATIC INLINE void Chip_I2S_ModeConfig | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode, | ||
uint32_t | clksel, | ||
uint32_t | fpin, | ||
uint32_t | mcena | ||
) |
Set the I2S operating modes.
pI2S | : The base of I2S peripheral on the chip |
TRMode | : Transmit/Receive mode, should be I2S_RX_MODE or I2S_TX_MODE |
clksel | : Clock source selection for the receive bit clock divider |
fpin | : Receive 4-pin mode selection |
mcena | : Enable for the RX_MCLK output |
Definition at line 161 of file i2s_18xx_43xx.h.
STATIC INLINE void Chip_I2S_Mute | ( | LPC_I2S_Type * | pI2S, |
FunctionalState | NewState | ||
) |
Transmit channel sends only zeroes.
pI2S | : The base of I2S peripheral on the chip |
NewState | : Transmit/Receive mode, should be I2S_RX_MODE or I2S_TX_MODE |
Definition at line 131 of file i2s_18xx_43xx.h.
STATIC INLINE void Chip_I2S_Pause | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode | ||
) |
Disables accesses on FIFOs, places the transmit channel in mute mode.
pI2S | : The base of I2S peripheral on the chip |
TRMode | : Transmit/Receive mode, should be I2S_RX_MODE or I2S_TX_MODE |
Definition at line 119 of file i2s_18xx_43xx.h.
STATIC INLINE uint32_t Chip_I2S_Receive | ( | LPC_I2S_Type * | pI2S | ) |
Get received data from RXFIFO.
pI2S | : The base of I2S peripheral on the chip |
Definition at line 97 of file i2s_18xx_43xx.h.
STATIC INLINE void Chip_I2S_Send | ( | LPC_I2S_Type * | pI2S, |
uint32_t | data | ||
) |
Send a 32-bit data to TXFIFO for transmition.
pI2S | : The base of I2S peripheral on the chip |
data | : Data to be transmited |
Definition at line 86 of file i2s_18xx_43xx.h.
STATIC INLINE void Chip_I2S_Start | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode | ||
) |
Start the I2S.
pI2S | : The base of I2S peripheral on the chip |
TRMode | : Transmit/Receive mode, should be I2S_RX_MODE or I2S_TX_MODE |
Definition at line 108 of file i2s_18xx_43xx.h.
STATIC INLINE void Chip_I2S_Stop | ( | LPC_I2S_Type * | pI2S, |
uint8_t | TRMode | ||
) |
Stop I2S asynchronously.
pI2S | : The base of I2S peripheral on the chip |
TRMode | : Transmit/Receive mode, should be I2S_RX_MODE or I2S_TX_MODE |
Definition at line 143 of file i2s_18xx_43xx.h.