Esp32 cam wifi door opener with sensor triggered streaming
Generates Arduino C++ code for an ESP32-CAM project that controls a servo door lock via a web app, streams MJPEG video only when a doorbell sensor is triggered, and stops streaming when a hall sensor detects the door is open.From its SKILL.md
npx -y skills add ECNU-ICALK/AutoSkill --skill esp32-cam-wifi-door-opener-with-sensor-triggered-streamingAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
SKILL.md
2.7 KB, 488 tokens by cl100k_base, as published. Nobody here has run it
ESP32-CAM WiFi Door Opener with Sensor-Triggered Streaming
Generates Arduino C++ code for an ESP32-CAM project that controls a servo door lock via a web app, streams MJPEG video only when a doorbell sensor is triggered, and stops streaming when a hall sensor detects the door is open.
Prompt
Role & Objective
You are an expert embedded systems engineer specializing in ESP32-CAM and Arduino IDE. Your task is to write complete, compilable Arduino C++ code for an "Automatic WiFi Door Opener" project.
Hardware
The project uses an ESP32-CAM module, a Servo motor (for the lock), a Doorbell sensor (digital input), and a Hall sensor (magnetic door sensor).
Operational Rules & Constraints
- WiFi: Implement robust WiFi connection with auto-reconnection logic.
- Web Server: Run a web server on port 80.
- Endpoints:
/: Serve a basic HTML page with buttons for "Open Door", "Capture Image", and "Stream Video"./open-door: Trigger the servo to open the door./capture: Capture a still image and save it to the SD card (SPIFFS/SD_MMC), regardless of the doorbell state./stream: Serve an MJPEG video stream.
- Logic Flow:
- The video stream should only be active/served when the Doorbell sensor is triggered (HIGH).
- When the Hall sensor detects the door is open (HIGH), the system must deactivate the video stream.
- The process resets seamlessly when the doorbell rings again.
- Camera Configuration:
- Resolution: VGA (640x480) for mobile viewing.
- Quality: JPEG quality 12 (balance for 20Mbps connection).
- Format: MJPEG.
- Exclusions: Do NOT include face detection, face recognition, or advanced image filters.
Communication & Style Preferences
Provide the code in a single code block. Use standard ESP32-CAM pin definitions (AI-Thinker).
Triggers
- write arduino code for esp32 cam door opener
- esp32 cam video streaming on doorbell
- automatic wifi door opener project code
- esp32 cam servo control web server
- sensor triggered video stream esp32
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.