Jan Kundrát | fc16f06 | 2018-08-09 19:58:55 +0200 | [diff] [blame] | 1 | [Unit] |
| 2 | Description=Indication of component state via LEDs on Clearfog |
| 3 | |
| 4 | [Service] |
| 5 | Type=oneshot |
| 6 | # SFP: green lit for "link" |
| 7 | # SFP: green blinking for activity |
| 8 | ExecStart=/bin/sh -c 'echo netdev > /sys/class/leds/sfp:green/trigger' |
| 9 | ExecStart=/bin/sh -c 'echo eth2 > /sys/class/leds/sfp:green/device_name' |
| 10 | ExecStart=/bin/sh -c 'echo 1 > /sys/class/leds/sfp:green/link' |
| 11 | ExecStart=/bin/sh -c 'echo 1 > /sys/class/leds/sfp:green/rx' |
| 12 | ExecStart=/bin/sh -c 'echo 1 > /sys/class/leds/sfp:green/tx' |
| 13 | # LINE/EXPRESS: green for "we're getting some signal" |
| 14 | ExecStart=/bin/sh -c 'echo gpio > /sys/class/leds/line:green/trigger' |
| 15 | ExecStart=/bin/sh -c "sed -En 's/.*gpio-(.*) \\(EDFA1_ST1_IN_LOS_A .*/\\1/p' /sys/kernel/debug/gpio > /sys/class/leds/line:green/gpio" |