diff --git a/BLESerial.cpp b/BLESerial.cpp index 8290804..d08aee9 100644 --- a/BLESerial.cpp +++ b/BLESerial.cpp @@ -1,3 +1,7 @@ +#include "Boards.h" + +#if HAS_BLE + #include "BLESerial.h" uint32_t bt_passkey_callback(); @@ -127,3 +131,5 @@ void BLESerial::SetupSerialService() { } BLESerial::BLESerial() { } + +#endif \ No newline at end of file diff --git a/BLESerial.h b/BLESerial.h index d1cae4d..f7c0132 100644 --- a/BLESerial.h +++ b/BLESerial.h @@ -1,4 +1,7 @@ -#pragma once +#include "Boards.h" + +#if HAS_BLE + #include #include @@ -109,3 +112,5 @@ private: bool started = false; }; + +#endif \ No newline at end of file diff --git a/Bluetooth.h b/Bluetooth.h index 0c05a2b..b5c3b77 100644 --- a/Bluetooth.h +++ b/Bluetooth.h @@ -14,7 +14,6 @@ // along with this program. If not, see . #if MCU_VARIANT == MCU_ESP32 - #elif MCU_VARIANT == MCU_NRF52 #endif diff --git a/Boards.h b/Boards.h index b43da3c..5a93b88 100644 --- a/Boards.h +++ b/Boards.h @@ -149,7 +149,6 @@ #define HAS_DISPLAY true #define HAS_PMU true #define HAS_BLUETOOTH true - #define HAS_BLE true #define HAS_CONSOLE true #define HAS_SD false #define HAS_EEPROM true @@ -185,7 +184,6 @@ #elif BOARD_MODEL == BOARD_LORA32_V1_0 #define HAS_DISPLAY true #define HAS_BLUETOOTH true - #define HAS_BLE true #define HAS_CONSOLE true #define HAS_EEPROM true const int pin_cs = 18; @@ -202,7 +200,6 @@ #elif BOARD_MODEL == BOARD_LORA32_V2_0 #define HAS_DISPLAY true #define HAS_BLUETOOTH true - #define HAS_BLE true #define HAS_CONSOLE true #define HAS_EEPROM true const int pin_cs = 18; @@ -219,7 +216,6 @@ #elif BOARD_MODEL == BOARD_LORA32_V2_1 #define HAS_DISPLAY true #define HAS_BLUETOOTH true - #define HAS_BLE true #define HAS_PMU true #define HAS_CONSOLE true #define HAS_EEPROM true diff --git a/RNode_Firmware.ino b/RNode_Firmware.ino index 6279fd0..fa563c4 100644 --- a/RNode_Firmware.ino +++ b/RNode_Firmware.ino @@ -224,8 +224,10 @@ inline void kiss_write_packet() { #if MCU_VARIANT == MCU_ESP32 || MCU_VARIANT == MCU_NRF52 packet_ready = false; #endif - #if MCU_VARIANT == MCU_ESP32 && HAS_BLE - bt_flush(); + #if MCU_VARIANT == MCU_ESP32 + #if HAS_BLE + bt_flush(); + #endif #endif } diff --git a/Release/console_image.bin b/Release/console_image.bin index 4af95f3..680de7b 100644 Binary files a/Release/console_image.bin and b/Release/console_image.bin differ