For the Raspberry Pi - Make LEDs blink on network and/or SD card/USB storage activity.
Based on the PiLEDLights project by Ragnar Jensen utilizing pigpio instead of WiringPi for GPIO manipulation.
hddledPi blinks a LED connected to a GPIO pin on any mass storage access. Not only on SD card access, but also on USB thumbdrive and hard drive activity.
netledPi blinks a LED connected to a GPIO pin when there is activity on any network interface. Not only the built-in ethernet interface, but also on any other USB ethernet or WiFi interface.
actledPi blinks the Pi's ACT led on all mass storage I/O, i.e. not only the SD card.
This application uses pigpiod instead of WiringPi for GPIO manipulation.
To install the application
sudo apt-get update
sudo apt-get install pigpiod
Enable and start the service:
sudo systemctl enable pigpiod
sudo systemctl start pigpiod
gcc -Wall -pthread -o actledPi actledPi.c
gcc -Wall -pthread -o netledPi netledPi.c -lpigpiod_if2 -lrt
gcc -Wall -pthread -o hddledPi hddledPi.c -lpigpiod_if2 -lrt
Copy the compiled program files to /usr/local/bin and follow the instructions in the initscripts README to run as a daemon.