Function esp_idf_svc::hal::sys::esp_transport_read

source ยท
pub unsafe extern "C" fn esp_transport_read(
    t: *mut esp_transport_item_t,
    buffer: *mut i8,
    len: i32,
    timeout_ms: i32,
) -> i32
Expand description

@brief Transport read function

@param t The transport handle @param buffer The buffer @param[in] len The length @param[in] timeout_ms The timeout milliseconds (-1 indicates wait forever)

@return

  • Number of bytes was read
  • 0 Read timed-out
  • (<0) For other errors

@note: Please refer to the enum esp_tcp_transport_err_t for all the possible return values