ST7789v In imx8mm

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ST7789v In imx8mm

546 Views
Udhay_
Contributor III

Hello,

we are interfacing SPI communication in st7789v.

      

&ecspi2 {
#address-cells = <1>;
#size-cells = <0>;
fsl,spi-num-chipselects = <1>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_ecspi2 &pinctrl_ecspi2_cs>;
cs-gpios = <&gpio5 13 GPIO_ACTIVE_LOW>;
status = "okay";

spidev0: spi@0 {
reg = <0>;
compatible = "sitronix,st7789v";
spi-max-frequency = <500000>;
};
}; This is my node


but im getting no data/signal

can anyone please tell me how to interface spi in imx8mm

Regards,

Udhayamoorthi Ramasamy

0 Kudos
Reply
2 Replies

521 Views
Alejandro_Salas
NXP TechSupport
NXP TechSupport

Hello @Udhay_ 

I hope you are doing well.

 

An example of ECSPI implementation on i.MX8MM can be found here:

https://github.com/boundarydevices/linux/blob/boundary-imx_4.14.x_1.0.0_ga/arch/arm64/boot/dts/frees...

 

If you are using the IMX8MM as slave, we have an application note (AN13633).

 

I hope this can helps to you.

 

Best regards.

 

Salas.

0 Kudos
Reply

446 Views
Udhay_
Contributor III

Hello @Alejandro_Salas 

I have followed that you have shared me based on that i changed the dtsi node

Here is my node

 

panel: panel@0{

		compatible = "sitronix,st7789v";
		reg = <0>; // Chip Select 0

		spi-max-frequency = <32000000>; // 32MHz
		
		reset-gpios = <&gpio5 26 GPIO_ACTIVE_HIGH>;
		dc-gpios = <&gpio5 27 GPIO_ACTIVE_HIGH>;

		spi-cpol;
		spi-cpha;
		
		width = <320>;
		height = <240>;
		buswidth = <8>; // Most controllers use this value

		rotate = <1>;

		debug = <0x4000000>;  // Print init commands to the kernel log
		
	};
/*
	spidev0: spi@0 {
		reg = <0>;
		compatible = "rohm,dh2228fv";
		spi-max-frequency = <500000>;
	};
*/
};

 


1. Even if I am not physically connecting the ST7789V to the i.MX8MM, the SPI communication appears to be probed. How can I confirm whether the SPI communication with the ST7789V is indeed happening through the i.MX8MM?

2. Also st7789v_prepare function is not called after st7789v_probe function in panel-sitronix-st7789v.c 

Regards,

Udhayamoorthi Ramasamy

 

0 Kudos
Reply