Sentry-Picam is a simple wildlife / security camera solution for the Raspberry Pi Zero W, providing 1080p/30fps motion activated H.264 video capture.

Sentry-Picam

Mosaic of a 3d printed sentry turret, bird, and screenshot of a bar graph

Sentry-Picam is a simple wildlife / security camera solution for the Raspberry Pi Zero W, providing 1080p/30fps motion activated H.264 video capture. The built in web interface makes it easy to review video clips and identify the busiest times of day.

Motion detection in Sentry-Picam uses vectors provided by RaspiVid's video pipeline, enabling performant and effective supression of video noise.

Thanks to Broadway and RaspiVid, the Pi Zero W hardware can also stream live video to multiple devices with a ~300ms delay over Wifi.

Minimum Hardware Requirements

  • Raspberry Pi Zero
  • Raspberry Pi Camera Module v2 (others not tested)

Prerequisite Software

  • raspivid - This should already be installed if using Raspberry Pi OS.
  • ffmpeg - This is only required for custom triggers and reviewing recordings.

Quick Setup

git clone https://github.com/TinkerTurtle/sentry-picam
cd sentry-picam
./sentry-picam

Navigate to http://IP_address_of_your_RPi:8080

Tips

  1. The default video settings strike a good balance between video quality and resource usage. To View options:

    ./sentry-picam -help
    
  2. For higher quality on Camera Module v2:

    ./sentry-picam -height 1088 -width 1920 -fps 30 -bitrate 4000000
    
  3. Use "Edit Detection Sectors" in the web UI to specify areas where motion detection should be triggered.

  4. Set up auto start:

    sudo cp sentry-picam.service /etc/systemd/system/
    sudo systemctl enable sentry-picam
    sudo systemctl start sentry-picam
    
  5. Custom programs can be set up to trigger other functionality, like notifications or image classification. Ffmpeg is a prerequisite.

    Sentry-picam runs your program after generating a thumbnail, and passes in the video/thumbnail name as an argument to your program. Your program will need to append the .mp4 file extension to access the video, or .jpg to access the thumbnail. Recordings are stored in ./www/recordings/

    ./sentry-picam -run my_script.sh
    
  6. Files discarded from the web interface may be recovered from the folder ./www/recordings/deleteme/. The web interface will occasionally empty this folder, starting with recordings over 7 days old.

Compiling from source code from Windows for a Raspberry Pi Zero

git clone https://github.com/TinkerTurtle/sentry-picam
cd sentry-picam

# Set environment variables for the Go compiler
SET GOOS=linux
SET GOARCH=arm
SET GOARM=6

go build

STLs for the Portal Turret

https://www.thingiverse.com/thing:8277

https://www.prusaprinters.org/prints/76478-supplemental-portal-turret-components

Enjoy!

Cardinal swinging on a birdfeeder while eating birdfeed

Similar Resources

SRS is a simple, high efficiency and realtime video server, supports RTMP/WebRTC/HLS/HTTP-FLV/SRT/GB28181.

SRS is a simple, high efficiency and realtime video server, supports RTMP/WebRTC/HLS/HTTP-FLV/SRT/GB28181.

SRS is a simple, high efficiency and realtime video server, supports RTMP/WebRTC/HLS/HTTP-FLV/SRT/GB28181.

Jun 23, 2022

SortNode is a JS binding for SORT: Simple, online, and real-time tracking of multiple objects in a video sequence.

SortNode is a JS binding for SORT: Simple, online, and real-time tracking of multiple objects in a video sequence.

Sep 17, 2021

a simple example of video streaming with a ESP32 AI Thinker

a simple example of video streaming with a ESP32 AI Thinker

esp32-video-streaming its a simple camera system that im trying to make for fun I want to make an async server but idk it doesnt works correctly and w

Mar 9, 2022

A simple example showing how to render a video with libvlc + raylib.

A simple example showing how to render a video with libvlc + raylib.

Hey! I bet you have been trying to render and control a video with raylib for a long long time. Don't you think you should at least buy me a beer? Wha

May 23, 2022

DTV is a library that provides a simple interface for generating video files from a C++ application

DTV is a library that provides a simple interface for generating video files from a C++ application

Direct to Video (DTV) What does DTV do? DTV is a library that provides a simple interface for generating video files from a C++ application. It uses F

Jun 20, 2022

C++ library for programming the VideoCore GPU on all Raspberry Pi's.

V3DLib is a C++ library for creating programs to run on the VideoCore GPU's of all versions of the Raspberry Pi.

Jun 5, 2022

Open h.265 video codec implementation.

Open h.265 video codec implementation.

libde265 - open h.265 codec implementation libde265 is an open source implementation of the h.265 video codec. It is written from scratch and has a pl

Jun 24, 2022

Vireo is a lightweight and versatile video processing library written in C++11

Overview Vireo is a lightweight and versatile video processing library that powers our video transcoding service, deep learning recognition systems an

Jun 15, 2022

Olive is a free non-linear video editor for Windows, macOS, and Linux.

Olive is a free non-linear video editor for Windows, macOS, and Linux.

Olive is a free non-linear video editor for Windows, macOS, and Linux.

Jun 15, 2022
Comments
  • 'invalid argument' after cam.startrecord()

    'invalid argument' after cam.startrecord()

    after typing

    cam.startrecord()

    in the javascript console,

    I get no video record ; instead a lot of lines like 2020/08/22 14:46:58 Message Received: startrecord 2020/08/22 14:47:11 invalid argument 2020/08/22 14:47:11 invalid argument ... 2020/08/22 14:47:19 invalid argument 2020/08/22 14:47:20 invalid argument 2020/08/22 14:47:20 invalid argument 2020/08/22 14:47:20 invalid argument 2020/08/22 14:47:20 invalid argument 2020/08/22 14:47:20 Message Received: stoprecord

    in the bash console of simple-webcam. the messages are triggered at the first motion detected after startrecord until a stoprecord is received.

    as as side note, I have a few more errors and warnings on Brave as well as no video display (only the motion detection squares), not sure if this is related. Attaching a screenshot for reference: https://www.imgpaste.net/image/9SGNa

An Open Source PSVita/TV MP4 player with 1080p playback and subtitle support
An Open Source PSVita/TV MP4 player with 1080p playback and subtitle support

Vita-Media-Player An Open Source PSVita/TV MP4 player with 1080p playback and subtitle support 1080i output supported on the PSTV natively and on the

May 28, 2022
Open Source H.264 Codec

OpenH264 OpenH264 is a codec library which supports H.264 encoding and decoding. It is suitable for use in real time applications such as WebRTC. See

Jun 17, 2022
🤟Super fast H.264/H.265 FLV player
🤟Super fast H.264/H.265 FLV player

??Super fast H.264/H.265 FLV player

Jun 21, 2022
Video game library manager with support for wide range of 3rd party libraries and game emulation support, providing one unified interface for your games.
Video game library manager with support for wide range of 3rd party libraries and game emulation support, providing one unified interface for your games.

An open source video game library manager and launcher with support for 3rd party libraries like Steam, GOG, Origin, Battle.net and Uplay. Includes game emulation support, providing one unified interface for your games.

Jun 24, 2022
ScanNet is an RGB-D video dataset containing 2.5 million views in more than 1500 scans, annotated with 3D camera poses, surface reconstructions, and instance-level semantic segmentations.

ScanNet is an RGB-D video dataset containing 2.5 million views in more than 1500 scans, annotated with 3D camera poses, surface reconstructions, and instance-level semantic segmentations.

Jun 24, 2022
Video stabilization is a software-based approach in real-time to eliminating environmental effects (wind, heavy vehicle etc.) and enhance the visual performance that degrade video streaming quality.
Video stabilization is a software-based approach in real-time to eliminating environmental effects (wind, heavy vehicle etc.) and enhance the visual performance that degrade video streaming quality.

Video Stabilization Contents General Info Installation To Do General Info Video stabilization is a software-based approach in real-time to eliminating

Mar 7, 2022
Minimalist video maker -- simplify your music score video making process!

VisualScores 极简视频制作程序,简化你的乐谱视频制作! 如果需要编译,请解压 lib 文件夹中压缩包。 使用前请参考 manual 文件夹中的用户手册。 请勿修改、移动或删除 resource 文件夹中的任何文件。 VisualScores Minimalist video maker

Jan 11, 2022
OpenShot Video Library (libopenshot) is a free, open-source C++ library dedicated to delivering high quality video editing, animation, and playback solutions to the world

OpenShot Video Library (libopenshot) is a free, open-source C++ library dedicated to delivering high quality video editing, animation, and playback solutions to the world

Jun 21, 2022
Blur is a program made for easily and efficiently adding motion blur to videos through frame blending.
Blur is a program made for easily and efficiently adding motion blur to videos through frame blending.

Blur Blur is a program made for easily and efficiently adding motion blur to videos through frame blending. Features The amount of motion blur is easi

Jun 8, 2022
A RTSPServer for RTS3903N based IP Cameras (Yi Camera Inspired)

RTSPServer for RTS3903N based YI Cameras While this repo is focused on Yi based cameras, it should compile and run on any RTS3903N based camera! Backg

Jun 11, 2022