This set of functions are related to ADCMic FIFO buffer.
◆ Cy_ADCMic_ReadFifoAll()
uint8_t Cy_ADCMic_ReadFifoAll |
( |
MXS40ADCMIC_Type const * |
base, |
|
|
uint16_t * |
data |
|
) |
| |
Reads whole the FIFO payload into the data array.
- Parameters
-
base | The pointer to the hardware ADCMic block. |
data | The pointer to the uint16_t data array for the FIFO payload. |
- Returns
- The 8-bit FIFO data count.
- Function Usage
uint16_t data[64];
uint8_t dataCount;
void ADCMic_Isr(void)
{
{
{
}
}
}
◆ Cy_ADCMic_GetFifoStatus()
__STATIC_INLINE uint8_t Cy_ADCMic_GetFifoStatus |
( |
MXS40ADCMIC_Type const * |
base | ) |
|
Returns the fifo status.
- Parameters
-
base | The pointer to the hardware ADCMic block. |
- Returns
- The 8-bit fifo status, see FIFO Status Masks.
- Function Usage
uint16_t data[64];
uint8_t dataCount;
void ADCMic_Isr(void)
{
{
{
}
}
}
◆ Cy_ADCMic_ReadFifo()
Low-level API which returns the ADCMIC_DATA register value that contains two subsequent FIFO data samples.
- Parameters
-
base | The pointer to the hardware ADCMic block. |
- Returns
- The combined 32-bit value of two 16-bit samples. Use FIFO Samples definitions to parse it.
- Function Usage
uint16_t samples[2U];
samples[0U] = (uint16_t)_FLD2VAL(CY_ADCMIC_FIFO_FIRST_SAMPLE, fifoData);
samples[1U] = (uint16_t)_FLD2VAL(CY_ADCMIC_FIFO_SECOND_SAMPLE, fifoData);