AnsweredAssumed Answered

How to enable power on/off of imx6 sabrelite board over gpio 7 13?

Question asked by Ivan Ljubicic on Apr 26, 2016
Latest reply on Apr 27, 2016 by Ivan Ljubicic

Hi,

 

How to enable power on/off of imx6 sabrelite board over gpio 7 13 button? I have already enabled snvs_pwrkey driver and added configuration in imx6qdl.dtsi:

            snvs-pwrkey@0x020cc000 {

                compatible = "fsl,imx6sx-snvs-pwrkey";

                reg = <0x020cc000 0x4000>;

                interrupts = <0 4 IRQ_TYPE_LEVEL_HIGH>;

                fsl,keycode = <116>; /* KEY_POWER */

                fsl,wakeup;

            };

 

I have also mapped gpio button to KEY_POWER in imx6qdl-sabrelite.dtsi:

 

        power {

            label = "Power Button";

            gpios = GP_GPIOKEY_VOL_UP;

            linux,code = <KEY_POWER>;    /* or KEY_SEARCH */

            gpio-key,wakeup;

        };

 

#define GP_GPIOKEY_VOL_UP    <&gpio7 13 GPIO_ACTIVE_LOW>

            MX6QDL_PAD_GPIO_18__GPIO7_IO13        0x1b0b0

 

I have compiled and probe image but failed. I have also tried more items from forum but also failed. So I need help.

 

Thanks, regards, Ivan.

Outcomes