tlora-t3s3-epaper: e-ink startup and build cleanup (#10973)

* T3s3 Eink

* Update SerialConsole.cpp

* Update

* Update SerialConsole.h

* Update EInkDisplay2.cpp
This commit is contained in:
HarukiToreda
2026-07-10 05:50:30 -05:00
committed by GitHub
parent 9060ab4418
commit f4efbd9149
5 changed files with 49 additions and 6 deletions
+7 -1
View File
@@ -64,4 +64,10 @@ bool fsFormat();
std::vector<meshtastic_FileInfo> getFiles(const char *dirname, uint8_t levels, size_t maxCount = 64, bool *wasLimited = nullptr);
void listDir(const char *dirname, uint8_t levels, bool del = false);
void rmDir(const char *dirname);
void setupSDCard();
void setupSDCard();
#if defined(HAS_SDCARD) && !defined(SDCARD_USE_SOFT_SPI) && defined(SDCARD_USE_SPI1)
#include <SPI.h>
// HSPI bus set up by setupSDCard(). Reuse this for other devices on the same bus.
extern SPIClass SPI_HSPI;
#endif
+15
View File
@@ -2,6 +2,7 @@
#if defined(USE_EINK) && !defined(USE_EINK_PARALLELDISPLAY)
#include "EInkDisplay2.h"
#include "FSCommon.h"
#include "SPILock.h"
#include "main.h"
#include <SPI.h>
@@ -214,9 +215,23 @@ bool EInkDisplay::connect()
defined(CROWPANEL_ESP32S3_5_EPAPER) || defined(CROWPANEL_ESP32S3_4_EPAPER) || defined(CROWPANEL_ESP32S3_2_EPAPER) || \
defined(MINI_EPAPER_S3)
{
#if defined(TLORA_T3S3_EPAPER)
// T3-S3 shares HSPI with the SD card; preconfigure the panel control pins.
hspi = &SPI_HSPI;
pinMode(PIN_EINK_CS, OUTPUT);
pinMode(PIN_EINK_DC, OUTPUT);
pinMode(PIN_EINK_BUSY, INPUT);
if (PIN_EINK_RES >= 0) {
pinMode(PIN_EINK_RES, OUTPUT);
digitalWrite(PIN_EINK_RES, HIGH);
}
digitalWrite(PIN_EINK_CS, HIGH);
digitalWrite(PIN_EINK_DC, HIGH);
#else
// Start HSPI
hspi = new SPIClass(HSPI);
hspi->begin(PIN_EINK_SCLK, -1, PIN_EINK_MOSI, PIN_EINK_CS); // SCLK, MISO, MOSI, SS
#endif
// VExt already enabled in setup()
// RTC GPIO hold disabled in setup()
+17 -2
View File
@@ -1,7 +1,22 @@
[inkhud]
build_src_filter =
build_src_filter =
+<graphics/niche/>; Include the nicheGraphics directory
build_flags =
-<graphics/draw/> ; BaseUI renderer stack is disabled for InkHUD
-<graphics/fonts/> ; InkHUD uses GFX_Root fonts instead of BaseUI font tables
-<graphics/EInkDisplay2.cpp> ; InkHUD drives e-ink through niche drivers
-<graphics/EInkDynamicDisplay.cpp>
-<graphics/EInkParallelDisplay.cpp>
-<graphics/EmoteRenderer.cpp>
-<graphics/emotes.cpp>
-<graphics/Panel_sdl.cpp>
-<graphics/ScreenGlobals.cpp>
-<graphics/SharedUIDisplay.cpp>
-<graphics/TFTColorRegions.cpp>
-<graphics/TFTDisplay.cpp>
-<graphics/tftSetup.cpp>
-<graphics/TimeFormatters.cpp>
-<graphics/VirtualKeyboard.cpp>
build_flags =
-D MESHTASTIC_INCLUDE_NICHE_GRAPHICS ; Use NicheGraphics
-D MESHTASTIC_INCLUDE_INKHUD ; Use InkHUD (a NicheGraphics UI)
-D MESHTASTIC_EXCLUDE_SCREEN ; Suppress default Screen class