feat(rlcd): Waveshare ESP32-S3-RLCD-4.2 support on latest main
- ST7305 driver with persistent 15KB DMA buffer (fix use-after-free +
WDT lockup that caused freeze after flash)
- Reset timing fix: 150ms after reset, 50ms after init
- DTS: i2s0 mclk 16, bclk 9, ws 45, out 8, in 10 - fixes GPIO5 conflict
- i2c0 uses esp32-i2c-master, SDMMC 1-bit
- device.properties: colorDepth 16, fontSize 20, DefaultDark
- Amp GPIO46 init in initBoot
- Buttons: two-button control GPIO18 (cycle) + GPIO0 (select)
Base: origin/main f9453d89
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
#include "Display.h"
|
||||
#include <St7305Display.h>
|
||||
|
||||
std::shared_ptr<tt::hal::display::DisplayDevice> createDisplay() {
|
||||
auto configuration = std::make_unique<St7305Display::Configuration>(
|
||||
SPI2_HOST,
|
||||
GPIO_NUM_40, // CS
|
||||
GPIO_NUM_5, // DC
|
||||
400, // Width
|
||||
300, // Height
|
||||
nullptr, // Touch device
|
||||
false, // swapXY
|
||||
false, // mirrorX
|
||||
false, // mirrorY
|
||||
true, // invertColor - initial true to match existing inverted look, user can toggle via Settings->Display
|
||||
0 // bufferSize (0 = default, which is full screen = 120,000 pixels)
|
||||
);
|
||||
|
||||
configuration->resetPin = GPIO_NUM_41;
|
||||
|
||||
auto display = std::make_shared<St7305Display>(std::move(configuration));
|
||||
return std::reinterpret_pointer_cast<tt::hal::display::DisplayDevice>(display);
|
||||
}
|
||||
Reference in New Issue
Block a user