The Milk Can
An old fashioned Milk Can that takes you into the process of how cream, butter and cheese are made.
In my project I wanted to incorporate the shaking motion and show things on my LCD display. This shaking motion reminded me of my childhood when I used to make butter by shaking buttermilk.
You can read more of my progress down below.
Downloads
Supplies
Supplies:
Arduino Uno
USB-A to USB-B cable
Powerbank
0.91 inch OLED Display (128 x 32)
SW-420 Vibration Sensor
MPU6050 Gyro Sensor
7x Jumper Wires M/F
8x Jumper Wires M/M
Breadboard
Tools:
Craft Knife
Soldering Iron
The Design:
1x (small) pringles can
1x Cork
Iron wire
Silver paint
Glue (I used contact cement)
Tape
Craft Foam
Programs:
Arduino IDE
The Idea & Some Iterations
I wanted to do something with the vibration sensor, I think the idea of using movement could be a fun interaction to implement in my project.
I wanted to combine this together with my LCD Display, but unfortunately after some time the display couldn't handle the code anymore and began crashing randomly.
My idea then fell onto some sort of game with sound but I didn't have any components that could play sound.
In the end I got the display to work again and began thinking about a fun little minigame.
The shaking motion reminded me of the process of transforming milk into butter and such, I have done a lot of this during my childhood and it inspired me to make something similar!
So my whole idea turned into a fun and educational way of showing how butter is made!
Downloads
Checking the Type of OLED Display
Most of the manufacturers you buy from mention what type of display it is (I'm using an 0x3C type)
You're gonna need this data to fill in the screen address in your code.
If your manufacturer does not have this included, there's a really good tutorial online!
Downloading the Libraries & Testing Your Components
What I found useful is checking out if your components are working. Then if later in the project a problem occured I could see if it's a power/wiring issue or a component problem.
If you're not sure if your components are working you can test them out using the examples from the downloaded libraries.
In this project you'll need to download the following libraries from the library manager:
- Adafruit SSD1306
- MPU6050
Downloads
Assembling
After testing I began assembling everything together.
I made sure that LCD screen and the Vibration Sensor would stick out the most from the components so I'd have the freedom to put it anywhere later in the design.
Coding
I started by using the base from the example code from Adafruit, make sure to change the Screen Address accordingly (Check 2 ^)
Then I made sure to add the MPU6050 Library so everything's connected.
In the code I wanted to incorporate the "steps" you're taking to get to the end. Each step is a different function, the functions automatically start a loop that can only continue if you meet the criteria (an amount of shakes).
To add a layer of difficulty, the gyrometer's Y-axis has to be upside down at some steps. (Do this by including "|| or &&" inside the parameters)
The printlines are in Dutch, feel free to change them!
The Design
I won't go too deep into the design, but once you have a small pringles can, cut open a small hole the size of your LCD Display.
Make the lid match the shape of an old milk can. Add some handles by using iron wire and a cork.
Then spray paint everything apart from the cork silver and it's done!
Assembling Everything Together
Before you solder make sure your plate, arduino and powerbank all fit inside the pringles can.
Solder everything together and tape your LCD display behind the hole you cut into the pringles can.
Then put everything inside the pringles can and your powerbank aswell.
Now you can start shaking your own butter and cream!
Downloads
Conclusion
This makes for a cute interactive design. I really wanted the design to scream what the intentions would be and I think that succeeded.
During this project I had some issues with fitting everything together inside the can, but it ended up fitting just right.
The trouble I had with the code was quickly solved with some trial and error (and I mean a lot!) Ultimately this was really fun and inspired me to come up with more projects.
Also note, in the future it might be a better if I could take it apart after it's done. Unfortunately it's now glued to the pringles can and all the things inside can no longer be used.