What it does
- Maps VLANs & link speeds from a UniFi switch (SNMP) to addressable LEDs
- Optional SPI display with rotating pages (overview, links, temps, sync)
- UDP multicast to sync VLAN colors across multiple Pis
- NEW: BMP280 sensor + Pi CPU temperature shown in UI and on display
- Raspberry Pi (any model with SPI + I2C; Pi 3/4/5 recommended)
- LED strip: WS2811 / WS2812 / WS2812B / SK6812 (RGB or RGBW)
- Small display (optional): SSD1351 OLED (128×128) or ST7789 LCD (e.g. 240×240)
- BMP280 temperature sensor (I2C; typical addr 0x76 or 0x77)
- Proper 5V power for LEDs; common ground with the Pi
LEDs (WS281x)
- Data → GPIO18 (physical pin 12) — default
- GND → any Pi GND (pins 6/9/14/20/25/30/34/39)
- 5V → external 5V supply (do not power long strips from Pi 5V)
- Share GND between Pi and LED PSU
Display (SPI0 default)
- VCC → 3.3V (pin 1 or 17)
- GND → GND
- SCK/SCL → GPIO11 (pin 23)
- MOSI/DIN → GPIO10 (pin 19)
- CS/CE0 → GPIO8 (pin 24)
- DC/RS → GPIO24 (pin 18)
- RST → GPIO25 (pin 22)
- (ST7789) BL/LED → 3.3V (or map to a GPIO if you want control)
BMP280 (I2C)
- VCC → 3.3V
- GND → GND
- SDA → GPIO2 (SDA1) (pin 3)
- SCL → GPIO3 (SCL1) (pin 5)
- Default address
0x76(some boards use0x77)
git clone https://github.com/Lukeskaiwalker/etherlight-pi
cd etherlight-pi
./install.shTo keep onboard audio enabled:
DISABLE_AUDIO=0 ./install.shThe script:
- Installs OS deps (Python, build tools, SNMP, I2C tools, scons)
- Enables SPI (display) and I2C (BMP280)
- Creates a
.venvand installs Python deps (Flask, PySNMP, rpi-ws281x, luma, smbus2, bmp280) - Installs a systemd service that uses the venv and starts the app
- Disables onboard audio by default (set
DISABLE_AUDIO=0to keep audio); reboot recommended after changes
Open: http://<pi-ip>:8080/
- Go to Setup → Service.
- Check for updates (requires internet on the Pi).
- Update via Git to pull the latest release and restart the service.
- Offline update: download a release
.zip/.tar.gzfrom GitHub on another machine, then upload it on the Service card. - Updates keep your local settings in
config.local.json.
cd ~/etherlight-pi
git pull
./install.shIf you move the repo, rerun the install so the systemd service points at the new path.
Releases use YYYY.MM.N (year, month, increment). Example: 2026.01.1.
Use scripts/bump_version.py to increment the month counter and update VERSION.
- Edit
config.local.json(auto-created on first run, preserved across updates). config.jsonis the template shipped with the repo.device.switch_host/device.snmp.communitydevice.ports.countif auto-detect differsled.*for type/order/pin/brightnessdisplay.enabledand model/sizesensors.bmp280.enabled,bus,address(0x76or0x77)
- If
device.nameis empty orEtherPi, it auto-sets toEtherPi-XXXX(based on MAC).
- Temperatures card shows: CPU and BMP280 in °C (live).
- Live Ports table: ifName, VLAN, speed, link state.
- VLAN → Color editor.
- Detect switch button fills model + port count.
- LED mmap()/PWM error: rerun
DISABLE_AUDIO=1 ./install.sh(or./fix-ws281x-root-audiooff.sh) and reboot; ensure GND shared. - No BMP280 reading: enable I2C, check wiring & address (0x76 vs 0x77). Use
i2cdetect -y 1to confirm presence. - BMP280 auto-disabled: if no sensor is detected at boot it is turned off in config; re-enable in Setup → Sensors after wiring.
- Display blank: confirm SPI enabled; ensure
spidevis installed in the venv (rerun./install.sh); check driver/size inconfig.local.jsonand wiring.
journalctl -u etherlight.service -f
sudo systemctl restart etherlight.service