Kristin and the boys left to get haircuts, this left Emily and I to our own devices. We decided we woudn’t waste our free time and bust out one of the Beagle Bone Blacks I bought awhile ago and hook up some Xbees. So I got my breakout boards and the xbees and my horror when I saw the xbees were to be soldered to the breakout board. I wasn’t about to do that, so we found the pins and have them coming from Spark Fun, so that project will wait for another day.
But I got everything out, what should I do??? I know I thought make a light blink, so that is what we did, with a simple bash script and some wiring, we had it done and blinking.
Here is a closeup of how complicated the wiring is 🙂
Here is the script
#!/bin/bash echo 30 > /sys/class/gpio/export echo high > /sys/class/gpio/gpio30/direction STATUS=`cat /sys/class/gpio/gpio30/value` while [ 42 == 42 ]; do if [ $STATUS == 1 ]; then echo 0 > /sys/class/gpio/gpio30/value else echo 1 > /sys/class/gpio/gpio30/value fi sleep 1 STATUS=`cat /sys/class/gpio/gpio30/value` done |
As promised here are the pins (FYI I used gpio 30 not 60 as the video stated).
Have fun and don’t get blinded by the light
–John