mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-22 18:52:30 +00:00
Merge remote-tracking branch 'remotes/origin/master' into arduino-esp32-v3.2
# Conflicts: # arch/esp32/esp32.ini # src/graphics/draw/MenuHandler.cpp # src/modules/Modules.cpp # variants/esp32s3/seeed-sensecap-indicator/platformio.ini
This commit is contained in:
56
variants/esp32s3/seeed-sensecap-indicator/pins_arduino.h
Normal file
56
variants/esp32s3/seeed-sensecap-indicator/pins_arduino.h
Normal file
@@ -0,0 +1,56 @@
|
||||
#ifndef Pins_Arduino_h
|
||||
#define Pins_Arduino_h
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
// static const uint8_t LED_BUILTIN = -1;
|
||||
|
||||
// static const uint8_t TX = 43;
|
||||
// static const uint8_t RX = 44;
|
||||
|
||||
static const uint8_t SDA = 39;
|
||||
static const uint8_t SCL = 40;
|
||||
|
||||
// Default SPI will be mapped to Radio
|
||||
static const uint8_t SS = -1;
|
||||
static const uint8_t MOSI = 48;
|
||||
static const uint8_t MISO = 47;
|
||||
static const uint8_t SCK = 41;
|
||||
|
||||
static const uint8_t A0 = 1;
|
||||
static const uint8_t A1 = 2;
|
||||
static const uint8_t A2 = 3;
|
||||
static const uint8_t A3 = 4;
|
||||
static const uint8_t A4 = 5;
|
||||
static const uint8_t A5 = 6;
|
||||
static const uint8_t A6 = 7;
|
||||
static const uint8_t A7 = 8;
|
||||
static const uint8_t A8 = 9;
|
||||
static const uint8_t A9 = 10;
|
||||
static const uint8_t A10 = 11;
|
||||
static const uint8_t A11 = 12;
|
||||
static const uint8_t A12 = 13;
|
||||
static const uint8_t A13 = 14;
|
||||
static const uint8_t A14 = 15;
|
||||
static const uint8_t A15 = 16;
|
||||
static const uint8_t A16 = 17;
|
||||
static const uint8_t A17 = 18;
|
||||
static const uint8_t A18 = 19;
|
||||
static const uint8_t A19 = 20;
|
||||
|
||||
static const uint8_t T1 = 1;
|
||||
static const uint8_t T2 = 2;
|
||||
static const uint8_t T3 = 3;
|
||||
static const uint8_t T4 = 4;
|
||||
static const uint8_t T5 = 5;
|
||||
static const uint8_t T6 = 6;
|
||||
static const uint8_t T7 = 7;
|
||||
static const uint8_t T8 = 8;
|
||||
static const uint8_t T9 = 9;
|
||||
static const uint8_t T10 = 10;
|
||||
static const uint8_t T11 = 11;
|
||||
static const uint8_t T12 = 12;
|
||||
static const uint8_t T13 = 13;
|
||||
static const uint8_t T14 = 14;
|
||||
|
||||
#endif /* Pins_Arduino_h */
|
||||
130
variants/esp32s3/seeed-sensecap-indicator/platformio.ini
Normal file
130
variants/esp32s3/seeed-sensecap-indicator/platformio.ini
Normal file
@@ -0,0 +1,130 @@
|
||||
; Seeed Studio SenseCAP Indicator
|
||||
[env:seeed-sensecap-indicator]
|
||||
extends = esp32s3_base
|
||||
platform =
|
||||
;https://github.com/pioarduino/platform-espressif32/releases/download/stable/platform-espressif32.zip
|
||||
https://github.com/pioarduino/platform-espressif32.git#develop
|
||||
;symlink:///home/manuel/Documents/PlatformIO/Projects/platform-espressif32
|
||||
platform_packages =
|
||||
;platformio/framework-arduinoespressif32-libs@https://dl.espressif.com/AE/esp-arduino-libs/esp32-3.2.0-h.zip
|
||||
platformio/framework-arduinoespressif32 @ https://github.com/mverch67/arduino-esp32/archive/919e485187a77b62b93f9b7fa09f43a8eeceaa44.zip
|
||||
;platformio/framework-arduinoespressif32 @ symlink:///home/manuel/Documents/PlatformIO/Projects/arduino-esp32
|
||||
|
||||
board = seeed-sensecap-indicator
|
||||
board_check = true
|
||||
upload_protocol = esptool
|
||||
|
||||
build_unflags =
|
||||
-DCONFIG_BT_NIMBLE_ENABLED
|
||||
-DCONFIG_NIMBLE_CPP_LOG_LEVEL=2
|
||||
-DCONFIG_BT_NIMBLE_MAX_CCCDS=20
|
||||
-DCONFIG_BT_NIMBLE_HOST_TASK_STACK_SIZE=8192
|
||||
|
||||
build_flags = ${esp32_base.build_flags} -D lcd_periph_signals=lcd_periph_rgb_signals -mtext-section-literals -ffat-lto-objects
|
||||
-Ivariants/esp32s3/seeed-sensecap-indicator
|
||||
-DSENSECAP_INDICATOR
|
||||
-DCONFIG_ARDUHAL_LOG_COLORS
|
||||
-DRADIOLIB_DEBUG_SPI=0
|
||||
-DRADIOLIB_DEBUG_PROTOCOL=0
|
||||
-DRADIOLIB_DEBUG_BASIC=0
|
||||
-DRADIOLIB_VERBOSE_ASSERT=0
|
||||
-DRADIOLIB_SPI_PARANOID=0
|
||||
-DIO_EXPANDER=0x40
|
||||
-DIO_EXPANDER_IRQ=42
|
||||
;-DIO_EXPANDER_DEBUG
|
||||
-DUSE_ARDUINO_HAL_GPIO
|
||||
|
||||
lib_deps = ${esp32s3_base.lib_deps}
|
||||
https://github.com/mverch67/LovyanGFX/archive/502127dfe28ab766b7ce7ba6470175ab6c9c1288.zip
|
||||
|
||||
custom_component_remove =
|
||||
espressif/esp_hosted
|
||||
espressif/esp_wifi_remote
|
||||
espressif/esp-dsp
|
||||
espressif/esp32-camera
|
||||
espressif/libsodium
|
||||
espressif/esp-modbus
|
||||
espressif/qrcode
|
||||
espressif/esp_insights
|
||||
espressif/esp_diag_data_store
|
||||
espressif/esp_diagnostics
|
||||
espressif/esp_rainmaker
|
||||
espressif/rmaker_common
|
||||
|
||||
custom_sdkconfig =
|
||||
CONFIG_SPIRAM_MODE_OCT=y
|
||||
CONFIG_SPIRAM_SPEED_120M=y
|
||||
CONFIG_LCD_RGB_ISR_IRAM_SAFE=y
|
||||
CONFIG_GDMA_CTRL_FUNC_IN_IRAM=y
|
||||
CONFIG_I2S_ISR_IRAM_SAFE=y
|
||||
CONFIG_GDMA_ISR_IRAM_SAFE=y
|
||||
CONFIG_SPIRAM_XIP_FROM_PSRAM=y
|
||||
CONFIG_SPIRAM_FETCH_INSTRUCTIONS=y
|
||||
CONFIG_SPIRAM_RODATA=y
|
||||
CONFIG_ESP32S3_DEFAULT_CPU_FREQ_240=y
|
||||
CONFIG_ESP32S3_DATA_CACHE_64KB=y
|
||||
CONFIG_ESP32S3_DATA_CACHE_LINE_64B=y
|
||||
CONFIG_I2C_SKIP_LEGACY_CONFLICT_CHECK=y
|
||||
CONFIG_FREERTOS_PLACE_FUNCTIONS_INTO_FLASH=y
|
||||
CONFIG_FREERTOS_PLACE_SNAPSHOT_FUNS_INTO_FLASH=y
|
||||
CONFIG_RINGBUF_PLACE_FUNCTIONS_INTO_FLASH=y
|
||||
CONFIG_ESP_SYSTEM_ESP32_SRAM1_REGION_AS_IRAM=y
|
||||
CONFIG_ESP_WIFI_IRAM_OPT=n
|
||||
CONFIG_ESP32_WIFI_RX_IRAM_OPT=n
|
||||
CONFIG_SPIRAM_CACHE_LIBCHAR_IN_IRAM=n
|
||||
CONFIG_SPIRAM_CACHE_LIBSTR_IN_IRAM=n
|
||||
CONFIG_SPIRAM_CACHE_LIBMISC_IN_IRAM=n
|
||||
CONFIG_SPIRAM_CACHE_LIBTIME_IN_IRAM=n
|
||||
CONFIG_HAL_DEFAULT_ASSERTION_LEVEL=0
|
||||
CONFIG_ESPTOOLPY_FLASHSIZE_8MB=y
|
||||
CONFIG_BT_ENABLED=y
|
||||
CONFIG_BT_NIMBLE_ENABLED=y
|
||||
CONFIG_BT_BLUEDROID_ENABLED=y
|
||||
CONFIG_BT_CONTROLLER_ENABLED=y
|
||||
CONFIG_BT_NIMBLE_HOST_TASK_STACK_SIZE=8192
|
||||
CONFIG_BT_NIMBLE_MAX_CCCDS=20
|
||||
CONFIG_BT_NIMBLE_CPP_LOG_LEVEL=2
|
||||
|
||||
[env:seeed-sensecap-indicator-tft]
|
||||
extends = env:seeed-sensecap-indicator
|
||||
board_level = pr
|
||||
upload_speed = 460800
|
||||
|
||||
build_flags =
|
||||
${env:seeed-sensecap-indicator.build_flags}
|
||||
-D INPUTDRIVER_BUTTON_TYPE=38
|
||||
-D MESHTASTIC_EXCLUDE_I2C=1
|
||||
-D MESHTASTIC_EXCLUDE_WEBSERVER=1
|
||||
-D MESHTASTIC_EXCLUDE_SERIAL=1
|
||||
-D MESHTASTIC_EXCLUDE_SOCKETAPI=1
|
||||
-D MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR=1
|
||||
-D MESHTASTIC_EXCLUDE_WIFI=1 ; workaround due to duplicated definitions of Syslog
|
||||
-D HAS_TELEMETRY=0
|
||||
-D CONFIG_DISABLE_HAL_LOCKS=1
|
||||
-D HAS_SCREEN=1
|
||||
-D HAS_TFT=1
|
||||
-D DISPLAY_SET_RESOLUTION
|
||||
-D RAM_SIZE=4096
|
||||
-D LV_LVGL_H_INCLUDE_SIMPLE
|
||||
-D LV_CONF_INCLUDE_SIMPLE
|
||||
-D LV_COMP_CONF_INCLUDE_SIMPLE
|
||||
-D LV_USE_SYSMON=0
|
||||
-D LV_USE_PROFILER=0
|
||||
-D LV_USE_PERF_MONITOR=0
|
||||
-D LV_USE_MEM_MONITOR=0
|
||||
-D LV_USE_LOG=0
|
||||
-D USE_LOG_DEBUG
|
||||
-D LOG_DEBUG_INC=\"DebugConfiguration.h\"
|
||||
-D CUSTOM_TOUCH_DRIVER
|
||||
-D LGFX_SCREEN_WIDTH=480
|
||||
-D LGFX_SCREEN_HEIGHT=480
|
||||
-D DISPLAY_SIZE=480x480
|
||||
-D LGFX_DRIVER=LGFX_INDICATOR
|
||||
-D GFX_DRIVER_INC=\"graphics/LGFX/LGFX_INDICATOR.h\"
|
||||
-D VIEW_320x240
|
||||
-D USE_PACKET_API
|
||||
|
||||
lib_deps =
|
||||
${env:seeed-sensecap-indicator.lib_deps}
|
||||
${device-ui_base.lib_deps}
|
||||
https://github.com/mverch67/bb_captouch/archive/8626412fe650d808a267791c0eae6e5860c85a5d.zip ; alternative touch library supporting FT6x36
|
||||
80
variants/esp32s3/seeed-sensecap-indicator/variant.h
Normal file
80
variants/esp32s3/seeed-sensecap-indicator/variant.h
Normal file
@@ -0,0 +1,80 @@
|
||||
#define I2C_SDA 39
|
||||
#define I2C_SCL 40
|
||||
|
||||
// This board has a serial coprocessor for sensor readings
|
||||
#define SENSOR_RP2040_TXD 19
|
||||
#define SENSOR_RP2040_RXD 20
|
||||
#define SENSOR_PORT_NUM UART_NUM_2
|
||||
#define SENSOR_BAUD_RATE 115200
|
||||
|
||||
#define BUTTON_PIN 38
|
||||
#define BUTTON_ACTIVE_LOW true
|
||||
#define BUTTON_ACTIVE_PULLUP true
|
||||
|
||||
// #define BUTTON_NEED_PULLUP
|
||||
|
||||
// #define BATTERY_PIN 27 // A battery voltage measurement pin, voltage divider connected here to measure battery voltage
|
||||
// #define ADC_CHANNEL ADC1_GPIO27_CHANNEL
|
||||
// #define ADC_MULTIPLIER 2
|
||||
|
||||
// ST7701 TFT LCD
|
||||
#define ST7701_CS (4 | IO_EXPANDER)
|
||||
#define ST7701_RS -1 // DC
|
||||
#define ST7701_SDA 48 // MOSI
|
||||
#define ST7701_SCK 41
|
||||
#define ST7701_RESET (5 | IO_EXPANDER)
|
||||
#define ST7701_MISO 47
|
||||
#define ST7701_BUSY -1
|
||||
#define ST7701_BL 45
|
||||
#define ST7701_SPI_HOST SPI2_HOST
|
||||
#define ST7701_BACKLIGHT_EN 45
|
||||
#define SPI_FREQUENCY 12000000
|
||||
#define TFT_HEIGHT 480
|
||||
#define TFT_WIDTH 480
|
||||
#define TFT_OFFSET_X 0
|
||||
#define TFT_OFFSET_Y 0
|
||||
#define TFT_OFFSET_ROTATION 0
|
||||
#define TFT_BL 45
|
||||
#define SCREEN_ROTATE
|
||||
#define SCREEN_TRANSITION_FRAMERATE 5 // fps
|
||||
|
||||
#define HAS_TOUCHSCREEN 1
|
||||
#define SCREEN_TOUCH_INT (6 | IO_EXPANDER)
|
||||
#define SCREEN_TOUCH_RST (7 | IO_EXPANDER)
|
||||
#define TOUCH_I2C_PORT 0
|
||||
#define TOUCH_SLAVE_ADDRESS 0x48
|
||||
|
||||
// in future, we may want to add a buzzer and add all sensors to the indicator via a data protocol for now only GPS is supported
|
||||
// // Buzzer
|
||||
// #define PIN_BUZZER 19
|
||||
|
||||
#define GPS_DEFAULT_NOT_PRESENT 1
|
||||
#define GPS_RX_PIN 20
|
||||
#define GPS_TX_PIN 19
|
||||
#define HAS_GPS 1
|
||||
|
||||
#define USE_SX1262
|
||||
#define USE_SX1268
|
||||
|
||||
#define LORA_SCK 41
|
||||
#define LORA_MISO 47
|
||||
#define LORA_MOSI 48
|
||||
#define LORA_CS (0 | IO_EXPANDER)
|
||||
|
||||
#define LORA_DIO0 -1 // a no connect on the SX1262 module
|
||||
#define LORA_RESET (1 | IO_EXPANDER)
|
||||
#define LORA_DIO1 (3 | IO_EXPANDER) // SX1262 IRQ
|
||||
#define LORA_DIO2 (2 | IO_EXPANDER) // SX1262 BUSY
|
||||
#define LORA_DIO3
|
||||
|
||||
#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 TCXO_OPTIONAL // handle Indicator V1 and V2
|
||||
#define SX126X_DIO3_TCXO_VOLTAGE 2.4
|
||||
|
||||
#define USE_VIRTUAL_KEYBOARD 1
|
||||
#define DISPLAY_CLOCK_FRAME 1
|
||||
Reference in New Issue
Block a user