Control RGB LED on your Raspberry Pi through a web browser. This is a companion to my project on Hackaday.io.
- Install Raspbian.
- Install prerequisites.
sudo apt install python3-pip pigpio
sudo pip3 install flask flask-socketio eventlet pigpio
- Install custom pigpiod service.
- Edit pigpiod service file:
nano /etc/systemd/system/pigpiod.service
- Paste the following in it:
[Unit]
Description=pigpio daemon
[Service]
ExecStart=/usr/bin/pigpiod -g
[Install]
WantedBy=multi-user.target
- Save and exit
- Enable and start the service:
sudo systemctl enable pigpiod.service
sudo systemctl start pigpiod.service
- Download and unpack this repository.
wget https://github.com/dimitry-ishenko/rgb-led/archive/master.zip
unzip master.zip
mv rgb-led-master rgb-led
- Launch the application:
cd rgb-led
python3 app.py
- On your computer, open the web browser and navigate to the Pi IP address and port 5000 (eg:
http://192.168.1.1:5000
). You should see the following: - Control your RGB LED Strip from the browser. How cool.
- Share and enjoy.
- Dimitry Ishenko - dimitry (dot) ishenko (at) (gee) mail (dot) com
This project is distributed under the GNU GPL license. See the LICENSE.md file for details.