Introduction

The app was firs only going to be a simply application which starts streaming from the back camera to a MJPEG stream over HTTP so that anyone can access it easily from any web browser or video player that they have installed already. However, as i started building the app, I noticed that it had huge potential for upgrades. I could build a camera Hub System, which other cameras can connect to, and it could handle communication from and to multiple cameras, with feautures such as:

  • Notifications on motion events
  • Heartbeat - Status checks every 30's to see if camera is alive and what it is doing
  • Hub Device can download video sequences of motion events recorded locally by the camera
  • Opportunities for upgrades are endless, really.

**

Core Architecture: Two Operating Modes

EasyCCTV operates in two distinct modes, allowing devices to fulfill different roles in your security system:

Camera Mode

When a device runs in Camera Mode**, it becomes a streaming camera server. The device:

  • Captures video from its back (or front) camera
  • Streams video as MJPEG over HTTP for universal compatibility
  • Detects motion using pixel-change analysis
  • Records video locally when motion is detected
  • Provides a built-in web interface for configuration
  • Communicates with hub devices via REST API
  • Sends status updates and motion events to connected hubs

**

Hub Mode

When a device runs in Hub Mode, it becomes the central monitoring station. The hub:

  • Manages multiple connected camera devices
  • Displays live feeds from all cameras in a grid layout
  • Receives motion detection notifications in real-time
  • Downloads and stores motion event recordings from cameras
  • Provides a unified interface for monitoring all cameras
  • Can request HD streams on-demand for detailed viewing
  • Tracks online/offline status of all connected cameras

This dual-mode architecture allows you to set up a complete multi-camera CCTV system using only Android phones—one as the hub* (likely your daily-use device) and others as cameras positioned around your home or office.*

Need an Android Developer or a full-stack website developer?

I specialize in Kotlin, Jetpack Compose, and Material Design 3. For websites, I use modern web technologies to create responsive and user-friendly experiences. Check out my portfolio or get in touch to discuss your project.