Software apps and online services
Hand tools and fabrication machines
It's someone's birthday, which means making a cake, preferably with some kind of design drawn onto it with icing. But drawing accurate and to-scale shapes in icing is very difficult. You can't erase any mistakes, which can make for a very poorly made design. Like trying to make this:
So what is the solution? Well just like with cutting plywood, a CNC machine makes everything more accurate. This project demonstrates how to create a CNC machine that can extrude icing to draw shapes onto a cake with ease.
On August 14, 2018 I published a project the featured a DIY Universal CNC machine. Its tools could be interchanged easily. Building the machine is quite complex, so see this project for further instructions.
My initial project did have some flaws, however, as brought to my attention in the comments section of it. For one, the X axis belt had uneven tension. This could cause the movements to not be as precise. The X axis carriage also didn't fit onto the rail tightly enough, causing the entire assembly to tip over and grind against the rail. To fix this I completely redesigned the X axis carriage block by moving where the timing belt fits in and moving the V slot wheels to better locations, as well as adding another wheel to the back to prevent tilting.
I needed a way to extrude icing at a very controlled and predictable rate. This meant using a stepper motor. But then the issue came to generating a lot of downwards force from rotation. Gears are a known force multiplier. A small gear attached to the shaft of a motor can turn a larger gear and that larger gear can output a larger force. But then how is rotary motion converted to linear motion? That's where screws and nuts come in to play. Instead of a nut turning on a stationary screw, I had the stationary nut (attached to the large gear) move the screw up or down. At first I was going to design this in Fusion 360, but after looking on Thingiverse I came across something that suited my needs. Find it here: https://www.thingiverse.com/thing:1121655
A Particle Photon controls the stepper motor that is controlled via cloud functions. I created an HTML page that is hosted by an Apache webserver. There are 3 buttons for up, down, and stop. Later on this page will be accessed by a Raspberry Pi 3 B+ and a touchscreen.
DFRobot helped sponsor this project by sending me the new Raspberry Pi 3 B+ and a 5in TFT Touchscreen. To start I downloaded the latest Raspbian image from https://www.raspberrypi.org/downloads/raspbian/ and then using Etcher.io to put it on an SD card.
Then on another Raspberry Pi install node js by entering the following commands:
git clone https://github.com/creationix/nvm.git ~/.nvm cd ~/.nvm git checkout `git describe --abbrev=0 --tags` cd .. . ~/.nvm/nvm.sh
Then you can install and use the version of node you want with
nvm install 6 nvm use 6
and also run this command to upgrade the node package manager (npm)
npm install npm@latest -g
and finally install the control software with
sudo npm install --unsafe-perm -g cncjs
cncjs to run it. Just go to http://<RPiHostname>:8000 to access the page. Also make sure to connect a USB cable from the Arduino Uno that's controlling the CNC machine to the Raspberry Pi running the CNCJS server.
I used Fusion 360 for both designing and generating gcode for CAM. The cake pattern I chose was the Arduino.cc logo. I first downloaded an image from the web and then inserted it into the work environment by using the attached canvas function.
Then I extruded a body from the sketch.
And then I went to the CAM environment and created a setup that mimics a cake (9x13x2in).
And finally I generated a toolpath using the 2d cutting operation.
I wanted to make a simple cake, so I got a box of generic yellow cake mix and prepared it according to the directions, pouring it into a 9x13inch pan. While that was baking I made a simple buttercream from 1 cup of butter, 4 cups of powdered sugar, 2Tbls of milk, and a little vanilla. Then that buttercream got spread evenly over the cooled cake. I made sure that there were no large deviations that could interfere with the icing nozzle.
The icing recipe is very important here. If it's too runny it won't stay in place when extruded. Too thick and the stepper won't be able to extrude it. Here's what I used:
- 7 ounces by weight of powdered sugar
- 15.5 teaspoons of water
- 4 drops of blue food coloring to make what I like to call "Arduino Blue"
Now that everything's prepared, it's time to decorate a cake. First I homed all the axes, making them touch the limit switches. Then I touched "down" on the touchscreen to start the icing extrusion. Then I clicked start on the cncjs webpage to make the cnc machine follow the gcode.