fb_st7789v.c in kernel 5.10 the color was swapped
tuanphan1790 opened this issue · 1 comments
Hi there,
I'm working with LCD via st7789v. I've already connected to my board. The device tree show below:
`spi0: spi@400 {
compatible = "microchip,sam9x60-spi", "atmel,at91rm9200-spi";
reg = <0x400 0x200>;
interrupts = <13 IRQ_TYPE_LEVEL_HIGH 7>;
clocks = <&pmc PMC_TYPE_PERIPHERAL 13>;
clock-names = "spi_clk";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_flx4_default>;
atmel,fifo-size = <16>;
#address-cells = <1>;
#size-cells = <0>;
status = "okay";
lcd@0 {
compatible = "sitronix,st7789v";
buswidth = <8>;
reg = <0>;
pinctrl-name = "default";
spi-max-frequency = <40000000>;
spi-cpol;
spi-cpha;
rotate = <0>;
rgb;
fps = <50>;
reset-gpios= <&pioA 2 0>;
dc-gpios = <&pioA 3 0>;
debug = <5>;
status = "okay";
};
};
`
But when I try to run simple app by QT5 on board to display a picture, the color was swapped (white->black, yellow->blue...). I searched some topics about this problem but I can't find solution. Can anyone help me?
Any suggestion would be appreciate!
I've already fixed by setting
tft.invertDisplay(0);