diff --git a/arch/stm32/stm32.ini b/arch/stm32/stm32.ini index ef38c3084..d5e615f5f 100644 --- a/arch/stm32/stm32.ini +++ b/arch/stm32/stm32.ini @@ -20,7 +20,7 @@ build_flags = -DMESHTASTIC_EXCLUDE_MQTT -DMESHTASTIC_EXCLUDE_BLUETOOTH -DMESHTASTIC_EXCLUDE_GPS - -DDEBUG_MUTE + ;-DDEBUG_MUTE -fmerge-all-constants -ffunction-sections -fdata-sections @@ -39,4 +39,4 @@ lib_deps = lib_ignore = mathertel/OneButton@2.6.1 - Wire \ No newline at end of file + Wire diff --git a/src/mesh/STM32WLE5JCInterface.cpp b/src/mesh/STM32WLE5JCInterface.cpp index ad1f675b6..6a340dd28 100644 --- a/src/mesh/STM32WLE5JCInterface.cpp +++ b/src/mesh/STM32WLE5JCInterface.cpp @@ -18,8 +18,10 @@ bool STM32WLE5JCInterface::init() { RadioLibInterface::init(); - // https://github.com/Seeed-Studio/LoRaWan-E5-Node/blob/main/Middlewares/Third_Party/SubGHz_Phy/stm32_radio_driver/radio_driver.c +// https://github.com/Seeed-Studio/LoRaWan-E5-Node/blob/main/Middlewares/Third_Party/SubGHz_Phy/stm32_radio_driver/radio_driver.c +#if (!defined(_VARIANT_RAK3172_)) setTCXOVoltage(1.7); +#endif lora.setRfSwitchTable(rfswitch_pins, rfswitch_table); @@ -42,4 +44,4 @@ bool STM32WLE5JCInterface::init() return res == RADIOLIB_ERR_NONE; } -#endif // ARCH_STM32WL \ No newline at end of file +#endif // ARCH_STM32WL diff --git a/variants/rak3172/platformio.ini b/variants/rak3172/platformio.ini index 2cf03da2e..456697aef 100644 --- a/variants/rak3172/platformio.ini +++ b/variants/rak3172/platformio.ini @@ -5,9 +5,6 @@ board_upload.maximum_size = 233472 ; reserve the last 28KB for filesystem build_flags = ${stm32_base.build_flags} -Ivariants/rak3172 - -DSERIAL_UART_INSTANCE=1 - -DPIN_SERIAL_RX=PB7 - -DPIN_SERIAL_TX=PB6 -DHAL_DAC_MODULE_ONLY -DHAL_RNG_MODULE_ENABLED -DRADIOLIB_EXCLUDE_SX128X=1 @@ -23,5 +20,4 @@ build_flags = -DMESHTASTIC_EXCLUDE_POWERMON=1 ;-DPIO_FRAMEWORK_ARDUINO_NANOLIB_FLOAT_PRINTF ;-DCFG_DEBUG - -upload_port = stlink \ No newline at end of file +upload_port = stlink diff --git a/variants/rak3172/variant.h b/variants/rak3172/variant.h index 21de65b2c..21676f9cf 100644 --- a/variants/rak3172/variant.h +++ b/variants/rak3172/variant.h @@ -1,3 +1,8 @@ +/* +STM32WLE5 Core Module for LoRaWAN® RAK3372 +https://store.rakwireless.com/products/wisblock-core-module-rak3372 +*/ + /* This variant is a work in progress. Do not expect a working Meshtastic device with this target. @@ -9,4 +14,7 @@ Do not expect a working Meshtastic device with this target. #define USE_STM32WLx #define MAX_NUM_NODES 10 -#endif \ No newline at end of file +#define LED_PIN PA0 // Green LED +#define LED_STATE_ON 1 + +#endif