Skip to content

WIP: Big Display Node#10926

Open
caveman99 wants to merge 3 commits into
developfrom
hub75
Open

WIP: Big Display Node#10926
caveman99 wants to merge 3 commits into
developfrom
hub75

Conversation

@caveman99

@caveman99 caveman99 commented Jul 7, 2026

Copy link
Copy Markdown
Member

Utilizing HUB75 display with DMA refresh

Summary by CodeRabbit

  • New Features

    • Added HUB75 RGB matrix display support on ESP32-S3, including a new visualizer build option.
    • Implemented a HUB75 display driver with theme-based color output and support for display on/off.
    • Added board-specific configuration for HUB75 control pins, default brightness, and LoRa-related pin mappings.
  • Bug Fixes

    • Improved frame rendering by skipping unchanged pixels via dirty-diff and handling first-frame/theme changes.
    • Added brightness updates that apply immediately, and ensured proper buffer clearing between frames.

@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

⚡ Try this PR in the Web Flasher

Flash this PR in the Web Flasher

firmware commit boards expires

Warning

This is an automated, unreviewed CI test build. Back up your device configuration
before flashing, and only flash devices you are able to recover.

Supported boards built by this PR (27)
Device Board Platform
Crowpanel Adv 3.5 TFT elecrow-adv-35-tft esp32-s3
Heltec HT62 heltec-ht62-esp32c3-sx1262 esp32-c3
Heltec Mesh Node 096 heltec-mesh-node-t096 nrf52840
Heltec Mesh Node T1 heltec-mesh-node-t1 nrf52840
Heltec Mesh Node T114 heltec-mesh-node-t114 nrf52840
Heltec V3 heltec-v3 esp32-s3
Heltec V4 heltec-v4 esp32-s3
Meshnology W10 meshnology_w10 esp32-s3
Raspberry Pi Pico pico rp2040
Raspberry Pi Pico W picow rp2040
RAK WisMesh Tag rak_wismeshtag nrf52840
RAK WisBlock 11200 rak11200 esp32
RAK WisBlock 11310 rak11310 rp2040
RAK3312 rak3312 esp32-s3
RAK WisBlock 4631 rak4631 nrf52840
Seeed SenseCAP Mesh-Tracker-X1 seeed_mesh_tracker_X1 nrf52840
Seeed Wio Tracker L1 seeed_wio_tracker_L1 nrf52840
Seeed Xiao NRF52840 Kit seeed_xiao_nrf52840_kit nrf52840
Seeed Xiao ESP32-S3 seeed-xiao-s3 esp32-s3
Station G2 station-g2 esp32-s3
Station G3 station-g3 esp32-s3
LILYGO T-Deck t-deck-tft esp32-s3
LILYGO T-Echo t-echo nrf52840
LILYGO T-Echo Plus t-echo-plus nrf52840
LILYGO T-Impulse Plus t-impulse-plus nrf52840
LilyGo T3-C6 tlora-c6 esp32-c6
Seeed SenseCAP T1000-E tracker-t1000-e nrf52840

Build artifacts expire on 2026-08-06. Updated for 2c2946c.

@github-actions github-actions Bot added needs-review Needs human review hardware-support Hardware related: new devices or modules, problems specific to hardware labels Jul 7, 2026
@coderabbitai

coderabbitai Bot commented Jul 7, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 64dadbc8-64e6-4640-bac2-95a532690a24

📥 Commits

Reviewing files that changed from the base of the PR and between beeb732 and 2c2946c.

📒 Files selected for processing (1)
  • src/graphics/HUB75Display.cpp
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/graphics/HUB75Display.cpp

📝 Walkthrough

Walkthrough

This PR adds a HUB75 RGB LED matrix display driver, wires it into Screen selection logic, and introduces a new ESP32-S3 visualizer-hub75 variant with matching PlatformIO settings and pin mappings.

Changes

HUB75 Display Driver

Layer / File(s) Summary
Class declaration
src/graphics/HUB75Display.h
Declares HUB75Display subclassing OLEDDisplay with display(), setDisplayBrightness(), protected overrides, and private matrix/brightness/frame state, guarded by USE_HUB75.
Constructor, destructor, and connect implementation
src/graphics/HUB75Display.cpp
Implements construction with geometry selection, destructor cleanup, and connect() with I2S config and matrix initialization.
Frame rendering and command handling
src/graphics/HUB75Display.cpp
Implements display() with per-pixel diffing, back-buffer comparison, TFT color region handling, and forced-redraw signature logic; sendCommand() maps DISPLAYON/OFF to brightness; setDisplayBrightness() updates live brightness.
Screen integration
src/graphics/Screen.cpp
Conditionally includes HUB75Display.h and adds a new #elif defined(USE_HUB75) branch in the Screen constructor to instantiate the driver.
Board variant and build config
variants/esp32s3/visualizer-hub75/platformio.ini, variants/esp32s3/visualizer-hub75/variant.h
Adds a new PlatformIO environment for ESP32-S3 with HUB75 library dependency and build flags, plus a variant header defining HUB75 pin mappings, brightness default, SX1262 LoRa pins, button/I2C pins, and heartbeat LED.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related PRs

  • meshtastic/firmware#10803: Both PRs modify src/graphics/Screen.cpp’s compile-time display-driver selection logic, so they overlap at the same branch point.
🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description is far too brief and does not fill the repository's required template or attestations. Replace it with the full PR template, including the attestations and any testing or regression notes.
Title check ❓ Inconclusive The title is related to the change but too generic to clearly describe the HUB75 DMA display work. Rename it to a concise title that mentions HUB75 display support with DMA refresh.
✅ Passed checks (3 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch hub75

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
src/graphics/HUB75Display.cpp (1)

44-46: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Trim the multi-line comment.

The single-buffer rationale spans three lines. As per coding guidelines, keep code comments to "one or two lines maximum."

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/graphics/HUB75Display.cpp` around lines 44 - 46, Trim the explanatory
comment in HUB75Display so it fits the one- or two-line guideline by shortening
the rationale around cfg.double_buff; keep only the essential single-buffer note
and remove the extra wrapped lines while preserving the meaning in the
HUB75Display setup code.

Source: Coding guidelines

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/graphics/HUB75Display.cpp`:
- Around line 48-56: `HUB75Display::connect()` leaves `matrix` allocated when
`MatrixPanel_I2S_DMA::begin()` fails, so subsequent `display()` and
`sendCommand()` calls can still use a half-initialized panel and the allocation
leaks. Update the failure path in `connect()` to clean up the `matrix` member by
deleting the failed `MatrixPanel_I2S_DMA` instance and resetting `matrix` to
null before returning false, keeping the existing success path unchanged.

---

Nitpick comments:
In `@src/graphics/HUB75Display.cpp`:
- Around line 44-46: Trim the explanatory comment in HUB75Display so it fits the
one- or two-line guideline by shortening the rationale around cfg.double_buff;
keep only the essential single-buffer note and remove the extra wrapped lines
while preserving the meaning in the HUB75Display setup code.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: d7b924b4-9f28-4403-b80d-6440b48122ad

📥 Commits

Reviewing files that changed from the base of the PR and between f250cf3 and beeb732.

📒 Files selected for processing (5)
  • src/graphics/HUB75Display.cpp
  • src/graphics/HUB75Display.h
  • src/graphics/Screen.cpp
  • variants/esp32s3/visualizer-hub75/platformio.ini
  • variants/esp32s3/visualizer-hub75/variant.h

Comment thread src/graphics/HUB75Display.cpp
@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Firmware Size Report

23 targets | vs develop: 21 increased, 1 decreased, net +422,872 (+413.0 KB)

Target Flash vs develop RAM RAM vs develop
picow 1,273,780 📈 +28,900 (+28.2 KB) 152,508 n/a
pico2w 1,248,288 📈 +27,772 (+27.1 KB) 158,988 n/a
rak11310 832,856 📈 +27,432 (+26.8 KB) 86,320 n/a
pico 810,104 📈 +27,416 (+26.8 KB) 85,876 n/a
seeed_xiao_rp2040 808,304 📈 +27,400 (+26.8 KB) 85,868 n/a
Show 18 more target(s)
Target Flash vs develop RAM RAM vs develop
pico2 796,232 📈 +26,456 (+25.8 KB) 92,376 n/a
seeed_xiao_rp2350 794,384 📈 +26,448 (+25.8 KB) 92,368 n/a
t-deck-tft 3,833,600 📈 +22,928 (+22.4 KB) 108,008 n/a
heltec-vision-master-e213-inkhud 2,249,136 📈 +21,776 (+21.3 KB) 92,408 n/a
elecrow-adv-35-tft 3,436,944 📈 +20,320 (+19.8 KB) 94,640 n/a
rak3312 2,290,272 📈 +18,032 (+17.6 KB) 102,032 n/a
heltec-ht62-esp32c3-sx1262 2,152,400 📈 +17,408 (+17.0 KB) 112,004 n/a
seeed-xiao-s3 2,293,392 📈 +17,248 (+16.8 KB) 102,064 n/a
station-g3 2,283,392 📈 +17,040 (+16.6 KB) 101,848 n/a
station-g2 2,283,376 📈 +17,024 (+16.6 KB) 101,848 n/a
rak11200 1,877,536 📈 +16,928 (+16.5 KB) 87,052 n/a
heltec-v3 2,280,992 📈 +16,912 (+16.5 KB) 130,232 n/a
t-eth-elite 2,507,648 📈 +16,160 (+15.8 KB) 103,068 n/a
heltec-v4 2,293,152 📈 +15,856 (+15.5 KB) 101,112 n/a
tlora-c6 2,384,000 📈 +15,696 (+15.3 KB) 102,764 n/a
rak3172 182,824 📉 -3,472 (-3.4 KB) 25,000 n/a
wio-e5 239,820 📈 +1,192 (+1.2 KB) 26,640 n/a
meshnology_w10 2,463,776 136,212 n/a

Size budgets

Env Metric Measured Budget Used
rak4631 RAM (.data+.bss) n/a 113,000 n/a
rak4631 flash n/a 786,000 n/a

Budgets live in bin/ram_budgets.json and are raised deliberately in the PR that needs the headroom - never automatically.


Updated for 4a84614

caveman99 and others added 2 commits July 7, 2026 22:11
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hardware-support Hardware related: new devices or modules, problems specific to hardware needs-review Needs human review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant