Home > Uncategorized > ArduinoLight Update

ArduinoLight Update

I’ve been running an updated (and I think improved!) version of my ArduinoLight project for some time, so I figured it was time to post some details about it.


Firstly thanks to the users who posted comments in my last post about this project. It helped me track down some mistakes I made. Hopefully now the system is a bit more robust now and more people can pick it up and use it.

To upload the Arduino section of this project to your board you’ll first need to download Adafruit’s WS2801 library from here. You can find some instructions on where to install this library here. You should then be able to hit verify or upload in your Arduino IDE and successfully compile the sketch.


Well for a start the LEDs are no longer mounted on cardboard! But as that’s not too much of a technological challenge, I’ll move on to the more interesting things that I’ve modified.

A lot of the changes that I’ve made are minor GUI changes and behind the scenes fixes to improve the functionality and general stability of the C# control panel application and the screen capture library.

One of the biggest changes I’ve made is to enable the “Active Scripts” functionality in the “Background” tab of the Control Panel. This allows you to compile small C# programs to generate your own lighting effects.

This picture shows the window that allows you to edit or create scripts. As an example, included with the Control Panel are 3 active scripts:

  • Colour Sweep – Sets all LEDs to red and then sweeps them all through the entire spectrum.
  • Fire – Gives the effect of flickering embers behind your monitor
  • Rainbow – A psychedelic colour show behind your monitor
Getting C# to compile it’s own code is quite an interesting topic and I may write up some kind of tuturial about how I achieved it at some point. So keep checking the site!
In the mean time, here’s a video of the improved application which shows how smoothing out colour changes using fades can really give a better effect than my previous video.

And here’s the download link to the latest project: Download

  1. CK
    May 11, 2012 at 3:12 am

    Nice Work. Is there a download link for the source code. I’m curious to see what you did to keep the colour changes so smooth.

    • May 12, 2012 at 7:36 am

      Hi CK, if you click the download link just below the video you’ll get my C# control panel app as well as the Arduino source code to upload to the board. The smooth colour changes are actually handled by the Arduino so you can see how I achieved this just by reading that code.
      In the sketch file you’ll see that I don’t just have the current RGB colour for each LED, I also have a source and a destination colour and have defined the number of milliseconds to fade over. When the PC sends some colour values to the board, the destination colour values will be set to this and the board will then spend the next few milliseconds fading from its current colour to that destination colour.
      I hope that helps you. As always, feel free to ask plenty of questions!

  2. Matthias
    May 11, 2012 at 1:28 pm

    Thank’s a lot! Really great Programm! 🙂

    But I have a little prob: I’m using the “Video Capture-Mode” (works great too), but I’ve on the bottom of the screen 8 LED’s (3 on each side, 2 in the corners)
    Is there a way to change that in the programm, or must I reorder my LED’s?


    • May 14, 2012 at 3:53 pm

      At the moment I’m afraid that the only thing you can really change is the Arduino sketch. You could do a bit of hacking on that to get close to the effect you’re looking for.
      There’s still a few things I’m planning on doing with this program. One thing I’d like to do is to neaten up the code and release it so that people like you can modify it to suit there needs. Another would be to make things like the screen capture regions configurable. It might be quicker for me to do the latter of these 2. Hopefully I’ll get some free time soon and be able to make these changes! I’ll post up any updates I make as soon as I can.

  3. Ale
    June 11, 2012 at 8:00 pm

    Is it possible to give a peek to the Control Panel source code? I’m curious about it 😉

    • September 8, 2012 at 9:22 am

      Hi Ale, sorry it took so long but you can now download the source for the control panel on my applications page.

  4. Jeremiah Berndt
    September 7, 2012 at 2:18 am

    I don’t know if you will read this but I am once again/finally trying to get this program to work. I am having no such luck and can’t seem to figure out what is going on. With your new update it still does the same errors for me. Now if I click Active Scene it completely errors out and asks me to ignore, continue or quit. I can always get it to color swipe but when I run the program nothing is sent to the Arduino properly even with a proper compile code on it. Do I need to put a file into a certain location or can it all be ran from the downloaded file without needed to do anything else?

    • September 7, 2012 at 7:45 am

      Hi Jeremiah, I’m glad to hear you’re still trying this project out. I’m just sorry it’s not worked yet. I plan on adding my adalight work to my applications page (hopefully this weekend) just to make it easier to find. I’ve done a few updates since my last posts so hopefully that will have improved things. I’ll try to put up the source code with the binary. It’s not as neat as I’d like it to be yet, but it may help you figure out what the issues are. Are you still using the Uno board? Because I’ve spotted a few posts around the net of people struggling to get the Adalight strips working with the Uno.

      • Jeremiah Berndt
        September 7, 2012 at 12:07 pm

        What board are you running because I am using the Uno board. I have actually tried on 3 different computers with no such luck. I can use the board for basic commands and everything functions properly. Just anything that is coming from the program doesn’t seem to register with it.

      • September 7, 2012 at 2:05 pm

        I’m using the duemilanove. It sounds like the errors you’re currently having are from my C# code so don’t worry about the board for now. Hopefully if I put the source code up we’ll be able to figure out where your issue is. I just wanted to double check what kit you’re running on.

      • Jeremiah Berndt
        September 7, 2012 at 2:12 pm

        I will try to borrow a friends duemilanove board to rule it out. I recently purchased a webcam, I will take a video of what is happening and post a YouTube video of the problems I am running into so you can visually see instead of it being explained to you.

      • September 8, 2012 at 9:21 am

        You should now be able to download the latest installer and source code from my applications page. Hopefully that’ll help you debug the program.

  5. Kokoloko
    February 8, 2013 at 1:03 pm

    Hi there,
    well I’m a noob, so could you provide some instructions on how to get this working? I have a running Adalight setup, but it’s a bit slow.
    I don’t know what to upload to my UNO, and how to continue…

    • February 10, 2013 at 10:59 pm

      Hi Kokoloko,
      The first thing you’ll want to do is grab the source code from the download page. If you open up that 7zip file and navigate to the ArduinoTaskerLight directory you’ll see a file called ArduinoTaskerLight.ino. You should open this up with your Arduino IDE and upload it to the UNO board (last time I checked, some people were having some issues with the UNO board so I’d be interested to see if it works ok for you).
      Once that uploads successfully you’ll want to grab the “TaskerLight” installer. This will install the Windows Control Panel program onto your computer. When you start that up it should communicate with your UNO board and hopefully show some pretty lighting effects!
      I hope that helps. Feel free to come back and ask more questions.

  6. Jeremiah Berndt
    April 17, 2013 at 1:30 am

    I have moved and put away my Arduino and once again brought it back out to see if I could get this going. I still get the same result and even got the new rev. 3 Uno, which seems to work just a little bit better but I have no clue why. Every other setup I use works flawlessly but not yours. I want to use yours, since you said it grabs info from the gpu and every one uses screen capturing. Screen capturing slows my computer down, the OS gets laggy and a lot of apps can’t be used with it due to images going straight to the gpu and bypassing other methods. My last resort is to get the same Arduino board you have and I was wondering which one it was. I remember you mentioning the Duemillinove but I was sure with one of the two type they sell. Hopefully it is the Atmega328p-20PU due that is all I am finding.

    • April 25, 2013 at 12:03 pm

      Hi Jeremiah, I believe that the Duemilanove board that I have used is the one using the ATmega328. I’ll have to double check that for you but that’s what I think it is. How much debugging have you done on your board to see what data is actually reaching it? e.g. have you tried echoing some data back down the serial and outputting it on screen to see what is being sent back and forth?

  7. Jeremiah Berndt
    April 26, 2013 at 1:00 am

    I haven’t done any echoing to see what data is getting back and forth. My knowledge with coding is still very limited, since I am learning as I go. Use to know things in college but that was quite a bit ago and I didn’t keep on using. So use it or lose and I didn’t use it. I had recently tried an Uno R3 (I have the Uno R2) and I actually saw some improvements so I believe it to be the usb-to-serial chip. The R3 has the new ATmega16U2 chip and the R2 had 8U2. I have see that the Duemilanove has a more tried and true usb-to-serial one that has been in a lot of other computer components. Would your application also work with a raspberry pi? My brother is starting to use that and he knows a bit more about programming that I.

  1. No trackbacks yet.

Tell me what you think!

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: