Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
VisionCamPro-Turn an ESP32-CAM into a Local First Smart Camera with HomeAssistant
#1
Hi everyone!

I'd like to share an open-source project I've been working on: VisionCam Pro, a custom security camera firmware built for the AI-Thinker ESP32-CAM (OV2640).
The idea behind this project is simple: turn an inexpensive ESP32-CAM module into a more capable standalone security camera that integrates with Home Assistant without depending on cloud services.
Instead of using the ESP32-CAM just for basic video streaming, I've been developing a complete camera firmware with its own web interface, local recording, motion detection, media management, and Home Assistant integration.

? Project Demo

Watch the project demonstration:



Full tutorial and walkthrough:



? Main Features

Some of the key features currently implemented include:
  • Live Video Streaming: Access the camera through its built-in web interface.
  • RTSP Streaming: Stream video to Home Assistant, VLC, and compatible NVR applications.
  • Local Video Recording: Record video directly to a microSD card in AVI format.
  • Motion Detection: Built-in motion detection with configurable thresholds.
  • Snapshot Capture: Capture and store images on the microSD card.
  • Media Management: Browse, play, download, and manage recorded videos and snapshots.
  • Storage Management: Configurable retention policies and storage monitoring.
  • MQTT Integration: Connect directly to your MQTT broker.
  • Home Assistant MQTT Discovery: Automatically create entities in Home Assistant.
  • Standalone Operation: Continue capturing and recording even when Home Assistant, MQTT, or internet connectivity is unavailable.

? Home Assistant Integration

One of the main goals was making the camera useful within a Home Assistant environment.
The firmware supports MQTT discovery, automatically creating a VisionCam Pro device with entities such as:
  • Motion detection binary sensor
  • Recording status binary sensor
  • SD card status
  • Storage usage sensor
  • Wi-Fi signal sensor
  • Take Snapshot button
  • Flash LED switch

For live video, the camera also provides an RTSP stream that can be integrated into Home Assistant using the Generic Camera integration and go2rtc.
This allows you to combine the camera with your existing Home Assistant automations.

For example:
  • Trigger automations when motion is detected.
  • Capture snapshots through Home Assistant.
  • Control the camera's flash LED.
  • Monitor recording and storage status.
  • View the live camera stream from your Home Assistant dashboard.
? Local-First Architecture

An important design decision was to keep the camera independent of cloud services.
The camera handles its own video capture, recording, motion detection, and media storage locally. MQTT and Home Assistant are additional integrations rather than mandatory dependencies.
Even if your internet connection or Home Assistant server goes offline, the camera can continue performing its core functions.

?️ Hardware Requirements

The project currently targets:
  • AI-Thinker ESP32-CAM
  • OV2640 camera module
  • ESP32-CAM-MB USB programming adapter
  • microSD card
  • Stable 5V power supply
? Source Code

The project is open source, and you can explore the firmware, documentation, and development progress on GitHub.

GitHub Repository:

https://github.com/charithmadhuranga/ESP-CAM

The firmware is developed using ESP-IDF with PlatformIO rather than the Arduino framework.

? Feedback and Suggestions

This is an ongoing project, and I'd love to hear from the Home Assistant community.

A few things I'd particularly like to discuss:

  1. What additional Home Assistant entities or integrations would make this camera more useful?
  2. What features would you expect from a low-cost, locally controlled security camera?
  3. Would you find support for multiple cameras and centralized management useful?
If you're experimenting with ESP32-CAM boards or building your own local security camera systems, feel free to check it out!
I'd appreciate your feedback, suggestions, and contributions.

Thanks!
Reply


Messages In This Thread
VisionCamPro-Turn an ESP32-CAM into a Local First Smart Camera with HomeAssistant - by nikhuge - 11 hours ago

Forum Jump:


Users browsing this thread:
1 Guest(s)