Skip to content

thompson318/BirthdayCandles

Repository files navigation

Virtual Cake

Cake, Real and Virtual

Author: Stephen Thompson

When confronted with the need to avoid children blowing out candles on an actual cake, the obvious solution was to build a virtual cake, with on screen candles controlled by a set of wind turbines. Here it is, as featured in the MagPi, the future of cake.

The project utilises a Raspberry Pi, an analogue to digital converter(ADC) like this one from BC-Robotics, and a set of DC turbines, like these from Sntieecr.

The software here consists of a Python library (main.py) to query the voltages on the ADC in response to POST requests from a javascript front end (static/happybirthday.js). We use Flask to create a web application overlaying various animations to give the appearance that blowing on the wind turbines blows out the on screen candles, shown above rendered with Minecraft.

Under the cake, the Raspberry Pi and 16 Channel ADC HAT.

Under the cake, the Raspberry Pi and 16 Channel ADC HAT.