RK integrated SIS touch screen

Mainly the sis.i2c.c file integrating the SIS touch screen

 Get the files provided by the manufacturer and import them into the corresponding directory.

Modify the corresponding kconfig


menu "SiS touchscreen series"
choice
	prompt "SiS controller select"
	default y

config TOUCHSCREEN_SIS_I2C_92XX
	bool "SiS92xx series I2C touchscreen driver"
	depends on I2C
	help
	  Say Y here to enable support for I2C connected SiS touchscreen.

	  If unsure, say N.
	  
	  To compile this driver as a module, choose M here: the
	  module will be called sis_i2c.

config TOUCHSCREEN_SIS_I2C_95XX
	bool "SiS95xx series I2C touchscreen driver"
	depends on I2C
	help
	  Say Y here to enable support for I2C connected SiS touchscreen.

	  If unsure, say N.
	  
	  To compile this driver as a module, choose M here: the
	  module will be called sis_i2c.

endchoice

if TOUCHSCREEN_SIS_I2C_92XX || TOUCHSCREEN_SIS_I2C_95XX
config REG_BY_BOARDINFO
	bool "Using boardinfo setting (Disable if using DTS)"
	default n
	help
		This option is for boardinfo, please disable when using DTS.

if REG_BY_BOARDINFO
config GPIO_INT_PIN_FOR_SIS
	int "Enter the interrupt pin"
	default 123
	help
		Configure GPIO pin used for interrupt from SiS 
		by entering unmber in dec in decimal format.
		
endif
endif
endmenu

Modify makefile

obj-$(CONFIG_TOUCHSCREEN_SIS_I2C_92XX)   += sis_i2c.o
obj-$(CONFIG_TOUCHSCREEN_SIS_I2C_95XX)   += sis_i2c.o

Modify dts and add sis_touchscreen

	sis_touchscreen@5c {
	       compatible = "sis,sis_touch";
	       reg = <0x5c>;
	       touch-gpio = <&gpio1 GPIO_B0 GPIO_ACTIVE_LOW>;
	       reset-gpio = <&gpio0 GPIO_D1 IRQ_TYPE_EDGE_RISING>;
	       status = "okay";
	};

Modify defconfig and add sis

CONFIG_TOUCHSCREEN_SIS_I2C_95XX=y

 

 The SIS document says that it needs to be modified, but I did not modify it and it still runs normally. ueventd.rc

/dev/null                 0666   root       root
/dev/zero                 0666   root       root
/dev/full                 0666   root       root
/dev/ptmx                 0666   root       root
/dev/tty                  0666   root       root
/dev/random               0666   root       root
/dev/urandom              0666   root       root
/dev/ashmem               0666   root       root
/dev/binder               0666   root       root
#sis
/dev/sis_aegis_touch_device      0666   root       root

Guess you like

Origin blog.csdn.net/u010823818/article/details/131509058