Struct esp_idf_hal::sys::i2s_event_callbacks_t
source · #[repr(C)]pub struct i2s_event_callbacks_t {
pub on_recv: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>,
pub on_recv_q_ovf: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>,
pub on_sent: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>,
pub on_send_q_ovf: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>,
}
Expand description
@brief Group of I2S callbacks @note The callbacks are all running under ISR environment @note When CONFIG_I2S_ISR_IRAM_SAFE is enabled, the callback itself and functions called by it should be placed in IRAM. The variables used in the function should be in the SRAM as well.
Fields§
§on_recv: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>
< Callback of data received event, only for rx channel The event data includes DMA buffer address and size that just finished receiving data
on_recv_q_ovf: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>
< Callback of receiving queue overflowed event, only for rx channel The event data includes buffer size that has been overwritten
on_sent: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>
< Callback of data sent event, only for tx channel The event data includes DMA buffer address and size that just finished sending data
on_send_q_ovf: Option<unsafe extern "C" fn(_: *mut i2s_channel_obj_t, _: *mut i2s_event_data_t, _: *mut c_void) -> bool>
< Callback of sending queue overflowed event, only for tx channel The event data includes buffer size that has been overwritten
Trait Implementations§
source§impl Clone for i2s_event_callbacks_t
impl Clone for i2s_event_callbacks_t
source§fn clone(&self) -> i2s_event_callbacks_t
fn clone(&self) -> i2s_event_callbacks_t
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more