A simple issue I hope. I export, set direction, then set value to HI. Perfect, get everything I expect from GPIO 4. Now, once I set value LO, perfect, goes to 0v, but then as soon as I unexport, the pin jumps back to HI.

I have the RPI 3. Any thoughts?

1 Answer 1


Perhaps the GPIO is set back to INPUT mode when unexported.

All GPIO have software selectable internal pulls to 3V3 and ground. They may be enabled in software to default the GPIO high or low in the absence of a stronger external voltage.

When a GPIO is switched to an INPUT the default pull will then apply.

In the case of GPIO 4 the default pull is high to 3V3.

  • Could you elaborate on your second sentence, the wording is throwing me off.
    – Lanet Rino
    May 10, 2017 at 4:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.