The Most Face Rockingest Project Blog on the Entire Fucking Web
The Make Contest
Published: April 11, 2013
My google AD, I know most hackers and DIY'ers hate ads but it brings in around 5 bucks on a good month and I use it to subsidize my hosting fee's so you can get access to my code :)

Hello and welcome to my entry for MAKE’s Raspberry Pi Design Contest! I’ve spent the past week working hard on building a ceiling lamp with a ring of LED’s below it.

I call it the Cloud Lamp, and here’s how it all went down:

The Goal

My Cloud Lamp

My Cloud Lamp

After getting my home somewhat automated with a z-wave network and a few other custom devices, I thought I’d like to have a simple way to see the status of my home, the weather, surf report, etc, easily visible from my bed. My initial thought was that I’d buy a conventional ceiling lamp and put four rgb LEDs around the perimeter of the lamp as status indicators. Well, two weeks ago I came upon Make’s contest and even though I was already behind I thought it’d be really fun to try building something. So I took my original idea and made the following changes: I went from 4 to 60 rgb LEDs after being inspired by this beautiful clock. Well, that and I love circular LED displays! :) I probably wouldn’t use the analogue-like clock functionality but I thought it was a beautiful design and I thought I could add something to it. And of course I changed out the Arduino for a Rasberry Pi, which made the project amazingly versatile!

 

The Build Process

The building process broke down into three major parts, the electronics, the physical lamp and the software.

Lamp Hardware

Lamp holder and start of holding rig

Lamp and assembly

The final product, but without it's clothes. (Stop looking, pervert!)

The final product, but without it’s clothes. (Stop looking, pervert!)

To start, I bought a cheap, commercial ceiling lamp from Home Depot for about 30 (Girlfriend reminded me that we got one on sale) 10 bucks along with a bunch of flat pieces of steel, wires and assorted nuts and bolts. I shaped the pieces of steel into a simple bracket that could attach to the lamp base and welded the assembly together. This would also be the platform for the power supply, power switch tail (for switching the light bulbs off and on), the Pi and electronics board.

 

This is my Lamp shade template, not an attempt to summon demons using garage materials.

This is my Lamp shade template, not an attempt to summon demons using garage materials.

To make the lamp shade, I used the thick steel wire and built a template on plywood. I drew a circle using a pencil and twine connected to a wood screw in the center of the circle. (A trick that I used many times during this build) More wood-screws held the wire in

2013-04-08 14.27.06

place while I soldered it together. This worked really well with a few caveats. Because the wire was under tension after welding it to keep it’s circular shape, welding cross-braces was problematic because the hot steel was ply-able enough to bend. Also, it’s just plain hard to make a nice, round circle even without the welding problems.

My LED platform base kind of looks like a wood-shop sun-dial

My LED platform base kind of looks like a wood-shop sun-dial

 

Lastly, the LED holder was done using a thin but durable board. I drew the initial circles using three strings, one had the outer diameter, another was the inner diameter and the final one was where the LED’s would be situated. I used the angle markings on a cheap protractor/square to get the rotational position of each LED; 60 LED’s, so I put one LED at every 6th degree. (360 degrees / 60 LEDs). Then, I cut out four holes from the center of the disk to allow light from the bulbs through, but left a wide column to keep the disc sturdy for the LEDs.

Electronics Hardware

Looks more like I'm building a robot than a lamp.

Looks more like I’m building a robot than a lamp.

For the electronics portion I breadboard-ed out a ws2801 LED string using the schematic on Cody Ledbetter’s blog. Hooking them up is really simple. There’s four wires coming from the LED string, the Yellow wire (DI, on the LED string I used, the four wires are labled on the small PCB embedded in the plastic below the LED) should connect to the Raspberry Pi’s MOSI pin. And the Green wire should connect to the SCLK pin. The red and black should be +5 Volts to the red and Gnd for the black. Note that you’ll probably need a beefy power supply if you plan to control many lights and definitely more than the small usb power supplies used for Raspberry Pi’s.

The two light bulbs in the fixture are wired to the Power Switch Tail 2, which made it safe and easy to control them from the Pi. I simply connected a GPIO pin to screw terminal 1 (+in) and ground to 2 (-in).

My soldering skills are improving! :D

My soldering skills are improving! :D

I also soldered up a prototyping board next to the Raspberry Pi for future expansions. There’s an H-bridge motor driver IC connected to two GPIOs and the PWM pin so that I can add a motor and another GPIO pin broken out so that I can connect other LED’s.

Software

The software was really exciting for this project. I’ve built lots of things with Arduino and it can be a lot of fun but it can also be limiting. To get this up and running quickly enough for the contest I’ve written a simple bit of code that will act as a web server, accepting commands over http that can control all the functions of the lamp. It works likes this:

To turn the bulbs off and on, send this command:

  •  http://[ ip of Pi ]:8080/?light=[ off or on ]

To change the ‘mode’ that the string lights are in

  • http://[ ip of Pi ]:8080/?mode=[ Integer of mode you want to select ]

The ‘Modes’ allow you to switch the functionality of string LEDs. Mode 0 is LEDs off, Mode 1 is the color swirl pattern that came with Lady Ada’s ws2801 example; and mode 2 is an analogue clock. However, I plan to create new and more useful modes. Like one that will tell me the weather and surfing forcast, along with whether the house is secure or not. I also thought about a music visualizer, a rain simulator and many more! The fact that I can ssh into a full development environment to code new functionality without taking anything apart is amazing and really shows the power of embedding a Pi into something.

Conclusion

This is the first personal project I’ve ever done that wasn’t only for the fun of it. It was stressful in some ways but also really rewarding and challenging. For instance, given more time, I probably would have used a service like Ponoko to CNC cut the LED holder. But with the time crunch it was cool figuring out how-to create and cut the shape and solve the LED spacing problem. ( I got some help on this ;) Thanks Corey! ) I hope that if anyone wants to recreate this or some variation thereof that I was explicit enough in my directions and code commenting. If not, please feel free to email me at falldeaf@gmail.com or leave a comment in the comment section below!

I plan on adding some more features in both hardware and software, so if you get a chance, check back here!

Oh, and here’s the injury tally for anyone keeping score:

2013-04-10 16.34.15Injuries sustained:

  • Minor lacerations (Steel is sharp after you cut it)
  • Sub-dermal irritatants (The lamp was chock full of insulation)
  • Welding Tan (New to welding… didn’t know this was a thing. Wear sunscreen!)
  • Severe Burns (Metal is very, very hot after you weld it, there’s probably room for a Captain Obvious Meme here…) 

Ok, that’s all, Thanks for reading! :)

--

Hey thanks for reading this far! Maybe you'll be interested in more of my projects? Check out my homepage :)
This entry was posted in Hardware and tagged , , , , , , , , . Bookmark the permalink. Follow any comments here with the RSS feed for this post. Post a comment or leave a trackback: Trackback URL.

2 Comments

  1. Ben
    Posted May 23 at 11:03 am | Permalink

    Hey, i really love this project but i’m asking a question : can you synchronize it with you tv ? I mean, you take the color of the image on you tv (an average color, i don’t know if you understand but it’s like you calculate which color is the most used in the picture or i don’t know…) then you make it with the LEDs, that’s the kind of atmosphere i want when i watch a movie.

    • Posted May 23 at 11:45 am | Permalink

      This is a great question. Since building this I’ve been working on a more sophisticated software package and I’ve gotten it to do some neat things! To answer your question, that is definitely a possibility. I’ll email you a link after I’ve posted the code I’ve written. :)

      Also, if you’re interested in lots of LED’s synchronized to television video output, check out my latest post. I built an Ambilight clone and wrote a very descriptive tutorial on how to replicate it! http://falldeaf.com/2013/05/the-ambilight-clone/

5 Trackbacks

  1. […] Check out this RasPi circular LED display project tutorial from falldeaf. The Cloud Lamp Project: […]

  2. […] Cloud Lamp Project: falldeaf shared his RasPi circular LED display project tutorial — The Cloud Lamp Project: “After […]

  3. By The Pi Control Script on Jul 08 at 11:20 am

    […] projects have used it’s small form factor to control all types of things. For example, the Cloud Lamp project, that I recently […]

  4. […] Many projects have used it’s small form factor to control all types of things. For example, the Cloud Lamp project, that I recently […]

  5. […] ที่มา http://falldeaf.com/2013/04/the-make-contest/ […]

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">