]> git.tnoah.ca Git - lora-radio.git/commitdiff
Fix builds and restructure configs for multi interface
authorjacob.eva <x00010@disroot.org>
Thu, 4 Jul 2024 17:52:29 +0000 (18:52 +0100)
committerjacob.eva <x00010@disroot.org>
Thu, 4 Jul 2024 17:52:29 +0000 (18:52 +0100)
Boards.h

index 25db2ab9ebdb7eab99360748072e125a76e9ebea..3d0a80c20679e6f91cd1d2427d5c72ce0e78500a 100644 (file)
--- a/Boards.h
+++ b/Boards.h
       #define I2C_SDA 21
       #define I2C_SCL 22
       #define PMU_IRQ 35
+      #define INTERFACE_COUNT 1
       const int pin_led_rx = 2;
       const int pin_led_tx = 4;
 
-      #define INTERFACE_COUNT 1
-
       const uint8_t interfaces[INTERFACE_COUNT] = {SX1262};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX1262
       #define HAS_BLUETOOTH true
       #define HAS_CONSOLE true
       #define HAS_EEPROM true
+      #define INTERFACE_COUNT 1
       const int pin_led_rx = 14;
       const int pin_led_tx = 32;
 
-      #define INTERFACE_COUNT 1
-
       const uint8_t interfaces[INTERFACE_COUNT] = {SX127X};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX127X
       #define HAS_BLE true
       #define HAS_CONSOLE true
       #define HAS_EEPROM true
+      #define INTERFACE_COUNT 1
       const int pin_cs = 18;
       const int pin_reset = 14;
       const int pin_dio = 26;
         const int pin_led_tx = 2;
       #endif
 
-      #define INTERFACE_COUNT 1
-
       const uint8_t interfaces[INTERFACE_COUNT] = {SX1276};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX1276
       #define HAS_BLE true
       #define HAS_CONSOLE true
       #define HAS_EEPROM true
+      #define INTERFACE_COUNT 1
       const int pin_cs = 18;
       const int pin_reset = 12;
       const int pin_dio = 26;
         const int pin_led_tx = 22;
       #endif
 
-      #define INTERFACE_COUNT 1
 
       const uint8_t interfaces[INTERFACE_COUNT] = {SX127X};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
       #define HAS_PMU true
       #define HAS_CONSOLE true
       #define HAS_EEPROM true
+      #define INTERFACE_COUNT 1
+
+      const uint8_t interfaces[INTERFACE_COUNT] = {SX127X};
       #if HAS_TCXO == true
         const bool interface_cfg[INTERFACE_COUNT][3] = { 
                         // SX127X
         const int pin_led_tx = 25;
       #endif
 
-      #define INTERFACE_COUNT 1
-
-      const uint8_t interfaces[INTERFACE_COUNT] = {SX127X};
-
       #if HAS_TCXO == false
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX127X
       #define HAS_BLUETOOTH true
       #define HAS_CONSOLE true
       #define HAS_EEPROM true
+      #define INTERFACE_COUNT 1
       #if defined(EXTERNAL_LEDS)
         const int pin_led_rx = 36;
         const int pin_led_tx = 37;
         const int pin_led_tx = 25;
       #endif
 
-      #define INTERFACE_COUNT 1
-
       const uint8_t interfaces[INTERFACE_COUNT] = {SX127X};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX127X
       #define HAS_NP true
       #define HAS_CONSOLE true
       #define HAS_EEPROM true
+      #define INTERFACE_COUNT 1
       const int pin_cs = 18;
       const int pin_reset = 12;
       const int pin_dio = 26;
         #endif
       #endif
 
+
       const uint8_t interfaces[INTERFACE_COUNT] = {SX1276};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX1276
       #define HAS_NP true
       #define HAS_SD false
       #define HAS_EEPROM true
+      #define INTERFACE_COUNT 1
       const int pin_np = 12;
       const int pin_dac = 25;
       const int pin_adc = 34;
         #endif
       #endif
 
+
       const uint8_t interfaces[INTERFACE_COUNT] = {SX127X};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX127X
 
     #elif BOARD_MODEL == BOARD_RNODE_NG_22
       #define IS_ESP32S3 true
-      #define MODEM SX1262
 
       #define HAS_DISPLAY true
       #define DISPLAY OLED
       #define HAS_SLEEP true
       #define PIN_WAKEUP GPIO_NUM_0
       #define WAKEUP_LEVEL 0
+      #define INTERFACE_COUNT 1
       // #define PIN_DISP_SLEEP 21
       // #define DISP_SLEEP_LEVEL HIGH
       const int pin_btn_usr1 = 0;
         #endif
       #endif
 
+
       const uint8_t interfaces[INTERFACE_COUNT] = {SX1262};
       const bool interface_cfg[INTERFACE_COUNT][3] = { 
                     // SX1262