back to top
Sunday, November 17, 2024
spot_img

MotionEye on Raspberry Pi: Proper Surveillance Software?

Share This Post

Welcome to another Raspberry Pi Post, this time we will get to know more about Motion, A highly configurable program that monitors video signals from many types of cameras. We will configure and Install MotionEye on Raspberry Pi raspbian stack, and see how to setup, record and activate motion services across your home or office.

What Is Motion/Eye?

Motion (Github) is a Unix CLI-tool to watch, record and manage multiple types of cameras under one roof. In Short it can:

  • Create videos or save pictures of the activity
  • Passthrough recording from many IP cameras
  • View live stream of cameras
  • Invoke scripts when activities occur
  • Log activity into multiple types of databases
  • Fully customizable masks for privacy or motion detection
  • Full TLS (https) support with authentication for web control and streams

MotionEye (GitHub) is a Web-Frontend written in Python. It sets up a very aesthetic view on a defined port, which you can access over network via IP address or a Domain name.

Does MotionEye suffice your project requirements?

MotionEye is a utility to collect video via different camera hardware’s, it provides us with hitbox type of Motion Detection, also it can send you notifications, Save video streams and control camera functions.
People often mistake MotionEye for a Computer Vision program, IT IS NOT. For facial-recognition, Speed tracking and object detection, Frigate is what you want.

Installing MotionEye On Raspberry Pi :

We shall install Motion, Its repos and the GUI on our Raspbian stack on a Raspberry Pi 3B+. We have also set another Pi zero as a sleeper camera (Active Medicenter) inside the house, and we have another IP Camera mounted outside the house. Assuming our Pi is updated, and we have root access by issuing sudo -i,we start the installation progress:

  1. Install ffmpeg and other motion dependencies:
apt-get install ffmpeg libmariadb3 libpq5 libmicrohttpd12
  1. Install motion:
wget https://github.com/Motion-Project/motion/releases \
/download/release-4.2.2/pi_buster_motion_4.2.2-1_armhf.deb
 dpkg -i pi_buster_motion_4.2.2-1_armhf.deb
  1. Get the dependencies from the repositories:
     apt-get install python-pip python-dev libssl-dev libcurl4-openssl-dev libjpeg-dev libz-dev
    
  2. Install motioneye on Raspberry Pi, which will automatically pull Python dependencies (tornadojinja2pillow and pycurl):
     pip install motioneye
    
  3. Prepare the configuration directory:
     mkdir -p /etc/motioneye
     cp /usr/local/share/motioneye/extra/motioneye.conf.sample /etc/motioneye/motioneye.conf
    
  4. Prepare the media directory:
     mkdir -p /var/lib/motioneye
    
  5. Add an init script, configure it to run at startup and start the motionEye server:
     cp /usr/local/share/motioneye/extra/motioneye.systemd-unit-local /etc/systemd/system/motioneye.service
     systemctl daemon-reload
     systemctl enable motioneye
     systemctl start motioneye
    

8. To upgrade to the newest version of motionEye, just issue:
pip install motioneye --upgrade
systemctl restart motioneye

Setting Up MotionEye and our Cameras:

After completing the above steps, Our MotionEye on Raspberry Pi will be visible at IPaddressofPi:8765. When accessing the portal for the first time, you can use root as username and login, No password is necessary. It’s a good choice to update it after log-in.
Go to Add Camera and paste the address of the stream of your camera. Once successfully paired, Motion-eye will present you with dozens of options.

You can now enable Video Recording, Motion Detection and other features by following on-screen steps. Congratulations on having a successful setup of MotionEye on Raspberry Pi, and a step towards making your home more secure.

Pilāni
clear sky
18.9 ° C
18.9 °
18.9 °
40 %
0.4kmh
0 %
Sun
30 °
Mon
28 °
Tue
28 °
Wed
29 °
Thu
28 °

Related Posts

Using Seeed Studio mmWave Module with ESPHome

In the ever-expanding universe of smart technology, the fusion...

Raspberry Pi Automatic Fans Using L298n PWM

Welcome, We all know Raspberry Pi SBC Likes to...

DIY Home Automation: ESP Home & Home Assistant

ESPHome is a powerful tool that simplifies the process...

Raspberry Pi Zero Explained: Comparing the Zero Family

The Raspberry Pi Zero series, known for its compact...

Aliens Guide to Earth’s Solar System

Position 00 - The Sun. Position: #0. The gravitational...

10 Best Gaming Mouse in India for Every Budget

Recently, my trusted old Logitech G602 gave out on...
- Advertisement -spot_img