Function esp_idf_svc::hal::sys::twai_receive_v2
source ยท pub unsafe extern "C" fn twai_receive_v2(
handle: *mut twai_obj_t,
message: *mut twai_message_t,
ticks_to_wait: u32,
) -> i32
Expand description
@brief Receive a TWAI message via a given handle
@note This is an advanced version of twai_receive
that can receive a TWAI message with a given handle.
Please refer to the documentation of twai_receive
for more details.
@param[in] handle TWAI driver handle returned by twai_driver_install_v2
@param[out] message Received message
@param[in] ticks_to_wait Number of FreeRTOS ticks to block on RX queue
@return - ESP_OK: Message successfully received from RX queue - ESP_ERR_TIMEOUT: Timed out waiting for message - ESP_ERR_INVALID_ARG: Arguments are invalid - ESP_ERR_INVALID_STATE: TWAI driver is not installed