Skip to content

Instantly share code, notes, and snippets.

@discarn8
Last active May 3, 2018 04:18
Show Gist options
  • Save discarn8/54ffd67f0cac8da27c649b4b30cffb04 to your computer and use it in GitHub Desktop.
Save discarn8/54ffd67f0cac8da27c649b4b30cffb04 to your computer and use it in GitHub Desktop.
NanoPi Neo Blue LED
#Make a backup:
cp /etc/rc.local /etc/rc.local.bac
#Edit:
nano /etc/rc.local
#Add following lines before "exit 0 ":
#[Example - edit or uncomment line you needed.]
#### switch on blue LED for sd-card activity
echo 1 >/sys/class/leds/blue_led/brightness
echo mmc0 >/sys/class/leds/blue_led/trigger
#On FriendlyElec OS
echo 1 > /sys/class/leds/nanopi:blue:status/trigger
echo mmc0 > /sys/class/leds/nanopi:blue:status/trigger
#### switch on blue LED for heartbeat
## echo 1 >/sys/class/leds/blue_led/brightness
## echo heartbeat >/sys/class/leds/blue_led/trigger
#On FriendlyElec OS
echo 1 > /sys/class/leds/nanopi:blue:status/trigger
echo heartbeat > /sys/class/leds/nanopi:blue:status/trigger
#### switch off blue LED
## echo 0 >/sys/class/leds/blue_led/brightness
## echo none >/sys/class/leds/blue_led/trigger
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment