Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rdcm/iot-camera-gun
Motion detection with ESP32 AI Thinker Camera
https://github.com/rdcm/iot-camera-gun
arduino eloquent esp32-cam iot motion-capture motion-detection telegram-bot
Last synced: about 2 months ago
JSON representation
Motion detection with ESP32 AI Thinker Camera
- Host: GitHub
- URL: https://github.com/rdcm/iot-camera-gun
- Owner: rdcm
- Created: 2024-04-06T13:45:32.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2024-04-06T13:46:02.000Z (10 months ago)
- Last Synced: 2024-10-12T00:16:53.697Z (4 months ago)
- Topics: arduino, eloquent, esp32-cam, iot, motion-capture, motion-detection, telegram-bot
- Language: C++
- Homepage:
- Size: 146 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## About
Example of usage [EloquentEsp32cam](https://github.com/eloquentarduino/EloquentEsp32cam) library.
## Problem
For example, you want to monitor activity behind a glass window and, if motion is detected, take a screenshot and send it over the network to a telegram bot.
The first solution that comes to mind is to use a PIR sensor. But this solution will not work, because... glass reflects ultraviolet and most infrared light.
![PIR](./images/PIR.jpg)
In the working solution, the PID sensor is excluded from the circuit. The camera takes pictures at a certain frequency and compares them with each other, if the comparison algorithm considers that the discrepancies between the frames are significant, the motion trigger is triggered.
## Components
ESP32 Ai Thinker Cam
![camera](./images/ESP32-CAM.jpeg)
## Settings
`secrets.h.example`:
```
// wifi
#define WIFI_SSID "wifi network"
#define WIFI_PASS "wifi network pass"// telegram
#define TELEGRAM_TOKEN "telegram token from @BotFather"/*
Request:
https://api.telegram.org/bot/getUpdates (Before execute http request you should send at least one message to bot)Response:
...
"chat": {
"id": ,
"first_name": "...",
"username": "...",
"type": "private"
}
...
*/
#define TELEGRAM_CHAT "CHAT_ID"
```## Links
[ESP32 cam motion detection without PIR](https://eloquentarduino.com/posts/esp32-cam-motion-detection)