From ccbf635eef944d7d3fea9a9bb19440b94bafbfed Mon Sep 17 00:00:00 2001 From: Gareth Coleman Date: Mon, 22 Apr 2024 17:21:41 +0100 Subject: [PATCH] corrected a bit of overzealous tidying --- variants/Dongle_nRF52840-pca10059-v1/variant.h | 9 ++++++++- variants/lora_relay_v1/variant.h | 6 +++--- variants/lora_relay_v2/variant.h | 6 +++--- variants/unphone/platformio.ini | 2 +- variants/unphone/variant.h | 13 ++----------- 5 files changed, 17 insertions(+), 19 deletions(-) diff --git a/variants/Dongle_nRF52840-pca10059-v1/variant.h b/variants/Dongle_nRF52840-pca10059-v1/variant.h index aef702c7c..2318450eb 100644 --- a/variants/Dongle_nRF52840-pca10059-v1/variant.h +++ b/variants/Dongle_nRF52840-pca10059-v1/variant.h @@ -44,12 +44,19 @@ extern "C" { // LEDs #define PIN_LED1 (0 + 6) // Built in Green P0.06 +#define PIN_LED2 (0 + 6) // Just here for completeness #define RGBLED_RED (0 + 8) // Red of RGB P0.08 #define RGBLED_GREEN (32 + 9) // Green of RGB P1.09 #define RGBLED_BLUE (0 + 12) // Blue of RGB P0.12 #define RGBLED_CA // comment out this line if you have a common cathode type, as defined use common anode logic #define LED_BUILTIN PIN_LED1 +#define LED_CONN PIN_LED2 + +#define LED_GREEN PIN_LED1 +#define LED_BLUE PIN_LED2 + +#define LED_STATE_ON 0 // State when LED is litted /* * Buttons @@ -157,4 +164,4 @@ static const uint8_t SCK = PIN_SPI_SCK; * Arduino objects - C++ only *----------------------------------------------------------------------------*/ -#endif \ No newline at end of file +#endif diff --git a/variants/lora_relay_v1/variant.h b/variants/lora_relay_v1/variant.h index 29fb4cb84..54bc87b68 100644 --- a/variants/lora_relay_v1/variant.h +++ b/variants/lora_relay_v1/variant.h @@ -51,12 +51,12 @@ extern "C" { #define NEOPIXEL_TYPE (NEO_GRB + NEO_KHZ800) // type of neopixels in use #define LED_BUILTIN PIN_LED1 -#define PIN_LED2 +#define LED_CONN PIN_LED2 #define LED_RED PIN_LED1 #define LED_BLUE PIN_LED2 -#define 1 // State when LED is litted +#define LED_STATE_ON 1 // State when LED is litted /* * Buttons @@ -158,4 +158,4 @@ static const uint8_t SCK = PIN_SPI_SCK; * Arduino objects - C++ only *----------------------------------------------------------------------------*/ -#endif \ No newline at end of file +#endif diff --git a/variants/lora_relay_v2/variant.h b/variants/lora_relay_v2/variant.h index 98881a496..6ef7ad7d6 100644 --- a/variants/lora_relay_v2/variant.h +++ b/variants/lora_relay_v2/variant.h @@ -70,12 +70,12 @@ extern "C" { #define PIN_BUZZER (40) #define LED_BUILTIN PIN_LED1 -#define PIN_LED2 +#define LED_CONN PIN_LED2 #define LED_RED PIN_LED1 #define LED_BLUE PIN_LED2 -#define 1 // State when LED is litted +#define LED_STATE_ON 1 // State when LED is litted /* * Buttons @@ -185,4 +185,4 @@ static const uint8_t SCK = PIN_SPI_SCK; * Arduino objects - C++ only *----------------------------------------------------------------------------*/ -#endif \ No newline at end of file +#endif diff --git a/variants/unphone/platformio.ini b/variants/unphone/platformio.ini index 407976c48..e4a92fe4c 100644 --- a/variants/unphone/platformio.ini +++ b/variants/unphone/platformio.ini @@ -13,7 +13,7 @@ build_unflags = -D ARDUINO_USB_MODE build_flags = ${esp32_base.build_flags} - -D BOARD_HAS_PSRAM + ;-D BOARD_HAS_PSRAM // what's up with this - doesn't seem to be recognised at boot -D UNPHONE -I variants/unphone -D ARDUINO_USB_MODE=0 diff --git a/variants/unphone/variant.h b/variants/unphone/variant.h index a3f2fce8c..180fdfe2c 100644 --- a/variants/unphone/variant.h +++ b/variants/unphone/variant.h @@ -1,16 +1,7 @@ // meshtastic/firmware/variants/unphone/variant.h #pragma once -// RGB LED configuration -#define HAS_NEOPIXEL // Enable the use of neopixels -#define NEOPIXEL_COUNT 1 // How many neopixels are connected -#define NEOPIXEL_DATA A0 // gpio pin used to send data to the neopixels -#define NEOPIXEL_TYPE (NEO_GRB + NEO_KHZ800) // type of neopixels in use -// NEO_KHZ800 800 KHz bitstream (most NeoPixel products w/WS2812 LEDs) -// NEO_KHZ400 400 KHz (classic 'v1' (not v2) FLORA pixels, WS2811 drivers) -// NEO_GRB Pixels are wired for GRB bitstream (most NeoPixel products) -// NEO_RGB Pixels are wired for RGB bitstream (v1 FLORA pixels, not v2) -// NEO_RGBW Pixels are wired for RGBW bitstream (NeoPixel RGBW products) + #define SPI_SCK 39 #define SPI_MOSI 40 #define SPI_MISO 41 @@ -47,7 +38,7 @@ #define SCREEN_TRANSITION_FRAMERATE 5 #define HAS_TOUCHSCREEN 1 -#define USE_XPT2046 +#define USE_XPT2046 1 #define TOUCH_CS 38 #define HAS_GPS \