[Voyage-linux] Leds on Alix 2D3
Punky Tse
(spam-protected)
Tue Feb 9 22:45:44 HKT 2010
Hi Giulio,
You need to load ledtrig-netdev as well.
- Punky
Giulio Giandonato wrote:
> Hi,
> I own an Alix 2D3 where I installed Debian Lenny 5.0 and
> linux-image-2.6.26-486-voyage
> (I prefer to use the original Debian instead of Voyage Linux 0.6.2)
>
> I inserted the following modules in /etc/modules to activate leds:
>
> leds-alix
> ledtrig-default-on
> ledtrig-heartbeat
> ledtrig-gpio
> ledtrig-timer
>
> and I created a script in /etc/init.d to start and stop them:
>
> #!/bin/sh
> case $1 in
> start)
> echo 'Leds ON'
> echo heartbeat > /sys/class/leds/alix\:1/trigger
> echo ide-disk > /sys/class/leds/alix\:2/trigger
> echo netdev > /sys/class/leds/alix\:3/trigger
> echo eth0 > /sys/class/leds/alix\:3/device_name
> echo "link tx rx" > /sys/class/leds/alix\:3/mode
> ;;
> stop)
> echo 'Leds OFF'
> echo heartbeat > /sys/class/leds/alix\:1/trigger
> echo heartbeat > /sys/class/leds/alix\:2/trigger
> echo heartbeat > /sys/class/leds/alix\:3/trigger
> ;;
> esac
> exit 0
>
> For loading the script at boot time I used these commands:
> chmod +x /etc/init.d/leds
> update-rc.d leds defaults
>
> When I boot, LED1 works in heartbeat mode, LED2 blinks on disk activity
> but LED3 doesn't work and I receive the following errors:
>
> /etc/rc2.d/S20leds: line 7: echo: write error: Invalid argument
> /etc/rc2.d/S20leds: line 8: /sys/class/leds/alix:3/device_name: No
> such file or directory
> /etc/rc2.d/S20leds: line 9: /sys/class/leds/alix:3/mode: No such file
> or directory
>
> I don't know what to do, can you help me?
>
> Thank you.
>
> Bye.
> Giulio
>
> _______________________________________________
> Voyage-linux mailing list
> Voyage-linux at list.voyage.hk
> http://list.voyage.hk/mailman/listinfo/voyage-linux
>
More information about the Voyage-linux
mailing list