Skip to content

Latest commit

 

History

History
71 lines (40 loc) · 2.81 KB

index.md

File metadata and controls

71 lines (40 loc) · 2.81 KB
title description image
DIY Bluetooth-controlled LED lamp
Building a Blutooth-controlled LED lamp with an ESP32 and an Android application.
path height width alt
/led-lamp/purple_orange.webp
873
728
Photo of the led lamp displaying a picture of a colorful comet

DIY Bluetooth LED lamp

How I built a Blutooth-controlled LED lamp with an ESP32 and an Android application.

Photo of the led lamp displaying a picture of a colorful comet Photo of the led lamp displaying a picture of super nova

Features

  • Spotify integration. Sets the lamp to a color matching the album art. Similar to how the color of the spotify status bar notification is picked.

  • Pick an image from the phone and display it on the lamp.

  • Flash lamp whenever the phone receives a new notification, such as when messages, emails etc. are received.

  • Various animated effects and mood effects. Night sky, green forest and sunset to name a few.

  • Simple RGB color picker in the app.

Hardware

Electronics

Lampshade, stand etc

  • The lamp shade is made from a cut PET bottle, and wrapped in a decorative window film found at Daiso in Tokyo. By gluing sawed off pieces of a square wood stick to the bottom of the lamp shade, some air is allowed to flow and cool the LEDs.

  • PVC pipe to wrap the led strip around.

  • Wooden panel to mount the PVC pipe on. On the bottom side the ESP32 and the rest of the electronics are mounted.

Software

You can browse the entire code base at github. https://github.com/miksto/BluetoothLEDLamp

ESP32

https://github.com/Makuna/NeoPixelBus - the only library supporting RGBW leds AND using DMA (Direct Memory Access) i could find by the time.

DMA is preferred for efficient control of the leds, as opposed to bit bang and interrupt driven libraries which do not support any other interrupt driven code to work.

Android App

The android application does not use any special libraries, and is written in kotlin and relies on the standard BLE library for communication with the ESP32.