Art, Arduino, Sound Sensors, LEDs, and Star Wars!

Regular drawing and painting just didn’t seem to fit the bill of a creative outlet for me, so I decided to design my own mix of art, Arduino, LEDs, sound sensors and star wars all sprinkled with a little computer code.  The end product is a MASSIVE (4’x5′) Star Wars art piece with lights that wirelessly dance to the beat of the music.  I hope this inspires you to build your own.

The list of supplies:

For the tech side:


I got all the tech working by compiling an uploading the following code to the Arduino:

#define REDPIN 5
#define GREENPIN 6
#define BLUEPIN 3

int redNow;
int blueNow;
int greenNow;
int redNew;
int blueNew;
int greenNew;

void setup()
pinMode(7,INPUT); //SIG of the Parallax Sound Impact Sensor connected to Digital Pin 7
redNow = random(255);
blueNow = random(255);
greenNow = random(255);
redNew = redNow;
blueNew = blueNow;
greenNew = greenNow;


#define fade(x,y) if (x>y) x–; else if (x<y) x++;

void loop()
boolean soundstate = digitalRead(7);
if (soundstate == 1) {
analogWrite(BLUEPIN, blueNow);
analogWrite(REDPIN, redNow);
analogWrite(GREENPIN, greenNow);
redNew = random(255);
blueNew = random(255);
greenNew = random(255);
// fade to new colors
while ((redNow != redNew) ||
(blueNow != blueNew) ||
(greenNow != greenNew))
analogWrite(BLUEPIN, blueNow);
analogWrite(REDPIN, redNow);
analogWrite(GREENPIN, greenNow);

Then I put all the wiring together using this schematic.


I started by tracing out Darth Vadar using a projector onto the floor under layment board.


Cut out everything that was white.

IMG_0143 IMG_0142

Glue and fixed everything I broke.

IMG_0145 IMG_0146 IMG_0147

and because I’m a bit of a perfectionist, weeks and weeks of sanding, filling, sanding, cutting (again), more sanding, and fine tooth filing with a jewelers file

IMG_0177 IMG_0169 IMG_0168 IMG_0170IMG_0207 IMG_0210

Then more cutting… this time it’s the backing plate (the MDF sheet):


This holds the LEDs, hides the wires, and provides structural support for the artistic front which we glue to next.


Now paint the back side with the chrome paint to reflect light.


LEDs were double sided taped around the outside of where I cut it out (see pic above). Paint the front with the flat black paint (I seem to have forgotten to take a pic.)  The wiring comes next following this schematic and the Arduino, sound sensor, and one of the bread boards glued to the front.  You can see I hid the wires by using a small router on the backing plate .


Then all that left is attaching the picture hangers and cleaning up.




Intro to the Arduino Board

One of my favorite quotes from Albert Einstein is:

If you can’t explain it simply, you don’t understand it well enough

So I find it stupid that Arduino tutorials would jump straight away into complicated code (called sketches in Arduino), electrical diagrams, and acronyms of complex electrical terms.  Arduinos are an awesome, cheap, and easy way of learning robotics. They’re so simple and should really be explained that way (at least initially), so in this blog post I will set out to do just that.


I’ll be explaining the Arduino Leonardo, built through Borderless Electronics, obtained through an Indiegogo campaign for a whole $9, and pictured below:


While it has some advanced things that differentiate the Leonardo from other Arduino micro controllers, the big difference is that by having only a single processor they can emulate a mouse and/or keyboard.  In lay terms, you can make a keyboard/mouse that amputees/spinal injuries control without their hands, or a glove that can control a quadracopter.  Pretty awesome, huh?

Digital Vs. Analog Pins

Analog input pins( A0-A5) are on the bottom left, and the digital pins (0-13) are on the right side.  I’ve highlighted both in the below pic


The difference between the two is actually so simple and is usually overcomplicated with voltage diagrams.  An Analog input is like a dimmer switch where you can control the how much light you want from a light bulb, and a Digital input is just a regular switch where output either on or off with no in between.

AREF pin


The AREF pin, or Analog REFerence pin, is the what sets the maximum power (from the left side of the pic above) and every step from zero to max (scaled in sketches 0-1024).  The power is 3.3 volts or 5 volts but these can be change/converted through the use of different techniques (think resistors).

SDA/SCL pins


These pins are used for communicating with other devices. For example, connecting to a lego mindstorm (example build). The SDA pin sends and receives the data between the two devices, and the SCL makes sure that data is being sent and received at the same speed.



The Arduino has pins for 3.3 volts and 5 volts, but if you want to build something with more power you can use external power put into the VIN pin.  If I was going to build and RC car or the like I would be using this to up the power to the maximum (and probably blow something up)


IOREF tells whether the power supplied is 3.3  or the 5 volts, and RST is used to reset the board.

GND pin


GND is for the ground and is needed always used with the power.  It’s to complete the circuit. A battery has two poles, positive and negative. Each side of a light bulb needs to be connected to each of the poles on the battery to complete the circuit and light the bulb.

Now we know what everything does it’s time to make something cool.