• sales

    +86-0755-88291180

Raspberry Pi Fan Hat RGB LED User Guide

Raspberry Pi Fan Hat User Guide


  1. Install libraries


(If only need one LED. Please refer to step 2 directly)


wiringPi

sudo apt-get install wiringpi


wget https://project-downloads.drogon.net/wiringpi-latest.deb


sudo dpkg -i wiringpi-latest.deb


gpio -v


#See gpio version: 2.52, indicating that the installation was successful


Python

sudo apt-get update


sudo apt-get install python-pip


sudo pip3 install RPi.GPIO


  1. One color LED (Do not occupy GPIO but can only select one color)


The jumper cap settings are as follows:



R is connected to GND (other NC) ,The red light is on





G B The same jumper method


  1. RGB LED multi-color light program control (occupy GPIO)


The jumper cap settings are as follows:






Code:


wget http://spotpear.cn/publichttps://cdn.static.spotpear.com/uploads/picture/learn/raspberry-pi/rpi-expansion/raspberry-pi-fan-hat/led_rgb.py


sudo python led_rgb.py



The RGB LED will turn on and off

TAG: Raspberry Pi 5 UART Raspberry Pi 5 CR2032 RS485 to RJ45 LuckFox Core3566 SpotPear Luckfox Pico Tutorial ESP32 1.54 inch E-Paper Smart Watch display Screen 200x200 Ultra-low power For Arduino/Micropython/RTOS For Watchy VGA to LVDS ESP32-S3 Round LCD ESP32 ESP32 S3 LCD 1.3 inch Holographic Display Screen 1.3inch 3D Transparent Refractive Prism Mini TV For Arduino ESP32 ST7789 tutorial ESP32-C5 Mini Development Board based on ESP32-C5-HF4 dual-core processor Raspberry Pi screen Intel BE200 Wireless WLAN Card Gigabit Tri-Band WiFi7 Bluetooth 5.4 M.2 MU-MIMO IEEE 802.11 Raspberry Pi Pico 2 RP2350B 2.1 inch Round LCD Touch Display 480x480 HMI LVGL QMI8658 6-axis 65K Colors Raspberry Pi Pico 2 RP2350 0.85 inch LCD Display mini Development Board 0.85inch Screen RGB LED/SD Slot /QMI8658 Gyroscope Sensor X1015 Raspberry Pi 5 PCIe to M.2 Key-M NVMe SSD Board Pi5 2280 Raspberry Pi 5 RS485 Bus