[][src]Function esp_idf_sys::i2s_pop_sample

pub unsafe extern "C" fn i2s_pop_sample(
    i2s_num: i2s_port_t,
    sample: *mut c_void,
    ticks_to_wait: TickType_t
) -> c_int

@brief Read a single sample from the I2S DMA RX buffer.

This function is deprecated. Use 'i2s_read' instead. This definition will be removed in a future release.

@param i2s_num I2S_NUM_0, I2S_NUM_1

@param sample Buffer to write data. Size of buffer (in bytes) = bits_per_sample / 8.

@param ticks_to_wait Timeout in RTOS ticks. If a sample is not available in the DMA buffer within this period, no data is read and function returns zero.

@return - Number of bytes successfully read from DMA buffer, will be either zero or the size of configured sample buffer (in bytes). - ESP_FAIL Parameter error