![]() |
![]() |
Basic I2S Parameters. More...
#include <I2S.h>

Data Fields | |
| bool | trueI2sFormat |
| bool | invertWS |
| bool | isMSBFirst |
| bool | isDMAUnused |
| I2S_MemoryLength | memorySlotLength |
| uint8_t | beforeWordPadding |
| uint8_t | afterWordPadding |
| uint8_t | bitsPerWord |
| I2S_Role | moduleRole |
| I2S_SamplingEdge | samplingEdge |
| I2S_DataInterfaceUse | SD0Use |
| I2S_DataInterfaceUse | SD1Use |
| I2S_ChannelConfig | SD0Channels |
| I2S_ChannelConfig | SD1Channels |
| I2S_PhaseType | phaseType |
| uint16_t | fixedBufferLength |
| uint16_t | startUpDelay |
| uint16_t | CCLKDivider |
| uint32_t | samplingFrequency |
| I2S_Callback | readCallback |
| I2S_Callback | writeCallback |
| I2S_Callback | errorCallback |
| void * | custom |
Basic I2S Parameters.
I2S parameters are used to with the I2S_open() call. Default values for these parameters are set using I2S_Params_init().
| bool I2S_Params::trueI2sFormat |
Activate "true I2S format".
| bool I2S_Params::invertWS |
WS must be internally inverted when using I2S data format.
| bool I2S_Params::isMSBFirst |
Endianness selection.
| bool I2S_Params::isDMAUnused |
Selection between DMA transmissions and CPU transmissions.
| I2S_MemoryLength I2S_Params::memorySlotLength |
Width of stored samples. It should be consistent with the word length.
| uint8_t I2S_Params::beforeWordPadding |
Number of SCK periods between the first WS edge and the MSB of the first audio channel data transferred during the phase.
| uint8_t I2S_Params::afterWordPadding |
Number of SCK periods between the LSB of the an audio channel and the MSB of the next audio channel.
| uint8_t I2S_Params::bitsPerWord |
Bits per sample (Word length): must be between 8 and 24 bits.
| I2S_Role I2S_Params::moduleRole |
Select if the I2S module is a Target or a Controller.
| I2S_SamplingEdge I2S_Params::samplingEdge |
Select edge sampling type.
| I2S_DataInterfaceUse I2S_Params::SD0Use |
Select if SD0 is an input, an output or disabled.
| I2S_DataInterfaceUse I2S_Params::SD1Use |
Select if SD1 is an input, an output or disabled.
| I2S_ChannelConfig I2S_Params::SD0Channels |
This parameter is indicating which channels are valid on SD0. Valid channels on SD1 and SD0 can be different.
Refer to I2S_ChannelConfig for a list of possible values, and for which phase types they can be used.
| I2S_ChannelConfig I2S_Params::SD1Channels |
This parameter is indicating which channels are valid on SD1. Valid channels on SD1 and SD0 can be different.
Refer to I2S_ChannelConfig for a list of possible values, and for which phase types they can be used.
| I2S_PhaseType I2S_Params::phaseType |
Select phase type.
| uint16_t I2S_Params::fixedBufferLength |
Number of consecutive bytes of the samples buffers. This field must be set to a value x different from 0. All the data buffers used (both for input and output) must contain N*x bytes (with N an integer satisfying N>0).
| uint16_t I2S_Params::startUpDelay |
Number of WS periods to wait before the first transfer.
| uint16_t I2S_Params::CCLKDivider |
Select the frequency divider for CCLK signal. Final value of CCLK is 48MHz/CCLKDivider. Value must be selected between 2 and 1024.
| uint32_t I2S_Params::samplingFrequency |
I2S sampling frequency configuration in samples/second.
The selected sampling frequency must ensure that the SCK frequency will be inside of its device-specific limits. Please refer to the device-specific documentation for the lower and upper limits of the SCK frequency.
| I2S_Callback I2S_Params::readCallback |
Pointer to read callback. Cannot be NULL if a read interface is activated.
| I2S_Callback I2S_Params::writeCallback |
Pointer to write callback. Cannot be NULL if a write interface is activated.
| I2S_Callback I2S_Params::errorCallback |
Pointer to error callback. Cannot be NULL.
| void* I2S_Params::custom |
Pointer to device specific custom params