Garage Door - revisited

I posted this project way back in November 2021, so 4-years old now.

This is a photo of the original project installed on my garage wall...

This week I took another look at the project with a view to bringing it up-to-date.
These are the changes I've implemented...

  • Re-written the code using Micro-Python
  • Removed the ESP-01S and re-routed D4 to drive the transistor that drives the relay
  • Swapped the Wemos D1 Mini for an ESP32-S2-Mini (faster processor and more PSRAM)
  • Enhanced the functionality to include sending responses to Alexa and Telegram
  • Enhanced the functionality to include (software) locks to Lock/Unlock the door
  • Created a dashboard so I could see what the door is doing and also control it remotely
    Here's a screenshot of the revised D1-dashboard.

I completely revamped the original FSM (Finite State Machine) so the new machine would handle sending feedback messages to Alexa and Telegram. Here's a small part of the FSM...


Here's a copy of the state transition diagram...

The top and bottom microswitches (used to detect whether the door is fully open or fully close) force the FSM into state S2 or S0. The following voice commands, sent via Alexa, and decoded using the VSH (Virtual Smart Home) node move the machine from one state to another.

"Alexa, open roller door"
"Alexa, stop roller door"
"Alexa, operate roller door"
"Alexa, close roller door"

"Alexa, lock roller door"
"Alexa, unlock roller door"

This is how some sample commands appear on Telegram...

Some parts of my Node-RED flow are...



This is what the new board looked like during the "testing" phase prior to installing it in the plastic box on the wall. My next step is to bring the documentation up-to-date and then write a tutorial.

1 Like

I had a PM from someone asking for a schematic of the PCB.
If anyone is interested, here it is...
Schematic_General-purpose-board_2024-11-24.pdf (86.4 KB)

Note: I've connected a wire link from D4 on the microcontroller to pin-1 on the ESP-01S socket.

2 Likes