Abstract

This project from the scratch implements an ambient lighting system that sheds light around the monitor or TV screen. Using only an Arduino Uno, a NodeMCU, and some LED strips, this system will obtain the colors captured from the perimeter area of the screen and extends them to the wall or curtain behind the monitor, in order to create an immersive visual effect. My solution is to use AVR assembly to implement the time-critical part of the library for driving the LED strip. However, I only managed to finish the library, but failed to send real-time color information from screen to the LED strip because of limited time.

Motivation

I enjoy watching movies. While cinemas generally have much better visual effects than home monitors, I am not able to go to the cinema to see every movie I am interested. I plan to build this ambient lighting system to create a home threate-like visual environment that can help me get immersive experience when using monitors, especially at night. By the way, it can also reduce eye strain in dark environment.

Goals

A.Milestone 1 I will have implemented the serial communication protocol (SPI-like) between Arduino and LED strips from scratch. And I will be able to control the LED strips as desired with any patterns I want. B.Final Demo Implement the wireless communication between screen capture software and NodeMCU Implement auto-brightness and constant-color modes for the LED strips under different lighting environment. I will finish all other parts and assemble together. The ambient light can make synchronized

Methodology

My initial idea is as follow. For communication system, the screen capture software will take a snap of the screen at 60 Hz and calculate the average colors at the perimeter area of the screen and send the RGB arrays to NodeMCU by Wi-Fi, which are transmitted to Arduino serially. For the arrangement of LED strips, I will evenly stick LEDs at edges of the monitor. And each LED will correspond to the average color at that small area.

Results

I only implemented the LED driver library. For other parts, I’ve tried to (1) use color sensors to capture the color, (2) use software like Prismatic to capture color information, (3) decode the HDMI signal the extract the color information. But none of these is successful or implemented because (1) the accuracy of color sensors are not enough for my project, (2) the software can capture the color information, but receiving the information need to use UART port of Arduino Uno, while I have to disable all interrupts because of the time-critical operations. (3) the protocols are too complicated to decode. I should have prepared earlier and maybe try to use another board like ESP8266 so I can receive the color information and drive the LED strip at the same time.

References

  1. Adafruit NeoPixel Überguide https://learn.adafruit.com/adafruit-neopixel-uberguide
  2. WS2812B datasheet http://www.world-semi.com/DownLoadFile/108
  3. AVR Instruction Set Manual http://ww1.microchip.com/downloads/en/devicedoc/atmel-0856-avr-instruction-set- manual.pdf
  4. AVR-GCC Inline Assembler Cookbook https://www.nongnu.org/avr-libc/user-manual/inline_asm.html

Built With

Share this project:

Updates