GPIO set pull up mode for INPUT?



  • I am curious because I don't see it mentioned anywhere in the documentation but is there a way to have an input GPIO set up in pull up mode so you just need to ground it to change state. It means all buttons can be connected to earth and don't need to have any power running through them.

    the gpioctl programs is exceptionally basic and does not seem to document any thing much but it does show

    gpioctl dirin|dirout|dirout-low|dirout-high|get|set|clear gpio

    So if it can do dirout-high why can it not do dirin-high as well?

    Am I missing something here ?



  • @T-NT said in GPIO set pull up mode for INPUT?:

    So if it can do dirout-high why can it not do dirin-high as well?

    Apples and oranges, pull-resistors have absolutely nothing to do with output.

    Am I missing something here ?

    Yes, the MT7688 doesn't have configurable pull-resistors.



  • @WereCatf

    Yes, the MT7688 doesn't have configurable pull-resistors.

    Rats. So that means I need to put a pull up resister for each switch then. Bummer because I was porting the project away from the Pi and kinda liked I did not have to have extra passive components.

    Oh well.



  • @T-NT I hear you. Having internal pull-ups/pull-downs is handy. But there's not much one can do about it. Just remember not to use pull-ups/pull-downs on the bootstrap-pins or the Omega2 may not be able to boot.



  • @WereCatf

    Just remember not to use pull-ups/pull-downs on the bootstrap-pins or the Omega2 may not be able to boot.

    Yeah.. I was looking at that annotated pin map thread and caught that. It is an important gotcha and cannot be emphasised enough.

    Thanks.



  • İNDEX OF/CONSOLE ERROR
    When I make 192.168.3.1 it gives this error and it is not an IP conflict problem. Why do I get this error? How do we fix it? I'm waiting for your help

    link text

    alt text0_1489356373995_photoo1.png



  • @WereCatf

    A thought I just had. Not best practice I know but suppose I wire up the common pin to the switches to 3.3v and had the GPIO pin default HIGH and when the button is pressed it would go LOW triggering an event. Is there any real reason I could not use 3.3V on these switches or a rotary encoder?

    Just curious.



Looks like your connection to Community was lost, please wait while we try to reconnect.