Danielle Lafarga

Daniel Yi

MR MEESEEKS HEAD

Motivation and concept

Because of advancements in technology, it is not uncommon to see people using lights as a part of their wardrobe, especially at music festivals. Famous artists like Deadmau5, Daft Punk, and Black Tiger Sex Machine are known for their helmets that light up and change with the music as they perform. Many have taken it upon themselves to recreate such helmets – and so will we.

Most of the helmets out there are variations of Deadmau5’s helmet. We will use this as our base but modify it to look more like the character Mr. Meeseeks from the popular television show, Rick and Morty. This is one of our favorite characters from our favorite show, so we want to pay tribute to him by bringing him to life. We will take advantage of his large eyes by fitting all of the LED’s into his eye holes.

Function Definition

Using two sound impact sensors and a separate sound detector, we will break down music into three different threshold sensitivities corresponding to three different colors. Each time a threshold is met the sound impact sensor will return a 1, otherwise it will remain at zero. When a sensor returns a 1, the LEDs corresponding to that sensor will turn on. The separate sensor will read volume levels and map to brightness levels.

Sensors

The sensors we will be using are two Parallax Sound Impact Sensors and a Sparkfun Sound Detector. The Parallax Sound Impact Sensors, or SIS, have adjustable sensitivity levels, perfect for on-the-go adjustments to the helmet. The Sparkfun Sound Detector (SDS) allows the output of volume levels which we use for the brightness levels. We were originally under the impression that the SIS had frequency detection capabilities but this ended up not being the case. As such, we had to reinvent our project to incorporate volume amplitudes instead. We took into consideration that the bass is typically the loudest, most prominent source of sound at festivals so we increased the threshold for that particular sensor. The Sparkfun Sound Detector did not have physical adjustment capabilities for its threshold sensitivity. We thought this would be a drawback due to its mobility-limitations but after some testing we decided to leave it very sensitive to pick up ambient noises, constantly providing illumination to the eyes at lower brightness.

Mechanical considerations

There aren’t quite mechanical considerations in our project, it’s mostly electrical. The helmet itself utilized acrylic, foam, metal mesh, and fabric. We placed the sensors in the hair for concealed, unobstructed input capabilities. The LEDs were concealed within smaller, frosted acrylic to aid in the diffusion of the light providing a wider illumination effect. For power, we took advantage of a barrel jack to screw terminal adapter for the LEDs as well as an 9V battery to barrel jack adapter to power the Arduino. The head itself is an acrylic globe which was then cut and sanded to match the physique of the character. Holes had to be drilled throughout the head to hide wires which were then taped down and secured on the inside. Due to some technical difficulties only some of the lights we were planning to use were usable. To disperse the light more we centered the lights and partially covered the smaller globes in black fabric. This not only helped patch up any unlit areas but gave the head a lot more dimension. The most difficult part in making the head was dressing it with fabric. Spheres are a very abnormal shape so we had to drape it and partially glue the seam for a more fitted look.

Electrical Considerations

The specific LEDs that we used were the Lumenati 8 Pack from Sparkfun. These multicolor LEDs are addressable, meaning we have control over each individual LED in the set, and come pre-assembled, ready for immediate use. These were placed under smaller acrylic globes, which acted as the eyes for Mr. Meeseeks. The LEDs required PWM pins so that we could control brightness, while the SIS simply utilized non-PWM digital pins. We used an analog pin for the input of the Sparkfun Sound Detector. For the sake of the presentation, we used a 5V, 2A wall adapter to power the LEDs. This method of powering our helmet is not portable, but for real-world implementation we looked into batteries on illumn.com. We originally planned to include 40 LEDs in our project but unfortunately due to unstable connectivity issues as well as constant solder and unsoldering, the Sparkfun Lumenati 90L’s we purchased ended up breaking. As such, we only used 16 LEDs. Each LED requires about 60 mA of current. As such, we considered using anywhere from 3500 – 5200 mAh (milliamp hours) batteries. The wide range was a result of uncertainties in the brightness levels the LEDs would achieve. This would require further testing in an actual musical festival environment.

Interface

The LEDs will be hooked up to PWM pins. The Sound Impact Sensors will be hooked up to standard digital pins while the SDS will use an analog pin. As mentioned previously, the sensors were housed in the hair while the LEDs were hosted by the eye holes.

Software

Each SIS returns a binary 0 or 1 given a certain threshold intensity level which will turn on specified LEDs, while the SDS will send analog inputs to control brightness levels. Luckily for us, there exists a pre-coded library called FastLED. This library allows us to define a set number of addressable LEDs, create an array of each LED, and control each LED based on its position in the array. This library condensed the code quite a bit but the real software challenge was the initial LED setup. The Lumenati 8-pack comes nicely labeled which helped us determine which LED would be in which position. The issue now was connectivity and color schemes. Oddly enough, the LEDs did not attach themselves in a standard RGB formation. There were different variations in which we attach the colors with the BGR formation being the one we needed. On top of that, we initially attempted to utilize threaded wire, as suggested by Professor Barreiro, but unfortunately plugging these into the Arduino was a problem. As such, we would get random LED hits and the color scheme seemed to be inconsistent. We rectified this buy purchasing pre-assembled threaded wire with pins.

Code

#include "FastLED.h"

#define NUM_LEDS 16

#define DATA_PIN_MID 11

#define CLOCK_PIN_MID 13

#define SIS2 3

#define SIS1 5

CRGB leds[NUM_LEDS];

int i, x, state1, state2, amplitude, brightness;

void setup() {

pinMode(SIS1, INPUT);

pinMode(SIS2, INPUT);

FastLED.addLeds<APA102, DATA_PIN_MID, CLOCK_PIN_MID, BGR>(leds, NUM_LEDS);

Serial.begin(9600);

}

void loop() {

state1 = digitalRead(SIS1);

state2 = digitalRead(SIS2);

amplitude = analogRead(A1);

brightness = map(amplitude, 0, 350, 50, 255);

Serial.print("Amplitude: ");

Serial.println(amplitude);

if(amplitude > 15 & state1 == LOW){

leds[0] = CRGB::White;

leds[8] = CRGB::White;

}

else if(state2 == HIGH){

for(i = 0; i < NUM_LEDS; i++){

leds[i] = CRGB::Maroon;

}

}

else if(state1 == HIGH & amplitude > 15 & state2 == LOW){

for(i = 1; i < NUM_LEDS/2; i++){

leds[i] = CRGB::SeaGreen;

}

for(i = 9; i < NUM_LEDS; i++){

leds[i] = CRGB::SeaGreen;

}

}

FastLED.setBrightness(brightness);

FastLED.show();

FastLED.delay(70);

for (x = 0; x < NUM_LEDS; x++)

{

leds[x] = CRGB::Black;

}

FastLED.show();

}

Parts required

Sparkfun Lumenati 8 pack (x2), 14” acrylic globe, 6” acrylic globe (x2), Sparkfun Sound Detector, Arduino Uno, Parallax Sound Impact Sensors (x2), wires, 9V Battery, 9V to Barrel Jack Adapter, Barrel Jack to Screw Terminal Adapter, fabric, hot glue, metal mesh, foam.

Testing

To best simulate a music festival environment, we utilized a keyboard amp owned by Daniel. We turned the low frequencies up to imitate the typical EQ setup in festivals. Unfortunately, due to neighbors and such, we could not quite calibrate our sensors to the estimated real-world implementation level. As a result, we simply set up our project to best demonstrate the different aspects of our sensors and LEDs as would be the purpose of our in-class presentation. We had to play around with different sensitivity levels and color schemes to find the setup we thought would make it easiest to see the versatility of our project.

Safety

The wires we used were set length, male-male, male-female, and female-female ends. This required us to make chains of wires throughout the helmet. For safety reasons, due to possible electrical discharge, we wrapped each connection in insulation putty. We secured each wire along the inside of the helmet with tape to prevent tangles and interactions with the human head present inside the helmet.

De Scope Option

We originally planned to use frequency as the input. As mentioned, the sensors did not quite come programmed with this function. As such, we de-scoped our project to include amplitude levels instead. We were also forced to make do with less than half our originally intended LEDs due to breakages.

Expansion Option

As mentioned previously, our project currently is limited to a fixed area due to outlet dependence. After further testing, we will add a battery pack designed to last the length of a full festival. This battery pack will be based on our assumption that each LED requires 60mA of current at full power. We may be able to get away with a smaller mAh level due to the fact that the LEDs will not always be at full brightness, depending on amplitude level.

What We Could Have Done Differently

We were very disappointed that we were unable to incorporate frequency into our project. Although our project worked flawlessly in the demonstration, volume levels don’t quite provide the precision that could be gained by using frequency as an input. With frequency ranges, we would be able to achieve our output with just about any volume intensity, specifying different colors to different frequency range inputs, and allow for fun color patterns based on repetitive input patterns and the like.

Who Did What

Dani received the SIS and tested their connection and uses. This was then passed onto Daniel, who tested and wrote the code to send the SIS and SDS data to the LEDs while Dani made the helmet. We then met up at lab to put everything together.

Conclusion

All in all, this project was very enjoyable. To certain demographics, we feel this project is extremely usable and relevant. Although our project did not seem as mechanically in-depth as some of our classmates, it is something we were both passionate about and took many hours of careful adjustments and calibration. This project also has endless expansion capabilities and personalization aspects that we are likely to explore in the future. Even though we went through a few hiccups, endless attempts at soldering and very dangerous acrylic cutting, we believe we have learned a lot and hope to continue to hone the skills we have acquired in this class. Thank you for a wonderful quarter and have an amazing winter break!