Reputation: 98
I am getting "RuntimeError: Failed to add edge detection" when trying to run the following on a BeagleBone running Ubuntu 13.10
import Adafruit_BBIO.GPIO as GPIO
def onGPIOEvent(channel):
print "event detected!"
GPIO.setup("P9_28", GPIO.IN)
GPIO.add_event_detect("P9_28", GPIO.RISING, callback=onGPIOEvent, bouncetime=300)
Please help.
Upvotes: 2
Views: 1903
Reputation: 11
The pin P9_28 does NOT have a GPIO option to it. Try another pin such as P9_30 and see if you still get the same error.
Upvotes: -1