2.5 Press Play

MINI LED LIGHT SHOW

I recreated one of my recent favourite songs : Oksami - Midnight Diner. It has a quirky tune.


INSTRUCTIONS
SUPPLIES:
• Bread board
• 1 Arduino board
• 7 LEDs of multiple colours
• 7 resistors
• 9 wires
Step 1: LED WIRING
• I used my online tinker board as a model to help set up:
I used LEDs of distinct colours (red, yellow, green, blue ,white)
• Each LED was placed across the centre divider: Negative end (short leg) in the left terminal rows, and Positive end (long leg) in the right terminal rows.
• I pinned them onto the exact row numbers (for even spacing + base/treble separation), in rainbow order.
And then, parallel to the LEDs (same row numbers), I added:
• The resistors: from the bus strips across to the terminal rows
• The jumper wires (with corresponding colours): Onto the RHS of the terminal rows
On the Arduino, I plugged each wire in order, into the ports (1-7).
I connected a black power wire from the left bus strip to the GND (ground) port. And the hardware is set up!
Step 2: CONNECT ARDUINO TO DEVICE
I connected the Arduino to my MacBook using the Arduino software (app)

Step 3: CODE
Google doc link

I pasted my code into the Arduino app, and pressed upload to play my LED light show:
START: TEMPO 1
TEMPO 2


REFLECTION - HOW ELSE COULD I USE THIS SCRIPT?
I think that a relatively simple song script like this is quite flexible, and can be adapted in many ways, as it has linear properties.
• It can be scaled up - for example, creating an extravagant display by using large light panels with a variety of colours and patterns, or using other mediums other than light, (such as water, or drones) , to create a visual experience. Combining different senses can enhance the mood - e.g. we can make the sensory experience of a concert more impactful if we have a  visual light display like this to match with the beats and the 'booms' of the song.
• Or, we can scale down,  e.g. making a mini circuit with small lights which could fit in a neat keychain which could also play the song (powered by a watch battery). In my childhood, I had collected small, interactive, keychains like this.

Here are some examples of funky projects we could create with the script- a display (water fountains) and a product (keychain) where each component (ground light & water streams/key) is lit up according to the song notes.


CODE MAKING PROCESS


"Test song" : Mary had a little lamb
I initially started with this simple song - I figured I could fit the basic tune using 3 LEDs.

Plan:
I used my phone's stop watch while recording my fingers tapping, to figure out the tempo I wanted. I then drew a note diagram which gives good clarity for the coding stage.
Running test: Tinkercard
I used tinkercard (an online circuit software) to simulate the real board (using the guideline example + an extra bulb) and tested the commands out.


Oksami - Mignight diner
From the previous song, I realised that I could actually do much more with the basic elements, so I gave myself a bit of a challenge. I chose this song, as it has a quirky transition in tempo (beat drop) and has scales.


Plan
This time, recreating the song meant I had to copy the tempo exactly. I used diagrams and charts to convert the song to code:
- I used a stopwatch to record the of a bar: (duration of x bars / x).
- I counted the number of notes (+ their duration + number of repeats) per bar
- As I had a beat on top of the main tune, I used the vertical charts to find the delay differences.

In reality, I had a sheet scribbled over with calculations, which I edited while experimenting. But here is a neat and simplified version of my working:

Test run:
I again used tinker card to simulate the circuit song, (this time with multiple LEDS), and  synced it by playing the song on my phone to see if anything is off, making adjustment accordingly. Then it was ready to take to the studio!