Giter Site home page Giter Site logo

shameerpuri / raspberry_pi_home_security_system Goto Github PK

View Code? Open in Web Editor NEW

This project forked from m0by314/raspberry_pi_home_security_system

0.0 1.0 0.0 158 KB

Home monitoring system with a Raspberry Pi and sending notifications with a Telegram bot

License: Other

Python 85.46% Makefile 14.54%

raspberry_pi_home_security_system's Introduction

Home security system with Raspberry Pi and sending notifications with a Telegram bot

CI

Tutorial to build a home security system with Raspberry Pi and sending notifications with a Telegram bot.

How it works

  • When a movement is detected, the application records a video that is sent to your phone by the Telegram bot.
  • Once installed, the surveillance system is managed from your smartphone with bot commands from the Telegram app.
  • The system is started by a systemd service activated at boot time

Prerequisites.

Connect the PIR sensor

image

Setting up the camera hardware

sudo raspi-config nonint do_camera 0

After this action reboot the raspberry

Setup

  • Open the config.py file and configure the TOKEN_ID and CHAT_ID variables with your token_id and your chat_id
    # Variable to configure
    TOKEN_ID = 'Your token_id'
    CHAT_ID = 'Your chat_id'

Installing

Before installing set your token_id then:

sudo make install

Bot's commands

  • /start : start the home monitoring system
  • /stop : stop the home monitoring system
  • /status : show the status of the monitoring system
  • /photo : take a picture
  • /video < delay > : records a video, by default delay is 60s
  • /clean : remove all files in video folder
  • /help : show help

Details

  • By default, the duration of the video is set to 60s. If you want change this, you need to modify the VIDEO_TIME constant in config.py

  • It's possible to add other commands to the bot in app.py with the decorator @bot.handler()

@bot.handler("/hello")		
def func_hello():		
    return bot.send_message("Hello World")		

Testing

make test

Uninstall

sudo make uninstall

Built With

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.