OPi.GPIO icon indicating copy to clipboard operation
OPi.GPIO copied to clipboard

Support for Pull up / Pull down resistors

Open rm-hull opened this issue 8 years ago • 2 comments

Pull request #8 added faux-compatibility for pull up/down resistors by adding an optional parameter, so that existing code doesn't break. This issue is a placeholder to add real support for pull-up/down resistors.

Related (originating) issue: #6

rm-hull avatar May 27 '17 16:05 rm-hull

As I understand, the sysfs interface does not support dynamic configuration of internal pull-up/down resistors. So an Allwinner-specific solution is necessary, just like Raspberry Pi has Broadcom-specific solutions.

  • The Allwinner-specific sunxi interface supports this, but you have to access the system memory directly. Is it compatible with sysfs interface?
  • Another option seems to be writing DTS overlays (like on RPi) and rebooting each time. But it seems this is not yet supported (/boot/dtb-4.13.8-sunxi/overlay/README.sun8i-h3-overlays)?
  • A similar Allwinner-specific solution are Fex Guide GPIO configuration and rebooting each time?

gw0 avatar Nov 19 '17 13:11 gw0

I've found a DTS that enables internal pullup, not sure if it can be used. https://github.com/armbian/sunxi-DT-overlays/blob/master/examples/gpio-button.dts

enesbcs avatar Apr 15 '20 17:04 enesbcs