Looking at esp_ieee802154_transmit from https://github.com/espressif/esp-idf/b ... ee802154.h
It's not clear what value to set for length, is it the length of (Len + MHR + MAC Payload + FCS) or (MHR + MAC Payload + FCS)?
Similarly on the receive side
/**
* @brief Transmit the given frame.
* The transmit result will be reported via `esp_ieee802154_transmit_done()`
* or `esp_ieee802154_transmit_failed()`.
*
* @param[in] frame The pointer to the frame, the frame format:
* |-----------------------------------------------------------------------|
* | Len | MHR | MAC Payload | FCS |
* |-----------------------------------------------------------------------|
* @param[in] cca Perform CCA before transmission if it's true, otherwise transmit the frame directly.
*
* @note During transmission, the hardware calculates the FCS, and send it over the air right after the MAC payload,
* so you just need to prepare the length, mac header and mac payload content.
*
* @return
* - ESP_OK on success.
* - ESP_ERR_INVALID_ARG on an invalid frame.
* - ESP_FAIL on failure due to invalid state.
*
*/
esp_err_t esp_ieee802154_transmit(const uint8_t *frame, bool cca);
what is correct length value for esp_ieee802154_transmit?
Re: what is correct length value for esp_ieee802154_transmit?
It's the length of (MHR + MAC Payload + FCS).
Who is online
Users browsing this forum: No registered users and 7 guests