From 76791220b967051ae13f3aefc59353f30b62f4ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9E=D1=81=D0=BC=D0=B0=D0=BD=D0=BE=D0=B2=20=D0=92=D0=BB?= =?UTF-8?q?=D0=B0=D0=B4=D0=B8=D1=81=D0=BB=D0=B0=D0=B2=20=D0=AE=D1=80=D1=8C?= =?UTF-8?q?=D0=B5=D0=B2=D0=B8=D1=87?= Date: Thu, 14 Oct 2021 16:16:20 +0300 Subject: [PATCH] Fix radio module declaration for `NRF52_SERIES` in `variant.h`-files --- variants/WisCore_RAK4631_Board/variant.h | 1 + variants/eink0.1/variant.h | 1 + variants/lora_isp4520/variant.h | 1 + variants/lora_relay_v1/variant.h | 3 +++ variants/lora_relay_v2/variant.h | 3 +++ variants/pca10056-rc-clock/variant.h | 1 + variants/ppr/variant.h | 1 + variants/ppr1/variant.h | 1 + variants/t-echo/variant.h | 1 + 9 files changed, 13 insertions(+) diff --git a/variants/WisCore_RAK4631_Board/variant.h b/variants/WisCore_RAK4631_Board/variant.h index 8598dc1b..bea410c3 100644 --- a/variants/WisCore_RAK4631_Board/variant.h +++ b/variants/WisCore_RAK4631_Board/variant.h @@ -151,6 +151,7 @@ static const uint8_t SCK = PIN_SPI_SCK; */ // RAK4630 LoRa module +#define USE_SX1262 #define SX126X_CS (42) #define SX126X_DIO1 (47) #define SX126X_BUSY (46) diff --git a/variants/eink0.1/variant.h b/variants/eink0.1/variant.h index d07597a2..b53f0481 100644 --- a/variants/eink0.1/variant.h +++ b/variants/eink0.1/variant.h @@ -178,6 +178,7 @@ External serial flash WP25R1635FZUIL0 * Lora radio */ +#define USE_SX1262 #define SX126X_CS (0 + 24) // FIXME - we really should define LORA_CS instead #define SX126X_DIO1 (0 + 20) // Note DIO2 is attached internally to the module to an analog switch for TX/RX switching diff --git a/variants/lora_isp4520/variant.h b/variants/lora_isp4520/variant.h index d23a20a0..3f26ce3d 100644 --- a/variants/lora_isp4520/variant.h +++ b/variants/lora_isp4520/variant.h @@ -57,6 +57,7 @@ #define WIRE_INTERFACES_COUNT 0 // GPIOs the SX1262 is connected +#define USE_SX1262 #define SX126X_CS 1 // aka SPI_NSS #define SX126X_DIO1 (4) #define SX126X_BUSY (5) diff --git a/variants/lora_relay_v1/variant.h b/variants/lora_relay_v1/variant.h index 74f3c5a6..3ee0406a 100644 --- a/variants/lora_relay_v1/variant.h +++ b/variants/lora_relay_v1/variant.h @@ -116,6 +116,9 @@ static const uint8_t SCK = PIN_SPI_SCK; // I2C device addresses #define I2C_ADDR_BQ27441 0x55 // Battery gauge +// SX1262 declaration +#define USE_SX1262 + // CUSTOM GPIOs the SX1262 #define SX126X_CS (32) diff --git a/variants/lora_relay_v2/variant.h b/variants/lora_relay_v2/variant.h index ec3e7e90..0ff47745 100644 --- a/variants/lora_relay_v2/variant.h +++ b/variants/lora_relay_v2/variant.h @@ -136,6 +136,9 @@ static const uint8_t SCK = PIN_SPI_SCK; // I2C device addresses #define I2C_ADDR_BQ27441 0x55 // Battery gauge +// SX1262 declaration +#define USE_SX1262 + // CUSTOM GPIOs the SX1262 #define SX126X_CS (32) diff --git a/variants/pca10056-rc-clock/variant.h b/variants/pca10056-rc-clock/variant.h index b9c4f9bf..20aed8cb 100644 --- a/variants/pca10056-rc-clock/variant.h +++ b/variants/pca10056-rc-clock/variant.h @@ -140,6 +140,7 @@ static const uint8_t SCK = PIN_SPI_SCK; #define EXTERNAL_FLASH_USE_QSPI // CUSTOM GPIOs the SX1262MB2CAS shield when installed on the NRF52840-DK development board +#define USE_SX1262 #define SX126X_CS (32 + 8) // P1.08 #define SX126X_DIO1 (32 + 6) // P1.06 #define SX126X_BUSY (32 + 4) // P1.04 diff --git a/variants/ppr/variant.h b/variants/ppr/variant.h index b055c3d8..24ddc09c 100644 --- a/variants/ppr/variant.h +++ b/variants/ppr/variant.h @@ -129,6 +129,7 @@ static const uint8_t SCK = PIN_SPI_SCK; #define PIN_WIRE_SCL (32) // CUSTOM GPIOs the SX1262 +#define USE_SX1262 #define SX126X_CS (10) #define SX126X_DIO1 (20) #define SX1262_DIO2 (26) diff --git a/variants/ppr1/variant.h b/variants/ppr1/variant.h index b5d398c3..8b9bc7c1 100644 --- a/variants/ppr1/variant.h +++ b/variants/ppr1/variant.h @@ -152,6 +152,7 @@ static const uint8_t SCK = PIN_SPI_SCK; #define PIN_WIRE_SCL (32) // CUSTOM GPIOs the SX1262 +#define USE_SX1262 #define SX126X_CS (0 + 10) // FIXME - we really should define LORA_CS instead #define SX126X_DIO1 (0 + 20) #define SX1262_DIO2 (0 + 26) diff --git a/variants/t-echo/variant.h b/variants/t-echo/variant.h index beb9e550..df57ee91 100644 --- a/variants/t-echo/variant.h +++ b/variants/t-echo/variant.h @@ -180,6 +180,7 @@ External serial flash WP25R1635FZUIL0 * Lora radio */ +#define USE_SX1262 #define SX126X_CS (0 + 24) // FIXME - we really should define LORA_CS instead #define SX126X_DIO1 (0 + 20) // Note DIO2 is attached internally to the module to an analog switch for TX/RX switching