Camera Alert Application with Raspberry Pi 3, iOS/Android

Introduction

In this tutorial, I am going to show you how to build a simple application that detects motion and sends notifications to the your smart phone using a Raspberry Pi and camera module. If there is something or someone moving in the camera setup's field, you will get notified to your phone or web browsers.camera alert application with raspberry pi 3 ios android

The notification comes with text, still image, and video that you can view it right on iOS or Android. The application is pretty simple. It utilizes the free software and services such as picamera, ffmpeg, and pushbullet.

I will walk you through the architecture, flowchart, and explain the main Python functions. At the end of this video, you can build your own application or customize the already built one as you wish.

Let's start!

Hardware

Or you can buy all-in-one set here.

Specification

This section explains the specification of application including app structure, and general flowchart. You will have a clear vision about what application does.

Application Structure

There are 3 actors that play together to build up the application:

  • (1) Raspberry Pi & camera module as the data source that continuously scan for motion and recording video at the same time.
  • (2) Pushbullet as the message-broker to send messages (text, still image, and videos) back and forth between Raspberry Pi and Mobile/Web
  • (3) Mobile/web acts as “notifyee” who receives the still image and video of motion. The communication is two ways though. It means you can send a command from mobile or web to Raspberry Pi for particular action such as “@snap” (for instantly take a photo) or “@check” (to get current system information of Pi).

schematic camera alert application with raspberry pi 3 ios android

General Flowchart

When the script launches, it takes 2 seconds to warm up the camera to make sure everything works properly. Then it jumps right into motion scanning. If moving happens, the Pi will capture a still image and send notifications to the phone immediately. At the same time, Pi keeps recording the moment for a few more seconds. After that amount of time, if movement is still there, Pi re-captures a new image and sends a new notification. Until there is no more motion, the recorded videos will be pushed to mobile to confirm the motion has ended. The system goes into motion scanning state. The program loops again and again as in this flowchart.

For more detail: Camera Alert Application with Raspberry Pi 3, iOS/Android


About The Author

Ibrar Ayyub

I am an experienced technical writer holding a Master's degree in computer science from BZU Multan, Pakistan University. With a background spanning various industries, particularly in home automation and engineering, I have honed my skills in crafting clear and concise content. Proficient in leveraging infographics and diagrams, I strive to simplify complex concepts for readers. My strength lies in thorough research and presenting information in a structured and logical format.

Follow Us:
LinkedinTwitter

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top