Skip to content

Move PSRAM request from DisplayApi to device.properties - #762

Merged
KenVanHoeylandt merged 4 commits into
mainfrom
display-lvgl-external-memory
Nov 18, 2026
Merged

KenVanHoeylandt merged 4 commits into
mainfrom
display-lvgl-external-memory

Conversation

@KenVanHoeylandt

@KenVanHoeylandt KenVanHoeylandt commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

A driver shouldn't request an LVGL behaviour. It's a device-specific setting. DTS isn't the right place for it either, because it is only relevant for the LVGL subsystem that might not even exit.

Hence the setting is moved to Kconfig and determined by device.properties, processed by device.py

Summary by CodeRabbit

  • New Features

    • Added a global option to allocate LVGL draw buffers from external RAM, with per-device settings available for supported devices.
    • Enabled external RAM preference on additional devices.
  • Changes

    • Updated display memory guidance and allocation behavior. Display drivers no longer advertise an external-RAM preference; buffer allocation is controlled by configuration instead.

@coderabbitai

coderabbitai Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

Explain Change →

Walkthrough

The changes add a Kconfig option for LVGL external RAM preference, defaulting to disabled. Device properties can set the option to true or false, and LVGL now uses that setting instead of display capabilities. Affected display drivers no longer advertise the removed capability. Multiple device properties enable the preference; one also sets the LVGL font size to 18. Three TODO entries were removed from the ideas document.

Merge Risk: Low · up to 1c648

The LVGL PSRAM preference now comes from device.properties instead of the display driver. Devices that use direct DMA from external-RAM buffers need the documented cache synchronization or the displayed pixels may be stale. Merge risk is low; document or verify the coherency requirement for esp-mosaico.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title names the main change: the PSRAM (external RAM) request for LVGL moves from DisplayApi to device.properties. The raw summary confirms this. Each device.properties gains lvgl.preferExternalRa…
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.
Full details: Title check

Explanation

The title names the main change: the PSRAM (external RAM) request for LVGL moves from DisplayApi to device.properties. The raw summary confirms this. Each device.properties gains lvgl.preferExternalRam, DISPLAY_CAPABILITY_PREFER_EXTERNAL_RAM is removed from the drivers and the enum, and device.py and Kconfig now carry the setting. The title is concise and specific to the primary change.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@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: 2

Review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 66b8d316-8b15-4020-ac1e-c76fa4a66973
Commits

Reviewing files that changed from the base of the PR and between 5310658 and 764c8c3.

Files selected for processing: 34

  • Devices/btt-panda-touch/device.properties
  • Devices/cl32-v02-v03/device.properties
  • Devices/cyd-4827s043c/device.properties
  • Devices/cyd-8048s043c/device.properties
  • Devices/elecrow-crowpanel-advance-50/device.properties
  • Devices/elecrow-crowpanel-basic-50/device.properties
  • Devices/espressif-esp-mosaico/device.properties
  • Devices/espressif-esp32-s31-korvo-1/device.properties
  • Devices/guition-jc8048w550c/device.properties
  • Devices/lilygo-t5-epd47-s3/device.properties
  • Devices/lilygo-tdeck-max/device.properties
  • Devices/lilygo-tdeck-pro/device.properties
  • Devices/m5stack-papers3/device.properties
  • Devices/m5stack-papers3/source/drivers/papers3_display.cpp
  • Devices/tulip-4r11/device.properties
  • Devices/waveshare-esp32-s3-epaper-397/device.properties
  • Devices/waveshare-s3-touch-amoled-206/device.properties
  • Devices/waveshare-s3-touch-lcd-43/device.properties
  • Drivers/co5300-module/bindings/chipone,co5300.yaml
  • Drivers/co5300-module/source/co5300.cpp
  • Drivers/lilygo-t5s3-epd-module/source/t5s3_display.cpp
  • Drivers/lilygo-t5s3-epd-module/source/t5s3_display_bw.cpp
  • Drivers/rgb-display-module/source/rgb_display.cpp
  • Drivers/sh8601-module/source/sh8601.cpp
  • Drivers/ssd1677-module/source/ssd1677.cpp
  • Drivers/ssd16xx-module/source/ssd16xx.cpp
  • Drivers/st7305-module/source/st7305.cpp
  • Drivers/uc8253-module/source/uc8253.cpp
  • Modules/lvgl-module/include/lvgl/devices/display.h
  • Modules/lvgl-module/source/devices/devices.cpp
  • Modules/lvgl-module/source/devices/display.cpp
  • Tactility/Kconfig
  • TactilityKernel/include/tactility/drivers/display.h
  • device.py
Files with no reviewable changes: 1

  • Drivers/co5300-module/bindings/chipone,co5300.yaml

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

@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

Review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 616d5efe-695f-48c3-ba3b-4e7fea64d707
Commits

Reviewing files that changed from the base of the PR and between 764c8c3 and 1c648de.

Files selected for processing: 3

  • Devices/cl32-v04/device.properties
  • Documentation/ideas.md
  • Modules/lvgl-module/include/lvgl/devices/display.h
Files with no reviewable changes: 1

  • Documentation/ideas.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 2 remain after this review.

@KenVanHoeylandt
KenVanHoeylandt merged commit b2ab8cf into main Nov 18, 2026
84 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant