Difference between revisions of "ECE497 Project Christmas Light Controller"

From eLinux.org
Jump to: navigation, search
(Beautified executive summary)
(Beautified needed hardware)
Line 48: Line 48:
  
 
== Needed Hardware ==
 
== Needed Hardware ==
 +
In addition to a BeagleBone, you will need:
  
You will the 5 meter [http://www.adafruit.com/products/306 Adafruit's LPD8806 LED String].
+
* [http://www.adafruit.com/products/306 Adafruit's LPD8806 LED String]
 
+
** Sold by the meter. Need to order 5 meters for a roll.  Our project uses two rolls, for a total of 10 meters.  The code can be easily adapted for more or less lights as needed.
5 Volt 10 amp Power Supply [https://www.adafruit.com/product/658 https://www.adafruit.com/product/658].  
+
* [https://www.adafruit.com/product/658 5V Power Supply]
 
+
** The LEDs use a lot of power. We used a 5V, 5A power supply to power our 10 meters, but we needed more power to have all the LEDs on full brightness. Adafruit sells a 5V, 10A supply, linked above, that they recommend to power the LEDs.
USB audio dongle [https://www.sabrent.com/product/USB-SBCV/usb-2-0-external-2-1-surround-sound-adapter https://www.sabrent.com/product/USB-SBCV/usb-2-0-external-2-1-surround-sound-adapter].
+
* [https://www.sabrent.com/product/USB-SBCV/usb-2-0-external-2-1-surround-sound-adapter USB Audio Dongle]
 +
** Necessary if you want to use the BeagleBone to play holiday music.  Connects to the USB port of the BeagleBone and has a 3.5mm audio output.
 +
* Speaker
 +
** Must be connected to the output of the USB Audio Dongle to play music for everyone to hear.  Headphones can be used instead for testing.
  
 
== Installation Instructions ==
 
== Installation Instructions ==

Revision as of 09:46, 14 November 2016

thumb‎ Embedded Linux Class by Mark A. Yoder


Team members: Josh Woods and Ricky Rung

Grading Template

Draft Feedback

Looks good. Keep up the good work.

Could you add some pictures to show what you are doing?

I'm using the following template to grade. Each slot is 10 points. 0 = Missing, 5=OK, 10=Wow!

00 Executive Summary
00 Installation Instructions 
00 User Instructions
00 Highlights
00 Theory of Operation
00 Work Breakdown
00 Future Work
00 Conclusions
00 Demo
00 Late
Comments: I'm looking forward to seeing this.

Score:  10/100

(Inline Comment)

Executive Summary

Image

Click for Video

Our project is to create a user interface to control 320 LED lights on a 10 meter LED strip. The LED strip will then be put on the ECE Department’s tree during the holiday season.

The interface will be online, and will allow anyone to write code to control the lights on the tree. Users will also be able to select patterns that others have programmed, if they don’t want to write their own.

Submitted programs will each run for a specified length of time. A queue will be used, so if multiple people write programs at once, each program will get a chance to run. When one program’s run time expires, the next program will run, until the queue is empty. If no programs are waiting to run, the last run program will continue indefinitely.

There will also be a speaker near the tree which will play holiday music, selected through the online interface. A separate “music queue” will be used to store songs to play. Users will be able to select from a list of songs to add music to the queue.

This will be a fun and exciting holiday feature for the ECE department.

Needed Hardware

In addition to a BeagleBone, you will need:

  • Adafruit's LPD8806 LED String
    • Sold by the meter. Need to order 5 meters for a roll. Our project uses two rolls, for a total of 10 meters. The code can be easily adapted for more or less lights as needed.
  • 5V Power Supply
    • The LEDs use a lot of power. We used a 5V, 5A power supply to power our 10 meters, but we needed more power to have all the LEDs on full brightness. Adafruit sells a 5V, 10A supply, linked above, that they recommend to power the LEDs.
  • USB Audio Dongle
    • Necessary if you want to use the BeagleBone to play holiday music. Connects to the USB port of the BeagleBone and has a 3.5mm audio output.
  • Speaker
    • Must be connected to the output of the USB Audio Dongle to play music for everyone to hear. Headphones can be used instead for testing.

Installation Instructions

Follow these steps to enjoy the light show

  • Clone this repository ECTree.
  • Connect the 5 V power supply to the Vcc and Ground pins of the LED strip
  • Connect the clk pin of LED strip to P9_22 of the bone
  • Connect the dO pin of the lED strip to the P9_18 pin of the bone
  • connect the audio dongle to the usb port of the bone
  • run the install.sh file from the cloned repo (this needs to be run one time)
  • run the setup.sh file from the cloned repo (this needs to be run every boot up)


User Instructions

  • run the web.js file to start the server
  • point any web browser to the IP of the bone and port 887
  • enjoy the light shows

thumb User Interface

Highlights

Our user interface will work on any browser including a phone's browser. All light display patterns made by user will be saved for future use. The code is written in a way that allows it to be easily expanded to include more audio and display patterns.

Theory of Operation

We have a server that is listening on port 80 for user's to connect. once a user connects the web page request all current queue information and displays that information for the user to know how long until their pattern or song will be played. The server handles all of the request from many users to maintain unity among all the users so that everyone sees the same queue. the display patterns are sent from the user to the server using a json object and not actual code to prevent bad code spinning the server out of control.

Work Breakdown

  • getting lights to interact with the bone : Ricky
  • build a server : Josh & Ricky
  • build user interface : Josh & Ricky
  • pattern queue : Josh & Ricky
  • audio queue : Josh
  • beautifying website : Ricky

Future Work

If we had more time, we would have liked to make the lights "dance" to the beat of the music.

Conclusions

I, Josh, really enjoyed working on this project because I got to learn and explore some of the aspects of web programming. It will be nice to come back to campus after fall break and see the project in use and see how much action the lights will be getting.




thumb‎ Embedded Linux Class by Mark A. Yoder