1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-25 14:33:52 +01:00

gnrc_lorawan: update gnrc_lorawan_radio_rx_done function

This commit is contained in:
Jose Alamos 2021-06-24 15:56:23 +02:00
parent 71ddd3bd61
commit a90e5e6fc4
No known key found for this signature in database
GPG Key ID: F483EB800EF89DD9
2 changed files with 4 additions and 5 deletions

View File

@ -237,8 +237,9 @@ void gnrc_lorawan_mcps_request(gnrc_lorawan_t *mac,
* To be called on radio RX done event.
*
* @param[in] mac pointer to the MAC descriptor
* @param[in] data pointer to the psdu. Pass NULL if the packet was wrong (or
* allocation failed)
* @param[in] data pointer to the psdu. Must not be NULL. Use
* @ref gnrc_lorawan_radio_rx_error_cb instead if the reception was
* not successful.
* @param[in] size size of the PSDU
*/
void gnrc_lorawan_radio_rx_done_cb(gnrc_lorawan_t *mac, uint8_t *data,

View File

@ -242,10 +242,8 @@ void gnrc_lorawan_send_pkt(gnrc_lorawan_t *mac, iolist_t *psdu, uint8_t dr)
void gnrc_lorawan_radio_rx_done_cb(gnrc_lorawan_t *mac, uint8_t *psdu,
size_t size)
{
assert(psdu);
_sleep_radio(mac);
if (psdu == NULL) {
return;
}
mac->state = LORAWAN_STATE_IDLE;
gnrc_lorawan_remove_timer(mac);