Side projects

Smart Fridge Part 1

As a tech-enthusiast, I like making dumb devices smart. For example, a couple of years ago I created a smart mirror (I’ll elaborate on it in a different article).

It’s the combination of boring practical things with simple, but modern/futuristic improvement that makes me love this realm. I admit. I’m a geek. I like those stuff. When a new microcomputer is available, I compare it to other microcomputers, and sometimes I even purchase it. I use them in my IoT projects.

What is IoT

Almost all our electrical appliances at home have a sort of microcomputer. Some can control heat. Some can clean our clothes. Each appliance is stand-alone. It’s there. It can do X, Y, and Z but nothing more. It (in most cases) doesn’t support software upgrades too.

Once we connect the appliance to the internet, we get a new interface to this device. Suddenly we can control it without pressing its buttons. We can get some information regarding the operations, and also automate the machine to do something for us. For example, I can tell my robotic vacuum cleaner to start working every day after I leave the house. Finally, we can upgrade the machine to an advanced version and get new features and fewer bugs (I hope).

IoT is an acronym for “Internet of Things”. It’s the name for those devices (“things”) that are now connected to the internet.

For example, connecting the AC to the internet can help us by turning it on before we get home so our place will be warm and cozy (or cold and refreshing) before we arrive.

Refrigerator

I assume you already know what a refrigerator does, so let’s talk about how smart it is.

Modern devices can do lots of smart things including connecting to the local WiFi network, but usually, they’re very expensive.

What if I already have an excellent fridge? It’s efficient, reliable, practical and looks nice. I don’t want to replace it with an expensive one, right? I just want to make it smarter. I want to connect it to the internet. This is what I did. Sort of.

You see, I can’t reach the motherboard of the fridge and a WiFi dongle. Thus, I bought a Raspberry Pi (RPi) microcomputer. It’s a tiny device that runs Linux OS (and Windows 10 for IoT) and has few IO interfaces (like USB sockets, WiFi interface, and more).

Since it runs Linux, I can install Python and run code on this small device.

Great. I can run Python code on a computer. What’s the big deal? Where is the Smart fridge thingy?

Motivation

When I go to the supermarket to buy some groceries, I (sometimes) forget what’s going on in my fridge. It makes me think very hard. Do I have lettuce? Do I need more cheese? Did I finish the onions? What about eggs?

Usually, I prefer to buy and find out that I already have tons of onions instead of not buying them at all. This procedure overloads my fridge and put pressure on my tummy to eat the food since I don’t like throwing food away. If I could only know what’s going on in my fridge when I buy those things. How can I take a glimpse on my fridge while I’m not at home (and no one else is there)?

Smart Fridge

By attaching a small camera to the fridge’s door, and connecting it to the RPi, I achieved a digital eye that captures pictures of my fridge content every time I open it. Then, I connected my RPi to the local Wi-Fi network and wrote some code for uploading the pictures to my Google Drive.

Since the application is also installed on my smartphone, I can browse those photos while I’m away.

Note that I bought an ultra-wide camera lens, so it captures the entire fridge in one shot.

In the next article, I’ll elaborate on the software design, issues I encountered, and more. Stay tuned!


If you have any questions feel free to comment or contact me directly.

Thank you for reading this. Please share and visit soon again,

Orian Zinger.

5 thoughts on “Smart Fridge Part 1

  1. Nice idea(about camera)
    U can also put inside a home security camera, connected to wifi and configured to activate on every movement . The problem is the minimum temperature that camera can support..
    Keep going 👍👍

    Liked by 2 people

    1. Besides the problem of low temperature and humidity, there is another one. Some fridges contain metal doors, so they become a Faraday cage that blocks/interferes with the Wi-Fi connection. The RPi isn’t located inside the fridge, but outside.

      Liked by 2 people

Leave a comment