Smart Kettle With Scheduling Feature

by taste_the_code in Circuits > Gadgets

2040 Views, 14 Favorites, 0 Comments

Smart Kettle With Scheduling Feature

Kettle Hack: DIY Programmable Smart Kettle for Scheduled Brews with Home Assistant

Hi everyone! Like many of you, my days are best started with a warm cup of tea or a fresh coffee. But waiting for the water to boil each morning can be a bit tedious, especially when you're still groggy from sleep. Wouldn't it be great to have hot water ready to go as soon as you wake up? 

Well, that's exactly what I thought, and it led me to brainstorm a fun and convenient solution: an automated kettle. Now, we're not talking about any high-tech, store-bought smart kettle. Instead, I'm about to walk you through my journey of transforming an ordinary kettle, the kind we're all familiar with, into a smart one that can be scheduled to boil water right before you step into the kitchen each morning. 

Join me as I guide you through the process of automating your kettle with some simple electronics and programming magic but before we continue it's crucial to understand that we'll be working with components that are connected to high voltages. Please ensure you disconnect everything from the mains and take all necessary safety precautions to prevent electric shock.

This post is sponsored by PCBWay

PCBWay offers services for custom PCBs, PCBA, 3D printing, CNC machining, Injection molding, and more.

You can get the PCB for the project from their shared projects section.

Supplies

WARNING!

This Instructable deals with mains voltage; if you are uncomfortable working with it, please do not attempt to replicate it. By replicating the project, you accept that you understand the risks involved and that you are the only one responsible for any consequences. My version is running on 240V and it is not suited to be done for 110V as the wires handling the load need to be substantially thicker. Additionally, my kettle is rated at 1800W and it is within specs on the relay. Any higher load than that needs to be handled by a better relay!

--------------------------------------------------------------------------


Tools and materials used in the video

Device Operation Principle

MVI_1101.MP4.00_00_03_23.Still001.jpg
MVI_1101.MP4.00_02_58_07.Still002.jpg

The principle behind automating this traditional kettle is relatively straightforward. Typically, to boil water, you'd need to manually press the switch on the top of the kettle.

In essence, I have set up an electronic circuit that acts as an intermediary between the kettle and the power source. This circuit is controlled by a compact microcontroller, specifically the Wemos D1 Mini, which is programmed to operate a relay at a set time in the morning. This relay effectively takes over the manual switch's function, turning the kettle on when it's time to heat up the water.

The ingenious part is that this set-up maintains the kettle's safety feature—an automatic cutoff mechanism that turns the kettle off once the water reaches boiling point. I've used a normally closed relay which means, by default, it allows electricity to flow normally as if the kettle is plugged directly into the wall outlet. However, when 'armed', the microcontroller sends a signal to the relay to open the circuit, preventing the kettle from starting until the scheduled time arrives. By setting this time via Home Assistant to your wake-up time, you ensure that a pot of hot water is ready for you, without any waiting required.

Making the Concept Permanent

MVI_1102.MP4.00_00_07_17.Still002.jpg
MVI_1104.MP4.00_00_07_10.Still001.jpg
MVI_1105.MP4.00_05_26_04.Still001.jpg
MVI_1106.MP4.00_01_59_13.Still001.jpg
MVI_1109.MP4.00_01_37_02.Still001.jpg
MVI_1113.MP4.00_01_58_23.Still001.jpg

To start, I have a custom-designed PCB that I manufactured with assistance from PCBWay, who sponsored this part of the project. This PCB is crucial for neatly organizing and connecting the components. For the brains of the operation, I have the Wemos D1 Mini, which is programmed to control a relay. I also have the push button that enables the arming of the device, and an HLK-PM01 module to step down the voltage to 5 volts to power the microcontroller and the relay.

Here are the steps I followed for soldering the components onto the PCB:

  1. First, I laid out the components on the PCB. This included the HLK-PM01 power module to convert the mains voltage to 5V for the microcontroller, the relay in the center, and the Vemos D1 Mini on the side.
  2. Using a soldering iron and some solder wire, I soldered the components onto the PCB. This included soldering the pin headers for the Wemos D1 Mini so I could easily insert or remove the microcontroller as needed. A little tip here: when soldering, make sure to heat the pad and the pin for a good joint, and avoid using too much solder to prevent shorts.
  3. I then cut the cable that comes with the base of the kettle—one side of this cut will plug into the input of the relay and the other will connect to the output. By controlling the relay, I now control the power to the kettle.

To see the entire process it is best to follow the video at the top of the page.

Remember to take your time with soldering and double-check your connections to ensure everything is connected correctly and safely. Once everything is soldered and in place, we'll move on to putting this control board into an electrical box to make it safe and ready to use.

Placing Everything Inside an Enclosure

MVI_1102.MP4.00_00_05_08.Still001.jpg
MVI_1123.MP4.00_00_13_02.Still001.jpg
MVI_1123.MP4.00_00_45_15.Still002.jpg

Now that all the key components are securely soldered onto the PCB, the next step is to place everything inside a durable enclosure for safety and aesthetics. I'll be using an electrical box that's commonly used in electronic projects like this one.

I placed the PCB inside the box and then I carefully routed the kettle's cable into the electrical box and connected it to the input and output of the PCB as planned. I then made sure that all connections were solid and that there was no strain on any wires. Finally, I secured the lid of the electrical box, which protects the high-voltage connections from accidental contact.

Safety alert: Remember, the inside of this box has live mains voltage when plugged in, so never open it or touch the components inside when the box is connected to an outlet. Always unplug it first.

With the electrical box assembled and the electronics neatly housed within it, the automated kettle is almost ready for action. We're now down to the final steps: connecting it to your home network, programming the operation times, and enjoying the convenience of waking up to water that's hot and ready for your morning brew. Let's move on to integrating this automated system into our smart home setup.

Code

All of the code for the device is available in the related article for it on my website.

In general, the code defines a device under ESPHome with a single relay and a push button to toggle that relay. A single automation checks at a specific time if the relay is on to turn it off.

Wrapping Up and Going Smart

MVI_1124.MP4.00_06_50_09.Still001.jpg
MVI_1125.MP4.00_00_18_05.Still001.jpg
MVI_1125.MP4.00_00_42_23.Still002.jpg

And there we have it, the final assembled device is now safely tucked away in its electrical box, ready to be plugged into the outlet and armed for that perfect morning routine. The LED indicator I extended from the board serves as a visual confirmation of the system status – armed or disarmed.

Stepping into the world of Home Assistant, the YAML configuration and automation scripts allow the system to turn on the kettle based on my set schedule. The beauty of this DIY solution is the customization. You set the wake-up time once, and every morning you can expect the kettle to have boiled the water just as you're ready for your tea or coffee. It's a small change to your daily routine, but it brings an added touch of comfort and convenience. 

I hope you've enjoyed following along with this project and found it insightful. If you have, don't forget to like and comment if you have any questions. Your feedback is invaluable and always welcome! Subscribe for more DIY tutorials and projects in the future, and I'll see you in the next one. Happy tinkering, and here's to many more peaceful mornings with your freshly automated kettle! Cheers!