Using LCD pins as GPIOs by modifying the tree

Hi There,
Using the example in here
I was not able to have successful use of SODIMM62 & SODIMM64 as gpios.(see attached file). The compilation and download seem to work successfully but I have no access by toggline the pins using:

gpioset /dev/gpiochip1 8=0
gpioset /dev/gpiochip1 8=1
Please I need your help to resolve this.
Best Regards,
A. Falhi
custom.dts (951 Bytes)

Software summary
Bootloader:               U-Boot
Kernel version:           5.15.129-6.6.0-devel+git.c6f626a5642c #1-TorizonCore SMP PREEMPT Sun Dec 24 15:44:39 UTC 2023
Kernel command line:      root=LABEL=otaroot rootfstype=ext4 quiet logo.nologo vt.global_cursor_default=0 plymouth.ignore-serial-consoles splash fbcon=map:3 ostree=/ostree/boot.1/torizon/1450d478eb3322851c5f9ddc7708cb515c0d2003f0aa58e8537b594251fa922c/0 spidev.bufsiz=131070
Distro name:              NAME="TorizonCore"
Distro version:           VERSION_ID=6.6.0-devel-20240120-build.490
Distro variant:           VARIANT="Docker"
Hostname:                 colibri-imx8x-07265948

Hardware info
HW model:                 Toradex Colibri iMX8DX on Colibri Evaluation Board V3
Toradex version:          0051 V1.0D
Serial number:            07265948
Processor arch:           aarch64

custom.dts (712 Bytes)

Greetings @falhi,

I see some issues with your device tree overlay. I used this instead and it seems to work:


// A) Header file with pin definitions
#include "dt-bindings/pinctrl/pads-imx8qxp.h"

/ {
    compatible = "toradex,colibri-imx8x";

&iomuxc {
    pinctrl-names = "default";
    pinctrl-0 = <&pinctrl_ext_io0>, <&pinctrl_hog0>, <&pinctrl_hog1>, <&pinctrl_lpspi2_cs2>, <&pinctrl_my_pins>;  // D) OPTION #1: Pin group available in userspace i.e. as GPIO

        // B) Pin Control node
        pinctrl_my_pins: my_muxgrp {
            fsl,pins = <IMX8QXP_ESAI0_TX4_RX1_LSIO_GPIO0_IO08 0x06000021>,   //  SODIMM 62
                <IMX8QXP_SPI3_SDI_LSIO_GPIO0_IO15  0x06000021 >;       //  SODIMM 64


That is to say I can see the pins reacting to gpioset and gpioget at least according to gpioinfo.

Best Regards,


Thank you. That helped a lot

Glad I was able to help!