• 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: UART To Ethernet Raspberry Pi 5 IR Camera Raspberry Pi 5 PCIE to MiniPCIe For wireless network WIFI Card USB Bluetooth RS232 to CAN Raspberry Pi 11 inch HDMI LCD Captive TouchScreen Display 11inch 1920x1200 For Jetson Series/Computer PC Banana Pi Jetson Orin Raspberry Pi CSI-to-HDMI Raspberry Pi Thermal imaging D-Robotics RDK X3 MD Carrier Board For RDK X3 Module Horizon Sunrise Pi ARM Cortex-A53 5Tops Raspberry Pi 5 DSI RS485 Bus Raspberry Pi 8.8 inch DSI MIPI LCD TouchScreen Display 8.8inch 480x1920 For Luckfox Lyra RK3506/ESP32-P4/Luckfox Omni3576 SpotPear RS232/485/422 To CAN Integrated capacitive fingerprint module Cortex core UART serial port High-precision fingerprint recognition ESP32 ST7789 configuration ESP32-C3-Ornament-Trinket-LVGL-Astronaut-Clock-Watch-MINI-TV-1.69inch-Round-LCD-TouchScreen-ST7789-240x280 2.8inch Round LCD USB Monitor Computer Monitor Display Screen USB Type C Secondary Screen PC CPU GPU Arduino board manager tutorial User Guide