RaspBerry WebCam Server

sudo apt install autoconf automake build-essential pkgconf libtool git libzip-dev libjpeg-dev gettext libmicrohttpd-dev libavformat-dev libavcodec-dev libavutil-dev libswscale-dev libavdevice-dev default-libmysqlclient-dev libpq-dev libsqlite3-dev libwebp-dev

sudo wget https://github.com/Motion-Project/motion/releases/download/release-4.3.1/pi_buster_motion_4.3.1-1_armhf.deb

sudo dpkg -i pi_buster_motion_4.3.1-1_armhf.deb

sudo nano /etc/motion/motion.conf

Find the following lines and update them to the following.

  • daemon on
  • stream_localhost off

Note: Change the following two lines from on to off if you’re having issues with the stream freezing whenever motion occurs.

  • picture_output off
  • movie_output off

Optional (Don’t include the text after the #)

  • stream_maxrate 100 This change will allow for real-time streaming but requires more bandwidth & resources. Needs to be added to the config file, default is 1
  • framerate 100 Changing this option will allow for 100 frames to be captured per second allowing for smoother video, default is 50
  • width 640 #This line changes the width of the image displayed, default is 640
  • height 480 #This option changes the height of the image displayed, default is 480

Altering these options can drastically affect the performance. You may need to tinker to get the best results.

 

sudo nano /etc/default/motion

start_motion_daemon=yes

sudo service motion start

connect to http://RASPBERRY_IP:8081

 

Screma

davide Written by: