Magic Candle Blowing Cupcake Tray

by dantedivincenzo in Circuits > Arduino

309 Views, 0 Favorites, 0 Comments

Magic Candle Blowing Cupcake Tray

Magic Candle Blowing Cupcake Tray

Have you ever not been able to blow out your birthday candles? Don’t have the energy? Celebrating a party virtually? Have you ever wished for a machine that could blow out your candles for you? The birthday boys have a solution for you! Introducing the Magic Candle Blowing Cupcake Tray! This not-so-useless machine is all yours for 3 easy installments of $74.99! Available in 3 premium colours: eggshell, Navajo white, and ivory!

Supplies

Machine Structure
1x 51.2cm x 77cm x 0.6cm Foam Core sheet

1x Roll of Scotch Tape

1x Glue Gun and Appropriately Sized Sticks

Electronics

1x Breadboard Breadboard Jumper Wires

1x Arduino Uno R3

2x Photoresistors

1x DC Motor

1x Fan

1x NPN Transistor

2x 1kΩ Resistor

1x 220Ω Resistor

Subject

1x Cupcake

1x Candle

1x Lighter

Features

model.jpg

-This "useful" machine acts as a sleek and stylish cake tray

-The Magic Candle Blowing Cupcake Tray detects when a candle is lit on the cake, and effectively blows it out

Theory

Exploded View.jpg

Photoresistors

-The resistor has a very light sensitive material on its face that reacts to changes in incident light, and when incident light increases, the resistor’s resistance in the circuit decreases. We use 2 parallel circuits connected to analog.
-One photoresistor monitors ambient light, and a second photoresistor detects light in the range of the cupcake’s candles, and when the difference is substantial enough, logically the machine assumes a lit candle is in front of it. This process isn’t infallible, as the ambient sensor can be tricked by casting a shadow over it to generate the accentuator value

DC Motor

-Detection of a candle in front of the photoresistor starts the motor. The direct current motor converts electrical energy from a digital pin, which is passed into it upon lit candle detection from the photoresistor into mechanical energy, thus powering the fan. More powerful fans can be substituted, though not illustrated in the Fritzing Diagram.

Fan

-Once the motor powers the fan, its blades start spinning, which creates air pressure and causes air flow forwards
-This air flow moves towards the lit candle and blows it out

Connecting the Circuit

Useless Machine_bb.png

1. Power Pins

a. Connect the 5V and GND pins to the positive and negative rows along your breadboard respectively

2. Sensory Pins

a. Make 2 parallel circuits complete with photoresistors and 1k Ω resistor in each connected by wires

b. Link each circuit to either the A0 and A1 analog pin (keep in mind A0 will sense candle brightness and A1 ambient brightness)

3. Motor and Fan

a. Connect the motor with fan attached to the breadboard and transistor, along with the corresponding wire connections to the power, grounding line, and 220Ω resistor as displayed on the Fritzing diagram. Make sure the motor is rotating in the right direction and blows forwards. If not, reverse the wiring.

Constructing the Tray

IMG_7263.HEIC.jpg
IMG_7256.HEIC.jpg
IMG_7257.HEIC.jpg

1. Cut and glue foam core to create a box for the base of the machine

2. Construct a second box facing upwards with the displayed holes, and on one end of the base box to house the breadboard and hold the motor

NOTE: Be sure to have the motor and attached wires fed through the top hole before securing the top surface of the box with scotch tape

3. Secure the motor with scotch tape atop the roof of the box

4. Feed the photoresistors through the holes and use scotch tape to secure them

NOTE: Photoresistor connected to A0 should be protruding from the front hole, while the photoresistor connected to A1 should be protruding from the same opening as the motor

Writing the Code

Screen Shot 2022-03-09 at 10.01.52 PM.png
Screen Shot 2022-03-09 at 10.02.21 PM.png

1. On a computer copy the Arduino code above

2. Connect the Arduino Uno R3 to the computer with a USB cord

3. Upload the Arduino code onto the Arduino Uno R3

Put Cake in Place

Screen Shot 2022-03-08 at 9.16.54 PM-1.jpg

Once the Magic Candle Blowing Cupcake Tray is set up, use is very simple. Place the cupcake on top of the tray, light the candles, and enjoy! Or rather, light it in frustration...

Process and Troubleshooting

Initially, our team utilized a thermal resistor to detect a lit candle, but the thermal resistor we had was not strong enough to sense the candle unless it was dangerously close to the candle, making its usage a fire hazard. Because of this, we switched over to using a light as our primary input, as it picked up differences in values between a non-lit and lit candle much stronger from a safe distance.

With the decision to deviate from temperature, we pursued a photoresistor as our key sensor, but this too presented issues. Initially, we tried to have a single sensor detect when a candle was lit by assigning a light value which when reached, turned on the motor. This however constrained the applicability of the machine, because if the background or ambient lighting was bright enough, the sensor values would . While we initially thought to circumvent the issue by stating the machine can only work in dimly lit places, we engineered a solution instead. We implemented a second photoresistor, placed further away from the candle, that sensed the ambient lighting. With the introduction of a new sensor, instead of fixed values we can compare how bright the two photoresistor lights are to each other. If a significant enough difference in value is achieved, we then have a more reliable determining input for the candle’s status

Overall, these two major bumps were of several smaller troubleshooting problems within our code and circuitry, some to this day remain unexplained, but resolved. Ultimately, the fiddling with wire connections, malfunctioning results, and determining value ranges were all part of our process to create a party gag and useless, but quite sadistic, birthday machine.

Future Iterations

Our marketing team feels that in future iterations of this project, the logical progression would be to create a full birthday cake tray. This would easily conceivable simply by using larger panels for the tray base, and raising the height of the photoresistors and fan to make them level with the full cake's candles.

Our fabrication team believes that either 3D printing or laser cutting the tray itself in future iterations will make it more sleek and durable. As well, the team is planning on extending the already diverse colour palette we offer to also include cloud white, as well as alabaster. Another future iteration would be to utilize a strong thermal resistor instead of a photoresistor, to react to the heat of the candle rather than the incident light of it.