Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blue and red inverted #3

Closed
edo44 opened this issue Feb 9, 2023 · 10 comments
Closed

Blue and red inverted #3

edo44 opened this issue Feb 9, 2023 · 10 comments

Comments

@edo44
Copy link

edo44 commented Feb 9, 2023

I have the two colors inverted for some reason when using LVGL. Any help?

@rzeldent
Copy link
Owner

rzeldent commented Feb 9, 2023

Hi Edo,

You can try to change the MADCTL value. This is currently defined like this (depending on the orientation)
static const uint8_t madctl[] = {MADCTL_MY | MADCTL_RGB}; // Portrait 0 Degrees

so change the color channels to BGR:
static const uint8_t madctl[] = {MADCTL_MY | MADCTL_BGR}; // Portrait 0 Degrees

Let me know if this helps. What are you using as display board?

@edo44
Copy link
Author

edo44 commented Feb 9, 2023

yep, that solves the problem, thank you very much

ESP32_3248S035C

@rzeldent
Copy link
Owner

Strange, I have also a ESP32_3248S035C and this worked with the MADCTL_RGB settings.
Maybe there are different panels? Maybe need to be configurable in the defines...

@edo44
Copy link
Author

edo44 commented Feb 10, 2023

Strange, I have also a ESP32_3248S035C and this worked with the MADCTL_RGB settings. Maybe there are different panels? Maybe need to be configurable in the defines...

photo_2023-02-10_16-33-11

how do I check if panels are different

@rzeldent
Copy link
Owner

PXL_20230210_153958557.jpg

@rzeldent
Copy link
Owner

This is mine; they look identical. I suspect the LCD panel might be another type....
Maybe some other users can share if they've also this problem?

@edo44
Copy link
Author

edo44 commented Feb 10, 2023

immagine

@rzeldent
Copy link
Owner

This is the capacitive touch controller

@edo44
Copy link
Author

edo44 commented Feb 10, 2023

This is the capacitive touch controller

I see, I thought it was the tft screen controller

@rzeldent
Copy link
Owner

Hi edo,

Made this setting an optional define and pushed a new version (1.0.4) to PlatformIO.

Enjoy!

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

No branches or pull requests

2 participants