From 2ed49453d1f12cf653e3cffe2755c9786ed920bc Mon Sep 17 00:00:00 2001 From: Diego Valcarce Date: Wed, 5 Nov 2025 21:22:36 +0100 Subject: [PATCH] fix: set context when using usp lbm (fixes #2) This commits needs the patch of https://github.com/Lora-net/usp/pull/2 as otherwise, the `modem_radio` is not initialized --- modules/smtc_modem_hal/smtc_modem_hal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/smtc_modem_hal/smtc_modem_hal.c b/modules/smtc_modem_hal/smtc_modem_hal.c index d6dbf85..4711cb5 100644 --- a/modules/smtc_modem_hal/smtc_modem_hal.c +++ b/modules/smtc_modem_hal/smtc_modem_hal.c @@ -48,6 +48,7 @@ #include #include +#include #include #if defined(CONFIG_USP) @@ -111,7 +112,7 @@ void lorawan_smtc_modem_hal_init(const struct device *transceiver) #if defined(CONFIG_USP) smtc_rac_set_radio_context(prv_transceiver_dev); // Driver HAL implementation #endif -#if defined( CONFIG_LORA_BASICS_MODEM ) +#if defined( CONFIG_LORA_BASICS_MODEM ) || defined( CONFIG_USP_LORA_BASICS_MODEM ) smtc_modem_set_radio_context(prv_transceiver_dev); #endif }