In this course we will see how to read the value of a push button on the beaglebone black.
Beaglebone Black
The beaglebone Black is a card developed by Beaglebone. It works with an ARM Cortex A8 processor.
The BeagleBoard is a low power single board computer type electronic card. This is open source hardware produced by Texas Instruments in collaboration with Digi-Key.
This BeagleBone board is a single board computer that can be used as a standalone computer or can be integrated into a system.
Electronic Diagram
Here’s the electrical diagram of the push button on the beaglebone black board. We’ve added a pull-up resistor to avoid indeterminate states and force the signal to 0 when you don’t press the button:
How do I choose which pin to connect the pushbutton to?
We’ve connected our pushbutton to one of the Beaglebone Black’s GPIOs (“P8_17”). However, you may wish to connect it to another pin. To do so, simply select one of the GPIOS below:
GPIO Library
To control the inputs/outputs of the Beaglebone black board, we’ll need to install the adafruit library. To do this, we propose two solutions, using “pip” or “git” :
sudo python -c "import Adafruit_BBIO.GPIO as GPIO; print GPIO"
#Vous devriez avoir ce message
<module 'Adafruit_BBIO.GPIO' from '/usr/local/lib/python2.7/dist-packages/Adafruit_BBIO/GPIO.so'>
Installation using git
With git you can copy the project directly from github :