summaryrefslogtreecommitdiff
path: root/openpicc/at91flash_automatic
diff options
context:
space:
mode:
Diffstat (limited to 'openpicc/at91flash_automatic')
-rwxr-xr-xopenpicc/at91flash_automatic19
1 files changed, 17 insertions, 2 deletions
diff --git a/openpicc/at91flash_automatic b/openpicc/at91flash_automatic
index 40c23a9..8f92989 100755
--- a/openpicc/at91flash_automatic
+++ b/openpicc/at91flash_automatic
@@ -33,11 +33,26 @@ flash $FLASH_FILE
ENDOFMYTEXT
}
+blink_thinklight() {
+ if [ ! -w /proc/acpi/ibm/light ]; then return; fi
+ OLDSTATUS=`grep status < /proc/acpi/ibm/light | awk '{print $2;}'`
+ if [ "${OLDSTATUS}" = "off" ]; then
+ echo "on" > /proc/acpi/ibm/light
+ sleep 1
+ echo "off" > /proc/acpi/ibm/light
+ else
+ echo "off" > /proc/acpi/ibm/light
+ sleep 1
+ echo "on" > /proc/acpi/ibm/light
+ fi
+}
+
flashing_failed() {
- :
+ aplay /usr/kde/3.5/share/sounds/KDE_Error.wav > /dev/null 2>&1
}
flashing_successful() {
- :
+ blink_thinklight &
+ aplay /usr/kde/3.5/share/sounds/KDE_Notify.wav > /dev/null 2>&1
}
do_detect() {
personal git repositories of Harald Welte. Your mileage may vary