INPUT always reads HIGH

8 views
Skip to first unread message

Łukasz Taras

unread,
Nov 7, 2016, 7:11:02 AM11/7/16
to BeagleBoard
Hi all!.
Struggling with GPIO inputs. Outputs work as expected but inputs are driving me nuts.

I have unloaded all default overlays from Debian and created my own with BBB Overlay generator. Tried to put P8_37 (PIN P8.3) into input modes with 0x27, 0x37, 0x67.
If it was with pulldown when i measured voltage between Pin and GND it was always ~2.6V and 'value' file was reading as HIGH (1). So i said ok, since i get take it down to less than 0.8V (LOW) and then put 3.3V on that pin and get HIGH i will revert it, so changed mode to be pullup, checked voltage to GND and it was ~3.3V (great!), so i said, ok i will put it down by toughing GND to Pin so it drops to LOW. No chance, value still reads as 1. What am i doing wrong guys?

My example overlay file:
/dts-v1/;
/plugin/;

/{
    compatible = "ti,beaglebone", "ti,beaglebone-black";
    part_number = "BS_PINMODE_P8_3_0x27";

    exclusive-use =
        "P8.3",
        "gpio1_6";

    fragment@0 {
        target = <&am33xx_pinmux>;
        __overlay__ {
            bs_pinmode_P8_3_0x27: pinmux_bs_pinmode_P8_3_0x27 {
                pinctrl-single,pins = <0x018 0x27>;
            };
        };
    };

    fragment@1 {
        target = <&ocp>;
        __overlay__ {
            bs_pinmode_P8_3_0x27_pinmux {
                compatible = "bone-pinmux-helper";
                status = "okay";
                pinctrl-names = "default";
                pinctrl-0 = <&bs_pinmode_P8_3_0x27>;
            };
        };
    };
};

Reply all
Reply to author
Forward
0 new messages