German Vice Chancellor Robert Habeck loudly condemns Israel:
"The famine, the suffering of the Palestinians, the attacks in the Gaza Strip are incompatible with international law. It is indeed the case that Israel has crossed a line there, and it must not do so.”
I installed a wall box near the front door, under a nearby electrical socket (see below)
When the company installed the front door, I asked them to install a UTP cable from the door lock mechanism to the socket.
Bought the materials above (Aliexpress for the boards, Conrad for the power suppy).
Connected the mains to the breaker (for emergency switch-off)
Connected the cables from the breaker to the 24V power supply
Connected the cables from the power supply to the ESP32 board, door solenoid relay and ESP32’s relay. Luckily, I didn’t need to install 5V power supply for the ESP board, because it also works with 24V.
Here’s the doodle of the connecting scheme:
doodle of the electrical schemeHere’s the original connecting scheme from Innotherm (door manufacturer), in Slovenian: It was useful because it reveals which power supply is appropriate (Meanwell MW HDR 30-24).
screenshot of the door lock automation14. Added Aqara Door sensor to the door and connected it my existing Zigbee network using Zigbee2MQTT. It’s for logging when the door is open and for turning on the red status LED on the ESP32 board when the door is opened.
After 6 months, it works great. Kids are satisfied and me too, because this is one of the first usable HomeAssistant projects that involve some electronics and physical devices. It works in 99% of cases.
There are some issues with it though:
The ESP32 board sometimes reboots after unlocking. It seems that the door solenoid relay draws too much current and the voltage from the power supply drops momentarily. Probably I need to add a capacitor to the board power input to smooth the voltage. This is not a big issue, because the board starts working normally after 3 or 4 seconds after the reboot.
Once or twice it happened the esp board relay got stuck in an OFF state. I had to hit it gently with a screwdriver to unstuck it. After that, I reduced the time the door solenoid is opened from 2 to 1 sec. Not sure if it will help. Maybe it’s just a bad relay.
Several times the wifi was down and the board couldn’t communicate with the Home Assistant. It looks like my telco provider’s router is not the best one and it freezes sometimes. Probably I need to buy a better wifi router.
TODO
I have several ideas on how to upgrade the unlocking mechanism:
unlocking with a fingerprint
unlocking with facial recognition
Disclaimer
The links to the products are not affiliate links and I don’t receive any compensation for linking.
The code and the ideas are mostly from HomeAssistant and ESPHome community forums.
Today I soldered the tiniest thing ever. This resistor (red circle) is 0.8mm long.
Who designed this s**t?
(it's for selecting internal-external antenna)
You don't want to see my burned fingers. #esp32cam