Merge branch 'master' into usbhost

This commit is contained in:
Thomas Göttgens
2025-03-31 11:36:34 +02:00
committed by GitHub
296 changed files with 12925 additions and 2925 deletions

View File

@@ -0,0 +1,28 @@
[env:CDEBYTE_E77-MBL]
extends = stm32_base
board = ebyte_e77_dev
board_upload.maximum_size = 233472 ; reserve the last 28KB for filesystem
board_level = extra
build_flags =
${stm32_base.build_flags}
-Ivariants/CDEBYTE_E77-MBL
-DSERIAL_UART_INSTANCE=1
-DPIN_SERIAL_RX=PA3
-DPIN_SERIAL_TX=PA2
-DHAL_DAC_MODULE_ONLY
-DHAL_RNG_MODULE_ENABLED
-DRADIOLIB_EXCLUDE_SX128X=1
-DRADIOLIB_EXCLUDE_SX127X=1
-DRADIOLIB_EXCLUDE_LR11X0=1
-DMESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR=1
-DMESHTASTIC_EXCLUDE_I2C=1
-DMESHTASTIC_EXCLUDE_WIFI=1
-DMESHTASTIC_EXCLUDE_BLUETOOTH=1
-DMESHTASTIC_EXCLUDE_GPS=1
-DMESHTASTIC_EXCLUDE_SCREEN=1
-DMESHTASTIC_EXCLUDE_MQTT=1
-DMESHTASTIC_EXCLUDE_POWERMON=1
;-DPIO_FRAMEWORK_ARDUINO_NANOLIB_FLOAT_PRINTF
;-DCFG_DEBUG
upload_port = stlink

View File

@@ -0,0 +1,22 @@
/*
EByte E77-MBL series
https://www.cdebyte.com/products/E77-900MBL-01
https://www.cdebyte.com/products/E77-400MBL-01
https://github.com/olliw42/mLRS-docu/blob/master/docs/EBYTE_E77_MBL.md
*/
/*
This variant is a work in progress.
Do not expect a working Meshtastic device with this target.
*/
#ifndef _VARIANT_EBYTE_E77_
#define _VARIANT_EBYTE_E77_
#define USE_STM32WLx
#define LED_PIN PB4 // LED1
// #define LED_PIN PB3 // LED2
#define LED_STATE_ON 1
#endif

View File

@@ -0,0 +1,29 @@
; First prototype eink/nrf52840/sx1262 device
[env:thinknode_m1]
extends = nrf52840_base
board = ThinkNode-M1
board_check = true
debug_tool = jlink
# add -DCFG_SYSVIEW if you want to use the Segger systemview tool for OS profiling.
build_flags = ${nrf52840_base.build_flags} -Ivariants/ELECROW-ThinkNode-M1
-DELECROW_ThinkNode_M1
-DGPS_POWER_TOGGLE
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m4/fpv4-sp-d16-hard"
-DEINK_DISPLAY_MODEL=GxEPD2_154_D67
-DEINK_WIDTH=200
-DEINK_HEIGHT=200
-DUSE_EINK_DYNAMICDISPLAY ; Enable Dynamic EInk
-DEINK_LIMIT_FASTREFRESH=10 ; How many consecutive fast-refreshes are permitted //20
-DEINK_LIMIT_RATE_BACKGROUND_SEC=10 ; Minimum interval between BACKGROUND updates //30
-DEINK_LIMIT_RATE_RESPONSIVE_SEC=1 ; Minimum interval between RESPONSIVE updates
; -DEINK_LIMIT_GHOSTING_PX=2000 ; (Optional) How much image ghosting is tolerated
-DEINK_BACKGROUND_USES_FAST ; (Optional) Use FAST refresh for both BACKGROUND and RESPONSIVE, until a limit is reached.
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/ELECROW-ThinkNode-M1>
lib_deps =
${nrf52840_base.lib_deps}
https://github.com/meshtastic/GxEPD2/archive/33db3fa8ee6fc47d160bdb44f8f127c9a9203a10.zip
lewisxhe/PCF8563_Library@^1.0.1
khoih-prog/nRF52_PWM@^1.0.1
;upload_protocol = fs

View File

@@ -0,0 +1,44 @@
/*
Copyright (c) 2014-2015 Arduino LLC. All right reserved.
Copyright (c) 2016 Sandeep Mistry All right reserved.
Copyright (c) 2018, Adafruit Industries (adafruit.com)
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#include "variant.h"
#include "nrf.h"
#include "wiring_constants.h"
#include "wiring_digital.h"
const uint32_t g_ADigitalPinMap[] = {
// P0 - pins 0 and 1 are hardwired for xtal and should never be enabled
0xff, 0xff, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
// P1
32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47};
void initVariant()
{
// LED1 & LED2
pinMode(PIN_LED1, OUTPUT);
ledOff(PIN_LED1);
pinMode(PIN_LED2, OUTPUT);
ledOff(PIN_LED2);
pinMode(PIN_LED3, OUTPUT);
ledOff(PIN_LED3);
}

View File

@@ -0,0 +1,205 @@
/*
Copyright (c) 2014-2015 Arduino LLC. All right reserved.
Copyright (c) 2016 Sandeep Mistry All right reserved.
Copyright (c) 2018, Adafruit Industries (adafruit.com)
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#ifndef _VARIANT_ELECROW_EINK_V1_0_
#define _VARIANT_ELECROW_EINK_V1_0_
/** Master clock frequency */
#define VARIANT_MCK (64000000ul)
#define USE_LFXO // Board uses 32khz crystal for LF
/*----------------------------------------------------------------------------
* Headers
*----------------------------------------------------------------------------*/
#include "WVariant.h"
#ifdef __cplusplus
extern "C" {
#endif // __cplusplus
// Number of pins defined in PinDescription array
// 在PinDescription数组中定义的引脚数
#define PINS_COUNT (48)
#define NUM_DIGITAL_PINS (48)
#define NUM_ANALOG_INPUTS (1)
#define NUM_ANALOG_OUTPUTS (0)
#define PIN_LED1 -1
#define PIN_LED2 -1
#define PIN_LED3 -1
// LED
#define POWER_LED (32 + 6) // red
#define LED_POWER (32 + 4)
#define USER_LED (0 + 13) // green
// USB_CHECK
#define USB_CHECK (32 + 3)
#define ADC_V (0 + 8)
#define LED_RED PIN_LED3
#define LED_BLUE PIN_LED1
#define LED_GREEN PIN_LED2
#define LED_BUILTIN LED_BLUE
#define LED_CONN PIN_GREEN
#define LED_STATE_ON 0 // State when LED is lit // LED灯亮时的状态
#define M1_buzzer (0 + 6)
/*
* Buttons
*/
#define PIN_BUTTON2 (32 + 10)
#define PIN_BUTTON1 (32 + 7)
// #define PIN_BUTTON1 (0 + 11)
// #define PIN_BUTTON1 (32 + 7)
// #define BUTTON_CLICK_MS 400
// #define BUTTON_TOUCH_MS 200
/*
* Analog pins
*/
#define PIN_A0 (4) // Battery ADC
#define BATTERY_PIN PIN_A0
static const uint8_t A0 = PIN_A0;
#define ADC_RESOLUTION 14
#define PIN_NFC1 (9)
#define PIN_NFC2 (10)
/*Wire Interfaces*/
#define WIRE_INTERFACES_COUNT 1
#define PIN_WIRE_SDA (26)
#define PIN_WIRE_SCL (27)
/* touch sensor, active high */
#define TP_SER_IO (0 + 11)
#define PIN_RTC_INT (0 + 16) // Interrupt from the PCF8563 RTC
/*
External serial flash WP25R1635FZUIL0
*/
// QSPI Pins
#define PIN_QSPI_SCK (32 + 14)
#define PIN_QSPI_CS (32 + 15)
#define PIN_QSPI_IO0 (32 + 12) // MOSI if using two bit interface
#define PIN_QSPI_IO1 (32 + 13) // MISO if using two bit interface
#define PIN_QSPI_IO2 (0 + 7) // WP if using two bit interface (i.e. not used)
#define PIN_QSPI_IO3 (0 + 5) // HOLD if using two bit interface (i.e. not used)
// On-board QSPI Flash
#define EXTERNAL_FLASH_DEVICES MX25R1635F
#define EXTERNAL_FLASH_USE_QSPI
/*
* Lora radio
*/
#define SX126X_POWER_EN (0 + 21)
#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
// #define SX1262_DIO3 (0 + 21) // This is used as an *output* from the sx1262 and connected internally to power the tcxo, do not
// drive from the main
#define SX126X_BUSY (0 + 17)
#define SX126X_RESET (0 + 25)
#define SX126X_DIO2_AS_RF_SWITCH
#define SX126X_DIO3_TCXO_VOLTAGE 3.3
#define PIN_EINK_EN (32 + 11) // Note: this is really just backlight power
#define PIN_EINK_CS (0 + 30)
#define PIN_EINK_BUSY (0 + 3)
#define PIN_EINK_DC (0 + 28)
#define PIN_EINK_RES (0 + 2)
#define PIN_EINK_SCLK (0 + 31)
#define PIN_EINK_MOSI (0 + 29) // also called SDI
// Controls power for all peripherals (eink + GPS + LoRa + Sensor)
#define PIN_POWER_EN (0 + 12)
#define USE_EINK
#define PIN_SPI1_MISO (32 + 7)
#define PIN_SPI1_MOSI PIN_EINK_MOSI
#define PIN_SPI1_SCK PIN_EINK_SCLK
/*
* GPS pins
*/
// #define HAS_GPS 1
#define GPS_L76K
#define GPS_BAUDRATE 9600
#define PIN_GPS_REINIT (32 + 5) // An output to reset L76K GPS. As per datasheet, low for > 100ms will reset the L76K
#define PIN_GPS_STANDBY (32 + 2) // An output to wake GPS, low means allow sleep, high means force wake
// Seems to be missing on this new board
// #define PIN_GPS_PPS (32 + 4) // Pulse per second input from the GPS
#define GPS_TX_PIN (32 + 9) // This is for bits going TOWARDS the CPU
#define GPS_RX_PIN (32 + 8) // This is for bits going TOWARDS the GPS
#define GPS_THREAD_INTERVAL 50
#define PIN_GPS_PPS (32 + 1) // GPS开关判断
#define PIN_SERIAL1_RX GPS_TX_PIN
#define PIN_SERIAL1_TX GPS_RX_PIN
// PCF8563 RTC Module
#define PCF8563_RTC 0x51
/*
* SPI Interfaces
*/
#define SPI_INTERFACES_COUNT 2
// For LORA, spi 0
#define PIN_SPI_MISO (0 + 23)
#define PIN_SPI_MOSI (0 + 22)
#define PIN_SPI_SCK (0 + 19)
#define PIN_PWR_EN (0 + 6)
// To debug via the segger JLINK console rather than the CDC-ACM serial device
// #define USE_SEGGER
// Battery
// The battery sense is hooked to pin A0 (4)
// it is defined in the anlaolgue pin section of this file
// and has 12 bit resolution
#define BATTERY_SENSE_RESOLUTION_BITS 12
#define BATTERY_SENSE_RESOLUTION 4096.0
#undef AREF_VOLTAGE
#define AREF_VOLTAGE 3.0
#define VBAT_AR_INTERNAL AR_INTERNAL_3_0
#define ADC_MULTIPLIER (2.02F)
// #define HAS_RTC 0
// #define HAS_SCREEN 0
#ifdef __cplusplus
}
#endif
#endif

View File

@@ -0,0 +1,28 @@
// Need this file for ESP32-S3
// No need to modify this file, changes to pins imported from variant.h
// Most is similar to https://github.com/espressif/arduino-esp32/blob/master/variants/esp32s3/pins_arduino.h
#ifndef Pins_Arduino_h
#define Pins_Arduino_h
#include <stdint.h>
#include <variant.h>
#define USB_VID 0x303a
#define USB_PID 0x1001
// Serial
static const uint8_t TX = UART_TX;
static const uint8_t RX = UART_RX;
// Default SPI will be mapped to Radio
static const uint8_t SS = LORA_CS;
static const uint8_t SCK = LORA_SCK;
static const uint8_t MOSI = LORA_MOSI;
static const uint8_t MISO = LORA_MISO;
// The default Wire will be mapped to PMU and RTC
static const uint8_t SCL = I2C_SCL;
static const uint8_t SDA = I2C_SDA;
#endif /* Pins_Arduino_h */

View File

@@ -0,0 +1,7 @@
[env:thinknode_m2]
extends = esp32s3_base
board = ESP32-S3-WROOM-1-N4
build_flags =
${esp32s3_base.build_flags}
-D ELECROW_ThinkNode_M2
-I variants/ELECROW-ThinkNode-M2

View File

@@ -0,0 +1,64 @@
// Status
#define LED_PIN_POWER 1
#define BIAS_T_ENABLE LED_PIN_POWER
#define BIAS_T_VALUE HIGH
#define PIN_BUTTON1 47 // 功能键
#define PIN_BUTTON2 4 // 电源键
#define POWER_CFG
#define POWER_CHRG 6
#define POWER_FULL 42
#define PIN_BUZZER 5
#define I2C_SCL 15
#define I2C_SDA 16
#define UART_TX 43
#define UART_RX 44
#define VEXT_ENABLE 46 // for OLED
#define VEXT_ON_VALUE HIGH
#define SX126X_CS 10
#define LORA_SCK 12
#define LORA_MOSI 11
#define LORA_MISO 13
#define SX126X_RESET 21
#define SX126X_BUSY 14
#define SX126X_DIO1 3
#define SX126X_DIO2_AS_RF_SWITCH
// #define SX126X_DIO3 9
#define SX126X_DIO3_TCXO_VOLTAGE 3.3
#define SX126X_MAX_POWER 22 // SX126xInterface.cpp defaults to 22 if not defined, but here we define it for good practice
#define USE_SX1262
#define LORA_CS SX126X_CS // FIXME: for some reason both are used in /src
#define LORA_DIO1 SX126X_DIO1
#define SX126X_POWER_EN 48
// Battery
// #define BATTERY_PIN 2
#define BATTERY_PIN 17
// #define ADC_CHANNEL ADC1_GPIO2_CHANNEL
#define ADC_CHANNEL ADC2_GPIO17_CHANNEL
#define BATTERY_SENSE_RESOLUTION_BITS 12
#define BATTERY_SENSE_RESOLUTION 4096.0
#undef AREF_VOLTAGE
#define AREF_VOLTAGE 3.0
#define VBAT_AR_INTERNAL AR_INTERNAL_3_0
#define ADC_MULTIPLIER (1.548F)
#define BAT_MEASURE_ADC_UNIT 2
#define HAS_SCREEN 1
#define USE_SH1106 1
// PCF8563 RTC Module
// #define PCF8563_RTC 0x51
// #define PIN_RTC_INT 48 // Interrupt from the PCF8563 RTC
#define HAS_RTC 0
#define HAS_GPS 0
#define BUTTON_PIN PIN_BUTTON1
#define BUTTON_PIN_ALT PIN_BUTTON2

View File

@@ -12,4 +12,4 @@ lib_deps =
${nrf52840_base.lib_deps}
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
upload_protocol = nrfutil
upload_port = /dev/ttyACM1
;upload_port = /dev/ttyACM1

View File

@@ -16,4 +16,4 @@ lib_deps =
zinggjm/GxEPD2@^1.6.2
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
upload_protocol = nrfutil
upload_port = /dev/ttyACM1
;upload_port = /dev/ttyACM1

View File

@@ -12,4 +12,4 @@ lib_deps =
${nrf52840_base.lib_deps}
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
upload_protocol = nrfutil
upload_port = /dev/ttyACM1
;upload_port = /dev/ttyACM1

View File

@@ -11,7 +11,7 @@ build_flags = ${nrf52840_base.build_flags} -Ivariants/MakePython_nRF52840_eink -
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/MakePython_nRF52840_eink>
lib_deps =
${nrf52840_base.lib_deps}
https://github.com/meshtastic/ESP32_Codec2.git#633326c78ac251c059ab3a8c430fcdf25b41672f
https://github.com/meshtastic/ESP32_Codec2/archive/633326c78ac251c059ab3a8c430fcdf25b41672f.zip
zinggjm/GxEPD2@^1.6.2
debug_tool = jlink
;upload_port = /dev/ttyACM4

View File

@@ -7,5 +7,5 @@ build_flags = ${nrf52840_base.build_flags} -Ivariants/MakePython_nRF52840_oled -
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/MakePython_nRF52840_oled>
lib_deps =
${nrf52840_base.lib_deps}
https://github.com/meshtastic/ESP32_Codec2.git#633326c78ac251c059ab3a8c430fcdf25b41672f
https://github.com/meshtastic/ESP32_Codec2/archive/633326c78ac251c059ab3a8c430fcdf25b41672f.zip
debug_tool = jlink

View File

@@ -0,0 +1,26 @@
#ifndef Pins_Arduino_h
#define Pins_Arduino_h
#include <stdint.h>
#define USB_VID 0x303a
#define USB_PID 0x1001
// The default Wire will be mapped to PMU and RTC
static const uint8_t SDA = 21;
static const uint8_t SCL = 15;
// Default SPI will be mapped to Radio
static const uint8_t SS = 14;
static const uint8_t MOSI = 8;
static const uint8_t MISO = 9;
static const uint8_t SCK = 3;
#define SPI_MOSI (40)
#define SPI_SCK (39)
#define SPI_MISO (13)
#define SPI_CS (10)
// IO42 TF_3V3_CTL
#define SDCARD_CS SPI_CS
#endif /* Pins_Arduino_h */

View File

@@ -0,0 +1,83 @@
[env:crowpanel-esp32s3-5-epaper]
extends = esp32s3_base
board_build.arduino.memory_type = qio_opi
board_build.flash_mode = qio
board_build.psram_type = opi
board_upload.flash_size = 8MB
board_upload.maximum_size = 8388608
board_build.partitions = default_8MB.csv
board = esp32-s3-devkitc-1
;upload_port = /dev/ttyUSB0
board_level = extra
upload_protocol = esptool
build_flags =
${esp32_base.build_flags} -D CROWPANEL_ESP32S3_5_EPAPER -I variants/crowpanel-esp32s3-5-epaper
-D PRIVATE_HW
-DBOARD_HAS_PSRAM
-DGPS_POWER_TOGGLE
-DEINK_DISPLAY_MODEL=GxEPD2_579_GDEY0579T93 ;https://www.good-display.com/product/439.html
-DEINK_WIDTH=792
-DEINK_HEIGHT=272
-DUSE_EINK_DYNAMICDISPLAY ; Enable Dynamic EInk
-DEINK_LIMIT_FASTREFRESH=100 ; How many consecutive fast-refreshes are permitted
;-DEINK_LIMIT_RATE_BACKGROUND_SEC=30 ; Minimum interval between BACKGROUND updates
;-DEINK_LIMIT_RATE_RESPONSIVE_SEC=1
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2/archive/33db3fa8ee6fc47d160bdb44f8f127c9a9203a10.zip
[env:crowpanel-esp32s3-4-epaper]
extends = esp32s3_base
board_build.arduino.memory_type = qio_opi
board_build.flash_mode = qio
board_build.psram_type = opi
board_upload.flash_size = 8MB
board_upload.maximum_size = 8388608
board_build.partitions = default_8MB.csv
board = esp32-s3-devkitc-1
;upload_port = /dev/ttyUSB0
board_level = extra
upload_protocol = esptool
build_flags =
${esp32_base.build_flags} -D CROWPANEL_ESP32S3_4_EPAPER -I variants/crowpanel-esp32s3-5-epaper
-D PRIVATE_HW
-DBOARD_HAS_PSRAM
-DGPS_POWER_TOGGLE
-DEINK_DISPLAY_MODEL=GxEPD2_420_GYE042A87 ; similar Panel: GDEY042T81 : https://www.good-display.com/product/386.html
-DEINK_WIDTH=400
-DEINK_HEIGHT=300
-DUSE_EINK_DYNAMICDISPLAY ; Enable Dynamic EInk
-DEINK_LIMIT_FASTREFRESH=100 ; How many consecutive fast-refreshes are permitted
;-DEINK_LIMIT_RATE_BACKGROUND_SEC=30 ; Minimum interval between BACKGROUND updates
;-DEINK_LIMIT_RATE_RESPONSIVE_SEC=1
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2/archive/33db3fa8ee6fc47d160bdb44f8f127c9a9203a10.zip
[env:crowpanel-esp32s3-2-epaper]
extends = esp32s3_base
board_build.arduino.memory_type = qio_opi
board_build.flash_mode = qio
board_build.psram_type = opi
board_upload.flash_size = 8MB
board_upload.maximum_size = 8388608
board_build.partitions = default_8MB.csv
board = esp32-s3-devkitc-1
;upload_port = /dev/ttyUSB0
board_level = extra
upload_protocol = esptool
build_flags =
${esp32_base.build_flags} -D CROWPANEL_ESP32S3_2_EPAPER -I variants/crowpanel-esp32s3-5-epaper
-D PRIVATE_HW
-DBOARD_HAS_PSRAM
-DGPS_POWER_TOGGLE
-DEINK_DISPLAY_MODEL=GxEPD2_290_GDEY029T94 ;https://www.good-display.com/product/389.html
-DEINK_WIDTH=296
-DEINK_HEIGHT=128
-DUSE_EINK_DYNAMICDISPLAY ; Enable Dynamic EInk
-DEINK_LIMIT_FASTREFRESH=100 ; How many consecutive fast-refreshes are permitted
;-DEINK_LIMIT_RATE_BACKGROUND_SEC=30 ; Minimum interval between BACKGROUND updates
;-DEINK_LIMIT_RATE_RESPONSIVE_SEC=1
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2/archive/33db3fa8ee6fc47d160bdb44f8f127c9a9203a10.zip

View File

@@ -0,0 +1,77 @@
#define HAS_SDCARD
#define SDCARD_USE_SPI1
// Display (E-Ink)
#define USE_EINK
#define PIN_EINK_CS 45
#define PIN_EINK_BUSY 48
#define PIN_EINK_DC 46
#define PIN_EINK_RES 47
#define PIN_EINK_SCLK 12
#define PIN_EINK_MOSI 11
#define VEXT_ENABLE 7 // e-ink power enable pin
#define VEXT_ON_VALUE HIGH
#define PIN_POWER_EN 42 // TF/SD Card Power Enable Pin
// #define BATTERY_PIN 1 // A battery voltage measurement pin, voltage divider connected here to
// measure battery voltage ratio of voltage divider = 2.0 (assumption)
// #define ADC_MULTIPLIER 2.11 // 2.0 + 10% for correction of display undervoltage.
// #define ADC_CHANNEL ADC1_GPIO1_CHANNEL
#define I2C_SDA SDA // 21
#define I2C_SCL SCL // 15
#define GPS_DEFAULT_NOT_PRESENT 1
// #define GPS_RX_PIN 44
// #define GPS_TX_PIN 43
#define LED_PIN 41
#define BUTTON_PIN 2
#define BUTTON_NEED_PULLUP
// Buzzer - noisy ?
#define PIN_BUZZER (0 + 18)
// Wheel
// Up 6
// Push 5
// Down 4
// MENU Top 2
// EXIT Bottom 1
// TTGO uses a common pinout for their SX1262 vs RF95 modules - both can be enabled and
// we will probe at runtime for RF95 and if not found then probe for SX1262
// #define USE_RF95 // RFM95/SX127x
#define USE_SX1262
// #define USE_SX1280
#define LORA_SCK 3
#define LORA_MISO 9
#define LORA_MOSI 8
#define LORA_CS 14
#define LORA_RESET 38
#define LORA_DIO1 16
#define LORA_DIO2 17
// per SX1262_Receive_Interrupt/utilities.h
#ifdef USE_SX1262
#define SX126X_CS LORA_CS
#define SX126X_DIO1 LORA_DIO1
#define SX126X_BUSY LORA_DIO2
#define SX126X_RESET LORA_RESET
#define SX126X_DIO2_AS_RF_SWITCH
#define SX126X_DIO3_TCXO_VOLTAGE 1.8
#endif
// per SX128x_Receive_Interrupt/utilities.h
#ifdef USE_SX1280
#define SX128X_CS LORA_CS
#define SX128X_DIO1 LORA_DIO1
#define SX128X_BUSY LORA_DIO2
#define SX128X_RESET LORA_RESET
#define SX128X_RXEN 21
#define SX128X_TXEN 15
#define SX128X_MAX_POWER 3
#endif

View File

@@ -88,6 +88,7 @@ debug_tool = jlink
[env:t-energy-s3_e22]
extends = esp32s3_base
board = esp32-s3-devkitc-1
board_build.partitions = default_16MB.csv
board_level = extra
board_upload.flash_size = 16MB ;Specify the FLASH capacity as 16MB
board_build.arduino.memory_type = qio_opi ;Enable internal PSRAM
@@ -100,4 +101,4 @@ build_flags =
-D BOARD_HAS_PSRAM
-D ARDUINO_USB_MODE=0
-D ARDUINO_USB_CDC_ON_BOOT=1
-I variants/diy/t-energy-s3_e22
-I variants/diy/t-energy-s3_e22

View File

@@ -1,6 +1,7 @@
[env:dreamcatcher] ; 2301, latest revision
extends = esp32s3_base
board = esp32s3box
board_build.partitions = default_16MB.csv
board_level = extra
build_flags =
@@ -8,7 +9,7 @@ build_flags =
-D PRIVATE_HW
-D OTHERNET_DC_REV=2301
-I variants/dreamcatcher
-DARDUINO_USB_CDC_ON_BOOT=1
-D ARDUINO_USB_CDC_ON_BOOT=1
lib_deps = ${esp32s3_base.lib_deps}
earlephilhower/ESP8266Audio@^1.9.9
@@ -17,6 +18,7 @@ lib_deps = ${esp32s3_base.lib_deps}
[env:dreamcatcher-2206]
extends = esp32s3_base
board = esp32s3box
board_build.partitions = default_16MB.csv
board_level = extra
build_flags =
@@ -24,4 +26,4 @@ build_flags =
-D PRIVATE_HW
-D OTHERNET_DC_REV=2206
-I variants/dreamcatcher
-DARDUINO_USB_CDC_ON_BOOT=1
-D ARDUINO_USB_CDC_ON_BOOT=1

View File

@@ -4,6 +4,7 @@ board_level = extra
extends = esp32s3_base
upload_protocol = esptool
board = esp32-s3-pico
board_build.partitions = default_16MB.csv
board_upload.use_1200bps_touch = yes
board_upload.wait_for_upload_port = yes

View File

@@ -0,0 +1,12 @@
[env:hackerboxes-esp32-io]
extends = esp32_base
board = esp32dev
board_level = extra
build_flags =
${esp32_base.build_flags}
-D PRIVATE_HW
-I variants/hackerboxes_esp32_io
monitor_speed = 115200
upload_protocol = esptool
;upload_port = /dev/ttyUSB0
upload_speed = 921600

View File

@@ -0,0 +1,30 @@
#define BUTTON_PIN 0
// HACKBOX LoRa IO Kit
// Uses a ESP-32-WROOM and a RA-01SH (SX1262) LoRa Board
#define LED_PIN 2 // LED
#define LED_STATE_ON 1 // State when LED is lit
#define HAS_SCREEN 0
#define HAS_GPS 0
#undef GPS_RX_PIN
#undef GPS_TX_PIN
#define USE_SX1262
#define LORA_SCK 18
#define LORA_MISO 19
#define LORA_MOSI 23
#define LORA_CS 5
#define LORA_DIO0 RADIOLIB_NC
#define LORA_RESET 27
#define LORA_DIO1 33
#define LORA_DIO2 RADIOLIB_NC
#define LORA_BUSY 32
#define SX126X_DIO2_AS_RF_SWITCH
#define SX126X_CS LORA_CS
#define SX126X_DIO1 LORA_DIO1
#define SX126X_BUSY LORA_BUSY
#define SX126X_RESET LORA_RESET
#define SX126X_MAX_POWER 22 // Max power of the RA-01SH is 22db

View File

@@ -0,0 +1,14 @@
[env:hackerboxes-esp32c3-oled]
extends = esp32c3_base
board = esp32-c3-devkitm-1
board_level = extra
build_flags =
${esp32_base.build_flags}
-D PRIVATE_HW
-D ARDUINO_USB_MODE=1
-D ARDUINO_USB_CDC_ON_BOOT=1
-I variants/hackerboxes_esp32c3_oled
monitor_speed = 115200
upload_protocol = esptool
;upload_port = /dev/ttyUSB0
upload_speed = 921600

View File

@@ -0,0 +1,36 @@
#define BUTTON_PIN 9
// Hackerboxes LoRa ESP32-C3 OLED Kit
// Uses a ESP32-C3 OLED Board and a RA-01SH (SX1262) LoRa Board
#define LED_PIN 8 // LED
#define LED_STATE_ON 1 // State when LED is lit
#define HAS_SCREEN 0
#define HAS_GPS 0
#undef GPS_RX_PIN
#undef GPS_TX_PIN
// #define USE_SSD1306_72_40
// #define I2C_SDA 5 // I2C pins for this board
// #define I2C_SCL 6 //
// #define TFT_WIDTH 72
// #define TFT_HEIGHT 40
#define USE_SX1262
#define LORA_SCK 4
#define LORA_MISO 7
#define LORA_MOSI 3
#define LORA_CS 1
#define LORA_DIO0 RADIOLIB_NC
#define LORA_RESET 0
#define LORA_DIO1 20
#define LORA_DIO2 RADIOLIB_NC
#define LORA_BUSY 10
#define SX126X_DIO2_AS_RF_SWITCH
#define SX126X_CS LORA_CS
#define SX126X_DIO1 LORA_DIO1
#define SX126X_BUSY LORA_BUSY
#define SX126X_RESET LORA_RESET
#define SX126X_MAX_POWER 22 // Max power of the RA-01SH is 22db

View File

@@ -2,7 +2,7 @@
extends = esp32s3_base
board = heltec_wifi_lora_32_V3
board_check = true
board_build.partitions = default_8MB.csv
build_flags =
${esp32s3_base.build_flags} -I variants/heltec_capsule_sensor_v3
-D HELTEC_CAPSULE_SENSOR_V3

View File

@@ -14,4 +14,4 @@ build_src_filter = ${nrf52_base.build_src_filter} +<../variants/heltec_mesh_node
lib_deps =
${nrf52840_base.lib_deps}
lewisxhe/PCF8563_Library@^1.0.1
https://github.com/meshtastic/st7789#bd33ea58ddfe4a5e4a66d53300ccbd38d66ac21f
https://github.com/meshtastic/st7789/archive/bd33ea58ddfe4a5e4a66d53300ccbd38d66ac21f.zip

View File

@@ -0,0 +1,11 @@
[env:heltec_sensor_hub]
extends = esp32s3_base
board = heltec_wifi_lora_32_V3
board_check = true
build_flags =
${esp32s3_base.build_flags} -I variants/heltec_sensor_hub
-D HELTEC_SENSOR_HUB
lib_deps = ${esp32s3_base.lib_deps}
adafruit/Adafruit NeoPixel @ ^1.12.0

View File

@@ -0,0 +1,46 @@
#define EXT_PWR_DETECT 20
#define BUTTON_PIN 17
#define BATTERY_PIN 7 // A battery voltage measurement pin, voltage divider connected here to measure battery voltage
#define ADC_CHANNEL ADC1_GPIO7_CHANNEL
#define ADC_ATTENUATION ADC_ATTEN_DB_2_5 // lower dB for high resistance voltage divider
#define ADC_MULTIPLIER (4.9 * 1.045)
#define ADC_CTRL 34 // active HIGH, powers the voltage divider. Only on 1.1
#define ADC_CTRL_ENABLED HIGH
#define HAS_NEOPIXEL // Enable the use of neopixels
#define NEOPIXEL_COUNT 1 // How many neopixels are connected
#define NEOPIXEL_DATA 18 // gpio pin used to send data to the neopixels
#define NEOPIXEL_TYPE (NEO_GRB + NEO_KHZ800) // type of neopixels in use
#define USE_SX1262
#define LORA_DIO0 RADIOLIB_NC
#define LORA_RESET 12
#define LORA_DIO1 14 // SX1262 IRQ
#define LORA_DIO2 13 // SX1262 BUSY
#define LORA_SCK 9
#define LORA_MISO 11
#define LORA_MOSI 10
#define LORA_CS 8
#define SX126X_CS LORA_CS
#define SX126X_DIO1 LORA_DIO1
#define SX126X_BUSY LORA_DIO2
#define SX126X_RESET LORA_RESET
#define SX126X_DIO2_AS_RF_SWITCH
#define SX126X_DIO3_TCXO_VOLTAGE 1.8
#define I2C_SDA 1
#define I2C_SCL 2
#define HAS_SCREEN 0
#define SENSOR_POWER_CTRL_PIN 33
#define SENSOR_POWER_ON 1
#define PERIPHERAL_WARMUP_MS 100
#define ESP32S3_WAKE_TYPE ESP_EXT1_WAKEUP_ANY_HIGH
#define ENVIRONMENTAL_TELEMETRY_MODULE_ENABLE 1

View File

@@ -2,7 +2,7 @@
extends = esp32s3_base
board = heltec_wifi_lora_32_V3
board_check = true
# Temporary until espressif creates a release with this new target
board_build.partitions = default_8MB.csv
build_flags =
${esp32s3_base.build_flags} -D HELTEC_V3 -I variants/heltec_v3
-DGPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely.
-D GPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely.

View File

@@ -6,7 +6,7 @@
// InkHUD-specific components
// ---------------------------
#include "graphics/niche/InkHUD/WindowManager.h"
#include "graphics/niche/InkHUD/InkHUD.h"
// Applets
#include "graphics/niche/InkHUD/Applets/User/AllMessage/AllMessageApplet.h"
@@ -49,49 +49,43 @@ void setupNicheGraphics()
// InkHUD
// ----------------------------
InkHUD::WindowManager *windowManager = InkHUD::WindowManager::getInstance();
InkHUD::InkHUD *inkhud = InkHUD::InkHUD::getInstance();
// Set the driver
windowManager->setDriver(driver);
inkhud->setDriver(driver);
// Set how many FAST updates per FULL update
// Set how unhealthy additional FAST updates beyond this number are
windowManager->setDisplayResilience(10, 1.5);
inkhud->setDisplayResilience(10, 1.5);
// Prepare fonts
InkHUD::AppletFont largeFont(FreeSans9pt7b);
InkHUD::AppletFont smallFont(FreeSans6pt7b);
InkHUD::Applet::fontLarge = InkHUD::AppletFont(FreeSans9pt7b);
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt7b);
/*
// Font localization demo: Cyrillic
InkHUD::AppletFont smallFont(FreeSans6pt8bCyrillic);
smallFont.addSubstitutionsWin1251();
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt8bCyrillic);
InkHUD::Applet::fontSmall.addSubstitutionsWin1251();
*/
InkHUD::Applet::setDefaultFonts(largeFont, smallFont);
// Init settings, and customize defaults
InkHUD::settings.userTiles.maxCount = 2; // How many tiles can the display handle?
InkHUD::settings.rotation = 3; // 270 degrees clockwise
InkHUD::settings.userTiles.count = 1; // One tile only by default, keep things simple for new users
InkHUD::settings.optionalMenuItems.nextTile = false; // Behavior handled by aux button instead
// Customize default settings
inkhud->persistence->settings.userTiles.maxCount = 2; // How many tiles can the display handle?
inkhud->persistence->settings.rotation = 3; // 270 degrees clockwise
inkhud->persistence->settings.userTiles.count = 1; // One tile only by default, keep things simple for new users
inkhud->persistence->settings.optionalMenuItems.nextTile = false; // Behavior handled by aux button instead
// Pick applets
// Note: order of applets determines priority of "auto-show" feature
// Optional arguments for defaults:
// - is activated?
// - is autoshown?
// - is foreground on a specific tile (index)?
windowManager->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
windowManager->addApplet("DMs", new InkHUD::DMApplet);
windowManager->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0));
windowManager->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1));
windowManager->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
windowManager->addApplet("Recents List", new InkHUD::RecentsListApplet);
windowManager->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, not autoshown, default on tile 0
// windowManager->addApplet("Basic", new InkHUD::BasicExampleApplet);
// windowManager->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
inkhud->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
inkhud->addApplet("DMs", new InkHUD::DMApplet); // Inactive
inkhud->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0)); // Inactive
inkhud->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1)); // Inactive
inkhud->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
inkhud->addApplet("Recents List", new InkHUD::RecentsListApplet); // Inactive
inkhud->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, not autoshown, default on tile 0
// inkhud->addApplet("Basic", new InkHUD::BasicExampleApplet);
// inkhud->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
// Start running window manager
windowManager->begin();
// Start running InkHUD
inkhud->begin();
// Buttons
// --------------------------
@@ -102,13 +96,13 @@ void setupNicheGraphics()
// Setup the main user button
buttons->setWiring(MAIN_BUTTON, BUTTON_PIN);
buttons->setHandlerShortPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonShort(); });
buttons->setHandlerLongPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonLong(); });
buttons->setHandlerShortPress(MAIN_BUTTON, []() { InkHUD::InkHUD::getInstance()->shortpress(); });
buttons->setHandlerLongPress(MAIN_BUTTON, []() { InkHUD::InkHUD::getInstance()->longpress(); });
// Setup the aux button
// Bonus feature of VME213
buttons->setWiring(AUX_BUTTON, BUTTON_PIN_SECONDARY);
buttons->setHandlerShortPress(AUX_BUTTON, []() { InkHUD::WindowManager::getInstance()->nextTile(); });
buttons->setHandlerShortPress(AUX_BUTTON, []() { InkHUD::InkHUD::getInstance()->nextTile(); });
buttons->start();
}

View File

@@ -1,8 +1,9 @@
[env:heltec-vision-master-e213]
extends = esp32s3_base
board = heltec_vision_master_e213
board_build.partitions = default_8MB.csv
build_flags =
${esp32s3_base.build_flags}
${esp32s3_base.build_flags}
-Ivariants/heltec_vision_master_e213
-DHELTEC_VISION_MASTER_E213
-DUSE_EINK
@@ -15,16 +16,14 @@ build_flags =
-DEINK_HASQUIRK_GHOSTING ; Display model is identified as "prone to ghosting"
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2#b202ebfec6a4821e098cf7a625ba0f6f2400292d
https://github.com/meshtastic/GxEPD2/archive/b202ebfec6a4821e098cf7a625ba0f6f2400292d.zip
lewisxhe/PCF8563_Library@^1.0.1
upload_speed = 115200
; Using experimental InkHUD UI (work in progress)
[platformio]
extra_configs = src/graphics/niche/InkHUD/PlatformioConfig.ini
[env:heltec-vision-master-e213-inkhud]
extends = esp32s3_base, inkhud
board = heltec_vision_master_e213
board_build.partitions = default_8MB.csv
build_src_filter =
${esp32_base.build_src_filter}
${inkhud.build_src_filter}
@@ -33,8 +32,8 @@ build_flags =
${inkhud.build_flags}
-I variants/heltec_vision_master_e213
-D HELTEC_VISION_MASTER_E213
-D MAX_THREADS=40
-D MAX_THREADS=40 ; Required if used with WiFi
lib_deps =
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot intead of AdafruitGFX
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot instead of AdafruitGFX
${esp32s3_base.lib_deps}
upload_speed = 115200
upload_speed = 921600

View File

@@ -62,66 +62,65 @@ void setupNicheGraphics()
// InkHUD
// ----------------------------
InkHUD::WindowManager *windowManager = InkHUD::WindowManager::getInstance();
InkHUD::InkHUD *inkhud = InkHUD::InkHUD::getInstance();
// Set the driver
windowManager->setDriver(driver);
inkhud->setDriver(driver);
// Set how many FAST updates per FULL update
// Set how unhealthy additional FAST updates beyond this number are
windowManager->setDisplayResilience(7, 1.5);
inkhud->setDisplayResilience(7, 1.5);
// Prepare fonts
InkHUD::AppletFont largeFont(FreeSans9pt7b);
InkHUD::AppletFont smallFont(FreeSans6pt7b);
InkHUD::Applet::fontLarge = InkHUD::AppletFont(FreeSans9pt7b);
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt7b);
/*
// Font localization demo: Cyrillic
InkHUD::AppletFont smallFont(FreeSans6pt8bCyrillic);
smallFont.addSubstitutionsWin1251();
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt8bCyrillic);
InkHUD::Applet::fontSmall.addSubstitutionsWin1251();
*/
InkHUD::Applet::setDefaultFonts(largeFont, smallFont);
// Init settings, and customize defaults
InkHUD::settings.userTiles.maxCount = 2; // How many tiles can the display handle?
InkHUD::settings.rotation = 1; // 90 degrees clockwise
InkHUD::settings.userTiles.count = 1; // One tile only by default, keep things simple for new users
InkHUD::settings.optionalMenuItems.nextTile = false; // Behavior handled by aux button instead
// Customize default settings
inkhud->persistence->settings.userTiles.maxCount = 2; // How many tiles can the display handle?
inkhud->persistence->settings.rotation = 1; // 90 degrees clockwise
inkhud->persistence->settings.userTiles.count = 1; // One tile only by default, keep things simple for new users
inkhud->persistence->settings.optionalMenuItems.nextTile = false; // Behavior handled by aux button instead
// Pick applets
// Note: order of applets determines priority of "auto-show" feature
// Optional arguments for defaults:
// - is activated?
// - is autoshown?
// - is foreground on a specific tile (index)?
windowManager->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
windowManager->addApplet("DMs", new InkHUD::DMApplet);
windowManager->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0));
windowManager->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1));
windowManager->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
windowManager->addApplet("Recents List", new InkHUD::RecentsListApplet);
windowManager->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, not autoshown, default on tile 0
// windowManager->addApplet("Basic", new InkHUD::BasicExampleApplet);
// windowManager->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
// Start running window manager
windowManager->begin();
// Order of applets determines priority of "auto-show" feature.
// Optional arguments for default state:
// - is activated?
// - is autoshown?
// - is foreground on a specific tile (index)?
inkhud->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
inkhud->addApplet("DMs", new InkHUD::DMApplet); // Inactive
inkhud->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0)); // Inactive
inkhud->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1)); // Inactive
inkhud->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
inkhud->addApplet("Recents List", new InkHUD::RecentsListApplet); // Inactive
inkhud->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, not autoshown, default on tile 0
// inkhud->addApplet("Basic", new InkHUD::BasicExampleApplet);
// inkhud->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
// Start running InkHUD
inkhud->begin();
// Buttons
// --------------------------
Inputs::TwoButton *buttons = Inputs::TwoButton::getInstance(); // Shared NicheGraphics component
constexpr uint8_t MAIN_BUTTON = 0;
constexpr uint8_t AUX_BUTTON = 1;
Inputs::TwoButton *buttons = Inputs::TwoButton::getInstance(); // A shared NicheGraphics component
// Setup the main user button
buttons->setWiring(MAIN_BUTTON, BUTTON_PIN);
buttons->setHandlerShortPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonShort(); });
buttons->setHandlerLongPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonLong(); });
// Setup the main user button (0)
buttons->setWiring(0, BUTTON_PIN);
buttons->setHandlerShortPress(0, []() { InkHUD::InkHUD::getInstance()->shortpress(); });
buttons->setHandlerLongPress(0, []() { InkHUD::InkHUD::getInstance()->longpress(); });
// Setup the aux button
// Setup the aux button (1)
// Bonus feature of VME290
buttons->setWiring(AUX_BUTTON, BUTTON_PIN_SECONDARY);
buttons->setHandlerShortPress(AUX_BUTTON, []() { InkHUD::WindowManager::getInstance()->nextTile(); });
buttons->setWiring(1, BUTTON_PIN_SECONDARY);
buttons->setHandlerShortPress(1, []() { InkHUD::InkHUD::getInstance()->nextTile(); });
buttons->start();
}

View File

@@ -2,6 +2,7 @@
[env:heltec-vision-master-e290]
extends = esp32s3_base
board = heltec_vision_master_e290
board_build.partitions = default_8MB.csv
build_flags =
${esp32s3_base.build_flags}
-I variants/heltec_vision_master_e290
@@ -19,16 +20,14 @@ build_flags =
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2#448c8538129fde3d02a7cb5e6fc81971ad92547f
https://github.com/meshtastic/GxEPD2/archive/448c8538129fde3d02a7cb5e6fc81971ad92547f.zip
lewisxhe/PCF8563_Library@^1.0.1
upload_speed = 115200
; Using experimental InkHUD UI (work in progress)
[platformio]
extra_configs = src/graphics/niche/InkHUD/PlatformioConfig.ini
[env:heltec-vision-master-e290-inkhud]
extends = esp32s3_base, inkhud
board = heltec_vision_master_e290
board_build.partitions = default_8MB.csv
build_src_filter =
${esp32_base.build_src_filter}
${inkhud.build_src_filter}
@@ -37,8 +36,8 @@ build_flags =
${inkhud.build_flags}
-I variants/heltec_vision_master_e290
-D HELTEC_VISION_MASTER_E290
-D MAX_THREADS=40
-D MAX_THREADS=40 ; Required if used with WiFi
lib_deps =
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot intead of AdafruitGFX
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot instead of AdafruitGFX
${esp32s3_base.lib_deps}
upload_speed = 115200
upload_speed = 921600

View File

@@ -1,13 +1,13 @@
[env:heltec-vision-master-t190]
extends = esp32s3_base
board = heltec_vision_master_t190
board_build.partitions = default_8MB.csv
build_flags =
${esp32s3_base.build_flags}
-Ivariants/heltec_vision_master_t190
-DHELTEC_VISION_MASTER_T190
; -D PRIVATE_HW
-DHELTEC_VISION_MASTER_T190
lib_deps =
${esp32s3_base.lib_deps}
lewisxhe/PCF8563_Library@^1.0.1
https://github.com/meshtastic/st7789#bd33ea58ddfe4a5e4a66d53300ccbd38d66ac21f
https://github.com/meshtastic/st7789/archive/bd33ea58ddfe4a5e4a66d53300ccbd38d66ac21f.zip
upload_speed = 921600

View File

@@ -6,7 +6,7 @@
// InkHUD-specific components
// ---------------------------
#include "graphics/niche/InkHUD/WindowManager.h"
#include "graphics/niche/InkHUD/InkHUD.h"
// Applets
#include "graphics/niche/InkHUD/Applets/User/AllMessage/AllMessageApplet.h"
@@ -49,48 +49,42 @@ void setupNicheGraphics()
// InkHUD
// ----------------------------
InkHUD::WindowManager *windowManager = InkHUD::WindowManager::getInstance();
InkHUD::InkHUD *inkhud = InkHUD::InkHUD::getInstance();
// Set the driver
windowManager->setDriver(driver);
inkhud->setDriver(driver);
// Set how many FAST updates per FULL update
// Set how unhealthy additional FAST updates beyond this number are
windowManager->setDisplayResilience(10, 1.5);
inkhud->setDisplayResilience(10, 1.5);
// Prepare fonts
InkHUD::AppletFont largeFont(FreeSans9pt7b);
InkHUD::AppletFont smallFont(FreeSans6pt7b);
InkHUD::Applet::fontLarge = InkHUD::AppletFont(FreeSans9pt7b);
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt7b);
/*
// Font localization demo: Cyrillic
InkHUD::AppletFont smallFont(FreeSans6pt8bCyrillic);
smallFont.addSubstitutionsWin1251();
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt8bCyrillic);
InkHUD::Applet::fontSmall.addSubstitutionsWin1251();
*/
InkHUD::Applet::setDefaultFonts(largeFont, smallFont);
// Init settings, and customize defaults
InkHUD::settings.userTiles.maxCount = 2; // How many tiles can the display handle?
InkHUD::settings.rotation = 3; // 270 degrees clockwise
InkHUD::settings.userTiles.count = 1; // One tile only by default, keep things simple for new users
// Customize default settings
inkhud->persistence->settings.userTiles.maxCount = 2; // How many tiles can the display handle?
inkhud->persistence->settings.rotation = 3; // 270 degrees clockwise
inkhud->persistence->settings.userTiles.count = 1; // One tile only by default, keep things simple for new users
// Pick applets
// Note: order of applets determines priority of "auto-show" feature
// Optional arguments for defaults:
// - is activated?
// - is autoshown?
// - is foreground on a specific tile (index)?
windowManager->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
windowManager->addApplet("DMs", new InkHUD::DMApplet);
windowManager->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0));
windowManager->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1));
windowManager->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
windowManager->addApplet("Recents List", new InkHUD::RecentsListApplet);
windowManager->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, not autoshown, default on tile 0
// windowManager->addApplet("Basic", new InkHUD::BasicExampleApplet);
// windowManager->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
inkhud->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
inkhud->addApplet("DMs", new InkHUD::DMApplet); // Inactive
inkhud->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0)); // Inactive
inkhud->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1)); // Inactive
inkhud->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
inkhud->addApplet("Recents List", new InkHUD::RecentsListApplet); // Inactive
inkhud->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, not autoshown, default on tile 0
// inkhud->addApplet("Basic", new InkHUD::BasicExampleApplet);
// inkhud->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
// Start running window manager
windowManager->begin();
// Start running InkHUD
inkhud->begin();
// Buttons
// --------------------------
@@ -100,8 +94,8 @@ void setupNicheGraphics()
// Setup the main user button
buttons->setWiring(MAIN_BUTTON, BUTTON_PIN);
buttons->setHandlerShortPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonShort(); });
buttons->setHandlerLongPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonLong(); });
buttons->setHandlerShortPress(MAIN_BUTTON, []() { InkHUD::InkHUD::getInstance()->shortpress(); });
buttons->setHandlerLongPress(MAIN_BUTTON, []() { InkHUD::InkHUD::getInstance()->longpress(); });
// No aux button on this board

View File

@@ -2,6 +2,7 @@
[env:heltec-wireless-paper]
extends = esp32s3_base
board = heltec_wifi_lora_32_V3
board_build.partitions = default_8MB.csv
build_flags =
${esp32s3_base.build_flags}
-I variants/heltec_wireless_paper
@@ -16,16 +17,14 @@ build_flags =
-D EINK_HASQUIRK_GHOSTING ; Display model is identified as "prone to ghosting"
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2#b202ebfec6a4821e098cf7a625ba0f6f2400292d
https://github.com/meshtastic/GxEPD2/archive/b202ebfec6a4821e098cf7a625ba0f6f2400292d.zip
lewisxhe/PCF8563_Library@^1.0.1
upload_speed = 115200
; Using experimental InkHUD UI (work in progress)
[platformio]
extra_configs = src/graphics/niche/InkHUD/PlatformioConfig.ini
[env:heltec-wireless-paper-inkhud]
extends = esp32s3_base, inkhud
board = heltec_wifi_lora_32_V3
board_build.partitions = default_8MB.csv
build_src_filter =
${esp32_base.build_src_filter}
${inkhud.build_src_filter}
@@ -34,8 +33,8 @@ build_flags =
${inkhud.build_flags}
-I variants/heltec_wireless_paper
-D HELTEC_WIRELESS_PAPER
-D MAX_THREADS=40
-D MAX_THREADS=40 ; Required if used with WiFi
lib_deps =
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot intead of AdafruitGFX
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot instead of AdafruitGFX
${esp32s3_base.lib_deps}
upload_speed = 115200
upload_speed = 921600

View File

@@ -2,6 +2,7 @@
extends = esp32s3_base
board_level = extra
board = heltec_wifi_lora_32_V3
board_build.partitions = default_8MB.csv
build_flags =
${esp32s3_base.build_flags}
-I variants/heltec_wireless_paper_v1
@@ -14,6 +15,6 @@ build_flags =
-D EINK_LIMIT_GHOSTING_PX=2000 ; (Optional) How much image ghosting is tolerated
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2#55f618961db45a23eff0233546430f1e5a80f63a
https://github.com/meshtastic/GxEPD2/archive/55f618961db45a23eff0233546430f1e5a80f63a.zip
lewisxhe/PCF8563_Library@^1.0.1
upload_speed = 115200

View File

@@ -1,6 +1,7 @@
[env:heltec-wireless-tracker]
extends = esp32s3_base
board = heltec_wireless_tracker
board_build.partitions = default_8MB.csv
upload_protocol = esptool
build_flags =

View File

@@ -2,6 +2,7 @@
extends = esp32s3_base
board_level = extra
board = heltec_wireless_tracker
board_build.partitions = default_8MB.csv
upload_protocol = esptool
build_flags =
${esp32s3_base.build_flags} -I variants/heltec_wireless_tracker_V1_0

View File

@@ -1,7 +1,8 @@
[env:heltec-wsl-v3]
extends = esp32s3_base
board = heltec_wifi_lora_32_V3
board_build.partitions = default_8MB.csv
# Temporary until espressif creates a release with this new target
build_flags =
${esp32s3_base.build_flags} -D HELTEC_WSL_V3 -I variants/heltec_wsl_v3
-DGPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely.
-D GPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely.

View File

@@ -4,6 +4,7 @@ board = icarus
board_level = extra
board_check = true
board_build.mcu = esp32s3
board_build.partitions = default_8MB.csv
upload_protocol = esptool
upload_speed = 921600
platform_packages = platformio/framework-arduinoespressif32@https://github.com/PowerFeather/powerfeather-meshtastic-arduino-lib/releases/download/2.0.16a/esp32-2.0.16.zip
@@ -15,5 +16,4 @@ build_unflags =
build_flags =
${esp32s3_base.build_flags} -D PRIVATE_HW -I variants/icarus
-DBOARD_HAS_PSRAM
-DARDUINO_USB_MODE=0
-DARDUINO_USB_MODE=0

View File

@@ -3,6 +3,7 @@
extends = esp32s3_base
board = m5stack-cores3
board_check = true
board_build.partitions = default_16MB.csv
upload_protocol = esptool
build_flags = ${esp32_base.build_flags}

View File

@@ -28,7 +28,6 @@ build_flags = ${esp32s3_base.build_flags}
-D USE_LOG_DEBUG
-D LOG_DEBUG_INC=\"DebugConfiguration.h\"
-D RADIOLIB_SPI_PARANOID=0
-D MAX_NUM_NODES=250
-D MAX_THREADS=40
-D HAS_SCREEN=0
-D HAS_TFT=1
@@ -47,14 +46,11 @@ build_flags = ${esp32s3_base.build_flags}
-D LGFX_TOUCH_INT=41
-D VIEW_320x240
-D USE_PACKET_API
-I lib/device-ui/generated/ui_320x240
-I variants/mesh-tab
build_src_filter = ${esp32_base.build_src_filter}
+<../lib/device-ui/generated/ui_320x240>
+<../lib/device-ui/resources>
+<../lib/device-ui/locale>
+<../lib/device-ui/source>
lib_deps = ${esp32_base.lib_deps}
lib_deps =
${esp32_base.lib_deps}
${device-ui_base.lib_deps}
lovyan03/LovyanGFX@^1.2.0
[mesh_tab_xpt2046]

View File

@@ -23,7 +23,7 @@ build_flags = ${nrf52840_base.build_flags} -I variants/meshlink -D MESHLINK
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/meshlink>
lib_deps =
${nrf52840_base.lib_deps}
https://github.com/meshtastic/GxEPD2#55f618961db45a23eff0233546430f1e5a80f63a
https://github.com/meshtastic/GxEPD2/archive/55f618961db45a23eff0233546430f1e5a80f63a.zip
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
; Note: as of 6/2013 the serial/bootloader based programming takes approximately 30 seconds

View File

@@ -23,7 +23,7 @@ build_flags = ${nrf52840_base.build_flags} -I variants/meshlink_eink -D MESHLINK
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/meshlink_eink>
lib_deps =
${nrf52840_base.lib_deps}
https://github.com/meshtastic/GxEPD2#55f618961db45a23eff0233546430f1e5a80f63a
https://github.com/meshtastic/GxEPD2/archive/55f618961db45a23eff0233546430f1e5a80f63a.zip
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
; Note: as of 6/2013 the serial/bootloader based programming takes approximately 30 seconds

View File

@@ -9,7 +9,7 @@ build_src_filter = ${nrf52_base.build_src_filter} +<../variants/monteops_hw1> +<
lib_deps =
${nrf52840_base.lib_deps}
${networking_base.lib_deps}
https://github.com/RAKWireless/RAK13800-W5100S.git#1.0.2
https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
;upload_protocol = jlink

View File

@@ -2,6 +2,7 @@
extends = esp32s3_base
board = bpi_picow_esp32_s3
board_check = true
board_build.partitions = default_8MB.csv
;OpenOCD flash method
;upload_protocol = esp-builtin
;Normal method
@@ -22,7 +23,6 @@ build_src_filter =
[env:picomputer-s3-tft]
extends = env:picomputer-s3
board_build.partitions = default_8MB.csv ; just for test
build_flags =
${env:picomputer-s3.build_flags}
@@ -35,7 +35,6 @@ build_flags =
-D INPUTDRIVER_MATRIX_TYPE=1
-D USE_PIN_BUZZER=PIN_BUZZER
-D USE_SX127x
-D MAX_NUM_NODES=200
-D HAS_SCREEN=0
-D HAS_TFT=1
-D RAM_SIZE=1024
@@ -54,11 +53,7 @@ build_flags =
-D VIEW_320x240
; -D USE_DOUBLE_BUFFER
-D USE_PACKET_API
-I lib/device-ui/generated/ui_320x240
build_src_filter =
${env:picomputer-s3.build_src_filter}
+<../lib/device-ui/generated/ui_320x240>
+<../lib/device-ui/resources>
+<../lib/device-ui/locale>
+<../lib/device-ui/source>
lib_deps =
${env:picomputer-s3.lib_deps}
${device-ui_base.lib_deps}

View File

@@ -18,12 +18,16 @@ build_flags = ${native_base.build_flags}
[env:native-tft]
extends = native_base
build_type = release
lib_deps =
${native_base.lib_deps}
${device-ui_base.lib_deps}
build_flags = ${native_base.build_flags} -Os -lX11 -linput -lxkbcommon -ffunction-sections -fdata-sections -Wl,--gc-sections
-D MESHTASTIC_EXCLUDE_CANNEDMESSAGES=1
-D RAM_SIZE=16384
-D USE_X11=1
-D HAS_TFT=1
-D HAS_SCREEN=0
-D LV_CACHE_DEF_SIZE=6291456
-D LV_BUILD_TEST=0
-D LV_USE_LIBINPUT=1
-D LV_LVGL_H_INCLUDE_SIMPLE
@@ -32,21 +36,19 @@ build_flags = ${native_base.build_flags} -Os -lX11 -linput -lxkbcommon -ffunctio
-D USE_LOG_DEBUG
-D LOG_DEBUG_INC=\"DebugConfiguration.h\"
-D USE_PACKET_API
-I lib/device-ui/generated/ui_320x240
-D VIEW_320x240
!pkg-config --libs libulfius --silence-errors || :
!pkg-config --libs openssl --silence-errors || :
build_src_filter = ${native_base.build_src_filter}
build_src_filter =
${native_base.build_src_filter}
-<graphics/TFTDisplay.cpp>
+<../lib/device-ui/generated/ui_320x240>
+<../lib/device-ui/generated/ui_320x240/fonts>
+<../lib/device-ui/resources>
+<../lib/device-ui/portduino>
+<../lib/device-ui/locale>
+<../lib/device-ui/source>
[env:native-tft-debug]
extends = native_base
build_type = debug
lib_deps =
${native_base.lib_deps}
${device-ui_base.lib_deps}
board_level = extra
build_flags = ${native_base.build_flags} -O0 -fsanitize=address -lX11 -linput -lxkbcommon
-D MESHTASTIC_EXCLUDE_CANNEDMESSAGES=1
@@ -55,7 +57,7 @@ build_flags = ${native_base.build_flags} -O0 -fsanitize=address -lX11 -linput -l
-D USE_X11=1
-D HAS_TFT=1
-D HAS_SCREEN=0
; -D CALIBRATE_TOUCH=0
-D LV_CACHE_DEF_SIZE=6291456
-D LV_BUILD_TEST=0
-D LV_USE_LOG=1
-D LV_USE_SYSMON=1
@@ -69,7 +71,7 @@ build_flags = ${native_base.build_flags} -O0 -fsanitize=address -lX11 -linput -l
-D USE_LOG_DEBUG
-D LOG_DEBUG_INC=\"DebugConfiguration.h\"
-D USE_PACKET_API
-I lib/device-ui/generated/ui_320x240
-D VIEW_320x240
!pkg-config --libs libulfius --silence-errors || :
!pkg-config --libs openssl --silence-errors || :
build_src_filter = ${env:native-tft.build_src_filter}

View File

@@ -13,4 +13,4 @@ board_build.f_cpu = 240000000L
upload_protocol = esptool
lib_deps =
${esp32_base.lib_deps}
https://github.com/gjelsoe/STK8xxx-Accelerometer.git#v0.1.1
https://github.com/gjelsoe/STK8xxx-Accelerometer/archive/v0.1.1.zip

View File

@@ -1,21 +1,20 @@
[env:rak11310]
extends = rp2040_base
board = wiscore_rak11300
board = rakwireless_rak11300
upload_protocol = picotool
# keep an old SDK to use less memory.
platform = https://github.com/maxgerhardt/platform-raspberrypi.git#v1.2.0-gcc12
platform_packages = framework-arduinopico@https://github.com/earlephilhower/arduino-pico.git#3.7.2
# add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags}
-DRAK11310
-Ivariants/rak11310
-DDEBUG_RP2040_PORT=Serial
-DRV3028_RTC=0x52
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m0plus"
build_src_filter = ${rp2040_base.build_src_filter} +<../variants/rak11310> +<mesh/eth/> +<mesh/api/> +<mqtt/>
lib_deps =
${rp2040_base.lib_deps}
${networking_base.lib_deps}
https://github.com/RAKWireless/RAK13800-W5100S.git#1.0.2
melopero/Melopero RV3028@^1.1.0
https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip
debug_build_flags = ${rp2040_base.build_flags}, -g
debug_tool = cmsis-dap ; for e.g. Picotool

View File

@@ -4,6 +4,12 @@
#define ARDUINO_ARCH_AVR
// Define I2C pins to ensure correct usage of both ports
#define I2C_SDA 20
#define I2C_SCL 21
#define I2C_SDA1 2
#define I2C_SCL1 3
#define LED_CONN PIN_LED2
#define LED_PIN LED_BUILTIN
#define ledOff(pin) pinMode(pin, INPUT)

View File

@@ -15,7 +15,7 @@ lib_deps =
${nrf52840_base.lib_deps}
${networking_base.lib_deps}
melopero/Melopero RV3028@^1.1.0
https://github.com/beegee-tokyo/RAK-OneWireSerial.git#0.0.2
https://github.com/beegee-tokyo/RAK-OneWireSerial/archive/0.0.2.zip
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
;upload_protocol = jlink

View File

@@ -1,36 +1,23 @@
[env:rak3172]
extends = stm32_base
board = wiscore_rak3172
board_upload.maximum_size = 233472 ; reserve the last 28KB for filesystem
build_flags =
${stm32_base.build_flags}
-Ivariants/rak3172
-DSERIAL_UART_INSTANCE=1
-DPIN_SERIAL_RX=PB7
-DPIN_SERIAL_TX=PB6
-DHAL_DAC_MODULE_ONLY
-DHAL_ADC_MODULE_DISABLED
-DHAL_COMP_MODULE_DISABLED
-DHAL_CRC_MODULE_DISABLED
-DHAL_CRYP_MODULE_DISABLED
-DHAL_GTZC_MODULE_DISABLED
-DHAL_HSEM_MODULE_DISABLED
-DHAL_I2C_MODULE_DISABLED
-DHAL_I2S_MODULE_DISABLED
-DHAL_IPCC_MODULE_DISABLED
-DHAL_IRDA_MODULE_DISABLED
-DHAL_IWDG_MODULE_DISABLED
-DHAL_LPTIM_MODULE_DISABLED
-DHAL_PKA_MODULE_DISABLED
-DHAL_RNG_MODULE_DISABLED
-DHAL_RTC_MODULE_DISABLED
-DHAL_SMARTCARD_MODULE_DISABLED
-DHAL_SMBUS_MODULE_DISABLED
-DHAL_TIM_MODULE_DISABLED
-DHAL_WWDG_MODULE_DISABLED
-DHAL_EXTI_MODULE_DISABLED
-DHAL_SAI_MODULE_DISABLED
-DHAL_ICACHE_MODULE_DISABLED
-DHAL_RNG_MODULE_ENABLED
-DRADIOLIB_EXCLUDE_SX128X=1
-DRADIOLIB_EXCLUDE_SX127X=1
-DRADIOLIB_EXCLUDE_LR11X0=1
upload_port = stlink
-DMESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR=1
-DMESHTASTIC_EXCLUDE_I2C=1
-DMESHTASTIC_EXCLUDE_WIFI=1
-DMESHTASTIC_EXCLUDE_BLUETOOTH=1
-DMESHTASTIC_EXCLUDE_GPS=1
-DMESHTASTIC_EXCLUDE_SCREEN=1
-DMESHTASTIC_EXCLUDE_MQTT=1
-DMESHTASTIC_EXCLUDE_POWERMON=1
;-DPIO_FRAMEWORK_ARDUINO_NANOLIB_FLOAT_PRINTF
;-DCFG_DEBUG
upload_port = stlink

View File

@@ -1,3 +1,8 @@
/*
STM32WLE5 Core Module for LoRaWAN® RAK3372
https://store.rakwireless.com/products/wisblock-core-module-rak3372
*/
/*
This variant is a work in progress.
Do not expect a working Meshtastic device with this target.
@@ -7,6 +12,8 @@ Do not expect a working Meshtastic device with this target.
#define _VARIANT_RAK3172_
#define USE_STM32WLx
#define MAX_NUM_NODES 10
#endif
#define LED_PIN PA0 // Green LED
#define LED_STATE_ON 1
#endif

View File

@@ -17,9 +17,9 @@ lib_deps =
${nrf52840_base.lib_deps}
${networking_base.lib_deps}
melopero/Melopero RV3028@^1.1.0
https://github.com/RAKWireless/RAK13800-W5100S.git#1.0.2
https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip
rakwireless/RAKwireless NCP5623 RGB LED library@^1.0.2
https://github.com/RAKWireless/RAK12034-BMX160.git#dcead07ffa267d3c906e9ca4a1330ab989e957e2
https://github.com/RAKWireless/RAK12034-BMX160/archive/dcead07ffa267d3c906e9ca4a1330ab989e957e2.zip
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
; Note: as of 6/2013 the serial/bootloader based programming takes approximately 30 seconds
@@ -41,7 +41,7 @@ build_flags =
lib_deps =
${env:rak4631.lib_deps}
https://github.com/geeksville/Armduino-Semihosting.git#35b538fdf208c3530c1434cd099a08e486672ee4
https://github.com/geeksville/Armduino-Semihosting/archive/35b538fdf208c3530c1434cd099a08e486672ee4.zip
; NOTE: the pyocd support for semihosting is buggy. So I switched to using the builtin platformio support for the stlink adapter which worked much better.
; However the built in openocd version in platformio has buggy support for TCP to semihosting.

View File

@@ -10,7 +10,6 @@ build_flags = ${nrf52840_base.build_flags} -Ivariants/rak4631_eth_gw -D RAK_4631
-DEINK_WIDTH=250
-DEINK_HEIGHT=122
-DNRF52_USE_JSON=1
-DMESHTASTIC_EXCLUDE_GPS=1
-DMESHTASTIC_EXCLUDE_WIFI=1
-DMESHTASTIC_EXCLUDE_SCREEN=1
; -DMESHTASTIC_EXCLUDE_PKI=1
@@ -28,9 +27,9 @@ lib_deps =
${nrf52840_base.lib_deps}
${networking_base.lib_deps}
melopero/Melopero RV3028@^1.1.0
https://github.com/RAKWireless/RAK13800-W5100S.git#1.0.2
https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip
rakwireless/RAKwireless NCP5623 RGB LED library@^1.0.2
https://github.com/meshtastic/RAK12034-BMX160.git#4821355fb10390ba8557dc43ca29a023bcfbb9d9
https://github.com/meshtastic/RAK12034-BMX160/archive/4821355fb10390ba8557dc43ca29a023bcfbb9d9.zip
bblanchon/ArduinoJson @ 6.21.4
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
; Note: as of 6/2013 the serial/bootloader based programming takes approximately 30 seconds
@@ -52,7 +51,7 @@ build_flags =
lib_deps =
${env:rak4631_eth_gw.lib_deps}
https://github.com/geeksville/Armduino-Semihosting.git#35b538fdf208c3530c1434cd099a08e486672ee4
https://github.com/geeksville/Armduino-Semihosting/archive/35b538fdf208c3530c1434cd099a08e486672ee4.zip
; NOTE: the pyocd support for semihosting is buggy. So I switched to using the builtin platformio support for the stlink adapter which worked much better.
; However the built in openocd version in platformio has buggy support for TCP to semihosting.
@@ -63,4 +62,4 @@ lib_deps =
upload_protocol = stlink
; eventually use platformio/tool-pyocd@^2.3600.0 instad
;upload_protocol = custom
;upload_command = pyocd flash -t nrf52840 $UPLOADERFLAGS $SOURCE
;upload_command = pyocd flash -t nrf52840 $UPLOADERFLAGS $SOURCE

View File

@@ -18,7 +18,7 @@ lib_deps =
${nrf52840_base.lib_deps}
${networking_base.lib_deps}
melopero/Melopero RV3028@^1.1.0
https://github.com/RAKWireless/RAK13800-W5100S.git#1.0.2
https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip
rakwireless/RAKwireless NCP5623 RGB LED library@^1.0.2
bodmer/TFT_eSPI
beegee-tokyo/RAKwireless RAK12034@^1.0.0

View File

@@ -23,8 +23,9 @@ build_flags = ${rp2350_base.build_flags}
-DHAS_WIFI=1
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m33"
-fexceptions # for exception handling in MQTT
-DHAS_UDP_MULTICAST=1
build_src_filter = ${rp2350_base.build_src_filter} +<mesh/wifi/>
lib_deps =
${rp2350_base.lib_deps}
${networking_base.lib_deps}
debug_build_flags = ${rp2350_base.build_flags}, -g
debug_build_flags = ${rp2350_base.build_flags}, -g

View File

@@ -10,9 +10,10 @@ build_flags = ${rp2040_base.build_flags}
-DHW_SPI1_DEVICE
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m0plus"
-fexceptions # for exception handling in MQTT
-DHAS_UDP_MULTICAST=1
build_src_filter = ${rp2040_base.build_src_filter} +<mesh/wifi/>
lib_deps =
${rp2040_base.lib_deps}
${networking_base.lib_deps}
debug_build_flags = ${rp2040_base.build_flags}, -g
debug_tool = cmsis-dap ; for e.g. Picotool
debug_tool = cmsis-dap ; for e.g. Picotool

View File

@@ -2,10 +2,11 @@
[env:seeed-sensecap-indicator]
extends = esp32s3_base
platform_packages =
platformio/framework-arduinoespressif32 @ https://github.com/mverch67/arduino-esp32.git#aef7fef6de3329ed6f75512d46d63bba12b09bb5 ; add_tca9535 (based on 2.0.16)
platformio/framework-arduinoespressif32 @ https://github.com/mverch67/arduino-esp32/archive/aef7fef6de3329ed6f75512d46d63bba12b09bb5.zip ; add_tca9535 (based on 2.0.16)
board = seeed-sensecap-indicator
board_check = true
board_build.partitions = default_8MB.csv
upload_protocol = esptool
build_flags = ${esp32_base.build_flags}
@@ -23,7 +24,7 @@ build_flags = ${esp32_base.build_flags}
-DUSE_ARDUINO_HAL_GPIO
lib_deps = ${esp32s3_base.lib_deps}
https://github.com/mverch67/LovyanGFX#develop
https://github.com/mverch67/LovyanGFX/archive/4c76238c1344162a234ae917b27651af146d6fb2.zip
earlephilhower/ESP8266Audio@^1.9.9
earlephilhower/ESP8266SAM@^1.0.1
@@ -32,7 +33,6 @@ lib_deps = ${esp32s3_base.lib_deps}
extends = env:seeed-sensecap-indicator
board_level = main
upload_speed = 460800
board_build.partitions = default_8MB.csv ; must be here for some reason, board.json is not enough !?
build_flags =
${env:seeed-sensecap-indicator.build_flags}
@@ -46,11 +46,10 @@ build_flags =
-D INPUTDRIVER_BUTTON_TYPE=38
-D HAS_TELEMETRY=0
-D CONFIG_DISABLE_HAL_LOCKS=1
-D MAX_NUM_NODES=250
-D HAS_SCREEN=0
-D HAS_TFT=1
-D DISPLAY_SET_RESOLUTION
-D USE_I2S_BUZZER
-D USE_PIN_BUZZER
-D RAM_SIZE=4096
-D LV_LVGL_H_INCLUDE_SIMPLE
-D LV_CONF_INCLUDE_SIMPLE
@@ -66,17 +65,9 @@ build_flags =
-D LGFX_DRIVER=LGFX_INDICATOR
-D GFX_DRIVER_INC=\"graphics/LGFX/LGFX_INDICATOR.h\"
-D VIEW_320x240
; -D USE_DOUBLE_BUFFER
-D USE_PACKET_API
-I lib/device-ui/generated/ui_320x240
build_src_filter =
${env:seeed-sensecap-indicator.build_src_filter}
+<../lib/device-ui/generated/ui_320x240>
+<../lib/device-ui/resources>
+<../lib/device-ui/locale>
+<../lib/device-ui/source>
lib_deps =
${env:seeed-sensecap-indicator.lib_deps}
https://github.com/bitbank2/bb_captouch.git#8f2f06462ff597847921739376a299db93612417 ; alternative touch library supporting FT6x36
${device-ui_base.lib_deps}
https://github.com/mverch67/bb_captouch/archive/8626412fe650d808a267791c0eae6e5860c85a5d.zip ; alternative touch library supporting FT6x36

View File

@@ -0,0 +1,13 @@
; Seeed Xiao BLE: https://www.digikey.com/en/products/detail/seeed-technology-co-ltd/102010448/16652893
[env:seeed_xiao_nrf52840_kit]
extends = nrf52840_base
board = xiao_ble_sense
build_flags = ${nrf52840_base.build_flags} -Ivariants/seeed_xiao_nrf52840_kit -Isrc/platform/nrf52/softdevice -Isrc/platform/nrf52/softdevice/nrf52 -DSEEED_XIAO_NRF52840_KIT
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m4/fpv4-sp-d16-hard"
board_build.ldscript = src/platform/nrf52/nrf52840_s140_v7.ld
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/seeed_xiao_nrf52840_kit>
lib_deps =
${nrf52840_base.lib_deps}
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
;upload_protocol = jlink

View File

@@ -0,0 +1,92 @@
#include "variant.h"
#include "configuration.h"
#include "nrf.h"
#include "wiring_constants.h"
#include "wiring_digital.h"
#include <map>
#include <memory>
#include <stddef.h>
#include <stdint.h>
const uint32_t g_ADigitalPinMap[] = {
// D0 .. D13
2, // D0 is P0.02 (A0)
3, // D1 is P0.03 (A1)
28, // D2 is P0.28 (A2)
29, // D3 is P0.29 (A3)
4, // D4 is P0.04 (A4,SDA)
5, // D5 is P0.05 (A5,SCL)
43, // D6 is P1.11 (TX)
44, // D7 is P1.12 (RX)
45, // D8 is P1.13 (SCK)
46, // D9 is P1.14 (MISO)
47, // D10 is P1.15 (MOSI)
// LEDs
26, // D11 is P0.26 (LED RED)
6, // D12 is P0.06 (LED BLUE)
30, // D13 is P0.30 (LED GREEN)
14, // D14 is P0.14 (READ_BAT)
// LSM6DS3TR
40, // D15 is P1.08 (6D_PWR)
27, // D16 is P0.27 (6D_I2C_SCL)
7, // D17 is P0.07 (6D_I2C_SDA)
11, // D18 is P0.11 (6D_INT1)
// MIC
42, // 17,//42, // D19 is P1.10 (MIC_PWR)
32, // 26,//32, // D20 is P1.00 (PDM_CLK)
16, // 25,//16, // D21 is P0.16 (PDM_DATA)
// BQ25100
13, // D22 is P0.13 (HICHG)
17, // D23 is P0.17 (~CHG)
//
21, // D24 is P0.21 (QSPI_SCK)
25, // D25 is P0.25 (QSPI_CSN)
20, // D26 is P0.20 (QSPI_SIO_0 DI)
24, // D27 is P0.24 (QSPI_SIO_1 DO)
22, // D28 is P0.22 (QSPI_SIO_2 WP)
23, // D29 is P0.23 (QSPI_SIO_3 HOLD)
// NFC
9, // D30 is P0.09 (NFC1)
10, // D31 is P0.10 (NFC2)
// VBAT
31, // D32 is P0.10 (VBAT)
};
/*
Copyright (c) 2014-2015 Arduino LLC. All right reserved.
Copyright (c) 2016 Sandeep Mistry All right reserved.
Copyright (c) 2018, Adafruit Industries (adafruit.com)
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
void initVariant()
{
// LED1 & LED2
pinMode(21, OUTPUT);
digitalWrite(21, LOW);
// LED1 & LED2
pinMode(22, OUTPUT);
digitalWrite(22, LOW);
pinMode(PIN_WIRE_SDA, INPUT_PULLUP);
pinMode(PIN_WIRE_SCL, INPUT_PULLUP);
}

View File

@@ -0,0 +1,170 @@
#ifndef _SEEED_XIAO_NRF52840_SENSE_H_
#define _SEEED_XIAO_NRF52840_SENSE_H_
/** Master clock frequency */
#define VARIANT_MCK (64000000ul)
#define USE_LFXO // Board uses 32khz crystal for LF
// #define USE_LFRC // Board uses RC for LF
/*----------------------------------------------------------------------------
* Headers
*----------------------------------------------------------------------------*/
#include "WVariant.h"
#ifdef __cplusplus
extern "C" {
#endif // __cplusplus
#define PINS_COUNT (33)
#define NUM_DIGITAL_PINS (33)
#define NUM_ANALOG_INPUTS (8) // A6 is used for battery, A7 is analog reference
#define NUM_ANALOG_OUTPUTS (0)
// LEDs
#define LED_RED 11
#define LED_BLUE 12
#define LED_GREEN 13
#define PIN_LED1 LED_GREEN
#define PIN_LED2 LED_BLUE
#define PIN_LED3 LED_RED
#define PIN_LED PIN_LED1
#define LED_PWR (PINS_COUNT)
#define LED_BUILTIN PIN_LED
#define LED_STATE_ON 1 // State when LED is lit
/*
* Buttons
*/
// Digital PINs
#define D0 (0ul)
#define D1 (1ul)
#define D2 (2ul)
#define D3 (3ul)
#define D4 (4ul)
#define D5 (5ul)
#define D6 (6ul)
#define D7 (7ul)
#define D8 (8ul)
#define D9 (9ul)
#define D10 (10ul)
/*Due to the lack of pins,and have to make sure gps standby work well we have temporarily removed the button.
There are some technical solutions that can solve this problem,
and we are currently exploring and researching them*/
// #define BUTTON_PIN D0 // This is the Program Button
// // #define BUTTON_NEED_PULLUP 1
// #define BUTTON_ACTIVE_LOW true
// #define BUTTON_ACTIVE_PULLUP false
/*
* Analog pins
*/
#define PIN_A0 (0)
#define PIN_A1 (1)
#define PIN_A2 (32)
#define PIN_A3 (3)
#define PIN_A4 (4)
#define PIN_A5 (5)
#define PIN_VBAT (32)
#define VBAT_ENABLE (14)
static const uint8_t A0 = PIN_A0;
static const uint8_t A1 = PIN_A1;
static const uint8_t A2 = PIN_A2;
static const uint8_t A3 = PIN_A3;
static const uint8_t A4 = PIN_A4;
static const uint8_t A5 = PIN_A5;
#define ADC_RESOLUTION 12
#define PIN_SERIAL2_RX (-1)
#define PIN_SERIAL2_TX (-1)
/*
* SPI Interfaces
*/
#define SPI_INTERFACES_COUNT 1
#define PIN_SPI_MISO (9)
#define PIN_SPI_MOSI (10)
#define PIN_SPI_SCK (8)
static const uint8_t SS = D4;
static const uint8_t MOSI = PIN_SPI_MOSI;
static const uint8_t MISO = PIN_SPI_MISO;
static const uint8_t SCK = PIN_SPI_SCK;
// supported modules list
#define USE_SX1262
// common pinouts for SX126X modules
#define SX126X_CS D4
#define SX126X_DIO1 D1
#define SX126X_BUSY D3
#define SX126X_RESET D2
#define SX126X_TXEN RADIOLIB_NC
#define SX126X_RXEN D4
#define SX126X_DIO2_AS_RF_SWITCH // DIO2 is used to control the RF switch really necessary!!!
#define SX126X_DIO3_TCXO_VOLTAGE 1.8
/*
* Wire Interfaces
*/
#define I2C_NO_RESCAN // I2C is a bit finicky, don't scan too much
#define WIRE_INTERFACES_COUNT 1 // 2
#define PIN_WIRE_SDA (24) // change to use the correct pins if needed
#define PIN_WIRE_SCL (25) // change to use the correct pins if needed
static const uint8_t SDA = PIN_WIRE_SDA;
static const uint8_t SCL = PIN_WIRE_SCL;
// GPS L76KB
#define GPS_L76K
#ifdef GPS_L76K
#define PIN_GPS_RX D6
#define PIN_GPS_TX D7
#define HAS_GPS 1
#define GPS_BAUDRATE 9600
#define GPS_THREAD_INTERVAL 50
#define PIN_SERIAL1_RX PIN_GPS_TX
#define PIN_SERIAL1_TX PIN_GPS_RX
#define PIN_GPS_STANDBY D0
#endif
// Battery
#define BAT_READ \
14 // P0_14 = 14 Reads battery voltage from divider on signal board. (PIN_VBAT is reading voltage divider on XIAO and is
// program pin 32 / or P0.31)
#define BATTERY_SENSE_RESOLUTION_BITS 10
#define CHARGE_LED 23 // P0_17 = 17 D23 YELLOW CHARGE LED
#define HICHG 22 // P0_13 = 13 D22 Charge-select pin for Lipo for 100 mA instead of default 50mA charge
// The battery sense is hooked to pin A0 (5)
#define BATTERY_PIN PIN_VBAT // PIN_A0
// ratio of voltage divider = 3.0 (R17=1M, R18=510k)
#define ADC_MULTIPLIER 3 // 3.0 + a bit for being optimistic
#ifdef __cplusplus
}
#endif
/*----------------------------------------------------------------------------
* Arduino objects - C++ only
*----------------------------------------------------------------------------*/
#endif

View File

@@ -2,7 +2,7 @@
extends = esp32s3_base
board = seeed-xiao-s3
board_check = true
board_build.mcu = esp32s3
board_build.partitions = default_8MB.csv
upload_protocol = esptool
upload_speed = 921600
lib_deps =

View File

@@ -2,6 +2,7 @@
extends = esp32s3_base
board = station-g2
board_check = true
board_build.partitions = default_16MB.csv
board_build.mcu = esp32s3
upload_protocol = esptool
;upload_port = /dev/ttyACM0
@@ -13,6 +14,6 @@ build_unflags =
-DARDUINO_USB_MODE=1
build_flags =
${esp32s3_base.build_flags} -D STATION_G2 -I variants/station-g2
-DBOARD_HAS_PSRAM
-DBOARD_HAS_PSRAM
-DSTATION_G2
-DARDUINO_USB_MODE=0
-DARDUINO_USB_MODE=0

View File

@@ -3,6 +3,7 @@
extends = esp32s3_base
board = t-deck
board_check = true
board_build.partitions = default_16MB.csv
upload_protocol = esptool
build_flags = ${esp32s3_base.build_flags}
@@ -20,7 +21,6 @@ lib_deps = ${esp32s3_base.lib_deps}
[env:t-deck-tft]
extends = env:t-deck
board_build.partitions = default_16MB.csv
build_flags =
${env:t-deck.build_flags}
@@ -38,11 +38,11 @@ build_flags =
-D INPUTDRIVER_ENCODER_DOWN=15
-D INPUTDRIVER_ENCODER_BTN=0
-D INPUTDRIVER_BUTTON_TYPE=0
-D MAX_NUM_NODES=250
-D HAS_SDCARD
-D HAS_SCREEN=0
-D HAS_TFT=1
-D USE_I2S_BUZZER
-D RAM_SIZE=4096
-D RAM_SIZE=5120
-D LV_LVGL_H_INCLUDE_SIMPLE
-D LV_CONF_INCLUDE_SIMPLE
-D LV_COMP_CONF_INCLUDE_SIMPLE
@@ -66,14 +66,8 @@ build_flags =
-D VIEW_320x240
; -D USE_DOUBLE_BUFFER
-D USE_PACKET_API
-I lib/device-ui/generated/ui_320x240
build_src_filter =
${env:t-deck.build_src_filter}
+<../lib/device-ui/generated/ui_320x240>
+<../lib/device-ui/resources>
+<../lib/device-ui/locale>
+<../lib/device-ui/source>
-D MAP_FULL_REDRAW
lib_deps =
${env:t-deck.lib_deps}
${device-ui_base.lib_deps}

View File

@@ -42,7 +42,7 @@
#define GPS_TX_PIN 43
// Have SPI interface SD card slot
#define HAS_SDCARD 1
// #define HAS_SDCARD // --> needs to be in platform.ini for device-ui
#define SPI_MOSI (41)
#define SPI_SCK (40)
#define SPI_MISO (38)

View File

@@ -6,7 +6,7 @@
// InkHUD-specific components
// ---------------------------
#include "graphics/niche/InkHUD/WindowManager.h"
#include "graphics/niche/InkHUD/InkHUD.h"
// Applets
#include "graphics/niche/InkHUD/Applets/User/AllMessage/AllMessageApplet.h"
@@ -50,31 +50,29 @@ void setupNicheGraphics()
// InkHUD
// ----------------------------
InkHUD::WindowManager *windowManager = InkHUD::WindowManager::getInstance();
InkHUD::InkHUD *inkhud = InkHUD::InkHUD::getInstance();
// Set the driver
windowManager->setDriver(driver);
inkhud->setDriver(driver);
// Set how many FAST updates per FULL update
// Set how unhealthy additional FAST updates beyond this number are
windowManager->setDisplayResilience(20, 1.5);
inkhud->setDisplayResilience(20, 1.5);
// Prepare fonts
InkHUD::AppletFont largeFont(FreeSans9pt7b);
InkHUD::AppletFont smallFont(FreeSans6pt7b);
InkHUD::Applet::fontLarge = InkHUD::AppletFont(FreeSans9pt7b);
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt7b);
/*
// Font localization demo: Cyrillic
InkHUD::AppletFont smallFont(FreeSans6pt8bCyrillic);
smallFont.addSubstitutionsWin1251();
InkHUD::Applet::fontSmall = InkHUD::AppletFont(FreeSans6pt8bCyrillic);
InkHUD::Applet::fontSmall.addSubstitutionsWin1251();
*/
InkHUD::Applet::setDefaultFonts(largeFont, smallFont);
// Init settings, and customize defaults
// Values ignored individually if found saved to flash
InkHUD::settings.userTiles.maxCount = 2; // Two applets side-by-side
InkHUD::settings.rotation = 3; // 270 degrees clockwise
InkHUD::settings.optionalFeatures.batteryIcon = true; // Device definitely has a battery
InkHUD::settings.optionalMenuItems.backlight = true; // Until proven (by touch) that user still has the capacitive button
// Customize default settings
inkhud->persistence->settings.userTiles.maxCount = 2; // Two applets side-by-side
inkhud->persistence->settings.rotation = 3; // 270 degrees clockwise
inkhud->persistence->settings.optionalFeatures.batteryIcon = true; // Device definitely has a battery
inkhud->persistence->settings.optionalMenuItems.backlight = true; // Until proves capacitive button works by touching it
// Setup backlight
// Note: AUX button behavior configured further down
@@ -83,30 +81,33 @@ void setupNicheGraphics()
// Pick applets
// Note: order of applets determines priority of "auto-show" feature
windowManager->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
windowManager->addApplet("DMs", new InkHUD::DMApplet);
windowManager->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0));
windowManager->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1));
windowManager->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
windowManager->addApplet("Recents List", new InkHUD::RecentsListApplet);
windowManager->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, no autoshow, default on tile 0
// windowManager->addApplet("Basic", new InkHUD::BasicExampleApplet);
// windowManager->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
inkhud->addApplet("All Messages", new InkHUD::AllMessageApplet, true, true); // Activated, autoshown
inkhud->addApplet("DMs", new InkHUD::DMApplet);
inkhud->addApplet("Channel 0", new InkHUD::ThreadedMessageApplet(0));
inkhud->addApplet("Channel 1", new InkHUD::ThreadedMessageApplet(1));
inkhud->addApplet("Positions", new InkHUD::PositionsApplet, true); // Activated
inkhud->addApplet("Recents List", new InkHUD::RecentsListApplet);
inkhud->addApplet("Heard", new InkHUD::HeardApplet, true, false, 0); // Activated, no autoshow, default on tile 0
// inkhud->addApplet("Basic", new InkHUD::BasicExampleApplet);
// inkhud->addApplet("NewMsg", new InkHUD::NewMsgExampleApplet);
// Start running window manager
windowManager->begin();
// Start running InkHUD
inkhud->begin();
// Buttons
// --------------------------
Inputs::TwoButton *buttons = Inputs::TwoButton::getInstance(); // Shared NicheGraphics component
// (To improve code readability only)
constexpr uint8_t MAIN_BUTTON = 0;
constexpr uint8_t TOUCH_BUTTON = 1;
// Setup the main user button
buttons->setWiring(MAIN_BUTTON, BUTTON_PIN, LOW);
buttons->setHandlerShortPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonShort(); });
buttons->setHandlerLongPress(MAIN_BUTTON, []() { InkHUD::WindowManager::getInstance()->handleButtonLong(); });
buttons->setTiming(MAIN_BUTTON, 75, 500);
buttons->setHandlerShortPress(MAIN_BUTTON, []() { InkHUD::InkHUD::getInstance()->shortpress(); });
buttons->setHandlerLongPress(MAIN_BUTTON, []() { InkHUD::InkHUD::getInstance()->longpress(); });
// Setup the capacitive touch button
// - short: momentary backlight
@@ -115,7 +116,8 @@ void setupNicheGraphics()
buttons->setTiming(TOUCH_BUTTON, 50, 5000); // 5 seconds before latch - limited by T-Echo's capacitive touch IC
buttons->setHandlerDown(TOUCH_BUTTON, [backlight]() {
backlight->peek();
InkHUD::settings.optionalMenuItems.backlight = false; // We've proved user still has the button. No need for menu entry.
InkHUD::InkHUD::getInstance()->persistence->settings.optionalMenuItems.backlight =
false; // We've proved user still has the button. No need to make backlight togglable via the menu.
});
buttons->setHandlerLongPress(TOUCH_BUTTON, [backlight]() { backlight->latch(); });
buttons->setHandlerShortPress(TOUCH_BUTTON, [backlight]() { backlight->off(); });

View File

@@ -20,13 +20,10 @@ build_flags = ${nrf52840_base.build_flags} -Ivariants/t-echo
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/t-echo>
lib_deps =
${nrf52840_base.lib_deps}
https://github.com/meshtastic/GxEPD2#55f618961db45a23eff0233546430f1e5a80f63a
https://github.com/meshtastic/GxEPD2/archive/55f618961db45a23eff0233546430f1e5a80f63a.zip
lewisxhe/PCF8563_Library@^1.0.1
;upload_protocol = fs
; Using experimental InkHUD UI (work in progress)
[platformio]
extra_configs = src/graphics/niche/InkHUD/PlatformioConfig.ini
[env:t-echo-inkhud]
extends = nrf52840_base, inkhud
board = t-echo
@@ -42,6 +39,6 @@ build_src_filter =
${inkhud.build_src_filter}
+<../variants/t-echo>
lib_deps =
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot intead of AdafruitGFX
${inkhud.lib_deps} ; InkHUD libs first, so we get GFXRoot instead of AdafruitGFX
${nrf52840_base.lib_deps}
lewisxhe/PCF8563_Library@^1.0.1

View File

@@ -0,0 +1,26 @@
#ifndef Pins_Arduino_h
#define Pins_Arduino_h
#include <stdint.h>
#define USB_VID 0x303a
#define USB_PID 0x1001
// The default Wire will be mapped to PMU and RTC
static const uint8_t SDA = 17;
static const uint8_t SCL = 18;
// Default SPI will be mapped to Radio
static const uint8_t SS = 40;
static const uint8_t MOSI = 11;
static const uint8_t MISO = 9;
static const uint8_t SCK = 10;
#define SPI_MOSI (11)
#define SPI_SCK (10)
#define SPI_MISO (9)
#define SPI_CS (12)
#define SDCARD_CS SPI_CS
#endif /* Pins_Arduino_h */

View File

@@ -0,0 +1,17 @@
[env:t-eth-elite]
extends = esp32s3_base
board = esp32s3box
board_check = true
board_build.partitions = default_16MB.csv
build_flags =
${esp32s3_base.build_flags}
-D T_ETH_ELITE
-I variants/t-eth-elite
-D GPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely.
lib_ignore =
Ethernet
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/ETHClass2/archive/v1.0.0.zip

View File

@@ -0,0 +1,11 @@
#include "RadioLib.h"
static const uint32_t rfswitch_dio_pins[] = {RADIOLIB_LR11X0_DIO5, RADIOLIB_LR11X0_DIO6, RADIOLIB_NC, RADIOLIB_NC, RADIOLIB_NC};
static const Module::RfSwitchMode_t rfswitch_table[] = {
// mode DIO5 DIO6
{LR11x0::MODE_STBY, {LOW, LOW}}, {LR11x0::MODE_RX, {HIGH, LOW}},
{LR11x0::MODE_TX, {LOW, HIGH}}, {LR11x0::MODE_TX_HP, {LOW, HIGH}},
{LR11x0::MODE_TX_HF, {LOW, LOW}}, {LR11x0::MODE_GNSS, {LOW, LOW}},
{LR11x0::MODE_WIFI, {LOW, LOW}}, END_OF_MODE_TABLE,
};

View File

@@ -0,0 +1,83 @@
#define HAS_SDCARD
#define SDCARD_USE_SPI1
#define HAS_GPS 1
#define GPS_RX_PIN 39
#define GPS_TX_PIN 42
#define GPS_BAUDRATE_FIXED 1
#define GPS_BAUDRATE 9600
#define I2C_SDA 17 // I2C pins for this board
#define I2C_SCL 18
#define HAS_SCREEN 1 // Allow for OLED Screens on I2C Header of shield
#define LED_PIN 38 // If defined we will blink this LED
#define BUTTON_PIN 0 // If defined, this will be used for user button presses,
#define BUTTON_NEED_PULLUP
// TTGO uses a common pinout for their SX1262 vs RF95 modules - both can be enabled and we will probe at runtime for RF95 and if
// not found then probe for SX1262
#define USE_RF95 // RFM95/SX127x
#define USE_SX1262
#define USE_SX1280
#define USE_LR1121
#define LORA_SCK 10
#define LORA_MISO 9
#define LORA_MOSI 11
#define LORA_CS 40
#define LORA_RESET 46
// per SX1276_Receive_Interrupt/utilities.h
#define LORA_DIO0 8
#define LORA_DIO1 16
#define LORA_DIO2 RADIOLIB_NC
// per SX1262_Receive_Interrupt/utilities.h
#ifdef USE_SX1262
#define SX126X_CS LORA_CS
#define SX126X_DIO1 8
#define SX126X_BUSY 16
#define SX126X_RESET LORA_RESET
#define SX126X_DIO2_AS_RF_SWITCH
#define SX126X_DIO3_TCXO_VOLTAGE 1.8
#endif
// per SX128x_Receive_Interrupt/utilities.h
#ifdef USE_SX1280
#define SX128X_CS LORA_CS
#define SX128X_DIO1 8
#define SX128X_DIO2 33
#define SX128X_DIO3 34
#define SX128X_BUSY 16
#define SX128X_RESET LORA_RESET
#define SX128X_RXEN 13
#define SX128X_TXEN 38
#define SX128X_MAX_POWER 3
#endif
// LR1121
#ifdef USE_LR1121
#define LR1121_IRQ_PIN 8
#define LR1121_NRESET_PIN LORA_RESET
#define LR1121_BUSY_PIN 16
#define LR1121_SPI_NSS_PIN LORA_CS
#define LR1121_SPI_SCK_PIN LORA_SCK
#define LR1121_SPI_MOSI_PIN LORA_MOSI
#define LR1121_SPI_MISO_PIN LORA_MISO
#define LR11X0_DIO3_TCXO_VOLTAGE 3.0
#define LR11X0_DIO_AS_RF_SWITCH
#endif
#define HAS_ETHERNET 1
#define USE_WS5500 1 // this driver uses the same stack as the ESP32 Wifi driver
#define ETH_MISO_PIN 47
#define ETH_MOSI_PIN 21
#define ETH_SCLK_PIN 48
#define ETH_CS_PIN 45
#define ETH_INT_PIN 14
#define ETH_RST_PIN -1
#define ETH_ADDR 1

View File

@@ -3,6 +3,7 @@
extends = esp32s3_base
board = t-watch-s3
board_check = true
board_build.partitions = default_8MB.csv
upload_protocol = esptool
build_flags = ${esp32_base.build_flags}

View File

@@ -2,6 +2,7 @@
[env:tbeam-s3-core]
extends = esp32s3_base
board = tbeam-s3-core
board_build.partitions = default_8MB.csv
board_check = true
lib_deps =

View File

@@ -15,4 +15,4 @@ build_flags =
lib_deps =
${esp32s3_base.lib_deps}
https://github.com/meshtastic/GxEPD2#b202ebfec6a4821e098cf7a625ba0f6f2400292d
https://github.com/meshtastic/GxEPD2/archive/b202ebfec6a4821e098cf7a625ba0f6f2400292d.zip

View File

@@ -1,7 +1,6 @@
[env:tlora-v3-3-0-tcxo]
extends = esp32_base
board = ttgo-lora32-v21
board_level = extra
build_flags =
${esp32_base.build_flags}
-D TLORA_V2_1_16

View File

@@ -9,7 +9,7 @@ board_build.ldscript = src/platform/nrf52/nrf52840_s140_v7.ld
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/tracker-t1000-e>
lib_deps =
${nrf52840_base.lib_deps}
https://github.com/meshtastic/QMA6100P_Arduino_Library.git#14c900b8b2e4feaac5007a7e41e0c1b7f0841136
https://github.com/meshtastic/QMA6100P_Arduino_Library/archive/14c900b8b2e4feaac5007a7e41e0c1b7f0841136.zip
debug_tool = jlink
; If not set we will default to uploading over serial (first it forces bootloader entry by talking 1200bps to cdcacm)
upload_protocol = nrfutil

View File

@@ -1,6 +1,7 @@
[env:tracksenger]
extends = esp32s3_base
board = heltec_wireless_tracker
board_build.partitions = default_8MB.csv
upload_protocol = esp-builtin
build_flags =
@@ -16,6 +17,7 @@ lib_deps =
[env:tracksenger-lcd]
extends = esp32s3_base
board = heltec_wireless_tracker
board_build.partitions = default_8MB.csv
upload_protocol = esp-builtin
build_flags =
@@ -31,6 +33,7 @@ lib_deps =
[env:tracksenger-oled]
extends = esp32s3_base
board = heltec_wireless_tracker
board_build.partitions = default_8MB.csv
upload_protocol = esp-builtin
build_flags =

View File

@@ -3,6 +3,7 @@
[env:unphone]
extends = esp32s3_base
board = unphone
board_build.partitions = default_8MB.csv
upload_speed = 921600
monitor_speed = 115200
monitor_filters = esp32_exception_decoder
@@ -32,7 +33,6 @@ lib_deps = ${esp32s3_base.lib_deps}
[env:unphone-tft]
extends = env:unphone
board_build.partitions = default_8MB.csv
build_flags =
${env:unphone.build_flags}
-D MESHTASTIC_EXCLUDE_CANNEDMESSAGES=1
@@ -42,10 +42,10 @@ build_flags =
-D MESHTASTIC_EXCLUDE_SERIAL=1
-D MESHTASTIC_EXCLUDE_SOCKETAPI=1
-D INPUTDRIVER_BUTTON_TYPE=21
-D MAX_NUM_NODES=200
-D MAX_THREADS=40
-D HAS_SCREEN=0
-D HAS_TFT=1
-D HAS_SDCARD
-D DISPLAY_SET_RESOLUTION
-D RAM_SIZE=3072
-D LV_LVGL_H_INCLUDE_SIMPLE
@@ -63,11 +63,7 @@ build_flags =
-D GFX_DRIVER_INC=\"graphics/LGFX/LGFX_UNPHONE.h\"
-D VIEW_320x240
-D USE_PACKET_API
-I lib/device-ui/generated/ui_320x240
build_src_filter =
${env:unphone.build_src_filter}
+<../lib/device-ui/generated/ui_320x240>
+<../lib/device-ui/resources>
+<../lib/device-ui/locale>
+<../lib/device-ui/source>
lib_deps =
${env:unphone.lib_deps}
${device-ui_base.lib_deps}

View File

@@ -48,7 +48,6 @@
#undef GPS_RX_PIN
#undef GPS_TX_PIN
#define HAS_SDCARD 1
#define SD_SPI_FREQUENCY 25000000
#define SDCARD_CS 43

View File

@@ -1,6 +1,7 @@
[env:wio-e5]
extends = stm32_base
board = lora_e5_dev_board
board_upload.maximum_size = 233472 ; reserve the last 28KB for filesystem
build_flags =
${stm32_base.build_flags}
-Ivariants/wio-e5
@@ -8,31 +9,19 @@ build_flags =
-DPIN_SERIAL_RX=PB7
-DPIN_SERIAL_TX=PB6
-DHAL_DAC_MODULE_ONLY
-DHAL_ADC_MODULE_DISABLED
-DHAL_COMP_MODULE_DISABLED
-DHAL_CRC_MODULE_DISABLED
-DHAL_CRYP_MODULE_DISABLED
-DHAL_GTZC_MODULE_DISABLED
-DHAL_HSEM_MODULE_DISABLED
-DHAL_I2C_MODULE_DISABLED
-DHAL_I2S_MODULE_DISABLED
-DHAL_IPCC_MODULE_DISABLED
-DHAL_IRDA_MODULE_DISABLED
-DHAL_IWDG_MODULE_DISABLED
-DHAL_LPTIM_MODULE_DISABLED
-DHAL_PKA_MODULE_DISABLED
-DHAL_RNG_MODULE_DISABLED
-DHAL_RTC_MODULE_DISABLED
-DHAL_SMARTCARD_MODULE_DISABLED
-DHAL_SMBUS_MODULE_DISABLED
-DHAL_TIM_MODULE_DISABLED
-DHAL_WWDG_MODULE_DISABLED
-DHAL_EXTI_MODULE_DISABLED
-DHAL_SAI_MODULE_DISABLED
-DHAL_ICACHE_MODULE_DISABLED
-DHAL_RNG_MODULE_ENABLED
-DRADIOLIB_EXCLUDE_SX128X=1
-DRADIOLIB_EXCLUDE_SX127X=1
-DRADIOLIB_EXCLUDE_LR11X0=1
; -D PIO_FRAMEWORK_ARDUINO_NANOLIB_FLOAT_PRINTF
-DMESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR=1
-DMESHTASTIC_EXCLUDE_I2C=1
-DMESHTASTIC_EXCLUDE_WIFI=1
-DMESHTASTIC_EXCLUDE_BLUETOOTH=1
-DMESHTASTIC_EXCLUDE_GPS=1
-DMESHTASTIC_EXCLUDE_SCREEN=1
-DMESHTASTIC_EXCLUDE_MQTT=1
-DMESHTASTIC_EXCLUDE_POWERMON=1
;-DPIO_FRAMEWORK_ARDUINO_NANOLIB_FLOAT_PRINTF
;-DCFG_DEBUG
upload_port = stlink

View File

@@ -13,9 +13,13 @@ Do not expect a working Meshtastic device with this target.
#define _VARIANT_WIOE5_
#define USE_STM32WLx
#define MAX_NUM_NODES 10
#define LED_PIN PB5
#define LED_STATE_ON 1
#if (defined(LED_BUILTIN) && LED_BUILTIN == PNUM_NOT_DEFINED)
#undef LED_BUILTIN
#define LED_BUILTIN (LED_PIN)
#endif
#endif

View File

@@ -143,9 +143,10 @@ static const uint8_t SCK = PIN_SPI_SCK;
#define SX126X_DIO2_AS_RF_SWITCH
#define SX126X_DIO3_TCXO_VOLTAGE 1.8
#ifdef EBYTE_E22_900M30S
// 10dB PA gain and 30dB rated output; based on PA output table from Ebyte Robin <sales06@ebyte.com>
#define REGULATORY_GAIN_LORA 10
#define SX126X_MAX_POWER 20
// 10dB PA gain and 30dB rated output; based on measurements from
// https://github.com/S5NC/EBYTE_ESP32-S3/blob/main/E22-900M30S%20power%20output%20testing.txt
#define REGULATORY_GAIN_LORA 7
#define SX126X_MAX_POWER 22
#endif
#ifdef EBYTE_E22_900M33S
// 25dB PA gain and 33dB rated output; based on TX Power Curve from E22-900M33S_UserManual_EN_v1.0.pdf