- I wanted to lower or raise the outdoor curtains using a single command, like "good night". Since I have Alexa 2,.0 I choosed to use SINRIC as proxi server because it is simple and working, even if I don't like to rely on an external service that could drop in any moment.
I wanted to keep the possibility to operate the curtain with a simple external push button, like in the old style, so to avoid conflicts I used the NC contact of the relay to avoid conflicts.
Finally, since the full cycle requires 35 seconds, I wanted to be able to stop the operation by using a voice command. For this reason I used the multitasking capability of ESP32: one task is listening the wifi communication and the second one operates the switches. In this way a second command will stop the motor.
Critical points are the complexity of command chain (Alexa, Alexa server, Sinric server, my device) and the local wifi network.
I used a 3 lights LED to indicate with blue the connection status and red and green the raise or the lower status.
Commands are on and off, but also lower or raise using voice or smart phone Alexa application.
EXPANDED TECHNICAL DETAILS
Voice-Activated Smart Home Aesthetics
This project automates standard curtains or blinds using the Alexa Voice Service and the powerful ESP32 microcontroller.
- Sinric Pro IoT Integration: Uses the Sinric Pro library to bridge the ESP32 with Alexa. The device is discovered as a standard "Window Covering" or "Dimmer," allowing for commands like "Alexa, open the curtains to 50%."
- Stepper/Servo Precision: Manages a high-torque 28BYJ-48 stepper motor or MG995 servo. The ESP32 calculates the precise number of steps or the exact angle required to reach the requested percentage, ensuring smooth and quiet movement.
Security and Safety
- Manual Override Pulse: Includes a physical button input; a quick press toggles the curtain state locally without needing WiFi or Alexa, providing a failsafe for the user.