ESP32-Fingerprint-Intercom to HA

My ESP32-Fingerprint-Intercom-Project

As I’m a new user it’s not possible for me to post more than one picture and more than 2 links here - you will find all in my github repo.

Abstract
I use a nuki smart lock and a self build fingerprint reader circuit and controll them via an esp32 microcontroller and Homeassistant. The intercom system is integrated for using the buzzer and as an interrupt to wake the components (battery driven). The project uses ESPHome for connecting to my central Homeassistant instance.

Longer Story
Its about the interest and deployment of a Nuki Smart Lock Pro Gen4 that brought some more thinking into it.
I’m an engineer and so I always thinker and play around with stuff like computers, raspberry pis, esp32s and so on. One day my interest grow on the side of smart locks. As I’m a huge fan and frequent deployer of Homeassistant in friends and familys homes, the smart lock pro from nuki seemed nice cause of it’s bride-less capabilities to smart home stations like Google, Apple or: HomeAssistant (HA)!
So, I ordered one. After recieving it and troubleshooting the mounting everything worked great with the Nuki App and with HA (via MQTT). But to always open the App (either way HA or Nuki) seems odd. You stand in front of your own door and need some moments to unlock it - even though I always have the key for the door in my pocket. First thing I tried was to do it via NFC. I had a NFC tag in the hallway that I could read with the back of my phone and so the door was unlocked (via a HA-Automation). Unfortunately Android phones do only read tags if they are unlocked (I think its a security feature) so I ended up unlocking my phone prior to reading the tag. It worked quite well but it was not convienient.
Surely I’m aware of proximity based stuff like bluetooth and BLE but that could be a topic for later. I thought about the lock and nuki and saw their off the shelf fingerprint reader. Can esp-microcontrollers work with fingerprint readers? Shurely! There is a part called R503, its capacitive and cheap. I ordered one, soldered it to the esp and it worket flawless.
A friend of mine was experimenting with door-access and fingerprint readers as well (off the shelf parts). I heard he had a box to wire up to his doorbell that he can use the intercom buzzer to open the main door (and speak to the person ringing but with a high latency). I was interested cause sometimes using of the buzzer could be useful. I studied how the intercom system in my flat works and found out its quite simple. It consists of an old Siedle 6+n system that is widely used in German homes. After digging some schematics and forums I found a nice discussion and many helpful ressources (in German).
After understanding how its done I wired up an esp32 and some components and the doorbell was in my HA - nice! I was getting notifications if somebody rang the doorbell and I could use the intercom buzzer via my phone. So I was eager to combine the stuff on one esp to simplify the electronics. It wasn’t difficult!
At that time I used a simply power supply to power it up but I had no outled close to my intercom. So I decided to power it by a battery. After some tinkering with battery boards for 18650 (I had good and realy bad boards) I found flat LiPo Cells with an integrated protection circuit. They fitted much more nicely to my esp and my stripboard and worked well. I figured out that an esp with an active wifi connection and an active fingerprint reader draws a realatively high current. Way to much for some months of battery life. So the task was to monitor the battery life and reduce the current drawn over time! Fortunately sleep modes for an esp32 are easy to use and now it goes to sleep and is waken up by an interrupt pin from my intercom. The fingerprint reader is also now sleeping if not in use.
After all that tinkering and 1 or 2 months of daily usage I decided to get rid of my stripboard and order a pcb that I designed. Its very cheap in various online stores. The schematics can be directly transformed into a pcb design and the gerber file for production is directly uploaded to a manufacturer.
Two or three weeks later I had my newly designed pcb in hand, soldered the components, tinkered with some new errors and issues (PCB design and bad battery connectors) and packed it in a dry wall box with the battery.
Now my procedure has changed: I enter our main door and ring my own doorbell. After walking up one floor the esp is awake, connected to my wifi and ready to read my fingerprint, the nuki opens the door to me and my phone can stay in my jacket. But: I still have the key in my pocket!

Entities involved

  • Nuki Smart Lock Pro Gen4
  • R503 grow fingerprint reader
  • Siedle doorbell (6+n system)
  • ESP32-board - ESP32-S3-Zero (Waveshare) with Charger and fuel gauge (see ressources)
  • LiPo battery 3,7 V 4000mAh
  • Homeassistant running on a Pi5

Schematics and PCB

  • in github

Help and ressources

  • in github

Homeassistant

  • ESPHome integrates the data from the fingerprint reader and from the intercom
  • the fuel gauge connected to the battery sends a battery charge percentage and a voltage to estimate the longevity
  • automations in HA open the door via nuki or use the buzzer to enter the building

Improvements

  • lots of them possible!
  • debug pins missing on the pcb
  • sometimes my doorbell recognized a ring but the ring of my neighbourgs was used - my circuit could be too sensitive on the doorbell lines
  • improve the wakeup speed → homeassistant connection for example via bluetooth should be faster, wifi can be slow to login, wifi 6!?
  • proximity wakeup or anything like this for the future
  • use some power from the intercom system to charge the battery?

I hope you enjoyed reading - start tinkering!

1 Like