]> git.tnoah.ca Git - lora-radio.git/commitdiff
Cleanup
authorMark Qvist <mark@unsigned.io>
Mon, 30 Sep 2024 17:18:30 +0000 (19:18 +0200)
committerMark Qvist <mark@unsigned.io>
Mon, 30 Sep 2024 17:18:30 +0000 (19:18 +0200)
BLESerial.cpp
BLESerial.h
Bluetooth.h
Boards.h
RNode_Firmware.ino
Release/console_image.bin

index 82908044786cb13741cc632893ed56b2b02f84fd..d08aee962ce888b7444ae21acff505177a954e5f 100644 (file)
@@ -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
index d1cae4d1d6cfc2db94e38bf593cfa72cf27bdf13..f7c0132f33e14bf8b82f7b7fd6a540184575e02c 100644 (file)
@@ -1,4 +1,7 @@
-#pragma once
+#include "Boards.h"
+
+#if HAS_BLE
+
 #include <Arduino.h>
 
 #include <BLEDevice.h>
@@ -109,3 +112,5 @@ private:
 
   bool started = false;
 };
+
+#endif
\ No newline at end of file
index 0c05a2bcae43bfa01bc34666899b8640738fb1c4..b5c3b77c0e7e083220f9381a1e506f853cf99faa 100644 (file)
@@ -14,7 +14,6 @@
 // along with this program.  If not, see <https://www.gnu.org/licenses/>.
 
 #if MCU_VARIANT == MCU_ESP32
-  
 
 #elif MCU_VARIANT == MCU_NRF52
 #endif
index b43da3c167aa66ce2485833a135b3ebca2affc85..5a93b88de0fc402f03f7475675a4e335e7c53acc 100644 (file)
--- a/Boards.h
+++ b/Boards.h
       #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
     #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;
     #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;
     #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
index 6279fd03ae509f1d71b4684a4d030f7a7d7ea5c4..fa563c4322640a1605b88d5963e95c89ebc421b4 100644 (file)
@@ -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
 }
 
index 4af95f371db635cdebcabf3720b99f3f01b0fde9..680de7b7de3d23e1c94e204c419e5b660c25cf1b 100644 (file)
Binary files a/Release/console_image.bin and b/Release/console_image.bin differ