1

I have four GPIO pins and a GND pin wired into the circuit board of a monster truck, and a couple pins seem to be going and staying high without any prompting.

I've been using RPi.GPIO, and I've been using GPIO.cleanup() at the end of every program. After the program runs, the truck keeps turning right, which was associated with GPIO04. I unplugged the truck and tested 04 with an LED, and it lit up. The other pins I'd been using didn't light up the LED.

I rebooted the RPi and tried a different set of GPIOs. Nothing happened for a minute after it booted, then the truck's wheels started spinning. I tested all four pins that had been connected to it with the LED, and two of them lit it up (GPIO 08 and 07).

I've been researching the problem and have not been able to find a working solution. I should also add that I accidentally short-circuited two GPIOs (04 and 17) the other day and kicked the RPi into safe mode (bad soldering job on the truck's circuit board), so there is a possibility my board is damaged from that.

Can anyone give me any input on this? I'm pretty inexperienced and I'm kind of at a loss.

1
  • So what happens if you try and examine and affect the pins via /sys/class/gpio?
    – goldilocks
    Mar 21, 2015 at 9:26

1 Answer 1

2

A gpio set as an input will float randomly between high and low until it is actively driven.

There are internal pull-ups and pull-downs for each gpio which you can select with software. The value is about 50k ohm which will easily be overridden by an external source.

Your Answer

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

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