ESP32 / Telegram / vision

Cat litterbox
notifier.

A small camera system that watches the litterbox, keeps the raw evidence visible, and only sends an alert when a cat is actually there.

01ESP32 cameramotion frame
02Telegram groupraw traffic
03VPS + visionclassify
04Notifieruseful alert

The basic parts

01

ESP32 camera node
The camera watches a fixed litterbox view and sends a frame when its firmware detects motion.

02

Shared Telegram group
The camera bot and notifier use the same group as a simple message bus.

03

Small VPS
An independent Python bot runs beside Hermes. Hermes only supplies the authenticated vision call through the existing OpenAI subscription.

04

Notifier bot
Subscribers receive the triggering image with a short cat, pee or poop classification.

Why keep the raw channel?

The shared Telegram group is intentionally left visible. It shows every frame produced by the ESP32, including empty scenes, lighting changes and false triggers. That makes the system inspectable: an alert can always be compared with the source image, and missed or incorrect classifications do not disappear into a hidden pipeline.

Spend fewer AI calls

The raw traffic is also useful training material for better firmware. Future versions can reject obvious noise before upload with motion debounce, a litterbox-only region of interest, exposure checks, image-difference thresholds and multi-frame confirmation. Better filtering on the ESP32 means fewer false triggers reach the VPS—and fewer images need an AI call.

Under the hood

A little more technical

01 / signal

Motion without chasing light

Each new frame is compared with a recent reference. The firmware first estimates the brightness change affecting the whole image and removes that global shift. It then measures what is left in local areas. A lamp switching on changes almost everything equally; a cat produces a concentrated shape that survives the correction and crosses the motion threshold.

02 / radio

Wi-Fi only when needed

The ESP32 units do not keep Wi-Fi active continuously. They wake the radio to send a triggered frame and for a scheduled check roughly every 30 minutes. During that check they can report their state and collect waiting Telegram commands, then disconnect again.

03 / topology

Two devices, two bots

Two ESP32 camera units share the first Telegram bot. A second bot runs on the VPS and watches the shared Telegram group using Telegram's bot-to-bot mode. The group is both transport and inspection window: it carries raw frames upstream, filtered results downstream and commands back to the units.

04 / pipeline

Filter, classify, notify

Firmware decides whether a frame is worth transmitting. The VPS deduplicates it, applies a cooldown and sends it to the vision model. Cat presence and litterbox activity are counted, while useful results are returned with the exact image that caused them.

ESP32 A ─┐
         ├─ camera bot ── Telegram group ── VPS bot ── vision ── alert
ESP32 B ─┘                       │
          30 min check-in ◀──── commands