I'm trying to read pins in Python after setting them in Pd. I have a Python script that just reads the pins using the Adafruit_BBIO library. It works when I'm not running the Pd patch, but not when Pd is running. Is there an issue with using these two things together? I could swear I've done this before, but I can't seem to get it working now.
Thanks,
Colin
import time
import Adafruit_BBIO.GPIO as GPIO
IN = "P9_12"
OUT = "P9_14"
setup BBB GPIO pins
GPIO.setup(IN, GPIO.IN)
GPIO.setup(OUT, GPIO.OUT)
while True:
if GPIO.input("P9_12"): # bela_setDigital17
print("HIGH")
else:
print("LOW")
clean stuff up when you're done
GPIO.cleanup()