I've got a display working with the gLCD_ILI9341_SPI1 component.
It's a 240/320 display like this one: https://nl.aliexpress.com/item/10050016 ... pt=glo2nld
But, maybe my fault: the R and B in the setForeGround macro are switched?
If I set the R to 255 and the rest to zero, I would suspect that I would get a red foreground? No it's 100% blue.
Same when I set B to 255 and the rest to zero... 100% red...
The green is OK but the R and B seem to be switched.
If I "invert the colours" in the gLCD_ILI9341_SPI1 component properties I get all messed up colours.
I need to see if the same issue is there in the background colours..
Is this a known issue? Or am I doing something wrong?
R/B in gLCD_ILI9341 component?
-
- Posts: 353
- http://meble-kuchenne.info.pl
- Joined: Tue Dec 08, 2020 5:11 pm
- Has thanked: 101 times
- Been thanked: 70 times
-
- Matrix Staff
- Posts: 1952
- Joined: Mon Dec 07, 2020 10:06 am
- Has thanked: 510 times
- Been thanked: 698 times
Re: R/B in gLCD_ILI9341 component?
Hello,
Looking at the component code it seems to correspond to the datasheet where it first sends red (MSb), then green and then blue (LSb) for each pixel.
It could be the display manufacturer has wired up the blue LEDs to the red channel. I'll add in a property to allow the colours to be switched.
Edit this is now live via the update system.
Looking at the component code it seems to correspond to the datasheet where it first sends red (MSb), then green and then blue (LSb) for each pixel.
It could be the display manufacturer has wired up the blue LEDs to the red channel. I'll add in a property to allow the colours to be switched.
Edit this is now live via the update system.
Regards Ben Rowland - MatrixTSL
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel