I need to disable all LEDs on my Raspberry Pi 3s otherwise they interfere with the operation of my camera setup. I use Raspbian Jessie.
I can successfully use the following code:
echo 0 >/sys/class/leds/led0/brightness echo 0 >/sys/class/leds/led1/brightness
Both LED go dark - I am happy. However, if I put these commands in rc.local or in a script called by rc.local, most of the times (but not always) one of those LEDs (in particular the red one) will not turn off. If I ssh into the Pi and repeat the command it will correctly turn off.
When the LED is not turned off, the brightness value contains 255:
# cat /sys/class/leds/led1/brightness 255
like if some other program sets it back up after rc.local is executed.
I have also tried to add:
echo none >/sys/class/leds/led0/trigger echo none >/sys/class/leds/led1/trigger
But it did not have any effect.
What entity/program might interfere with LED brightness at boot time?
Also note: I have tried to add a 5 to 15 seconds delay to the execution in rc.local but the problem did not disappear, in fact I did not see any difference