Skip to content

Use better defines for TFT_LVGL_UI: SPI and FSMC version#23

Merged
makerbase-mks merged 1 commit intomakerbase-mks:bugfix-2.0.xfrom
rhapsodyv:tft_lvgl_ui_defines
Jul 25, 2020
Merged

Use better defines for TFT_LVGL_UI: SPI and FSMC version#23
makerbase-mks merged 1 commit intomakerbase-mks:bugfix-2.0.xfrom
rhapsodyv:tft_lvgl_ui_defines

Conversation

@rhapsodyv
Copy link

Description

LVGL UI have two versions: SPI (used in Nano v2.0) and FSMC (used in Nano v1.2 and Chitu).

Before this PR, to use the FSMC version, you define TFT_LVGL_UI, but to use the SPI version, you had to define both: TFT_LVGL_UI and SPI_GRAPHICAL_TFT.

It can lead to confusion, because Marlin has other similar define: FSMC_GRAPHICAL_TFT, the emulated DOGM using FSMC. And SPI_GRAPHICAL_TFT looks like its the DOGM, but using SPI...

So, I changed the LVGL UI defines to better match with what Marlin follows. Now we have:

  • TFT_LVGL_UI_FSMC -> LVGL for FSMC displays
  • TFT_LVGL_UI_SPI -> LVGL for SPI displays

I removed references for SPI_GRAPHICAL_TFT, as in the future we may have a emulated DOGM using SPI, and can use that define when appropriated.

Benefits

  • Follow the Marlin Standards
  • Less confusion

@makerbase-mks makerbase-mks merged commit 4dc81cd into makerbase-mks:bugfix-2.0.x Jul 25, 2020
@rhapsodyv rhapsodyv deleted the tft_lvgl_ui_defines branch October 25, 2020 00:27
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.

2 participants