diff --git a/src/mesh/RF95Interface.cpp b/src/mesh/RF95Interface.cpp index 498727639..f57aaa055 100644 --- a/src/mesh/RF95Interface.cpp +++ b/src/mesh/RF95Interface.cpp @@ -15,7 +15,7 @@ RF95Interface::RF95Interface(RADIOLIB_PIN_TYPE cs, RADIOLIB_PIN_TYPE irq, RADIOL SPIClass &spi) : RadioLibInterface(cs, irq, rst, busy, spi) { - // FIXME - we assume devices never get destroyed + LOG_WARN("RF95Interface(cs=%d, irq=%d, rst=%d, busy=%d)\n", cs, irq, rst, busy); } /** Some boards require GPIO control of tx vs rx paths */ diff --git a/src/mesh/SX128xInterface.cpp b/src/mesh/SX128xInterface.cpp index aff4c1253..85e41f29f 100644 --- a/src/mesh/SX128xInterface.cpp +++ b/src/mesh/SX128xInterface.cpp @@ -13,6 +13,7 @@ SX128xInterface::SX128xInterface(RADIOLIB_PIN_TYPE cs, RADIOLIB_PIN_TYPE irq, SPIClass &spi) : RadioLibInterface(cs, irq, rst, busy, spi, &lora), lora(&module) { + LOG_WARN("SX128xInterface(cs=%d, irq=%d, rst=%d, busy=%d)\n", cs, irq, rst, busy); } /// Initialise the Driver transport hardware and software. @@ -73,6 +74,13 @@ template bool SX128xInterface::init() LOG_INFO("Bandwidth set to %f\n", bw); LOG_INFO("Power output set to %d\n", power); +#if defined(SX128X_TXEN) && (SX128X_TXEN != RADIOLIB_NC) && defined(SX128X_RXEN) && (SX128X_RXEN != RADIOLIB_NC) + // lora.begin sets Dio2 as RF switch control, which is not true if we are manually controlling RX and TX + if (res == RADIOLIB_ERR_NONE) { + lora.setRfSwitchPins(SX128X_RXEN, SX128X_TXEN); + } +#endif + if (res == RADIOLIB_ERR_NONE) res = lora.setCRC(2); diff --git a/variants/tlora_t3s3_v1/variant.h b/variants/tlora_t3s3_v1/variant.h index 0f88af819..768a7c2da 100644 --- a/variants/tlora_t3s3_v1/variant.h +++ b/variants/tlora_t3s3_v1/variant.h @@ -59,4 +59,5 @@ #define SX128X_RESET LORA_RESET #define SX128X_RXEN 21 #define SX128X_TXEN 10 +#define SX128X_MAX_POWER 3 #endif \ No newline at end of file