# Minimal motion example config file provided by the
# Debian motion package - for basic webcam operation.
#
# You most certainly want to investigate
# /usr/share/doc/motion/examples/motion-dist.conf.gz
# for further configuration options. Also, refer to the
# motion man page and /usr/share/doc/motion/motion_guide.html
# for detailed information on configuration options.

daemon off
quiet off

# You may very well need to change this (check with 'dmesg'
# after plugging in your webcam)
# this is just for testing
#videodevice /dev/video0
#video_pipe /dev/video4
#target_dir /storage/camera1

# Image size in pixels (valid range is camera dependent)
width 320
height 240

framerate 25
quality 50
auto_brightness off

# Initial brightness, contrast, hue (NTSC), and saturation
# 0 = disabled (valid range 0-255)
brightness 0
contrast 0
saturation 0
hue 0

#the text shown on the video files
text_right %Y-%m-%d\n%T

# Encode movies in real-time (install ffmpeg before enabling)
ffmpeg_cap_new on
ffmpeg_filename %v-%Y%m%d%H%M%S
ffmpeg_bps 400000
output_normal off

# Target base directory for pictures and films
# You should probably change this (create dir beforehand)
#target_dir /tmp

# Define a port number (e.g. 8000) to enable the mini-http server
# 0 = disabled
webcam_port 0

# Set to 'off' to allow anybody (not just localhost) to view the
# webcam via the mini-http server (http://hostname:port)
webcam_localhost on

webcam_quality 50
webcam_maxrate 8

############################################################
# HTTP Based Control
############################################################

# TCP/IP port for the http server to listen on (default: 0 = disabled)
control_port 8080

# Restrict control connections to localhost only (default: on)
control_localhost on

# Output for http server, select off to choose raw text plain (default: on)
control_html_output on

# Authentication for the http based control. Syntax username:password
# Default: not defined (Disabled)
; control_authentication username:password

#the thread files path
thread /etc/motion/cam1.conf
thread /etc/motion/cam2.conf
thread /etc/motion/cam3.conf
thread /etc/motion/cam4.conf
