I tried out the the BBB with the Adafruit python library.
I was connecting a Voltmeter to the right Pin and run the following program
import Adafruit_BBIO.GPIO as GPIO
import time
pin = "P8_10"
GPIO.setup(pin, GPIO.OUT)
for x in range(0,5):
print("High")
GPIO.output(pin,GPIO.HIGH)
time.sleep(1)
print("Low")
GPIO.output(pin,GPIO.LOW)
time.sleep(1)
GPIO.cleanup()
Unfortunalty it was always on high, I did try a 1kOhm pulldown resistor to the ground. Still the same always high.
I did try the it the other way using this code:
import Adafruit_BBIO.GPIO as GPIO
import time
pin = "P8_10"
print("Setup " + pin)
GPIO.setup(pin, GPIO.IN)
for x in range(0,5):
if GPIO.input(pin):
print("High")
else:
print("Low")
time.sleep(0.5)
print("end")
GPIO.cleanup()
Connecting it over a 1kOhm resistor to ground. I did still stay High all the time.
The OS on my BBB is Ubuntu. Any suggestions what could be wrong with the setup?
python your_script.py
, or assudo python your_script.py
\$\endgroup\$