Olimex Support Forum

OLinuXino Android / Linux boards and System On Modules => iMX233 => Topic started by: artone on July 02, 2015, 07:18:58 PM

Title: how enable/disable internal pull-up gpio?
Post by: artone on July 02, 2015, 07:18:58 PM
i use a external pull-up to read a gpio pin with my code in c .
to test if it is possible use a pin with internal pull-up (without external), how  can i enable and set internal pull-up?
Thanks
Title: Re: how enable/disable internal pull-up gpio?
Post by: swahren on July 02, 2015, 08:02:12 PM
At First

disclaimer: i never tested pull-up configuration on my Olimex board.

To your question, it depends on the Kernel version

Freescale downstream kernel 2.6.35: look at the board config code

Mainline kernel > 3.x: look at the devicetree source (http://lxr.free-electrons.com/source/arch/arm/boot/dts/imx23-olinuxino.dts) and binding doc (http://lxr.free-electrons.com/source/Documentation/devicetree/bindings/pinctrl/fsl,mxs-pinctrl.txt)

Looking at the i.MX23 reference manual shows only a few pins on Olimex boards have configurable pull-ups like GPMI_CE0N and GPMI_CE1N (10 k).