Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 5011

Advanced users • Re: Using I2C 5 and DPI 666 simultaneously

$
0
0
I have encountered a new problem with getting the software i2c reserved by the kernel.

Im trying to use a goodix touchscreen with software i2c. Im using a custom dtoverlay for gt9110 from github

https://gist.github.com/i0annis/1d7b6e8 ... 3af376420c

Code:

// Device tree overlay for Goodix GT9110 touch controller// connected to Raspberry Pi via I2C on GPIO pins. /dts-v1/;/plugin/;/ {        compatible = "brcm,bcm2835", "brcm,bcm2836", "brcm,bcm2708", "brcm,bcm2709";        fragment@0 {                target = <&gpio>;                        // Overlay for GPIO pins, using standard 'gpio' node                __overlay__ {                        goodix_pins: goodix_pins {       // create overlay labeled "goodix_pins"                                brcm,pins = <27 4>;      // use GPIO_27(pin 13), GPIO_4(pin 7)                                brcm,function = <0 0>;   // set pins as Output                                brcm,pull = <2 2>;       // enable internal pull-up resistors                        };                };        };        fragment@1 {                target = <&i2c1>;                        // Overlay for I2C pins, using the 'i2c1' node                __overlay__ {                                                    #address-cells = <1>;                        #size-cells = <0>;                        status = "okay";                 // device is enabled                        gt9110: gt9110@14 {                   // set GT9110 with i2c address 0x14                                compatible = "goodix,gt9110"; // using 'goodix' kernel device driver                                reg = <0x14>;                 // I2C address (needs to match above)                                pinctrl-names = "default";    // default pin configuration                                pinctrl-0 = <&goodix_pins>;   // assign overlay to pin control                                interrupt-parent = <&gpio>;   // assign interrupt rutines                                interrupts = <27 2>;          // high-to-low edge triggered                                irq-gpios = <&gpio 27 0>;     // set Interupt pin on GPIO 27                                reset-gpios = <&gpio 4 0>;    // set Reset pin on GPIO 4                        };                };        };};
i used this setup in config.txt

Code:

 dtoverlay=i2c-gpio,bus=1,i2c_gpio_sda=2,i2c_gpio_scl=3dtoverlay=gt9110
when i try i2cdetect -y 1 I can see i2c address 0x14. But it is not reserved by the kernel , if it did it will be listed as UU
So the touch screen is not working.


I went through other posts and changed

Code:

      target = <&i2c1>;   TO  target = <&i2c_gpio>;  
But still the i2c address is not getting reserved.

Any pointers will be highly helpful.

Statistics: Posted by BalajiNarasimhan — Tue Jan 16, 2024 7:03 am



Viewing all articles
Browse latest Browse all 5011

Trending Articles