From 0c8f9ed64ecfe304cafab9735055de917fd22808 Mon Sep 17 00:00:00 2001 From: pennam Date: Wed, 16 Nov 2022 11:12:38 +0100 Subject: [PATCH] Make Portenta a LoRa device if Arduino_LoRaConnectionHandler.h is included in sketch file --- src/AIoTC_Config.h | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/AIoTC_Config.h b/src/AIoTC_Config.h index 56c90697..623ef4e4 100644 --- a/src/AIoTC_Config.h +++ b/src/AIoTC_Config.h @@ -115,12 +115,20 @@ #endif #if defined(ARDUINO_SAMD_MKRGSM1400) || defined(ARDUINO_SAMD_MKR1000) || \ - defined(ARDUINO_SAMD_MKRNB1500) || defined(ARDUINO_PORTENTA_H7_M7) || \ - defined (ARDUINO_NANO_RP2040_CONNECT) + defined(ARDUINO_SAMD_MKRNB1500) || defined (ARDUINO_NANO_RP2040_CONNECT) #define BOARD_HAS_ECCX08 #define HAS_TCP #endif +#if defined(ARDUINO_PORTENTA_H7_M7) + #if __has_include("Arduino_LoRaConnectionHandler.h") + #define HAS_LORA + #else + #define BOARD_HAS_ECCX08 + #define HAS_TCP + #endif +#endif + #if defined(ARDUINO_NICLA_VISION) #define BOARD_HAS_SE050 #define HAS_TCP