# HG changeset patch # User Christophe Lincoln # Date 1399235137 -7200 # Node ID af4b31a2d8f22dd094c6e5a4bad07ead44376c29 # Parent 6db0c7f6fd1078485fed1de361c1394e722ddfd5 Add support for 8x8 leds exampe in pileds diff -r 6db0c7f6fd10 -r af4b31a2d8f2 rpi/pileds --- a/rpi/pileds Sun May 04 20:35:14 2014 +0100 +++ b/rpi/pileds Sun May 04 22:25:37 2014 +0200 @@ -14,10 +14,10 @@ $(boldify "Commands:") act Turn on/off the on board ACT green led 7-clock Adafruit 7-segment LED Backpack clock example + 8x8 Adafruit 8x8 LED Matrix Backpack example ada-clean Clean: Adafruit 7-segment or 8x8 Matrix EOT -#8x8 Adafruit 8x8 LED Matrix Backpack example } load_modules() { @@ -43,6 +43,7 @@ status="$(cat $brightness)" [ "$quiet" ] || gettext "Current status:"; echo " '$status'" if [ "$status" == 0 ]; then + echo "0" > ${brightness}; usleep 50000 echo "1" > ${brightness} else echo "0" > ${brightness} @@ -60,9 +61,13 @@ 8x8) scripts="/usr/share/adafruit/LEDBackpack" - #load_modules - #check_packages "python-rpi-adafruit" - echo "TODO: $scripts" ;; + load_modules + check_packages "python-rpi-adafruit" + if [ -f "${scripts}/ex_7segment_clock.py" ]; then + python ${scripts}/ex_8x8_pixels.py + else + gettext "Missing:"; echo " ${scripts}/ex_8x8_pixels.py" + fi ;; ada-clean) adafruit_clean ;;