mirror of
https://github.com/Motion-Project/motion.git
synced 2025-12-23 23:18:21 -05:00
6003 lines
234 KiB
HTML
6003 lines
234 KiB
HTML
<h1><a name="Motion_Guide_One_Large_Document."></a> Motion Guide </h1>
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<ul>
|
|
<li> <a href="#Motion_Overview"> Overview </a> </li>
|
|
<li> <a href="#Install_Build"> Installing with apt / debs / building from source </a></li>
|
|
<li> <a href="#Error_Logging"> Questions, Issues and Error Reporting </a></li>
|
|
<li> <a href="#Important_Definitions"> Important Definitions </a></li>
|
|
<li> <a href="#The_Config_Files"> The Configuration Files </a></li>
|
|
<li> <a href="#Command_Line_Options"> Command Line Options </a></li>
|
|
<li> <a href="#Signals_Sent"> Signals (sent with e.g. kill command) </a></li>
|
|
<li> <a href="#Basic_Setup"> The Basic Setup </a></li>
|
|
<li> Configuration Options</li>
|
|
<ul>
|
|
<li> <a href="#Configuration_OptionsAlpha"> Listed alphabetically with mapping of old option names to current names </a></li>
|
|
<li> <a href="#Configuration_OptionsTopic"> Listed by topic </a></li>
|
|
<li> <a href="#Configuration_OptionsDetail"> Detail descriptions of each option</a></li>
|
|
<ul>
|
|
|
|
<li> <a href="#conversion_specifiers"> Conversion Specifiers</a></li>
|
|
<li> <a href="#Options_System_Processing"> System Processing</a></li>
|
|
<li> <a href="#Options_Video4Linux_Devices"> Video4Linux Devices</a></li>
|
|
<li> <a href="#Options_Network_Cameras"> Network Cameras</a></li>
|
|
<li> <a href="#Options_Raspi_Cameras"> Raspberry Cameras</a></li>
|
|
<li> <a href="#Options_Image_Processing"> Image Processing</a></li>
|
|
<li> <a href="#Options_Motion_Detection"> Motion Detection</a></li>
|
|
<li> <a href="#Options_Scripts"> Script Execution</a></li>
|
|
<li> <a href="#Options_Output_General"> General Output Options</a></li>
|
|
<li> <a href="#Options_Pictures"> Picture Output</a></li>
|
|
<li> <a href="#Options_Movies"> Movie Output</a></li>
|
|
<li> <a href="#Options_Pipe"> Pipe Output</a></li>
|
|
<li> <a href="#Options_Stream_Webcontrol"> Stream and Webcontrol</a></li>
|
|
<li> <a href="#Options_Database"> Database Options</a></li>
|
|
<li> <a href="#Options_Tracking"> Tracking Camera Options</a></li>
|
|
</ul>
|
|
</ul>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="Motion_Overview"></a> Overview </h2>
|
|
<ul>
|
|
<ul>
|
|
<li> <a href="#What_is_Motion"> What is Motion? </a></li>
|
|
<li> <a href="#How_do_I_get_Motion_and_what_does_it_cost"> How do I get Motion and what does it cost? </a></li>
|
|
<li> <a href="#Maintenance_and_Support"> Maintenance and Support </a></li>
|
|
<li> <a href="#Which_version_to_download_and_use"> Which version to download and use? </a></li>
|
|
<li> <a href="#What_features_does_Motion_have"> What features does Motion have? </a></li>
|
|
<li> <a href="#Documentation"> Documentation </a></li>
|
|
<li> <a href="#Supported_Hardware"> Supported Hardware </a></li>
|
|
<li> <a href="#Known_Problems"> Known Problems </a></li>
|
|
</ul>
|
|
<p></p>
|
|
<h3><a name="What_is_Motion"></a> What is Motion? </h3>
|
|
<p></p>
|
|
Motion is a program that monitors the video signal from one or more cameras and is able to detect if a
|
|
significant part of the picture has changed. Or in other words, it can detect motion.
|
|
<p></p>
|
|
The program is written in C and was made for the Linux operating system. Recent revisions have also made it
|
|
available for BSD.
|
|
<p></p>
|
|
Motion is a command line based tool with only limited support for configuration via a http interface.
|
|
The many configuration options are set via the command line or configuration files.
|
|
|
|
<p></p>
|
|
The output from motion can be:
|
|
<p></p>
|
|
<ul>
|
|
<li> jpg files</li>
|
|
<li> ppm format files</li>
|
|
<li> movie video sequences</li>
|
|
</ul>
|
|
<p></p>
|
|
<h3><a name="How_do_I_get_Motion_and_what_does_it_cost"></a> How do I get Motion and what does it cost? </h3>
|
|
<p></p>
|
|
Motion is an open source type of project. It does not cost anything. Motion is published
|
|
under the <a href="http://www.gnu.org/licenses/gpl.html" rel="nofollow" target="_top">GNU GENERAL PUBLIC LICENSE</a>
|
|
(GPL) version 2 or later. It may be a bit difficult to understand all the details of the license text (especially if
|
|
your first language is not English). It means that you can get the program, install it and use it freely. You do not
|
|
have to pay anything and you do not have to register anywhere or ask the author or publisher for permission. The GPL
|
|
gives you both rights and some very reasonable duties when it comes to copying, distribution and modification of the
|
|
program. So in very general terms you do not have to worry about licensing as a normal hobby user. If you want to use
|
|
Motion in a commercial product, if you want to distribute either modified or original versions of Motion - for free or
|
|
for a fee, you should read the license carefully. For more information about free software and the GPL, I encourage you
|
|
to study the very interesting documents about the subject available the of the Free Software Foundation pages about
|
|
the <a href="http://www.gnu.org/philosophy/philosophy.html" rel="nofollow" target="_top">Philosophy of the GNU Project</a>.
|
|
<p></p>
|
|
<h3><a name="Maintenance_and_Support"></a> Maintenance and Support </h3>
|
|
<p></p>
|
|
Both Motion and the Motion Guide are written by people that do all this as a hobby and without asking for any payments
|
|
or donations. We have a life other than developing Motion and its documentation. This means that bugfixes and updates
|
|
to this guide are done as our time and families allow it. You are however encouraged to participate and contribute in
|
|
a very active <a href="https://lists.sourceforge.net/lists/listinfo/motion-user">mailing list</a>. It is a list with
|
|
a very "positive attitude" and with many contributors that propose features, post patches, discuss problems and
|
|
patiently answer newbie questions with a very positive spirit. Expect 1-10 emails per day.
|
|
<p></p>
|
|
To get Motion direct your browser to the <a href="https://motion-project.github.io/">Motion Homepage</a>.
|
|
<p></p>
|
|
On the <a href="https://github.com/Motion-Project/motion/releases/">Releases</a> page you will find
|
|
links to the latest stable version binaries for some of the most popular Linux distributions.
|
|
<p></p>
|
|
Motion was originally written by Jeroen Vreeken and later Folkert van Heusden continued as a
|
|
lead programmer with Kenneth Lavrsen responsible for Motion Guide, website and releases on Sourceforge.
|
|
<p></p>
|
|
Staring with version 3.4.1 Motion is managed on github with many maintainers and contributors.
|
|
<p></p>
|
|
For support we encourage you to join the mailing list instead of writing to the maintainers directly. Newbies
|
|
and stupid questions are welcome on the list. Contributions in the form of pull requests to the github
|
|
repository are also very welcome.
|
|
<p></p>
|
|
<h3><a name="Which_version_to_download_and_use"></a> Which version to download and use? </h3>
|
|
<p></p>
|
|
The most current release version can be found on the github releases page <a href="https://github.com/Motion-Project/motion/releases">here</a>.
|
|
The master branch of the github repository represents the official development branch of Motion. Additional
|
|
independent development forks exist
|
|
in other Github repos that contain additional bug fixes, enhanced features and updated documentation.
|
|
This guide is based upon the features and options included in the source code with which it is distributed.
|
|
It was re-written in September 2015 to reflect the changes and options in the code at that time.
|
|
The majority of the new options and changed names represent differences between the 3.2.12 version
|
|
and the legacy SVN trunk. Since 3.2.12 many options have been renamed to make setting up Motion easier.
|
|
A cross reference of the old 3.2.12 option names to the new names can be
|
|
reviewed <a href="#Configuration_OptionsAlpha">here</a>
|
|
<p></p>
|
|
Motion is included in Debian, Ubuntu and Raspbian respositories and RPM can obtain Motion from rpmfusion.
|
|
<p></p>
|
|
<h3><a name="What_features_does_Motion_have"></a> What features does Motion have? </h3>
|
|
<ul>
|
|
<li> Taking snapshots of movement</li>
|
|
<li> Watch multiple video devices at the same time</li>
|
|
<li> Watch multiple inputs on one capture card at the same time</li>
|
|
<li> Live streaming webcam </li>
|
|
<li> Real time creation of movies using libraries from ffmpeg</li>
|
|
<li> Take automated snapshots on regular intervals</li>
|
|
<li> Take automated snapshots at irregular intervals using cron</li>
|
|
<li> Executing external program when a particular event occurs</li>
|
|
<li> Motion tracking</li>
|
|
<li> Feed events to an MySQL, PostgreSQL or SQLite3 database.</li>
|
|
<li> Feed video back to a video4linux loopback for real time viewing</li>
|
|
<li> Control via simple web interface.</li>
|
|
<li> Automatic noise and threshold control</li>
|
|
<li> Ability to control the pan/tilt of a tracking camera.</li>
|
|
<li> Highly configurable display of text on images.</li>
|
|
<li> Highly configurable definition of path and file names of the stored images and movies.</li>
|
|
</ul>
|
|
<p></p>
|
|
<h3><a name="Documentation"></a> Documentation </h3>
|
|
<p></p>
|
|
You have the following sources of information:
|
|
<p></p>
|
|
<ul>
|
|
<li> This Motion Guide</li>
|
|
<li> The <a href="https://github.com/Motion-Project/motion/wiki/FAQ">Frequently Asked Questions</a></li>
|
|
<li> The original author of the program has written a description of the <a href="https://github.com/Motion-Project/motion/wiki/Technology">technology behind motion</a>.</li>
|
|
<li> The man page. After installation simply type 'man motion' into a terminal screen.</li>
|
|
</ul>
|
|
<p></p>
|
|
<h3><a name="Supported_Hardware"></a> Supported Hardware </h3>
|
|
<p></p>
|
|
Motion supports video input from three kinds of sources.
|
|
<p></p>
|
|
Standard video4linux devices (e.g. /dev/video0), network cameras and the PI camera. Motion has no drivers for cameras.
|
|
Installing or configuring the camera itself is outside the scope of this document. Generally, if the device works with
|
|
other common video player software, it will work with Motion (and vice versa). As a result, it is
|
|
often convenient to first get the device working with other software and then use those connection options with Motion.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="Known_Problems"></a> Known Problems</a> </h3>
|
|
|
|
<p></p>
|
|
See the <a href="https://github.com/Motion-Project/motion/wiki/FAQ">Frequently Asked Questions</a>,
|
|
<a href="https://github.com/Motion-Project/motion/issues">Issues</a> and the release notes for the
|
|
particular version on the <a href="https://github.com/Motion-Project/motion/releases">releases</a> page
|
|
for known open issues.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
</ul>
|
|
|
|
<h2><a name="Install_Build"></a> Installing with apt / debs / building from source </h2>
|
|
<ul>
|
|
<p></p>
|
|
<ul>
|
|
<li> <a href="#Install_Apt"> Installing with apt</a></li>
|
|
<li> <a href="#Install_Deb"> Installing with a release deb package</a></li>
|
|
<li> <a href="#Abbreviated_Building"> Abbreviated Building Guide</a></li>
|
|
<li> <a href="#Preparation_For_Building"> Preparation For Building </a></li>
|
|
<li> <a href="#Configure_Script"> Configure Script </a></li>
|
|
<li> <a href="#Make"> Make </a></li>
|
|
<ul>
|
|
<li> <a href="#Make_Install"> Make Install </a></li>
|
|
<li> <a href="#Un_Install"> Un-install </a></li>
|
|
<li> <a href="#Additional_Make_Options"> Additional Make Options </a></li>
|
|
</ul>
|
|
<li> <a href="#Upgrading_From_Older_Version"> Upgrading From Older Version </a></li>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
<h3><a name="Install_Apt"></a> Installing with apt </h3>
|
|
<ul>
|
|
<p></p>
|
|
Motion is part of the Ubuntu and Debian repositories and can be installed with the apt tool. The
|
|
version included with apt will be the version that was available when the Ubuntu or Debian version
|
|
was initially deployed.
|
|
<p></p>
|
|
Open up a terminal window and type: <code><strong>sudo apt-get install motion</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Install_Deb"></a> Installing with a release deb package </h3>
|
|
<ul>
|
|
Motion can also be installed from the release deb files which may provide a more recent version than what
|
|
is available via apt.
|
|
<p></p>
|
|
Determine the deb file name that is appropriate for the distribution and platform from
|
|
the <a href="https://github.com/Motion-Project/motion/releases">Releases</a> page
|
|
and open up a terminal window and type:
|
|
<p></p>
|
|
<ul>
|
|
<code><strong>wget https://github.com/Motion-Project/motion/releases/{deb package name} </strong></code>
|
|
</ul>
|
|
<p></p>
|
|
Next, install the retrieved deb package. Below is a sample method to install that
|
|
uses the gdebi tool.
|
|
<p></p>
|
|
<ul>
|
|
<code><strong>sudo apt-get install gdebi-core</strong></code>
|
|
<p></p>
|
|
<code><strong>sudo gdebi {deb package name}</strong></code>
|
|
</ul>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Abbreviated_Building"></a> Abbreviated Building Guide </a> </h3>
|
|
<ul>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
If you are familiar with the building of applications, then the following is a basic build / install
|
|
script. If errors occur during the process or you wish to customize the build, please
|
|
review the extended building instructions further below.
|
|
<p></p>
|
|
Ubuntu / Debian Packages
|
|
<ul>
|
|
<code><strong>sudo apt-get install autoconf automake build-essential pkgconf libtool libzip-dev
|
|
libjpeg-dev git libavformat-dev libavcodec-dev libavutil-dev libswscale-dev libavdevice-dev </strong></code>
|
|
<p></p>
|
|
<code><strong>cd ~</strong></code>
|
|
<br /><code><strong>git clone https://github.com/Motion-Project/motion.git</strong></code>
|
|
<br /><code><strong>cd motion</strong></code>
|
|
<br /><code><strong>autoreconf -fiv</strong></code>
|
|
<br /><code><strong>./configure</strong></code>
|
|
<br /><code><strong>make</strong></code>
|
|
<br /><code><strong>make install</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
FreeBSD
|
|
<ul>
|
|
<code><strong>sudo pkg install autoconf pkgconf automake gmake git ffmpeg</strong></code>
|
|
<p></p>
|
|
<code><strong>cd ~</strong></code>
|
|
<br /><code><strong>git clone https://github.com/Motion-Project/motion.git</strong></code>
|
|
<br /><code><strong>cd motion</strong></code>
|
|
<br /><code><strong>autoreconf -fiv</strong></code>
|
|
<br /><code><strong>./configure</strong></code>
|
|
<br /><code><strong>gmake</strong></code>
|
|
<br /><code><strong>gmake install</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
Mac OS X
|
|
<ul>
|
|
<code><strong>sudo brew install ffmpeg pkg-config libjpeg </strong></code>
|
|
<p></p>
|
|
<code><strong>cd ~</strong></code>
|
|
<br /><code><strong>git clone https://github.com/Motion-Project/motion.git</strong></code>
|
|
<br /><code><strong>cd motion</strong></code>
|
|
<br /><code><strong>autoreconf -fiv</strong></code>
|
|
<br /><code><strong>./configure</strong></code>
|
|
<br /><code><strong>make</strong></code>
|
|
<br /><code><strong>make install</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
|
|
</ul>
|
|
<h3><a name="Preparation_For_Building"></a> Preparation For Building</a> </h3>
|
|
<ul>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
In order to build Motion from source many shared libraries must be installed.
|
|
The particular libraries needed will vary depending upon the features desired.
|
|
<p></p>
|
|
When you install software using pre-compiled binaries (Redhat type RPMs, Debian debs etc)
|
|
you normally only get what is needed to run the programs themselves. In order to compile programs
|
|
from source that use these libraries you also need to install the development packages.
|
|
These are normally called the same name as the package suffixed by -devel or -dev. These development
|
|
packages contain the header files (xxx.h) that Motion needs to build. If
|
|
you build a library from sources you already have these header files. It is recommended to simply
|
|
install the pre-compiled binary packages and their development brothers.
|
|
<p></p>
|
|
Open a terminal and run the following commands to install the packages.
|
|
<p></p>
|
|
Ubuntu / Debian Packages
|
|
<ul>
|
|
<li>Required</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo apt-get install autoconf automake build-essential pkgconf libtool git libzip-dev libjpeg-dev </strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<p></p>
|
|
<li>Optional Packages</li>
|
|
<ul>
|
|
<li>FFMpeg Functionality(Required for creating movies, using network cameras, etc.)</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo apt-get install libavformat-dev libavcodec-dev libavutil-dev libswscale-dev libavdevice-dev</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>MySQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo apt-get install mysql-server libmysqlclient-dev</strong></code>
|
|
<p></p>
|
|
or (depends upon your distribution and version)
|
|
<p></p>
|
|
<code><strong>sudo apt-get install default-libmysqlclient-dev</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>PostgreSQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo apt-get install libpq-dev</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>SQLite3 database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo apt-get install libsqlite3-dev</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>JPEG Turbo</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo apt-get install libjpeg-turbo8 libjpeg-turbo8-dev</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>Webp Image Support</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo apt-get install libwebp-dev</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
|
|
</ul>
|
|
</ul>
|
|
<p></p>
|
|
<p></p>
|
|
openSUSE Packages
|
|
<ul>
|
|
<li>Required</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo zypper install autoconf automake libtool git </strong></code>
|
|
<p></p>
|
|
<code><strong>sudo zypper install --type pattern devel_basis </strong></code>
|
|
<p></p>
|
|
<code><strong>sudo zypper install libjpeg8-devel </strong></code>
|
|
<p></p>
|
|
<code><strong>sudo zypper install -t pattern devel_C_C++ </strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<p></p>
|
|
<li>Optional Packages</li>
|
|
<ul>
|
|
<li>FFMpeg Functionality(Required for creating movies, using network cameras, etc. SEE NOTE BELOW!)</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo zypper ar -f -n packman-essentials http://packman.inode.at/suse/openSUSE_13.1/Essentials/ packman-essentials</strong></code>
|
|
<p></p>
|
|
<code><strong>sudo zypper ar -f -n packman-multimedia http://packman.inode.at/suse/openSUSE_13.1/Multimedia/ packman-multimedia</strong></code>
|
|
<p></p>
|
|
<code><strong>sudo zypper install libffmpeg-devel</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>MySQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>Not known by author</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>PostgreSQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>Not known by author</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>SQLite3 database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>Not known by author</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>Webp Image Support</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo zypper install libwebp-devel </strong></code>
|
|
<p></p>
|
|
</ul>
|
|
</ul>
|
|
Important ffmpeg note: The ffmpeg libraries indicated above are provided by a external repository. This may
|
|
change in the future. Validate that the repository is still valid when doing the install on openSUSE systems.
|
|
The default for the configure is to require that ffmpeg is installed. Use the configure option to
|
|
compile without the ffmpeg functionality.
|
|
</ul>
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
FreeBSD
|
|
<ul>
|
|
<li>Required packages</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong> sudo pkg install autoconf pkgconf automake gmake git</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>Optional packages</li>
|
|
<ul>
|
|
<li>FFMpeg Functionality(Required for creating movies, using network cameras, etc.)</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo pkg install ffmpeg</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>MySQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo pkg install mysql57-client</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>PostgreSQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo pkg install postgresql95-contrib</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>SQLite3 database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo pkg install sqlite3</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>Webcam Support</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo pkg install v4l_compat webcamd</strong></code>
|
|
<p></p>
|
|
<li>Add cuse_load="YES" in /boot/loader.conf</li>
|
|
<li>Add webcamd_enable="YES" in the /etc/rc.conf</li>
|
|
<li>chmod 666 /dev/video0</li>
|
|
<p></p>
|
|
</ul>
|
|
<li>Webp Image Support</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo pkg install libwebp</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>Temorary bktr Support</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo kldload bktr_mem.ko</strong></code><p></p>
|
|
<code><strong>sudo kldload bktr.ko</strong></code><p></p>
|
|
<code><strong>sudo sysctl hw.bt848.card=1</strong></code> ( Miro pctv )<p></p>
|
|
<code><strong>sudo sysctl hw.bt848.tuner=10</strong></code> ( PHILIPS_FR1216_PAL )<p></p>
|
|
<code><strong>sudo sysctl hw.bt848.format=0</strong></code> ( PAL )<p></p>
|
|
<p></p>
|
|
</ul>
|
|
<li>Persistent bktr Support</li>
|
|
<ul>
|
|
<li>Add <code><strong>bktr_mem_load="YES"</strong></code> in /boot/loader.conf</li>
|
|
<li>Add <code><strong>bktr_load="YES"</strong></code> in /boot/loader.conf</li>
|
|
<li>Add <code><strong>hw.bt848.card=1</strong></code> in /etc/sysctl.conf</li>
|
|
<li>Add <code><strong>hw.bt848.tuner=10</strong></code> in /etc/sysctl.conf</li>
|
|
<li>Add <code><strong>hw.bt848.format=0</strong></code> in /etc/sysctl.conf</li>
|
|
</ul>
|
|
</ul>
|
|
</ul>
|
|
<p></p>
|
|
<p></p>
|
|
CentOS 7 Packages
|
|
<ul>
|
|
<li>Required</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo yum groupinstall 'Development Tools'</strong></code>
|
|
<p></p>
|
|
<code><strong>sudo yum install libjpeg-turbo libjpeg-turbo-devel</strong></code>
|
|
<p></p>
|
|
<code><strong>sudo yum install libzip-devel</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<p></p>
|
|
<li>Optional Packages</li>
|
|
<ul>
|
|
<li>FFMpeg Functionality(Required for creating movies, using network cameras, etc. SEE NOTE BELOW!)</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo yum localinstall --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-7.noarch.rpm https://download1.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-7.noarch.rpm</strong></code>
|
|
<p></p>
|
|
<code><strong>sudo yum install ffmpeg ffmpeg-devel</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>MySQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>Not known by author</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>PostgreSQL database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>Not known by author</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>SQLite3 database functionality</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>sudo yum install sqlite-devel</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<li>Webp Image Support</li>
|
|
<ul>
|
|
<p></p>
|
|
<code><strong>Not known by author</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
</ul>
|
|
Important ffmpeg note: The ffmpeg libraries indicated above are provided by a external repository. This may
|
|
change in the future. Validate that the repository is still valid when doing the install on CentOS systems.
|
|
The default for the configure is to require that ffmpeg is installed. Use the configure option to
|
|
compile without the ffmpeg functionality.
|
|
</ul>
|
|
<p></p>
|
|
MacOSX
|
|
<ul>
|
|
<li>Required</li>
|
|
<ul>
|
|
<p></p>
|
|
<li>Install brew as described on https://brew.sh</li>
|
|
<p></p>
|
|
<code><strong>brew upgrade ffmpeg pkg-config jpeg</strong></code>
|
|
<p></p>
|
|
<code><strong>brew install ffmpeg pkg-config libjpeg</strong></code>
|
|
<p></p>
|
|
</ul>
|
|
<p></p>
|
|
<li>Optional Packages</li>
|
|
<ul>
|
|
<li>None known by author</li>
|
|
</ul>
|
|
</ul>
|
|
|
|
<h3><a name="Configure_Script"></a> Configure Script</a> </h3>
|
|
<ul>
|
|
Motion uses a set tools called the "autotools" in order to generate the required scripts in order to
|
|
compile and install Motion. The next step after installing all of the required and desired libraries is to
|
|
have the autotools create a configure script. To do this open a terminal and change to the directory with
|
|
the source code and type
|
|
<p></p>
|
|
<code><strong>autoreconf </strong></code>
|
|
<p></p>
|
|
If the 'configure' file exists and contains a valid script, the tool will return immediately since no additional work
|
|
needs to be completed. If the script needs updating, then it will take a moment to return. Once it has been executed,
|
|
a file called 'configure' will exist in the directory. Note that if the command is run as
|
|
<p></p>
|
|
<code><strong>autoreconf -f</strong></code>
|
|
<p></p>
|
|
The -f parameter instructs it to force a new configure file to be created. This can be preferable in certain
|
|
situations so that the configure script gets updated with the correct version number.
|
|
Once the 'configure' file is created, we can execute it. What the script does is interrogate the system and look
|
|
for all the needed items in order to compile Motion. In this process it looks to determine which optional components
|
|
have been installed on the system and if found sets flags to indicate for them to be included. If a particular library
|
|
is required by Motion and is not found, the configure script will issue an error. The error means that the library was
|
|
not found because it was either not installed or that it was installed into a location that the script could not find.
|
|
With the Motion configure script, once it has ended it also lists out all of the optional components that were located.
|
|
Note that if you KNOW that a particular component is installed yet the configure script reports it as not installed, then
|
|
it may be necessary to use one or more of the configure options described below to tell the script where to find
|
|
the particular component.
|
|
|
|
<p></p>
|
|
To run the configure your current directory must be the motion directory. You type
|
|
<p></p>
|
|
<code>./configure</code>
|
|
<p></p>
|
|
You can add the parameter <code>./configure --help</code> to get help on the different switches.
|
|
<p></p>
|
|
When the configure script finishes you should validate that the options desired
|
|
were correctly identified by the configure. In particular, the ffmpeg option is occasionally not
|
|
found even if it is actually installed. Various users have indicated this to be a particular
|
|
problem with the PI. If using a PI and have this issue, you can use the following option
|
|
<p></p>
|
|
<code>./configure --with-ffmpeg=/usr/lib/arm-linux-gnueabihf</code>
|
|
<p></p>
|
|
For a long term option, you can edit the file
|
|
<code>$HOME/.bashrc</code>
|
|
and within it place the following two lines at the end
|
|
<code>PKG_CONFIG_PATH=/usr/lib/arm-linux-gnueabihf:$PKG_CONFIG_PATH</code>
|
|
<code>export PKG_CONFIG_PATH</code> This option will however only become
|
|
effective the next time you open the terminal shell.
|
|
<p></p>
|
|
<p></p>
|
|
The following options can be specified with the configure script to customize
|
|
how Motion is built.
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="200px">
|
|
<col width="500px">
|
|
<col width="700px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Options</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Description <br /> Defaults for the options are specified in brackets [ ]</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Editors comment </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > -h, --help </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > display this help and exit</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --help=short</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > display options specific to this package </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > This command shows the options special to Motion.</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --help=recursive </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > display the short help of all the included packages </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word >-V, --version </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > display version information and exit</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Provides the version number of the source code and autotools </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > -q, --quiet, --silent </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > do not print `checking...' messages </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Illustrates only the results of the script. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --cache-file=FILE </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > cache test results in FILE. [disabled] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > No function</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > -C, --config-cach </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > alias for `--cache-file=config.cache' </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > No function </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > -n, --no-create</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > do not create output files </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Used for testing if other switches produce error - without writing anything to the disk </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --srcdir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > find the sources in DIR. [configure dir or `..'] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > DIR is a directory path. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Installation directories:</td>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > </th>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > </th>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --prefix=PREFIX </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > install architecture-independent files in PREFIX <br /> [/usr/local]</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > The default /usr/local means that
|
|
<br /><br />The executable binary "motion" is installed in /usr/local/bin
|
|
<br /> The manual page in /usr/local/man/man1
|
|
<br />The document files in /usr/local/docs/motion
|
|
<br />The configuration file in /usr/local/etc/motion
|
|
<br />The example config files in /usr/local/motion/examples
|
|
<br /><br />If you are experimenting with many parallel versions it may be desirable to set the PREFIX to e.g. /usr/local/motion and then add /usr/local/motion/bin to your search path (or simply cd /usr/local/motion/bin before execution).
|
|
<br /><br />This way you can change version just by changing the symbolic link in /usr/local/motion.
|
|
<br /><br />If you are installing the software on a machine where you do not have access to the /usr/local but have write access to a home directory, then you should change this to point to a directory within your home tree.
|
|
<br /><br />Example: --prefix=$HOME </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --exec-prefix=EPREFIX </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > install architecture-dependent files in EPREFIX <br /> [PREFIX] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > This defines an alternative installation directory for the executable binary. <br /> Note: The executable binary will be placed in a directory "bin" below the directory specified by this option <br /> Author recommends leaving this as default (i.e. not setting it). </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --bindir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > user executables [EPREFIX/bin] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > With this option you can control exactly which directory the executable binary is installed. The previous option automatically adds the bin directory. Here you are in full control of the directory. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --sbindir=DIR </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > System admin executables [EPREFIX/sbin] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --libexecdir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > program executables [EPREFIX/libexec] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --datadir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > read-only architecture-independent data [PREFIX/share] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --sysconfdir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > read-only single-machine data [PREFIX/etc] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word >
|
|
This is where Motion both installs the default configuration file and also where it will later search for it. <br />
|
|
Motion searches for the configuration file "motion.conf" in the following order:
|
|
<br />
|
|
<UL> <br />1. Current directory from where Motion was invoked
|
|
<br />2. $HOME/.motion
|
|
<br />3. The motion subdirectory inside the sysconfig directory set by this switch. If not defined the default is /usr/local/etc/ <br />
|
|
</UL> <br /> Editor recommends leaving this at default. Be careful if you run "make install" again.
|
|
This will overwrite the motion-dist.conf file that you may have edited.
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --sharedstatedir=DIR </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > modifiable architecture-independent data [PREFIX/com] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --localstatedir=DIR </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > modifiable single-machine data [PREFIX/var] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --libdir=DIR </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > object code libraries [EPREFIX/lib]</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --includedir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > C header files [PREFIX/include] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --oldincludedir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > C header files for non-gcc [/usr/include] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --infodir=DIR </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > info documentation [PREFIX/info] </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Not used by Motion. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --mandir=DIR</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > man documentation [PREFIX/man]</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Editor recommends the default.</td>
|
|
</tr>
|
|
<tr>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > Optional Packages: </th>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > </th>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > </th>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --without-bktr </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Exclude bktr video subsystem devices </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > ONLY used in *BSD </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --without-v4l2 </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Exclude using v4l2 (video4linux2) subsystem. Makes Motion so it only supports network cameras. </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Can be used if you do not need support or lack some of the libraries for it. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --with-webp </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Compile with webp image support</td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --with-ffmpeg=DIR </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Specify the path for the directory prefix in which the
|
|
library and headers are installed.
|
|
<br /> If not specified configure will search in /usr/ and /usr/local/ </td>
|
|
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > DIR is the directory PREFIX in which
|
|
the ffmpeg shared libraries and their headers are installed.
|
|
<br /> If you install ffmpeg from sources and use the default directories or
|
|
if ffmpeg is installed as a binary package (RPM or deb) you may not need to specify the directory prefix.
|
|
Configure should find the libraries automatically.
|
|
<br />If you installed ffmpeg from sources and specified a different --prefix when building f
|
|
fmpeg you must use the same value for the DIR ( --with-ffmpeg=DIR)
|
|
or export that location to be included in the PKG_CONFIG_PATH
|
|
<br />The option of --with-ffmpeg is the default for Motion. If the required libraries are not located, the
|
|
configure script will stop at the ffmpeg section and report which libraries need to be installed.
|
|
Once the required libraries are installed, run the script again. As noted previously, make sure
|
|
to install the -dev versions.
|
|
<br />For more information on FFmpeg see the documentation for the FFmpeg project.
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --without-ffmpeg </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Do not compile with ffmpeg </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Use this if you do not want to compile with ffmpeg. If ffmpeg is not installed you must specify this option for Motion to build without ffmpeg. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --without-mysql </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Do not compile with MySQL support </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Use this if you do not want to include MySQL support in the package. <br /> This can also be useful if you get compilation errors related to MySQL and you actually do not need the feature anyway. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --without-pgsql </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Do not compile with PostgreSQL support </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Use this if you do not want to include PostgreSQL support in the package. <br /> This can also be useful if you get compilation errors related to PostgreSQL and you actually do not need the feature anyway. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --without-sqlite3 </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Disable sqlite3 support in motion. </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Use this if you do not want to include SQLite3 support in the package. <br /> This can also be useful if you get compilation errors related to SQLite3 and you actually do not need the feature anyway. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --without-optimizecpu </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Exclude autodetecting platform and cpu type. This will disable the compilation of gcc optimizing code by platform and cpu. </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Use this if the optimization causes problems. Not typically needed. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > --with-developer-flags </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Add additional warning flags for the compiler. </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > This option is for developers only. It checks to ensure that the code is robust. </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
<h3><a name="Make"></a> Make </h3>
|
|
<ul>
|
|
|
|
Once the configure script has successfully finished and indicates all options desired, a 'makefile' is created.
|
|
The makefile builds the Motion program and links in all of the required libraries. To run the makefile on most
|
|
distributions, type: <code>make</code> For FreeBSD distributions use <code>gmake</code>
|
|
<p></p>
|
|
The makefile will go through each of the files and compile them. Depending upon the source code obtained, there may be
|
|
warnings or usually none.
|
|
<p></p>
|
|
If the notifications indicate undefined references, then it is most likely that
|
|
an additional library needs to be added in via the configure switches. Many of these additional missing libraries
|
|
issues may be related to the version of ffmpeg and how it was built or installed. The following is a sample of some
|
|
of the extra ffmpeg libraries that may need to be added to pkg-config <strong><code>.pc</code></strong> files that are
|
|
located in the ffmpeg /lib/pkgconfig directory.
|
|
<p></p>
|
|
<code>
|
|
-lavformat -lswscale -lavcodec -lavutil -lfdk-aac -lswresample -lm -lopus -lz -lva -lvpx -lx264 -lmp3lame -lbz2 -ldl -lvorbisenc -lvorbis -ltheoraenc -ltheoradec
|
|
</code>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
Once the makefile has completed correctly, it will report 'build complete'.
|
|
<p></p>
|
|
If you have run <code>make</code> before, you should run a <code>make clean</code> before
|
|
running <code>make</code> again. This cleans out all the object files that were
|
|
generated the previous time you ran <code>make</code>. If you do not run <code>make clean</code> first
|
|
before you rebuild Motion you may not get the additional feature included.
|
|
For example: If you built Motion without ffmpeg support and then add it later and rebuild Motion
|
|
without running <code>make clean</code> first the ffmpeg feature does not get compiled into the Motion binary.
|
|
<p></p>
|
|
The first time you build Motion run <code>./configure</code>, <code>make</code>, <code>make install</code>.
|
|
If you need to build it again (to run with different configure options) run <code>./configure</code>,
|
|
<code>make clean</code>, <code>make</code>, <code>make install</code>.
|
|
<p></p>
|
|
<h3><a name="Make_Install"></a> Make Install </h3>
|
|
For most distributions type <code>make install</code> to install the files. For FreeBSD systems, use
|
|
<code>gmake install</code>
|
|
<p></p>
|
|
These commands create the required directories and copy the files into the following locations. (default directories):
|
|
<ul>
|
|
<li>/usr/local/bin</li>
|
|
<li>usr/local/man/man1</li>
|
|
<li>/usr/local/etc/motion</li>
|
|
<li>/usr/local/share/doc/motion</li>
|
|
<li>/usr/local/share/motion/examples</li>
|
|
</ul>
|
|
<p></p>
|
|
The contents of what gets copied into each directory is as follows:
|
|
(assuming the default PREFIX /usr/local was used when running configure. Otherwise adjust to the actual directory specified during the configure step.)
|
|
<ul>
|
|
<li> Executable binary "motion" to /usr/local/bin</li>
|
|
<li> Manual page "motion.1" to /usr/local/man/man1</li>
|
|
<li> Document files "CHANGELOG, COPYING, CREDITS, motion_guide.html, and README.md to /usr/local/share/doc/motion</li>
|
|
<li> Example configuration files "*.conf" to /usr/local/share/motion/examples</li>
|
|
<li> Configuration file "motion-dist.conf" to /usr/local/etc/motion</li>
|
|
</ul>
|
|
|
|
Note that any existing files are overwritten. The default configuration file motion-dist.conf is named like
|
|
this so that you do not get your working motion.conf file overwritten when you upgrade Motion.
|
|
|
|
<p></p>
|
|
<h3><a name="Un_Install"></a> Un-install </h3>
|
|
From the Motion base installation directory run <code>make uninstall</code>
|
|
<p></p>
|
|
And delete the base installation directory in /usr/local and any link pointing to it. If you have forgotten where
|
|
you installed it or someone else did it for you, simply search for the files and directories starting with Motion.
|
|
If the filenames and the directories match the names described in the "Make Install" section of this document, you
|
|
can safely delete them.
|
|
<p></p>
|
|
<h3><a name="Additional_Make_Options"></a> Additional Make Options </h3>
|
|
The make command can be run with several options.
|
|
<code>make</code>,
|
|
<code>make install</code> and
|
|
<code>make uninstall</code> has already been described above.
|
|
<p></p>
|
|
<dl>
|
|
<dt> <strong>make clean</strong> </dt>
|
|
<dd> deletes all the binary files (object files) and the motion binary generated by make. It also deletes temporary files and any jpg files that motion has saved in the motion source directory. It is very important to always run <code>make clean</code> before you run <code>make</code> if you change the configuration (like adding features such as ffmpeg) and rebuild motion.</dd>
|
|
</dl>
|
|
<p></p>
|
|
<dl>
|
|
<dt> <strong>make distclean</strong> </dt>
|
|
<dd> deletes the files: config.status, config.log, config.cache, Makefile, and motion.spec.</dd>
|
|
</dl>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
|
|
</ul>
|
|
<h3><a name="Upgrading_From_Older_Version"></a> Upgrading From Older Version </h3>
|
|
<ul>
|
|
If you are upgrading from an older version of Motion many options have been renamed, added or removed.
|
|
The author recommends that you start by copying the configuration files from the older version to a safe
|
|
location for reference only. Then start with a clean copy of the new motion-dist.conf installed and make changes to it.
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
</ul>
|
|
</ul>
|
|
|
|
<h2><a name="Error_Logging"></a> Questions, Issues and Error Reporting</h2>
|
|
<ul>
|
|
<p></p>
|
|
Issues on the github site are for discussing code problems, crashes and application enhancements only.
|
|
<p></p>
|
|
"How to" questions or issues with the setup, configuration or use of Motion, should be asked to the mailing list or on IRC.
|
|
<p></p>
|
|
<ul>
|
|
<li>User Group List: Please sign-up and send your question to the
|
|
<a href="https://lists.sourceforge.net/lists/listinfo/motion-user" rel="nofollow" target="_top">motion-user</a>.
|
|
list </li>
|
|
<li>#motion(irc://chat.freenode.net/motion) on freenode</li>
|
|
</ul>
|
|
<p></p>
|
|
It is very important to use these resources for non-code issues since it engages a much wider audience who may have experience resolving
|
|
the particular issue you are trying to resolve.
|
|
|
|
<h3><a name="Error_Submitting"></a> Submitting Problems</h3>
|
|
|
|
Before submitting a error to the github site, please make sure that you are using either the latest release as posted
|
|
on the <a href="https://github.com/Motion-Project/motion/releases" rel="nofollow" target="_top">project release page</a>.
|
|
or that you have built the latest source code from the github master branch.
|
|
<p></p>
|
|
If the issue still remains with the current version, please validate that the issue has not already been reported
|
|
by searching through the issue log.
|
|
<p></p>
|
|
Next, the project maintainers must be provided the following in order to replicate and ultimately resolve the issue:
|
|
<p></p>
|
|
<ul>
|
|
<li>A complete Motion log for a single run from startup to shutdown at the
|
|
<a href="#log_level" >log_level</a> of 7(INF).</li>
|
|
<li> The expected versus actual result</li>
|
|
</ul>
|
|
<p></p>
|
|
The preferred method of providing the log file is by posting it on
|
|
<a href="https://gist.github.com/" rel="nofollow" target="_top">gist</a> and only providing the link to the
|
|
file within the issue.
|
|
<p></p>
|
|
It is recommended that any IP addresses and/or usernames and passwords included in the file be masked to preserve
|
|
your privacy. Also do not forget to mask any database IDs that the log file may be reporting.
|
|
<p></p>
|
|
For more information please read the
|
|
<a href="https://github.com/Motion-Project/motion/wiki/Privacy" rel="nofollow" target="_top">privacy wiki article</a>.
|
|
<p></p>
|
|
Note that the developers do not use any front-end application to use Motion and we need the actual logs from the Motion
|
|
application rather than logs from the front-end application.
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="Important_Definitions"></a> Important Definitions </h2>
|
|
<ul>
|
|
|
|
<p></p>
|
|
Motion is invoked from the command line. It has no GUI. It is designed to be controlled from config files.
|
|
From version 3.2 the command line is only used to define location of config file and has only a few special
|
|
options.
|
|
<p></p>
|
|
A few important definitions.
|
|
<ul>
|
|
<li> A snapshot is a picture taken at regular intervals independently of any movement in the picture.</li>
|
|
<li> A "motion" or "debug" image/movie shows the pixels that have actually changed during the last frames.
|
|
These pictures are not very useful for normal presentation to the public but they are quite useful
|
|
for testing, tuning and making mask files as you can see exactly where Motion sees something moving.
|
|
Motion is shown in greytones. If labelling is enabled the largest area is marked as blue. Smart mask is
|
|
shown in red.</li>
|
|
<li> A "normal" image is the real image taken by the camera with text overlaid.</li>
|
|
</ul>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="The_Config_Files"></a> The Configuration Files </h2>
|
|
<ul>
|
|
<p></p>
|
|
If Motion was invoked with command line option <code>-c pathname</code> Motion will expect the config file to be as specified. When you specify the config file on the command line with -c you can call it anything.
|
|
<p></p>
|
|
If you do not specify -c or the filename you give Motion does not exist, Motion will search for the configuration file called 'motion.conf' in the following order:
|
|
<p></p>
|
|
<ol>
|
|
<li> Current directory from where motion was invoked</li>
|
|
<li> Then in a directory called '.motion' in the current users home directory (shell environment variable $HOME). E.g. /home/goofy/.motion/motion.conf</li>
|
|
<li> The directory defined by the --sysconfdir=DIR when running .configure during installation of Motion<br />(If this option was not defined the default is /usr/local/etc/motion)</li>
|
|
</ol>
|
|
|
|
If you have write access to /usr/local/etc/motion then the editor recommends having only one motion.conf file
|
|
in the default /usr/local/etc/motion directory.
|
|
<p></p>
|
|
Motion has a configuration file in the distribution package called motion-dist.conf. When you run 'make install' this
|
|
file gets copied to the /usr/local/etc/motion directory.
|
|
<p></p>
|
|
The configuration file needs to be renamed from motion-dist.conf to motion.conf. The original file is called
|
|
motion-dist.conf so that your working motion.conf file does not accidentally get overwritten when
|
|
you re-install or upgrade to a newer version of Motion.
|
|
<p></p>
|
|
If you have more than one camera you should not try and invoke Motion more times. Motion is made to work with
|
|
more than one camera at the same time. The motion.conf file establishes global parameters that apply to all
|
|
cameras and separate camera.conf files that specify the parameters that apply to
|
|
each specific camera. The camera.conf files are specified at the bottom of the motion.conf file. If you only
|
|
have one camera you only need the motion.conf file but if you have more than one camera, then you will
|
|
need to have
|
|
<strong>one camera config file per camera</strong> plus the motion.conf file.
|
|
<p></p>
|
|
If you have for example two cameras you need motion.conf
|
|
<strong>and two</strong> camera config files. So a total of <strong>three</strong> config files.
|
|
<p></p>
|
|
An option that is common to all cameras can be placed in motion.conf. (You can also put all parameters in the
|
|
camera files but that makes a lot of editing when you change a common thing).
|
|
<p></p>
|
|
An option that is unique to a camera must be specified in each camera file.
|
|
<p></p>
|
|
The first camera is defined in the first camera file called from motion.conf. The 2nd camera is defined in the
|
|
2nd camera file called from motion.conf etc.
|
|
<p></p>
|
|
Any option defined in motion.conf will be used for all cameras except for the cameras in which the same option
|
|
is defined in a camera config file.
|
|
<p></p>
|
|
To make it clear, the camera files format and syntax is the same as motion.conf. An example of what you might want
|
|
in a camera file as follows: assume you have two cameras, attached to one system. Create files camera0.conf and
|
|
camera1.conf. At the end of motion.conf, uncomment out the lines that refer to them. The full contents of the
|
|
camera files can be as simple as
|
|
|
|
<p></p>
|
|
<p></p>
|
|
camera0.conf:
|
|
<br /><code><strong> videodevice /dev/video0</strong></code>
|
|
<br /><code><strong>stream_port 8081</strong></code>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
camera1.conf:
|
|
<br /><code><strong> videodevice /dev/video1</strong></code>
|
|
<br /><code><strong>stream_port 8082</strong></code>
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
Motion reads its configuration parameters in the following sequence. If the same
|
|
parameter exists more than one place <strong>the last one read wins</strong>
|
|
|
|
|
|
<ol>
|
|
<li> Motion reads the configuration file motion.conf from the beginning of the file going down line by line.</li>
|
|
<li> If the option "camera" is defined in motion.conf, the camera configuration file(s) is/(are) read.</li>
|
|
<li> Motion continues reading the rest of the motion.conf file. Any options from here will overrule the same option previously defines in a camera config file.</li>
|
|
<li> Motion reads the command line option again overruling any previously defined options.</li>
|
|
</ol>
|
|
So always call the camera config files in the end of the motion.conf file. If you define options in motion.conf
|
|
AFTER the camera file calls, the same options in the camera files will never be used. So always put the camera
|
|
file call at the end of motion.conf.
|
|
<p></p>
|
|
Nearly all config options can be unique for a specific camera and placed in a camera config file.
|
|
There are a few options that must be in motion.conf and cannot be in a camera config
|
|
file: stream_auth_method, webcontrol_* , daemon, and camera.
|
|
<p></p>
|
|
If motion is built without specific features such as ffmpeg, mysql etc it will ignore the options that
|
|
belong to those features and report them as unknown configuration options.
|
|
<p></p>
|
|
If you run the http control command
|
|
<a href="http://host:port/0/config/writeyes" rel="nofollow" target="_top">http://host:port/0/config/writeyes</a>,
|
|
motion will overwrite motion.conf and all the camera.conf files by autogenerated config files neatly formatted and
|
|
only with the features included that Motion was built with. If you later re-build Motion with more features or
|
|
upgrade to a new version, you can use your old config files, run the motion.conf.write command, and you will have
|
|
new config files with the new options included all set to their default values.
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="Command_Line_Options"></a> Command Line Options </h2>
|
|
<ul>
|
|
|
|
<p></p>
|
|
SYNOPSIS
|
|
<pre>
|
|
motion [ -hbnsm ] [ -c config file path ] [ -d level ] [ -k level ] [ -p process_id_file ] [ -l log_file ]
|
|
</pre>
|
|
<p></p>
|
|
<ul>
|
|
<li>-c : Full path and filename of config file.</li>
|
|
<li>-h : Show help screen</li>
|
|
<li>-b : Run in daemon mode</li>
|
|
<li>-n : Run in non-daemon mode</li>
|
|
<li>-s : Run in setup mode. Also forces non-daemon mode.</li>
|
|
<li>-d : Run with message log level 1 - 9</li>
|
|
<li>-k : Run with message log type 1 - 9</li>
|
|
<li>-l : Full path and file name for log file</li>
|
|
<li>-p : Full path and file name for the process id file</li>
|
|
<li>-m : Start in pause mode</li>
|
|
</ul>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="Signals_Sent"></a> Signals (sent with e.g. kill command) </h2>
|
|
<ul>
|
|
<p></p>
|
|
A signal can be sent from the command line by typing
|
|
e.g. <code>kill -s SIGHUP pid</code>, where the last parameter is the process ID which
|
|
you get by typing <code>ps -ef ¦ grep motion</code>. The PID is the first on the
|
|
list which is the parent process for the threads.
|
|
Motion responds to the following signals:
|
|
<p></p>
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<thead>
|
|
<tr>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > Signal </th>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > Description </th>
|
|
<th bgcolor="#edf4f9" word-wrap:break-word > Editors comment </th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > SIGHUP </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > The config file will be reread. </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > This is a very useful signal when you experiment with settings in the config file. </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > SIGTERM </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > If needed motion will create an movie file of the last event and exit </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > SIGUSR1 </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > Motion will create an movie file of the current event. </td>
|
|
<td bgcolor="#edf4f9" word-wrap:break-word > </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="Basic_Setup"></a> Basic Setup </h2>
|
|
<ul>
|
|
<p></p>
|
|
|
|
Before you can start using Motion you need to know some basics about your camera(s).
|
|
<p></p>
|
|
For video4linux devices, the camera must be installed per the requirements of the camera. It is
|
|
out of the scope of this document to tell you how to do this and it depends on which type of camera. Once
|
|
the camera is installed it will have the device name(s) of /dev/video0, /dev/video1, /dev/video2...
|
|
<p></p>
|
|
FreeBSD has a different naming scheme for pci devices that use the bktr subsystem. The bktr subsystem will report
|
|
devices using a naming scheme of /dev/bktr0, /dev/bktr1, etc. These device may also need to use the other
|
|
special device for the tuner. The tuner will need to be specified with the tunerdevice option as /dev/tuner0.
|
|
<p></p>
|
|
<strong>USB cameras</strong> take a lot of bandwidth. A USB camera connected to a USB2 port or hub consumes virtually
|
|
all the bandwidth that the port can handle. Even with a small framesize and low framerate you should not expect to have
|
|
more than one camera per USB controller. If you need more than one USB camera it is possible to add extra USB PCI cards
|
|
to your computer. It is also possible that your computer has more than one controller for different USB slots. For
|
|
example, if the computer has six USB ports, the three on the left may be on controller A versus the three on the right
|
|
may be on controller B. In this situation, connecting two cameras to ports only on the left would not work due to
|
|
excessive bandwidth. However connecting one camera to port on the right and the other to the port on the left
|
|
may work since they are on different controllers.
|
|
|
|
<p></p>
|
|
Motion permits the use of video cards that have discreet input channels. Since USB cameras do not have input channels,
|
|
the option <code><a href="#input" >input</a> </code> must be set to the value -1 for USB cameras.
|
|
<p></p>
|
|
|
|
<strong>Network cameras</strong> are set up via the
|
|
<code><strong> <a href="#netcam_url" >netcam_url</a> </code></strong> parameter.
|
|
The latest versions of Motion support rtsp format which many cameras now stream.
|
|
The URL connection string to enter is specific to the camera and is
|
|
usually provided by the manufacturer. The connection string is the same as what would be used by other
|
|
video playing software such as VLC. If the camera does not stream via RTSP and instead uses a MJPEG, then Motion
|
|
can also view that format. See the option <code><strong> <a href="#netcam_url" >netcam_url</a> </code></strong>
|
|
for additional options.
|
|
<p></p>
|
|
|
|
<strong>Raspberry Pi cameras</strong> can be set up two different ways. If Motion is installed by using the
|
|
apt packages (e.g. apt-get install motion), then the camera must be set up using the bcm2835-v4l2 module which creates
|
|
a v4l2 device for the camera. Users will need to install this module using the
|
|
command <code><strong>sudo modprobe bcm2835-v4l2</strong></code>. This
|
|
will set up the camera as a normal v4l2 device and it can be accessed via a standard /dev/videoX device. If Motion is
|
|
built from source or installed via the deb packages on the project release page, then an additional option is to set
|
|
up the camera using the <code><strong><a href="#mmalcam_name" >mmalcam_name</a> </code></strong> parameter or using
|
|
the bcm2835-v4l2 module. <strong><code>When Motion is installed via apt, the mmalcam option is not available.</code></strong>
|
|
<p></p>
|
|
|
|
<strong>Composite video cards</strong> are normally made with a chip called BT878 (older cards have a BT848). They
|
|
all use the Linux driver called 'bttv'.
|
|
<p></p>
|
|
There are cards with more then one video input but still only one BT878 chip. They have a video multiplexer which
|
|
input is selected with the config option <code>input</code>. Input channel numbers start at 0
|
|
(which is why the value -1 and not 0 disables input selection). There are video capture cards available
|
|
with 4 or 8 inputs but only one chip. They present themselves as one single video device and
|
|
you select input using the 'input' option. If you define e.g. 4 camera config files with the
|
|
same video device name but different input numbers Motion automatically
|
|
goes into round robin mode.
|
|
<p></p>
|
|
Many TV tuner cards have the input channels: TV Tuner = 0, Standard composite video = 1, S-VHS = 3.
|
|
Others have TV=0, composite video 1= 1, composite video = 2, S-VHS = 3.
|
|
For video capture cards input 1 is normally the composite video input.
|
|
<p></p>
|
|
Some capture cards are specially made for surveillance with for example 4 inputs.
|
|
Others have a TV tuner, a composite input and perhaps also a S-Video input.
|
|
For all these cards the inputs are numbered. The numbering varies from card to card so the easiest
|
|
is to experiment with a program such as VLC that can show the video stream.
|
|
<p></p>
|
|
If you use the TV tuner input you also need to set the frequency of the TV channel using the
|
|
option <code><strong><a href="#frequency" >frequency</a></strong></code>. Otherwise
|
|
set <code><strong><a href="#frequency" >frequency</a></strong></code> to 0.
|
|
<p></p>
|
|
Finally you need to set the TV <code><strong><a href="#norm" >norm</a></strong></code>.
|
|
Values: 0 (PAL), 1 (NTSC), 2 (SECAM), 3 (PAL NC no colour). Default is 0 (PAL).
|
|
If your camera is a PAL black and white you may get a better result with norm=3 (PAL no colour).
|
|
<p></p>
|
|
|
|
<strong>Static files</strong> can also be processed with a bit of additional setup via a v4l2loopback device.
|
|
Install the loopback software as described in the
|
|
<code><strong><a href="#Options_Pipe" >Output - Pipe Options</a> </code></strong>
|
|
section of this guide to create a /dev/videoX device and then use software such as ffmpeg to stream
|
|
the static file into the v4l2 device. e.g.
|
|
<code><strong> ffmpeg -re -i mymovie.mp4 -f v4l2 /dev/video0 </strong></code> Then in a separate terminal, start Motion
|
|
with it set to use the <code><strong>/dev/video0</strong></code> device as input. This method can can also be used to
|
|
reformat the content to a different format. The following outputs the original movie into a gray pixel format.
|
|
<code><strong> ffmpeg -re -i mymovie.mp4 -f v4l2 -pix_fmt gray /dev/video0 </strong></code>
|
|
This can be helpful as a interim process where ffmpeg supports a particular input but that format is not yet supported
|
|
by Motion.
|
|
<p></p>
|
|
|
|
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="Configuration_OptionsAlpha"></a> Configuration Options-Listed Alphabetically </h2>
|
|
<ul>
|
|
<p></p>
|
|
These are the options that can be used in the config file.
|
|
<p></p>
|
|
All number values are integer numbers (no decimals allowed). Boolean options can be on or off.
|
|
<p></p>
|
|
Some configuration options are only used if Motion is built on a system that has the matching software libraries installed (MySQL, PostgreSQL, SQLite, FFMPEG, etc).
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<table cellspacing="0" border="0">
|
|
<colgroup width="152"></colgroup>
|
|
<colgroup width="190"></colgroup>
|
|
<colgroup width="160"></colgroup>
|
|
<colgroup width="160"></colgroup>
|
|
<tr>
|
|
<td height="17" align="left"><b>Version 3.2</b></td>
|
|
<td align="left"><b>Version 3.4</b></td>
|
|
<td align="left"><b>Version 4.0</b></td>
|
|
<td align="left"><b>Current Version</b></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">area_detect</td>
|
|
<td align="left">area_detect</td>
|
|
<td align="left">area_detect</td>
|
|
<td align="left"><a href="#area_detect" >area_detect</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">auto_brightness</td>
|
|
<td align="left">auto_brightness</td>
|
|
<td align="left">auto_brightness</td>
|
|
<td align="left"><a href="#auto_brightness" >auto_brightness</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">brightness</td>
|
|
<td align="left">brightness</td>
|
|
<td align="left">brightness</td>
|
|
<td align="left"><a href="#brightness" >brightness</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">thread</td>
|
|
<td align="left">thread</td>
|
|
<td align="left">camera</td>
|
|
<td align="left"><a href="#camera" >camera</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left"><br /></td>
|
|
<td align="left">camera_dir</td>
|
|
<td align="left"><a href="#camera_dir" >camera_dir</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left"><br /></td>
|
|
<td align="left">camera_id</td>
|
|
<td align="left"><a href="#camera_id" >camera_id</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left"><br /></td>
|
|
<td align="left">camera_name</td>
|
|
<td align="left"><a href="#camera_name" >camera_name</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">contrast</td>
|
|
<td align="left">contrast</td>
|
|
<td align="left">contrast</td>
|
|
<td align="left"><a href="#contrast" >contrast</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">daemon</td>
|
|
<td align="left">daemon</td>
|
|
<td align="left">daemon</td>
|
|
<td align="left"><a href="#daemon" >daemon</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">database_busy_timeout</td>
|
|
<td align="left">database_busy_timeout</td>
|
|
<td align="left"><a href="#database_busy_timeout" >database_busy_timeout</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">mysql_db</td>
|
|
<td align="left">database_dbname</td>
|
|
<td align="left">database_dbname</td>
|
|
<td align="left"><a href="#database_dbname" >database_dbname</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">pgsql_db</td>
|
|
<td align="left">database_dbname</td>
|
|
<td align="left">database_dbname</td>
|
|
<td align="left"><a href="#database_dbname" >database_dbname</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">mysql_host</td>
|
|
<td align="left">database_host</td>
|
|
<td align="left">database_host</td>
|
|
<td align="left"><a href="#database_host" >database_host</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">pgsql_host</td>
|
|
<td align="left">database_host</td>
|
|
<td align="left">database_host</td>
|
|
<td align="left"><a href="#database_host" >database_host</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">mysql_password</td>
|
|
<td align="left">database_password</td>
|
|
<td align="left">database_password</td>
|
|
<td align="left"><a href="#database_password" >database_password</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">pgsql_password</td>
|
|
<td align="left">database_password</td>
|
|
<td align="left">database_password</td>
|
|
<td align="left"><a href="#database_password" >database_password</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">pgsql_port</td>
|
|
<td align="left">database_port</td>
|
|
<td align="left">database_port</td>
|
|
<td align="left"><a href="#database_port" >database_port</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">database_type</td>
|
|
<td align="left">database_type</td>
|
|
<td align="left"><a href="#database_type" >database_type</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">mysql_user</td>
|
|
<td align="left">database_user</td>
|
|
<td align="left">database_user</td>
|
|
<td align="left"><a href="#database_user" >database_user</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">pgsql_user</td>
|
|
<td align="left">database_user</td>
|
|
<td align="left">database_user</td>
|
|
<td align="left"><a href="#database_user" >database_user</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">despeckle</td>
|
|
<td align="left">despeckle_filter</td>
|
|
<td align="left">despeckle_filter</td>
|
|
<td align="left"><a href="#despeckle_filter" >despeckle_filter</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">output_all</td>
|
|
<td align="left">emulate_motion</td>
|
|
<td align="left">emulate_motion</td>
|
|
<td align="left"><a href="#emulate_motion" >emulate_motion</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">gap</td>
|
|
<td align="left">event_gap</td>
|
|
<td align="left">event_gap</td>
|
|
<td align="left"><a href="#event_gap" >event_gap</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">exif_text</td>
|
|
<td align="left">exif_text</td>
|
|
<td align="left"><a href="#exif_text" >exif_text</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">extpipe</td>
|
|
<td align="left">extpipe</td>
|
|
<td align="left"><a href="#extpipe" >extpipe</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_bps</td>
|
|
<td align="left">ffmpeg_bps</td>
|
|
<td align="left">ffmpeg_bps</td>
|
|
<td align="left"><a href="#ffmpeg_bps" >ffmpeg_bps</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">ffmpeg_duplicate_frames</td>
|
|
<td align="left">ffmpeg_duplicate_frames</td>
|
|
<td align="left"><a href="#ffmpeg_duplicate_frames" >ffmpeg_duplicate_frames</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_cap_motion</td>
|
|
<td align="left">ffmpeg_output_debug_movies</td>
|
|
<td align="left">ffmpeg_output_debug_movies</td>
|
|
<td align="left"><a href="#ffmpeg_output_debug_movies" >ffmpeg_output_debug_movies</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_cap_new</td>
|
|
<td align="left">ffmpeg_output_movies</td>
|
|
<td align="left">ffmpeg_output_movies</td>
|
|
<td align="left"><a href="#ffmpeg_output_movies" >ffmpeg_output_movies</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_variable_bitrate</td>
|
|
<td align="left">ffmpeg_variable_bitrate</td>
|
|
<td align="left">ffmpeg_variable_bitrate</td>
|
|
<td align="left"><a href="#ffmpeg_variable_bitrate" >ffmpeg_variable_bitrate</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_video_codec</td>
|
|
<td align="left">ffmpeg_video_codec</td>
|
|
<td align="left">ffmpeg_video_codec</td>
|
|
<td align="left"><a href="#ffmpeg_video_codec" >ffmpeg_video_codec</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#flip_axis" >flip_axis</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">framerate</td>
|
|
<td align="left">framerate</td>
|
|
<td align="left">framerate</td>
|
|
<td align="left"><a href="#framerate" >framerate</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">frequency</td>
|
|
<td align="left">frequency</td>
|
|
<td align="left">frequency</td>
|
|
<td align="left"><a href="#frequency" >frequency</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">height</td>
|
|
<td align="left">height</td>
|
|
<td align="left">height</td>
|
|
<td align="left"><a href="#height" >height</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">hue</td>
|
|
<td align="left">hue</td>
|
|
<td align="left">hue</td>
|
|
<td align="left"><a href="#hue" >hue</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">input</td>
|
|
<td align="left">input</td>
|
|
<td align="left">input</td>
|
|
<td align="left"><a href="#input" >input</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">ipv6_enabled</td>
|
|
<td align="left">ipv6_enabled</td>
|
|
<td align="left"><a href="#ipv6_enabled" >ipv6_enabled</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">lightswitch</td>
|
|
<td align="left">lightswitch</td>
|
|
<td align="left">lightswitch</td>
|
|
<td align="left"><a href="#lightswitch" >lightswitch</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">locate</td>
|
|
<td align="left">locate_motion_mode</td>
|
|
<td align="left">locate_motion_mode</td>
|
|
<td align="left"><a href="#locate_motion_mode" >locate_motion_mode</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">locate_motion_style</td>
|
|
<td align="left">locate_motion_style</td>
|
|
<td align="left"><a href="#locate_motion_style" >locate_motion_style</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">log_level</td>
|
|
<td align="left">log_level</td>
|
|
<td align="left"><a href="#log_level" >log_level</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">log_type</td>
|
|
<td align="left">log_type</td>
|
|
<td align="left"><a href="#log_type" >log_type</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">logfile</td>
|
|
<td align="left">logfile</td>
|
|
<td align="left"><a href="#logfile" >logfile</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">mask_file</td>
|
|
<td align="left">mask_file</td>
|
|
<td align="left">mask_file</td>
|
|
<td align="left"><a href="#mask_file" >mask_file</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#mask_privacy" >mask_privacy</a></td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td height="17" align="left">max_mpeg_time</td>
|
|
<td align="left">max_movie_time</td>
|
|
<td align="left">max_movie_time</td>
|
|
<td align="left"><a href="#max_movie_time" >max_movie_time</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">minimum_frame_time</td>
|
|
<td align="left">minimum_frame_time</td>
|
|
<td align="left">minimum_frame_time</td>
|
|
<td align="left"><a href="#minimum_frame_time" >minimum_frame_time</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">minimum_motion_frames</td>
|
|
<td align="left">minimum_motion_frames</td>
|
|
<td align="left">minimum_motion_frames</td>
|
|
<td align="left"><a href="#minimum_motion_frames" >minimum_motion_frames</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left"><br /></td>
|
|
<td align="left">mmalcam_control_params</td>
|
|
<td align="left"><a href="#mmalcam_control_params" >mmalcam_control_params</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left"><br /></td>
|
|
<td align="left">mmalcam_name</td>
|
|
<td align="left"><a href="#mmalcam_name" >mmalcam_name</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">motion_video_pipe</td>
|
|
<td align="left">motion_video_pipe</td>
|
|
<td align="left">motion_video_pipe</td>
|
|
<td align="left"><a href="#motion_video_pipe" >motion_video_pipe</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">movie_filename</td>
|
|
<td align="left">movie_filename</td>
|
|
<td align="left">movie_filename</td>
|
|
<td align="left"><a href="#movie_filename" >movie_filename</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#netcam_highres" >netcam_highres</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">netcam_keepalive</td>
|
|
<td align="left">netcam_keepalive</td>
|
|
<td align="left">netcam_keepalive</td>
|
|
<td align="left"><a href="#netcam_keepalive" >netcam_keepalive</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">netcam_proxy</td>
|
|
<td align="left">netcam_proxy</td>
|
|
<td align="left">netcam_proxy</td>
|
|
<td align="left"><a href="#netcam_proxy" >netcam_proxy</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">netcam_tolerant_check</td>
|
|
<td align="left">netcam_tolerant_check</td>
|
|
<td align="left">netcam_tolerant_check</td>
|
|
<td align="left"><a href="#netcam_tolerant_check" >netcam_tolerant_check</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">netcam_url</td>
|
|
<td align="left">netcam_url</td>
|
|
<td align="left">netcam_url</td>
|
|
<td align="left"><a href="#netcam_url" >netcam_url</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">netcam_userpass</td>
|
|
<td align="left">netcam_userpass</td>
|
|
<td align="left">netcam_userpass</td>
|
|
<td align="left"><a href="#netcam_userpass" >netcam_userpass</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">noise_level</td>
|
|
<td align="left">noise_level</td>
|
|
<td align="left">noise_level</td>
|
|
<td align="left"><a href="#noise_level" >noise_level</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">noise_tune</td>
|
|
<td align="left">noise_tune</td>
|
|
<td align="left">noise_tune</td>
|
|
<td align="left"><a href="#noise_tune" >noise_tune</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">norm</td>
|
|
<td align="left">norm</td>
|
|
<td align="left">norm</td>
|
|
<td align="left"><a href="#norm" >norm</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_area_detected</td>
|
|
<td align="left">on_area_detected</td>
|
|
<td align="left">on_area_detected</td>
|
|
<td align="left"><a href="#on_area_detected" >on_area_detected</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_camera_lost</td>
|
|
<td align="left">on_camera_lost</td>
|
|
<td align="left">on_camera_lost</td>
|
|
<td align="left"><a href="#on_camera_lost" >on_camera_lost</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#on_camera_found" >on_camera_found</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_event_end</td>
|
|
<td align="left">on_event_end</td>
|
|
<td align="left">on_event_end</td>
|
|
<td align="left"><a href="#on_event_end" >on_event_end</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_event_start</td>
|
|
<td align="left">on_event_start</td>
|
|
<td align="left">on_event_start</td>
|
|
<td align="left"><a href="#on_event_start" >on_event_start</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_motion_detected</td>
|
|
<td align="left">on_motion_detected</td>
|
|
<td align="left">on_motion_detected</td>
|
|
<td align="left"><a href="#on_motion_detected" >on_motion_detected</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_movie_end</td>
|
|
<td align="left">on_movie_end</td>
|
|
<td align="left">on_movie_end</td>
|
|
<td align="left"><a href="#on_movie_end" >on_movie_end</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_movie_start</td>
|
|
<td align="left">on_movie_start</td>
|
|
<td align="left">on_movie_start</td>
|
|
<td align="left"><a href="#on_movie_start" >on_movie_start</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">on_picture_save</td>
|
|
<td align="left">on_picture_save</td>
|
|
<td align="left">on_picture_save</td>
|
|
<td align="left"><a href="#on_picture_save" >on_picture_save</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">output_motion</td>
|
|
<td align="left">output_debug_pictures</td>
|
|
<td align="left">output_debug_pictures</td>
|
|
<td align="left"><a href="#output_debug_pictures" >output_debug_pictures</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">output_normal</td>
|
|
<td align="left">output_pictures</td>
|
|
<td align="left">output_pictures</td>
|
|
<td align="left"><a href="#output_pictures" >output_pictures</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">jpeg_filename</td>
|
|
<td align="left">picture_filename</td>
|
|
<td align="left">picture_filename</td>
|
|
<td align="left"><a href="#picture_filename" >picture_filename</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ppm</td>
|
|
<td align="left">picture_type</td>
|
|
<td align="left">picture_type</td>
|
|
<td align="left"><a href="#picture_type" >picture_type</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">post_capture</td>
|
|
<td align="left">post_capture</td>
|
|
<td align="left">post_capture</td>
|
|
<td align="left"><a href="#post_capture" >post_capture</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">power_line_frequency</td>
|
|
<td align="left">power_line_frequency</td>
|
|
<td align="left"><a href="#power_line_frequency" >power_line_frequency</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">pre_capture</td>
|
|
<td align="left">pre_capture</td>
|
|
<td align="left">pre_capture</td>
|
|
<td align="left"><a href="#pre_capture" >pre_capture</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">process_id_file</td>
|
|
<td align="left">process_id_file</td>
|
|
<td align="left">process_id_file</td>
|
|
<td align="left"><a href="#process_id_file" >process_id_file</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">quality</td>
|
|
<td align="left">quality</td>
|
|
<td align="left">quality</td>
|
|
<td align="left"><a href="#quality" >quality</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">quiet</td>
|
|
<td align="left">quiet</td>
|
|
<td align="left">quiet</td>
|
|
<td align="left"><a href="#quiet" >quiet</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">rotate</td>
|
|
<td align="left">rotate</td>
|
|
<td align="left">rotate</td>
|
|
<td align="left"><a href="#rotate" >rotate</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">roundrobin_frames</td>
|
|
<td align="left">roundrobin_frames</td>
|
|
<td align="left">roundrobin_frames</td>
|
|
<td align="left"><a href="#roundrobin_frames" >roundrobin_frames</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">roundrobin_skip</td>
|
|
<td align="left">roundrobin_skip</td>
|
|
<td align="left">roundrobin_skip</td>
|
|
<td align="left"><a href="#roundrobin_skip" >roundrobin_skip</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">rtsp_uses_tcp</td>
|
|
<td align="left">rtsp_uses_tcp</td>
|
|
<td align="left"><a href="#rtsp_uses_tcp" >rtsp_uses_tcp</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">saturation</td>
|
|
<td align="left">saturation</td>
|
|
<td align="left">saturation</td>
|
|
<td align="left"><a href="#saturation" >saturation</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">setup_mode</td>
|
|
<td align="left">setup_mode</td>
|
|
<td align="left">setup_mode</td>
|
|
<td align="left"><a href="#setup_mode" >setup_mode</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">smart_mask_speed</td>
|
|
<td align="left">smart_mask_speed</td>
|
|
<td align="left">smart_mask_speed</td>
|
|
<td align="left"><a href="#smart_mask_speed" >smart_mask_speed</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">snapshot_filename</td>
|
|
<td align="left">snapshot_filename</td>
|
|
<td align="left">snapshot_filename</td>
|
|
<td align="left"><a href="#snapshot_filename" >snapshot_filename</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">snapshot_interval</td>
|
|
<td align="left">snapshot_interval</td>
|
|
<td align="left">snapshot_interval</td>
|
|
<td align="left"><a href="#snapshot_interval" >snapshot_interval</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">sql_log_mpeg</td>
|
|
<td align="left">sql_log_movie</td>
|
|
<td align="left">sql_log_movie</td>
|
|
<td align="left"><a href="#sql_log_movie" >sql_log_movie</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">sql_log_image</td>
|
|
<td align="left">sql_log_picture</td>
|
|
<td align="left">sql_log_picture</td>
|
|
<td align="left"><a href="#sql_log_picture" >sql_log_picture</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">sql_log_snapshot</td>
|
|
<td align="left">sql_log_snapshot</td>
|
|
<td align="left">sql_log_snapshot</td>
|
|
<td align="left"><a href="#sql_log_snapshot" >sql_log_snapshot</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">sql_log_timelapse</td>
|
|
<td align="left">sql_log_timelapse</td>
|
|
<td align="left">sql_log_timelapse</td>
|
|
<td align="left"><a href="#sql_log_timelapse" >sql_log_timelapse</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">sql_query</td>
|
|
<td align="left">sql_query</td>
|
|
<td align="left">sql_query</td>
|
|
<td align="left"><a href="#sql_query" >sql_query</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#sql_query_start" >sql_query_start</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">stream_auth_method</td>
|
|
<td align="left">stream_auth_method</td>
|
|
<td align="left"><a href="#stream_auth_method" >stream_auth_method</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">stream_authentication</td>
|
|
<td align="left">stream_authentication</td>
|
|
<td align="left"><a href="#stream_authentication" >stream_authentication</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">webcam_limit</td>
|
|
<td align="left">stream_limit</td>
|
|
<td align="left">stream_limit</td>
|
|
<td align="left"><a href="#stream_limit" >stream_limit</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">webcam_localhost</td>
|
|
<td align="left">stream_localhost</td>
|
|
<td align="left">stream_localhost</td>
|
|
<td align="left"><a href="#stream_localhost" >stream_localhost</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">webcam_maxrate</td>
|
|
<td align="left">stream_maxrate</td>
|
|
<td align="left">stream_maxrate</td>
|
|
<td align="left"><a href="#stream_maxrate" >stream_maxrate</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">webcam_motion</td>
|
|
<td align="left">stream_motion</td>
|
|
<td align="left">stream_motion</td>
|
|
<td align="left"><a href="#stream_motion" >stream_motion</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">webcam_port</td>
|
|
<td align="left">stream_port</td>
|
|
<td align="left">stream_port</td>
|
|
<td align="left"><a href="#stream_port" >stream_port</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">stream_preview_newline</td>
|
|
<td align="left">stream_preview_newline</td>
|
|
<td align="left"><a href="#stream_preview_newline" >stream_preview_newline</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">stream_preview_scale</td>
|
|
<td align="left">stream_preview_scale</td>
|
|
<td align="left"><a href="#stream_preview_scale" >stream_preview_scale</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">webcam_quality</td>
|
|
<td align="left">stream_quality</td>
|
|
<td align="left">stream_quality</td>
|
|
<td align="left"><a href="#stream_quality" >stream_quality</a></td>
|
|
</tr>
|
|
m <tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#substream_port" >substream_port</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">switchfilter</td>
|
|
<td align="left">switchfilter</td>
|
|
<td align="left">switchfilter</td>
|
|
<td align="left"><a href="#switchfilter" >switchfilter</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">target_dir</td>
|
|
<td align="left">target_dir</td>
|
|
<td align="left">target_dir</td>
|
|
<td align="left"><a href="#target_dir" >target_dir</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">text_changes</td>
|
|
<td align="left">text_changes</td>
|
|
<td align="left">text_changes</td>
|
|
<td align="left"><a href="#text_changes" >text_changes</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">text_double</td>
|
|
<td align="left">text_double</td>
|
|
<td align="left">text_double</td>
|
|
<td align="left"><a href="#text_double" >text_double</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">text_event</td>
|
|
<td align="left">text_event</td>
|
|
<td align="left">text_event</td>
|
|
<td align="left"><a href="#text_event" >text_event</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">text_left</td>
|
|
<td align="left">text_left</td>
|
|
<td align="left">text_left</td>
|
|
<td align="left"><a href="#text_left" >text_left</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">text_right</td>
|
|
<td align="left">text_right</td>
|
|
<td align="left">text_right</td>
|
|
<td align="left"><a href="#text_right" >text_right</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">threshold</td>
|
|
<td align="left">threshold</td>
|
|
<td align="left">threshold</td>
|
|
<td align="left"><a href="#threshold" >threshold</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">threshold_tune</td>
|
|
<td align="left">threshold_tune</td>
|
|
<td align="left">threshold_tune</td>
|
|
<td align="left"><a href="#threshold_tune" >threshold_tune</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_video_codec</td>
|
|
<td align="left">ffmpeg_video_codec</td>
|
|
<td align="left">ffmpeg_video_codec</td>
|
|
<td align="left"><a href="#timelapse_codec" >timelapse_codec</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">timelapse_filename</td>
|
|
<td align="left">timelapse_filename</td>
|
|
<td align="left">timelapse_filename</td>
|
|
<td align="left"><a href="#timelapse_filename" >timelapse_filename</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#timelapse_fps" >timelapse_fps</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_timelapse</td>
|
|
<td align="left">ffmpeg_timelapse</td>
|
|
<td align="left">ffmpeg_timelapse</td>
|
|
<td align="left"><a href="#timelapse_interval" >timelapse_interval</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_timelapse_mode</td>
|
|
<td align="left">ffmpeg_timelapse_mode</td>
|
|
<td align="left">ffmpeg_timelapse_mode</td>
|
|
<td align="left"><a href="#timelapse_mode" >timelapse_mode</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_auto</td>
|
|
<td align="left">track_auto</td>
|
|
<td align="left">track_auto</td>
|
|
<td align="left"><a href="#track_auto" >track_auto</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_iomojo_id</td>
|
|
<td align="left">track_iomojo_id</td>
|
|
<td align="left">track_iomojo_id</td>
|
|
<td align="left"><a href="#track_iomojo_id" >track_iomojo_id</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_maxx</td>
|
|
<td align="left">track_maxx</td>
|
|
<td align="left">track_maxx</td>
|
|
<td align="left"><a href="#track_maxx" >track_maxx</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_maxy</td>
|
|
<td align="left">track_maxy</td>
|
|
<td align="left">track_maxy</td>
|
|
<td align="left"><a href="#track_maxy" >track_maxy</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_motorx</td>
|
|
<td align="left">track_motorx</td>
|
|
<td align="left">track_motorx</td>
|
|
<td align="left"><a href="#track_motorx" >track_motorx</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_motory</td>
|
|
<td align="left">track_motory</td>
|
|
<td align="left">track_motory</td>
|
|
<td align="left"><a href="#track_motory" >track_motory</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_move_wait</td>
|
|
<td align="left">track_move_wait</td>
|
|
<td align="left">track_move_wait</td>
|
|
<td align="left"><a href="#track_move_wait" >track_move_wait</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_port</td>
|
|
<td align="left">track_port</td>
|
|
<td align="left">track_port</td>
|
|
<td align="left"><a href="#track_port" >track_port</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_speed</td>
|
|
<td align="left">track_speed</td>
|
|
<td align="left">track_speed</td>
|
|
<td align="left"><a href="#track_speed" >track_speed</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_step_angle_x</td>
|
|
<td align="left">track_step_angle_x</td>
|
|
<td align="left">track_step_angle_x</td>
|
|
<td align="left"><a href="#track_step_angle_x" >track_step_angle_x</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_step_angle_y</td>
|
|
<td align="left">track_step_angle_y</td>
|
|
<td align="left">track_step_angle_y</td>
|
|
<td align="left"><a href="#track_step_angle_y" >track_step_angle_y</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_stepsize</td>
|
|
<td align="left">track_stepsize</td>
|
|
<td align="left">track_stepsize</td>
|
|
<td align="left"><a href="#track_stepsize" >track_stepsize</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">track_type</td>
|
|
<td align="left">track_type</td>
|
|
<td align="left">track_type</td>
|
|
<td align="left"><a href="#track_type" >track_type</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">tunerdevice</td>
|
|
<td align="left">tunerdevice</td>
|
|
<td align="left">tunerdevice</td>
|
|
<td align="left"><a href="#tunerdevice" >tunerdevice</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br /></td>
|
|
<td align="left">use_extpipe</td>
|
|
<td align="left">use_extpipe</td>
|
|
<td align="left"><a href="#use_extpipe" >use_extpipe</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">v4l2_palette</td>
|
|
<td align="left">v4l2_palette</td>
|
|
<td align="left">v4l2_palette</td>
|
|
<td align="left"><a href="#v4l2_palette" >v4l2_palette</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">video_pipe</td>
|
|
<td align="left">video_pipe</td>
|
|
<td align="left">video_pipe</td>
|
|
<td align="left"><a href="#video_pipe" >video_pipe</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">videodevice</td>
|
|
<td align="left">videodevice</td>
|
|
<td align="left">videodevice</td>
|
|
<td align="left"><a href="#videodevice" >videodevice</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">control_authentication</td>
|
|
<td align="left">webcontrol_authentication</td>
|
|
<td align="left">webcontrol_authentication</td>
|
|
<td align="left"><a href="#webcontrol_authentication" >webcontrol_authentication</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">control_html_output</td>
|
|
<td align="left">webcontrol_html_output</td>
|
|
<td align="left">webcontrol_html_output</td>
|
|
<td align="left"><a href="#webcontrol_html_output" >webcontrol_html_output</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">control_localhost</td>
|
|
<td align="left">webcontrol_localhost</td>
|
|
<td align="left">webcontrol_localhost</td>
|
|
<td align="left"><a href="#webcontrol_localhost" >webcontrol_localhost</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"></td>
|
|
<td align="left"><a href="#webcontrol_parms" >webcontrol_parms</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">control_port</td>
|
|
<td align="left">webcontrol_port</td>
|
|
<td align="left">webcontrol_port</td>
|
|
<td align="left"><a href="#webcontrol_port" >webcontrol_port</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">width</td>
|
|
<td align="left">width</td>
|
|
<td align="left">width</td>
|
|
<td align="left"><a href="#width" >width</td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left">ffmpeg_deinterlace</td>
|
|
<td align="left">-Depreciated</td>
|
|
<td align="left">-Depreciated</td>
|
|
<td align="left">-Depreciated</td>
|
|
</tr>
|
|
<tr>
|
|
<td height="17" align="left"><br></td>
|
|
<td align="left">sdl_threadnr</td>
|
|
<td align="left">sdl_threadnr</td>
|
|
<td align="left">-Depreciated</td>
|
|
</tr>
|
|
|
|
|
|
</table>
|
|
</ul>
|
|
|
|
<h2><a name="Configuration_OptionsTopic"></a> Configuration Options-Listed by Topic </h2>
|
|
<ul>
|
|
|
|
<p></p>
|
|
These are the options that can be used in the config file.
|
|
<p></p>
|
|
All number values are integer numbers (no decimals allowed). Boolean options can be on or off.
|
|
<p></p>
|
|
Some configuration options are only used if Motion is built on a system that has the matching software libraries installed (MySQL, PostgreSQL, SQLite, FFMPEG, etc).
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<a href="#Options_System_Processing" >System Processing</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#daemon" >daemon</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#process_id_file" >process_id_file</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#setup_mode" >setup_mode</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#logfile" >logfile</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#log_level" >log_level</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#log_type" >log_type</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#camera" >camera</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#camera_id" >camera_id</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#camera_name" >camera_name</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#camera_dir" >camera_dir</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Video4Linux_Devices" >Video4Linux Devices</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#videodevice" >videodevice</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#v4l2_palette" >v4l2_palette</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#tunerdevice" >tunerdevice</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#input" >input</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#norm" >norm</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#frequency" >frequency</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#power_line_frequency" >power_line_frequency</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#auto_brightness" >auto_brightness</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#brightness" >brightness</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#contrast" >contrast</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#saturation" >saturation</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#hue" >hue</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#roundrobin_frames" >roundrobin_frames</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#roundrobin_skip" >roundrobin_skip</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#switchfilter" >switchfilter</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Network_Cameras" >Network Cameras</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#netcam_url" >netcam_url</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#netcam_userpass" >netcam_userpass</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#netcam_keepalive" >netcam_keepalive</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#netcam_proxy" >netcam_proxy</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#netcam_tolerant_check" >netcam_tolerant_check</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#rtsp_uses_tcp" >rtsp_uses_tcp</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#netcam_highres" >netcam_highres</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Raspi_Cameras" >Raspberry Pi Camera</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#mmalcam_name" >mmalcam_name</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#mmalcam_control_params" >mmalcam_control_params</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Image_Processing" >Image_Processing</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#rotate" >rotate</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#width" >width</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#height" >height</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#framerate" >framerate</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#minimum_frame_time" >minimum_frame_time</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#despeckle_filter" >despeckle_filter</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#locate_motion_mode" >locate_motion_mode</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#locate_motion_style" >locate_motion_style</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#text_left" >text_left</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#text_right" >text_right</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#text_changes" >text_changes</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#text_event" >text_event</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#text_double" >text_double</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#flip_axis" >flip_axis</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Motion_Detection" >Motion Detection</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#emulate_motion" >emulate_motion</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#threshold" >threshold</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#threshold_tune" >threshold_tune</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#noise_level" >noise_level</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#noise_tune" >noise_tune</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#area_detect" >area_detect</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#mask_file" >mask_file</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#mask_privacy" >mask_privacy</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#smart_mask_speed" >smart_mask_speed</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#lightswitch" >lightswitch</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#minimum_motion_frames" >minimum_motion_frames</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#event_gap" >event_gap</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Scripts" >Script Execution</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#on_event_start" >on_event_start</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#on_event_end" >on_event_end</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#on_picture_save" >on_picture_save</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#on_motion_detected" >on_motion_detected</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#on_area_detected" >on_area_detected</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#on_movie_start" >on_movie_start</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#on_movie_end" >on_movie_end</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#on_camera_lost" >on_camera_lost</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#on_camera_found" >on_camera_found</a> </td>
|
|
</tr>
|
|
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Output_General" >Output - General</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#quiet" >quiet</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#pre_capture" >pre_capture</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#post_capture" >post_capture</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#target_dir" >target_dir</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Pictures" >Output - Picture </a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#output_pictures" >output_pictures</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#output_debug_pictures" >output_debug_pictures</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#quality" >quality</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#picture_type" >picture_type</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#snapshot_interval" >snapshot_interval</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#snapshot_filename" >snapshot_filename</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#picture_filename" >picture_filename</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#exif_text" >exif_text</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Movies" >Output - Movie</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#max_movie_time" >max_movie_time</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#ffmpeg_output_movies" >ffmpeg_output_movies</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#ffmpeg_output_debug_movies" >ffmpeg_output_debug_movies</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#ffmpeg_bps" >ffmpeg_bps</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#ffmpeg_variable_bitrate" >ffmpeg_variable_bitrate</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#ffmpeg_video_codec" >ffmpeg_video_codec</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#ffmpeg_duplicate_frames" >ffmpeg_duplicate_frames</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#movie_filename" >movie_filename</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#timelapse_filename" >timelapse_filename</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#timelapse_interval" >timelapse_interval</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#timelapse_mode" >timelapse_mode</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#timelapse_codec" >timelapse_codec</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#timelapse_fps" >timelapse_fps</a> </td>
|
|
</tr>
|
|
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Pipe" >Output - Pipe</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#video_pipe" >video_pipe</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#motion_video_pipe" >motion_video_pipe</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#use_extpipe" >use_extpipe</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#extpipe" >extpipe</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Stream_Webcontrol" >Stream and Webcontrol</a>
|
|
<ul>
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#ipv6_enabled" >ipv6_enabled</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_port" >stream_port</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#substream_port" >substream_port</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_quality" >stream_quality</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_motion" >stream_motion</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_maxrate" >stream_maxrate</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_localhost" >stream_localhost</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_limit" >stream_limit</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_auth_method" >stream_auth_method</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_authentication" >stream_authentication</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_preview_scale" >stream_preview_scale</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#stream_preview_newline" >stream_preview_newline</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#webcontrol_port" >webcontrol_port</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#webcontrol_localhost" >webcontrol_localhost</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#webcontrol_html_output" >webcontrol_html_output</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#webcontrol_authentication" >webcontrol_authentication</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#webcontrol_parms" >webcontrol_parms</a> </td>
|
|
</tr>
|
|
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Database" >Database</a>
|
|
<ul>
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#sql_log_picture" >sql_log_picture</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#sql_log_snapshot" >sql_log_snapshot</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#sql_log_movie" >sql_log_movie</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#sql_log_timelapse" >sql_log_timelapse</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#sql_query" >sql_query</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#sql_query_start" >sql_query_start</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#database_type" >database_type</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#database_dbname" >database_dbname</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#database_host" >database_host</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#database_user" >database_user</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#database_password" >database_password</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#database_port" >database_port</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#database_busy_timeout" >database_busy_timeout</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<a href="#Options_Tracking" >Tracking</a>
|
|
<ul>
|
|
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
<col width="250px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#track_type" >track_type</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_auto" >track_auto</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_port" >track_port</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_motorx" >track_motorx</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#track_motorx_reverse" >track_motorx_reverse</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_motory" >track_motory</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_motory_reverse" >track_motory_reverse</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_maxx" >track_maxx</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#track_minx" >track_minx</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_maxy" >track_maxy</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_miny" >track_miny</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_homex" >track_homex</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#track_homey" >track_homey</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_iomojo_id" >track_iomojo_id</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_step_angle_x" >track_step_angle_x</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_step_angle_y" >track_step_angle_y</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" ><a href="#track_move_wait" >track_move_wait</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_speed" >track_speed</a> </td>
|
|
<td bgcolor="#edf4f9" ><a href="#track_stepsize" >track_stepsize</a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h2><a name="Configuration_OptionsDetail"></a> Configuration Options-Detail Descriptions </h2>
|
|
<ul>
|
|
<p></p>
|
|
<p></p>
|
|
The following section provides detailed descriptions of each of the configuration options.
|
|
<p></p>
|
|
|
|
<h3><a name="conversion_specifiers"></a>Conversion Specifiers</h3>
|
|
<ul>
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="50px">
|
|
<col width="300px">
|
|
<col width="50px">
|
|
<col width="300px">
|
|
<col width="50px">
|
|
<col width="300px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%Y </a> </td>
|
|
<td bgcolor="#edf4f9" >year</a> </td>
|
|
<td bgcolor="#edf4f9" >%m </a> </td>
|
|
<td bgcolor="#edf4f9" >month</a> </td>
|
|
<td bgcolor="#edf4f9" >%d </a> </td>
|
|
<td bgcolor="#edf4f9" >day</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%H </a> </td>
|
|
<td bgcolor="#edf4f9" >hour</a> </td>
|
|
<td bgcolor="#edf4f9" >%M </a> </td>
|
|
<td bgcolor="#edf4f9" >minute</a> </td>
|
|
<td bgcolor="#edf4f9" >%S </a> </td>
|
|
<td bgcolor="#edf4f9" >second</a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%T </a> </td>
|
|
<td bgcolor="#edf4f9" >HH:MM:SS </a> </td>
|
|
<td bgcolor="#edf4f9" >%v </a> </td>
|
|
<td bgcolor="#edf4f9" >event</a> </td>
|
|
<td bgcolor="#edf4f9" >%q </a> </td>
|
|
<td bgcolor="#edf4f9" >frame number</a> </td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%t </a> </td>
|
|
<td bgcolor="#edf4f9" >camera id number</a> </td>
|
|
<td bgcolor="#edf4f9" >%D </a> </td>
|
|
<td bgcolor="#edf4f9" >changed pixels</a> </td>
|
|
<td bgcolor="#edf4f9" >%N </a> </td>
|
|
<td bgcolor="#edf4f9" >noise level</a> </td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%i </a> </td>
|
|
<td bgcolor="#edf4f9" >width of motion area,</a> </td>
|
|
<td bgcolor="#edf4f9" >%J </a> </td>
|
|
<td bgcolor="#edf4f9" >height of motion area</a> </td>
|
|
<td bgcolor="#edf4f9" >%J </a> </td>
|
|
<td bgcolor="#edf4f9" >height of motion area</a> </td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%K </a> </td>
|
|
<td bgcolor="#edf4f9" >X coordinates of motion center</a> </td>
|
|
<td bgcolor="#edf4f9" >%L </a> </td>
|
|
<td bgcolor="#edf4f9" >Y coordinates of motion center</a> </td>
|
|
<td bgcolor="#edf4f9" >%C </a> </td>
|
|
<td bgcolor="#edf4f9" >value defined by text_event</a> </td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%f</a> </td>
|
|
<td bgcolor="#edf4f9" >filename with full path</a> </td>
|
|
<td bgcolor="#edf4f9" >%n </a> </td>
|
|
<td bgcolor="#edf4f9" >number indicating filetype</a> </td>
|
|
<td bgcolor="#edf4f9" >%$</a> </td>
|
|
<td bgcolor="#edf4f9" >camera name</a> </td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" >%{host}</a> </td>
|
|
<td bgcolor="#edf4f9" >name of computer running Motion</a> </td>
|
|
<td bgcolor="#edf4f9" >%{fps}</a> </td>
|
|
<td bgcolor="#edf4f9" >current frames per second</a> </td>
|
|
<td bgcolor="#edf4f9" >%{dbeventid}</a> </td>
|
|
<td bgcolor="#edf4f9" >See <a href="#sql_query_start">sql_query_start</a> </a> </td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<p></p>
|
|
The use of quotation marks around string is permitted. The conversion specifiers used have
|
|
the same options as for the C function strftime (3) plus the few that are unique to Motion.
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_System_Processing"></a>System Processing</h3>
|
|
<ul>
|
|
|
|
<p></p>
|
|
<h3><a name="daemon"></a> daemon </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
When Motion is started, immediately go to daemon mode and release the terminal.
|
|
<p></p>
|
|
|
|
<h3><a name="process_id_file"></a> process_id_file </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: </li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
Specify the full path and file name in order to store the pid for processing.
|
|
<p></p>
|
|
|
|
<h3><a name="setup_mode"></a> setup_mode </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
When this option is turned on, Motion starts in setup mode so that the
|
|
parameters can be set more easily. In setup mode two things happen:
|
|
With 'motion -s' Motion runs in console mode instead of daemon. It outputs a lot of
|
|
useful information for each frame from the camera. Each message is prefixed by [number]
|
|
where number is the camera id number.
|
|
When you look at the webcam stream you see a black image with numbers.
|
|
What you see is the number of changed pixels, number of labeled areas and noise setting.
|
|
When something moves you see the pixels detected as Motion in black and white. The largest
|
|
labeled area (assuming despeckle is enabled and with the 'l' at the end) is blue. It is
|
|
only the blue areas which is counted as Motion. If smartmask is enabled you see this as red areas.
|
|
|
|
Here is a suggestion how to initially setup Motion.
|
|
<p></p>
|
|
<ul>
|
|
<li> Disable despeckle (comment it out in motion.conf).</li>
|
|
<li> Disable smartmask</li>
|
|
<li> Enable both http control and webcam by setting port numbers. Example 8080 for control and 8081 for webcam.</li>
|
|
<li> Start Motion in setup mode</li>
|
|
<li> View the webcam stream. Either with Iceweasel or with Firefox by entering in the address of
|
|
<a href="http://localhost:8081/" rel="nofollow" target="_top">http://localhost:8080/</a>
|
|
</li>
|
|
<li> Open a new tab and connect to the http interface.
|
|
<a href="http://localhost:8080/" rel="nofollow" target="_top">http://localhost:8080/</a> .
|
|
You can now control and change almost anything while Motion is running. To disable a feature enter a space.</li>
|
|
<li> Start by experimenting with noise level. Do this both during daylight and during darkness.
|
|
You will be surprised to see how much noise a camera makes during night. Try using the automatic
|
|
noise feature. It should work for most.</li>
|
|
<li> Now try the despeckle feature. Enable it using the recommended default EedDl. If this is not enough experiment.
|
|
Remember that the l must be the last letter.</li>
|
|
<li> Set the threshold to what you want to trigger Motion.</li>
|
|
</ul>
|
|
In normal mode you can use the same setting with two browser tabs and experiment with
|
|
settings of the camera if needed.
|
|
From the web interface you can ask Motion to write all your changes back to the config files
|
|
(motion.conf and camera config files).
|
|
<p></p>
|
|
|
|
<h3><a name="logfile"></a> logfile </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
Use this option to specify the full path and filename to use
|
|
for logging of the messages generated from Motion. If this option
|
|
is not defined, the stderr and syslog is used. Note that Motion
|
|
can generate a LOT of messages and as a result, this option should
|
|
be considered if the log_level is at any of the higher levels.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="log_level"></a> log_level </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 9 </li>
|
|
<li> Default: 6</li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies the level of verbosity of the messages sent from Motion.
|
|
At a level of 8(DBG), there are a LOT of messages. At a level of 1(EMR) virtually no
|
|
messages will be output.
|
|
<p></p>
|
|
The various levels are [1..9] (EMR, ALR, CRT, ERR, WRN, NTC, INF, DBG, ALL).
|
|
<p></p>
|
|
When reporting any issues or errors associated with the Motion application,
|
|
use the INF level.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="log_type"></a> log_type </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discreet Strings </li>
|
|
<li> Range / Valid values: See Below</li>
|
|
<li> Default: ALL</li>
|
|
</ul>
|
|
<p></p>
|
|
The different components of Motion use different log types. This option allows the
|
|
user to only show the messages from particular components. The choices for this option
|
|
are: COR, STR, ENC, NET, DBL, EVT, TRK, VID, ALL
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="camera"></a> camera </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name for the camera file.
|
|
Motion allows for this line to be listed in the motion.conf file multiple
|
|
times. These specifications should be the LAST lines in the
|
|
motion.conf file.
|
|
See the <a href="#The_Config_Files">Configuration Files</a> section within
|
|
this guide for a complete discussion of what to put into the
|
|
camera0.conf, camera1.conf, cameraX.conf files that would be specified
|
|
in this option.
|
|
<p></p>
|
|
|
|
<h3><a name="camera_id"></a> camera_id </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: </li>
|
|
<li> Default: The sequence that the camera file is read</li>
|
|
</ul>
|
|
<p></p>
|
|
This option is useful for situations where there are multiple cameras being
|
|
used by Motion. This option allows for the assignment of a numeric id number
|
|
that can be used in database queries as well as format specifiers.
|
|
<p></p>
|
|
|
|
<h3><a name="camera_name"></a> camera_name </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies a camera name to be used in the format
|
|
specifiers as well as on the web interface.
|
|
<p></p>
|
|
|
|
<h3><a name="camera_dir"></a> camera_dir </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies a directory to contain the individual camera configuration files.
|
|
Any files ending in '.conf' in this directory will be read as a camera config file.
|
|
<br />Users can disable a camera (config file) by renaming it so it does not end with '.conf'.
|
|
<p></p>
|
|
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_Video4Linux_Devices"></a>Video4Linux Device</h3>
|
|
<ul>
|
|
<p></p>
|
|
Please refer to the <a href="#Basic_Setup">Basic Setup</a> section of this guide for an additional discussion
|
|
of Video4Linux devices and how to test and specify them correctly for Motion.
|
|
<h3><a name="videodevice"></a> videodevice </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: /dev/video0 </li>
|
|
</ul>
|
|
<p></p>
|
|
The video device to be used for capturing. Default is /dev/video0.
|
|
See the <a href="#Basic_Setup">Basic Setup</a>
|
|
section of this guide for an additional discussion of this option.
|
|
<p></p>
|
|
This option is the preferred way to specify the video4linux device name. If the camera does
|
|
not work when specifying the device with this option, it is also possible to specify the device
|
|
in the <a href="#netcam_url" >netcam_url</a> with the v4l2 prefix option. The
|
|
<a href="#netcam_url" >netcam_url</a> option uses an alternative method to open and operate the
|
|
device but has fewer options available. If the <a href="#netcam_url" >netcam_url</a> is used for
|
|
either this alternative method or for a normal network camera, the videodevice option is ignored.
|
|
<p></p>
|
|
|
|
<h3><a name="v4l2_palette"></a> v4l2_palette </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: 0 - 21</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The v4l2_palette allows the user to choose a palette to be use by Motion. This
|
|
is only the <u>preferred</u> option. If the video device does not support this preferred format,
|
|
Motion will loop through the available palettes to try to find one that is supported by both Motion
|
|
and the device.
|
|
Motion will report the supported palettes of the device when Motion starts when the log_level
|
|
is specified as NTC or higher.
|
|
<p></p>
|
|
The default of 17 is highly preferred over <u>all</u> other formats since this the native
|
|
format that Motion uses internally.
|
|
<p></p>
|
|
The following are each of the palette options. For the Motion configuration,
|
|
specify the numeric value as the Motion option.
|
|
<p></p>
|
|
<table border="1" class="fixed" >
|
|
<colgroup>
|
|
<col width="250px">
|
|
<col width="200px">
|
|
<col width="200px">
|
|
</colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="center" > V4l2 Option</td>
|
|
<td bgcolor="#edf4f9" align="center" > FOURCC</td>
|
|
<td bgcolor="#edf4f9" align="center" > v4l2_palette option </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" >V4L2_PIX_FMT_SN9C10X</td>
|
|
<td bgcolor="#edf4f9" align="center" >S910</td>
|
|
<td bgcolor="#edf4f9" align="center" >0</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" >V4L2_PIX_FMT_SBGGR16</td>
|
|
<td bgcolor="#edf4f9" align="center" >BYR2</td>
|
|
<td bgcolor="#edf4f9" align="center" >1</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" >V4L2_PIX_FMT_SBGGR8</td>
|
|
<td bgcolor="#edf4f9" align="center" >BA81</td>
|
|
<td bgcolor="#edf4f9" align="center" >2</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" >V4L2_PIX_FMT_SPCA561</td>
|
|
<td bgcolor="#edf4f9" align="center" >S561</td>
|
|
<td bgcolor="#edf4f9" align="center" >3</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" >V4L2_PIX_FMT_SGBRG8</td>
|
|
<td bgcolor="#edf4f9" align="center" >GBRG</td>
|
|
<td bgcolor="#edf4f9" align="center" >4</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" >V4L2_PIX_FMT_SGRBG8</td>
|
|
<td bgcolor="#edf4f9" align="center" >GRBG</td>
|
|
<td bgcolor="#edf4f9" align="center" >5</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" >V4L2_PIX_FMT_PAC207</td>
|
|
<td bgcolor="#edf4f9" align="center" >P207</td>
|
|
<td bgcolor="#edf4f9" align="center" >6</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_PJPG</td>
|
|
<td bgcolor="#edf4f9" align="center" >PJPG</li>
|
|
<td bgcolor="#edf4f9" align="center" >7</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_MJPEG</td>
|
|
<td bgcolor="#edf4f9" align="center" >MJPG</li>
|
|
<td bgcolor="#edf4f9" align="center" >8</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_JPEG</td>
|
|
<td bgcolor="#edf4f9" align="center" >JPEG</li>
|
|
<td bgcolor="#edf4f9" align="center" >9</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_RGB24</td>
|
|
<td bgcolor="#edf4f9" align="center" >RGB3</li>
|
|
<td bgcolor="#edf4f9" align="center" >10</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_SPCA501</td>
|
|
<td bgcolor="#edf4f9" align="center" >S501</li>
|
|
<td bgcolor="#edf4f9" align="center" >11</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_SPCA505</td>
|
|
<td bgcolor="#edf4f9" align="center" >S505</li>
|
|
<td bgcolor="#edf4f9" align="center" >12</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_SPCA508</td>
|
|
<td bgcolor="#edf4f9" align="center" >S508</li>
|
|
<td bgcolor="#edf4f9" align="center" >13</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_UYVY</td>
|
|
<td bgcolor="#edf4f9" align="center" >UYVY</li>
|
|
<td bgcolor="#edf4f9" align="center" >14</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_YUYV</td>
|
|
<td bgcolor="#edf4f9" align="center" >YUYV</li>
|
|
<td bgcolor="#edf4f9" align="center" >15</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_YUV422P</td>
|
|
<td bgcolor="#edf4f9" align="center" >422P</li>
|
|
<td bgcolor="#edf4f9" align="center" >16</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_YUV420</td>
|
|
<td bgcolor="#edf4f9" align="center" >YU12</li>
|
|
<td bgcolor="#edf4f9" align="center" >17</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_Y10</td>
|
|
<td bgcolor="#edf4f9" align="center" >Y10</li>
|
|
<td bgcolor="#edf4f9" align="center" >18</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_Y12</td>
|
|
<td bgcolor="#edf4f9" align="center" >Y12</li>
|
|
<td bgcolor="#edf4f9" align="center" >19</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_GREY</td>
|
|
<td bgcolor="#edf4f9" align="center" >GREY</li>
|
|
<td bgcolor="#edf4f9" align="center" >20</td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#edf4f9" align="left" > V4L2_PIX_FMT_H264</td>
|
|
<td bgcolor="#edf4f9" align="center" >H264</li>
|
|
<td bgcolor="#edf4f9" align="center" >21</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<p></p>
|
|
It is possible that after looping through all of the palette options for the camera, Motion will not
|
|
find a palette that is acceptable for processing. In this situation, it is possible to use the
|
|
<a href="#netcam_url" >netcam_url</a> option with the v4l2 prefix. When using the
|
|
<a href="#netcam_url" >netcam_url</a> option, the v4l2_palette option can be used to specify the
|
|
V4L2_PIX_FMT_MJPEG and V4L2_PIX_FMT_H264 options ONLY. If any of the other palette options
|
|
are specified when using the <a href="#netcam_url" >netcam_url</a> the v4l2_palette option
|
|
is ignored and the camera default is used.
|
|
|
|
<p></p>
|
|
The V4L2_PIX_FMT_H264(21) option is valid ONLY when using the <a href="#netcam_url" >netcam_url</a> option.
|
|
When V4L2_PIX_FMT_H264(21) is specified using the videodevice, Motion will change the v4l2_palette option to the
|
|
default of V4L2_PIX_FMT_YUV420 (17)
|
|
<p></p>
|
|
|
|
<h3><a name="tunerdevice"></a> tunerdevice </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: /dev/tuner0 </li>
|
|
</ul>
|
|
<p></p>
|
|
The tuner device used for controlling the tuner in a tuner card. This option is only used when Motion is compiled
|
|
for FreeBSD with the bktr option.
|
|
See the <a href="#Basic_Setup">Basic Setup</a> section of this guide for a additional discussion of this option.
|
|
<p></p>
|
|
|
|
<h3><a name="input"></a> input </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: -1, 0 - 7</li>
|
|
<li> Default: 1 (Disabled) </li>
|
|
</ul>
|
|
<p></p>
|
|
Input channel to use expressed as an integer number starting from 0.
|
|
This option should normally be set to 1 for video/TV cards, and -1 for USB cameras.
|
|
This parameter is used only with video capture cards that have more than one input.
|
|
If you set the input number to values other than -1 USB cameras Motion will report
|
|
an error message back. For video capture cards with tuners or multiple inputs such as
|
|
S-VHS or Composite you may need to use this option to specify the correct input for
|
|
the camera. Using a external application such as VLC which allows for easier specification
|
|
of the input associated with the camera can assist in determining the correct value for Motion.
|
|
<p></p>
|
|
|
|
<h3><a name="norm"></a> norm </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: 0 (PAL), 1 (NTSC), 2 (SECAM), 3 (PAL NC no colour)</li>
|
|
<li> Default: 0 (PAL) </li>
|
|
</ul>
|
|
<p></p>
|
|
Select the video norm of the device. Values: 0 (PAL), 1 (NTSC), 2 (SECAM), 3 (PAL NC no colour). Default: 0 (PAL)
|
|
This value is only used for capture cards using the BTTV driver.
|
|
<p></p>
|
|
|
|
<h3><a name="frequency"></a> frequency </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 999999</li>
|
|
<li> Default: 0 (Not set)</li>
|
|
</ul>
|
|
<p></p>
|
|
The frequency to set the tuner to (kHz) per the tuner specifications. The default is 0 meaning
|
|
not set. This option is only relevant if you have a TV tuner card where you can select the tuner frequency.
|
|
Your tuner card must support this feature.
|
|
<p></p>
|
|
|
|
<h3><a name="power_line_frequency"></a> power_line_frequency </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: -1 to 3 </li>
|
|
<li> Default: -1 </li>
|
|
</ul>
|
|
<p></p>
|
|
This option allows the user to specify the power line frequency that is applicable to the user. This option
|
|
can help stabilize the images of some webcams that are sensitive to this frequency. This is not normally necessary.
|
|
<ul>
|
|
<li> -1 : Do not modify device setting</li>
|
|
<li> 0 : Power line frequency Disabled</li>
|
|
<li> 1 : 50hz</li>
|
|
<li> 2 : 60hz</li>
|
|
<li> 3 : Auto</li>
|
|
</ul>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="auto_brightness"></a> auto_brightness </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off </li>
|
|
</ul>
|
|
<p></p>
|
|
Let motion regulate the brightness of a video device. Only recommended for cameras without auto brightness
|
|
Motion will try to adjust the brightness of the video device if the images captured are too dark or too light.
|
|
This option will be most useful for video devices which sometimes don't have such an option in
|
|
hardware. The auto_brightness feature will adjust the brightness of the device up or down until the value defined
|
|
by the option brightness is reached (1 = dark, 255 = bright). If brightness is zero auto_brightness will try to
|
|
adjust to the average brightness level 128. You need to know if the camera supports auto brightness. Most cameras
|
|
have auto everything. If your video device already does this for you this option might cause oscillations. If you
|
|
do not know assume that it has and do not use the Motion auto brightness feature. At least not to start with.
|
|
<p></p>
|
|
|
|
<h3><a name="brightness"></a> brightness </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 255</li>
|
|
<li> Default: 0 (disabled) </li>
|
|
</ul>
|
|
<p></p>
|
|
The brightness level for the video device. Value 0 means that Motion does not set the brightness value but
|
|
leaves it unchanged. If this setting is used in conjunction with the auto_brightness feature then this setting
|
|
is the average brightness level in the range 1 (dark) to 255 (bright) that the auto_brightness feature will try
|
|
to achieve by adjusting the device brightness up and down.
|
|
<p></p>
|
|
|
|
<h3><a name="contrast"></a> contrast </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 255</li>
|
|
<li> Default: 0 (disabled) </li>
|
|
</ul>
|
|
<p></p>
|
|
The contrast level for the video device. Disabled (Value 0) means that Motion does not set the contrast value.
|
|
<p></p>
|
|
|
|
<h3><a name="saturation"></a> saturation </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 255</li>
|
|
<li> Default: 0 (disabled) </li>
|
|
</ul>
|
|
<p></p>
|
|
The color saturation level for the video device.
|
|
<p></p>
|
|
|
|
<h3><a name="hue"></a> hue </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 255</li>
|
|
<li> Default: 0 (disabled) </li>
|
|
</ul>
|
|
<p></p>
|
|
The hue level for the video device.
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="roundrobin_frames"></a> roundrobin_frames </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 2147483647</li>
|
|
<li> Default: 1</li>
|
|
</ul>
|
|
<p></p>
|
|
Specifies the number of frames to capture before switching inputs, this way also slow switching (e.g. every second)
|
|
is possible. The Round Robin feature is automatically activated where multiple cameras are sharing the same video
|
|
device. Each camera can then set different <code>input</code> or <code>frequency</code> options to change camera.
|
|
If multiple cameras use the same video device, they each can capture roundrobin_frames number of frames before having
|
|
to share the device with the other cameras.
|
|
<p></p>
|
|
Round Robin is not relevant for Network cameras or standard USB web cameras. It is used with video capture
|
|
cards which have multiple inputs per video chip. This is not the ideal way to run multiple cameras.
|
|
When the capture card changes input it takes some time before the decoder chip has synchronized to the new camera.
|
|
You can improve this if you have expensive cameras with a synchronized input. Only one camera can be decoded
|
|
at a time so if you have 4 cameras connected 3 of the cameras will need to wait for their
|
|
turn. The fact that cameras have to take turns and the fact that you have to skip a few frames after
|
|
each turn dramatically lowers the possible framerate. You can get a high framerate by viewing each
|
|
camera for a long time. But then you may miss the action on one of the inactive cameras. If you can
|
|
afford it avoid Round Robin and buy the more expensive type of capture cards that has one decoder chip
|
|
per input. If you only need 2 or 3 cameras you can also simply put 2 or 3 cheap TV cards in the computer.
|
|
Linux has no problem working with multiple TV cards. (or better yet, it multiple cheap network cameras)
|
|
If multiple cameras use the same video device, they each can capture
|
|
<code><a href="#roundrobin_frames">roundrobin_frames</a></code> number of frames
|
|
before having to share the device with the other cameras.
|
|
When another camera wants to watch another input or frequency or size the first
|
|
<code><a href="#roundrobin_skip">roundrobin_skip</a> </code> number of frames are skipped to allow the
|
|
device to settle. The last option <code><a href="#switchfilter">switchfilter</a></code> is supposed
|
|
to prevent the change of camera from being detected
|
|
as Motion. Its function is not perfect and sometimes prevents detection of real motion. You should start
|
|
with having the option disabled and then try with the option enabled to see if you can skip less frames
|
|
without loosing the detection of the type of motion you normally want to detect.
|
|
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="roundrobin_skip"></a> roundrobin_skip </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 2147483647</li>
|
|
<li> Default: 1</li>
|
|
</ul>
|
|
<p></p>
|
|
Specifies the number of frames to skip after a switch. (1 if you are feeling lucky, 2 if you want to be safe).
|
|
The Round Robin feature is automatically activated where multiple cameras are sharing the same video device.
|
|
Each camera can then set different input channels or frequencies to change camera.
|
|
When another camera wants to watch another input or frequency or size the first roundrobin_
|
|
skip number of frames are skipped to allow the device to settle.
|
|
<p></p>
|
|
|
|
<h3><a name="switchfilter"></a> switchfilter </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Turns the switch filter on or off. The filter can distinguish between most switching noise and real motion. With this
|
|
you can even set roundrobin_skip to 1 without generating much false detection.
|
|
This is a round robin related feature used when you have a capture card with multiple inputs (controlled by the
|
|
'input' option) on the same videodevice.
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_Network_Cameras"></a>Network Cameras</h3>
|
|
<ul>
|
|
<p></p>
|
|
Motion can connect to certain network cameras. Please refer to the <a href="#Basic_Setup">Basic Setup</a> section
|
|
of this guide for an additional discussion of network camera and how to test and specify them correctly for Motion.
|
|
<p></p>
|
|
Motion cannot connect to a video stream such a mpeg, mpeg4, divx to connect to streams such as these
|
|
the user may review the static files portion of the <a href="#Basic_Setup">Basic Setup</a>
|
|
section of this guide which illustrates some possible work arounds using ffmpeg and v4l2loopback devices.
|
|
<p></p>
|
|
The URL must return one single jpeg image, a mjpeg stream
|
|
a RTSP stream, RTMP stream, file or ftp. When getting a still image, make sure to validate that
|
|
the camera is serving up a actual raw JPG file and not a HTML page with an embedded JPG which Motion
|
|
will not be able to process.
|
|
When the <a href="#netcam_url" >netcam_url</a> is defined the
|
|
<a href="#Options_Video4Linux_Devices" >video4linux</a> options above are mostly ignored.
|
|
<p></p>
|
|
If the connection to a network camera is lost, Motion will reuse the last good image for
|
|
approx 30 seconds. After 30 seconds the image is replaced by a grey image with a text
|
|
telling that the signal is lost and when the connection was lost.
|
|
<em>This text and its date format is not configurable.</em>
|
|
|
|
|
|
<h3><a name="netcam_url"></a> netcam_url </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
|
|
<p></p>
|
|
URL to use if you are using a network camera, size will be autodetected.
|
|
Available prefixes to the URL:
|
|
<p></p>
|
|
<ul>
|
|
<i>http://</i>
|
|
<ul>
|
|
This prefix uses the traditional http format and opens the netcam looking for a motion jpg image.
|
|
</ul>
|
|
<p></p>
|
|
|
|
<i>ftp://</i>
|
|
<ul>
|
|
This prefix opens the ftp site and grabs a static image. The camera will be expected to periodically
|
|
replace that static image as it processes images.
|
|
</ul>
|
|
<p></p>
|
|
|
|
<i>mjpg://</i>
|
|
<ul>
|
|
This prefix is experimental and when Motion sees this prefix it will replace the mjpg with http and
|
|
then process the network camera using the extremely experimental method of grabbing motion jpg images.
|
|
<p></p>
|
|
The functionality of this option is unknown and may be removed in future releases.
|
|
</ul>
|
|
<p></p>
|
|
|
|
<i>rtsp://</i>
|
|
<ul>
|
|
This prefix is the standard for all modern network cameras. It is recommended that users search the
|
|
web or the camera manual for the exact connection string to use for their camera.
|
|
<p></p>
|
|
Once a potential connection string is found, it should be validated as being functional using a
|
|
external application such as ffplay or vlc.
|
|
<p></p>
|
|
The connection string that works for these applications is what needs to be specified for this option.
|
|
<p></p>
|
|
When using the rtsp format, Motion will ignore the netcam_keepalive and netcam_tolerant_check options.
|
|
</ul>
|
|
<p></p>
|
|
|
|
<i>rtmp://</i>
|
|
<ul>
|
|
This prefix may be available on modern network cameras. It is recommended that users search the
|
|
web or the camera manual for the exact connection string to use for their camera.
|
|
<p></p>
|
|
Once a potential connection string is found, it should be validated as being functional using a
|
|
external application such as ffplay or vlc.
|
|
<p></p>
|
|
The connection string that works for these applications is what needs to be specified for this option.
|
|
<p></p>
|
|
When using the rtmp format, Motion will ignore the netcam_keepalive and netcam_tolerant_check options.
|
|
</ul>
|
|
<p></p>
|
|
|
|
<i>mjpeg://</i>
|
|
<ul>
|
|
This is an alternative prefix for http. The mjpeg is replaced with http by Motion internally and forces the
|
|
use of the ffmpeg libraries and the mjpeg format.
|
|
<p></p>
|
|
This option is equivalent to using <code>ffplay -f mjpeg http://{yourip}</code>.
|
|
<p></p>
|
|
In certain situations, this option may result in better results than using the http protocol.
|
|
<p></p>
|
|
Motion will ignore the netcam_keepalive and netcam_tolerant_check options when this format is specified.
|
|
</ul>
|
|
<p></p>
|
|
|
|
<i>file://</i>
|
|
<ul>
|
|
This option allows for the processing of a static image. A process outside of Motion is required to
|
|
replace the image.
|
|
<p></p>
|
|
A scenario for this would be processing a large number of previously saved images. The file
|
|
option would point to a single location such as <code>/home/user/test/currentimage.jpg</code> and a script
|
|
running external to Motion would loop through all the images and copy them into <code>currentimage.jpg</code>.
|
|
</ul>
|
|
<p></p>
|
|
|
|
<i>v4l2://</i>
|
|
<ul>
|
|
This option allows for an alternative method of using a v4l2 device that is not natively supported by Motion.
|
|
<p></p>
|
|
A sample format for the netcam_url would be <code>v4l2:///dev/video0</code> Internally, this
|
|
is equivalent to running the following from the command line <code>ffplay -f v4l2 /dev/video0</code>
|
|
<p></p>
|
|
Since this is not the preferred method of specifying a v4l2 device, many of the usual v4l2 controls such as
|
|
hue, brightness, etc as well as other netcam options are ignored.
|
|
The options <a href="#width">width</a>, <a href="#height">height</a> as well as two of
|
|
the <a href="#v4l2_palette">v4l2_palette</a> can be used. The two options
|
|
for <a href="#v4l2_palette">v4l2_palette</a> which can be used are option 8 (V4L2_PIX_FMT_MJPEG) and
|
|
option 21 (V4L2_PIX_FMT_H264). If any other option is selected for the <a href="#v4l2_palette">v4l2_palette</a>
|
|
Motion will revert to the camera default.
|
|
</ul>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="netcam_highres"></a> netcam_highres </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The network camera high resolution URL. This option can be used in conjunction with the netcam_url for rtsp/rtmp cameras.
|
|
Users may specify the normal resolution url in the netcam_url which will be used for the motion detection and then
|
|
specify the high resolution url for this parameter. Motion detection on the normal resolution will trigger the saving
|
|
of images from the high resolution stream. Note that the ONLY overlay that will be present on the resulting high
|
|
resolution pictures and movies is the privacy mask. The other overlays such as date/time, motion boxes, camera
|
|
name, etc will not be included. Users wishing to see those overlays on the resulting images and movies will need to
|
|
specify the high resolution url as the netcam_url and not use this option.
|
|
<p></p>
|
|
If the netcam_url is not specified, this option is ignored.
|
|
<p></p>
|
|
|
|
<h3><a name="netcam_userpass"></a> netcam_userpass </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The Username and password for the network camera. For http protocols, this
|
|
option is for HTTP 1.1 Basic authentication only. The string is specified as username:password.
|
|
To use no authentication simply remove this option. Digest authentication is only available for rtsp/rtmp cameras.
|
|
<p></p>
|
|
|
|
<h3><a name="netcam_keepalive"></a> netcam_keepalive </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The setting for keep-alive of network socket, should improve performance on compatible net cameras.
|
|
<ul>
|
|
<li> off: The historical implementation using HTTP/1.0, closing the socket after each http request.</li>
|
|
<li> force: Use HTTP/1.0 requests with keep alive header to reuse the same connection.</li>
|
|
<li> on: Use HTTP/1.1 requests that support keep alive as default.</li>
|
|
</ul>
|
|
<p></p>
|
|
Motion will ignore this option for rtsp/rtmp cameras.
|
|
<p></p>
|
|
|
|
<h3><a name="netcam_proxy"></a> netcam_proxy </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
URL to use for a netcam proxy server, if required. The syntax is
|
|
<a href="http://myproxy:portnumber" rel="nofollow" target="_top">http://myproxy:portnumber</a>
|
|
Use this if you need to connect to a network camera through a proxy server.
|
|
Example of syntax: "http://myproxy.mydomain.com:1024
|
|
If the proxy port number is 80 you can omit the port number. Then the syntax is use "http://myproxy.mydomain.com" .
|
|
Leave this option undefined if you do not use a proxy server.
|
|
<p></p>
|
|
Motion will ignore this option for rtsp/rtmp cameras.
|
|
<p></p>
|
|
|
|
<h3><a name="netcam_tolerant_check"></a> netcam_tolerant_check </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
Use less strict jpeg checks for network cameras
|
|
<p></p>
|
|
Motion will ignore this option for rtsp/rtmp cameras.
|
|
<p></p>
|
|
|
|
<h3><a name="rtsp_uses_tcp"></a> rtsp_uses_tcp </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: on off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies the transport method for rtsp/rtmp cameras. The TCP transport is highly preferred because
|
|
without this option the rtsp/rtmp images are frequently corrupted and result in many false positive values and
|
|
images that appear to be smeared. Off indicates that UDP will be used.
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_Raspi_Cameras"></a>Raspberry Pi Camera</h3>
|
|
<ul>
|
|
<p></p>
|
|
Motion can use the Raspberry Pi camera when connected and Motion is compiled and installed with the
|
|
MMAL support. Before setting up Motion with the camera, it is recommended that the user first
|
|
validate that the camera is functional with the raspistill/raspivid applications.
|
|
<p></p>
|
|
Please refer to the <a href="#Basic_Setup">Basic Setup</a> section
|
|
of this guide for an additional discussion of network camera and how to test and specify them correctly for Motion.
|
|
<p></p>
|
|
<h3><a name="mmalcam_name"></a> mmalcam_name </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
Name of camera to use if you are using a camera accessed through OpenMax/MMAL. The standard
|
|
Raspberry Pi camera device name is "vc.ril.camera" without the quotes.
|
|
<p></p>
|
|
Motion will ignore this option when the MMAL support is not included. In these situations,
|
|
users will need to use the modprobe method of setting up the camera as a v4l2 device. See
|
|
the <a href="#Basic_Setup">Basic Setup</a> section of this guide for further details.
|
|
<p></p>
|
|
|
|
<h3><a name="mmalcam_control_params"></a> mmalcam_control_params</h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
This option allows the user to specify control parameters to the Pi camera. The documentation of
|
|
all of the options available to the Raspberry Camera module is beyond the scope of this guide. In
|
|
general, the command line options that are available via the raspistill / raspivid applications are
|
|
the options that can be specified in this Motion configuration option.
|
|
|
|
Some of the more frequently used options are:
|
|
<ul>
|
|
<li>Horizontal Flip: -hf</li>
|
|
<li>Vertical Flip: -vf</li>
|
|
<li>Rotation: -rot</li>
|
|
</ul>
|
|
<p></p>
|
|
<p></p>
|
|
Motion will ignore this option when the MMAL support is not included. In these situations,
|
|
users will need to use the modprobe method of setting up the camera as a v4l2 device. See
|
|
the <a href="#Basic_Setup">Basic Setup</a> section of this guide for further details.
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_Image_Processing"></a> Image Processing</h3>
|
|
<ul>
|
|
<p></p>
|
|
<h3><a name="rotate"></a> rotate </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: 0, 90, 180, 270</li>
|
|
<li> Default: 0 (not rotated)</li>
|
|
</ul>
|
|
<p></p>
|
|
Rotate image the given number of degrees. The rotation affects all saved images as well as movies.
|
|
The rotation feature is used when the camera is hanging upside down (180 degrees) or if you choose a picture
|
|
format in portrait instead of the normal landscape (90 or 270 degrees).
|
|
Note that the CPU load increases when using this feature with a value other than 0. Also note that
|
|
Motion automatically swaps width and height if you rotate 90 or 270 degrees, so you don't have to touch these options.
|
|
<p></p>
|
|
|
|
<h3><a name="flip_axis"></a> flip_axis </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: none, v, h</li>
|
|
<li> Default: none (no change)</li>
|
|
</ul>
|
|
<p></p>
|
|
Flip the image according to specified axis. The flip affects all saved images as well as movies.
|
|
The flip feature is used when the camera is pointed towards a mirror or provides itself a mirrored image (as found in some cars).
|
|
Note that the CPU load increases when using this feature with a value other than none.
|
|
<p></p>
|
|
|
|
<h3><a name="width"></a> width </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: Device Dependent</li>
|
|
<li> Default: 352</li>
|
|
</ul>
|
|
<p></p>
|
|
The width in pixels of each frame. Valid range is camera dependent.
|
|
<p></p>
|
|
For all devices, the width must be a multiple of 8.
|
|
<p></p>
|
|
Motion does not scale v4l2 devices and http netcams so the value should be set to the actual
|
|
size of the image provided by the device.
|
|
In case of a rtsp/rtmp network camera, Motion will rescale the camera image to the
|
|
requested dimensions. This rescaling comes at a very high CPU cost so it
|
|
is recommended that the network camera send the image in the same dimensions as included
|
|
in the configuration file.
|
|
<p></p>
|
|
While Motion will not rescale the image provided, it will attempt to set the size of the image
|
|
coming from the video4linux device to match the values provided for height/width.
|
|
<p></p>
|
|
It is important to realize that certain height/width combinations are only valid at
|
|
certain frame rates. The particular combinations which are valid are dependent upon
|
|
the device.
|
|
<p></p>
|
|
For some device drivers like pwc (driver for Philips USB cameras) setting the
|
|
size to a non-standard value makes the driver create an image of the nearest
|
|
smaller size and create a gray band around the image to fit the size given by
|
|
motion. Note that it is the driver and not motion that generates the gray band.
|
|
Motion will try to detect motion in the entire image including the gray band.
|
|
<p></p>
|
|
|
|
<h3><a name="height"></a> height </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: Device Dependent</li>
|
|
<li> Default: 288</li>
|
|
</ul>
|
|
<p></p>
|
|
The height in pixels of each frame. Valid range is camera dependent.
|
|
<p></p>
|
|
For all devices, the height must be a multiple of 8.
|
|
<p></p>
|
|
Motion does not scale v4l2 devices and http netcams so the value should be set to the actual
|
|
size of the image provided by the device.
|
|
In case of a rtsp/rtmp network camera, Motion will rescale the camera image to the
|
|
requested dimensions. This rescaling comes at a very high CPU cost so it
|
|
is recommended that the network camera send the image in the same dimensions as included
|
|
in the configuration file.
|
|
<p></p>
|
|
While Motion will not rescale the image provided, it will attempt to set the size of the image
|
|
coming from the video4linux device to match the values provided for height/width.
|
|
<p></p>
|
|
It is important to realize that certain height/width combinations are only valid at
|
|
certain frame rates. The particular combinations which are valid are dependent upon
|
|
the device.
|
|
<p></p>
|
|
For some device drivers like pwc (driver for Philips USB cameras) setting the size to a non-standard value
|
|
makes the driver create an image of the nearest smaller size and create a gray band around the image to fit
|
|
the size given by motion. Note that it is the driver and not motion that generates the gray band. Motion will
|
|
try to detect motion in the entire image including the gray band.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="framerate"></a> framerate </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 2 - 100</li>
|
|
<li> Default: 100 (no limit)</li>
|
|
</ul>
|
|
<p></p>
|
|
Maximum number of frames to be captured from the camera per second.
|
|
The faster you fetch pictures from the camera the more CPU load you
|
|
get and the more pictures get included when Motion is detected.
|
|
Motion will stop storing pictures if the framerate is set to less than 2.
|
|
Set this parameter to the maximum number of images per second that you want
|
|
to store either as images or movies.
|
|
To set intervals longer than one second use the 'minimum_gap' option instead.
|
|
<p></p>
|
|
|
|
<h3><a name="minimum_frame_time"></a> minimum_frame_time </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Minimum time in seconds between the capturing picture frames from the camera. Default: 0 = disabled - the capture
|
|
rate is given by the camera framerate.
|
|
This option is used when you want to capture images at a rate lower than 2 per second.
|
|
When this is enabled the framerate option is used only to set the pace the Motion service the
|
|
webcam port etc.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="despeckle_filter"></a> despeckle_filter </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: EedDl</li>
|
|
<li> Default: Not defined </li>
|
|
</ul>
|
|
<p></p>
|
|
Despeckle motion image using combinations of (E/e)rode or (D/d)ilate. And ending with optional (l)abeling.
|
|
A way of tuning (by removing or enhancing) noise in the motion image. Options for the despeckle feature are
|
|
any of 'e', 'E', 'd' or 'D'. This can be combined by a trailing 'l' (letter l) which enables the labeling
|
|
feature.
|
|
<p></p>
|
|
Wind blowing grass and trees around or poor light conditions can cause a lot of dots (or noise) to appear in the
|
|
motion image (See the section on Tuning Motion). This feature removes (or enhances!) this noise and so improves
|
|
the reliability of motion.
|
|
<p></p>
|
|
The 'e' option removes diamonds, 'E' removes squares and alternating eE will remove circles. Each e/E you add will
|
|
shrink the noise by a pixel all the way around. So 'despeckle Ee' will remove circles of radius 2. However, this
|
|
will also shrink the detection by 2 and will affect the threshold. So to remove noise and then restore the detected
|
|
motion to its original size try 'despeckle EedD'.
|
|
After the despeckle feature is done you can let the labeling feature search for areas of connected pixels and "label"
|
|
each area. The program will now trigger motion based on the number of changed pixels in the largest area. In other words,
|
|
the largest labeled area has to be above the threshold to trigger a motion detected.
|
|
The value EedDl is a good starting point. The possible combinations are endless and it requires many experiments to
|
|
find the best combination. Just remember that the labeling feature only works as intended if it runs after the
|
|
despeckle feature. Ie. the letter 'l' must be the last letter and only one 'l'.
|
|
If you have very few problems with false detections leave this option either blank or at EedD which will remove
|
|
most of the single pixel noise.
|
|
<p></p>
|
|
A very detailed technical explanation of the despeckle part can be found at the webpage of the author of this
|
|
feature <a href="http://emit.demon.co.uk/motion/" rel="nofollow" target="_top">Ian McConnell's Webcam: Motion
|
|
Web Page</a>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="locate_motion_mode"></a> locate_motion_mode </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off, preview</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Locate and draw a box around the moving object. Value 'preview' makes Motion only draw a box on a
|
|
saved preview jpeg image and not on the saved movie.
|
|
<p></p>
|
|
|
|
<h3><a name="locate_motion_style"></a> locate_motion_style </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: box, redbox, cross, redcross</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
Set the look and style of the locate box if enabled.
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="text_left"></a> text_left </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
User defined text overlaid on each in the lower left corner.
|
|
Use A-Z, a-z, 0-9, " / ( ) @ ~ # < > \ , . : - + _ \n and conversion specifiers
|
|
<p></p>
|
|
If the option is not defined no text is displayed at this position.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> to define this field and also include
|
|
a new line specifier as \n and spaces if this option is enclosed in quotes.
|
|
<p></p>
|
|
<p></p>
|
|
By combining spaces and new lines '\n' you can place
|
|
your text anywhere on the picture. When setting the text using http remote control the text
|
|
must be URL encoded. The browser does this for you. If you need
|
|
to set it with a command line tool, use a browser first and let it make the encoded URL for you. Then
|
|
you can copy paste it to your script file or cron line or whatever you want to use.
|
|
<p></p>
|
|
This is how the overlaid text is located.
|
|
<p></p>
|
|
<table border="1" width="354">
|
|
<tr>
|
|
<td width="344">
|
|
<table cellpadding="0" cellspacing="0" width="344">
|
|
<tr>
|
|
<td width="216">
|
|
<p> <br /><br /><br /><br /><br /><br /> </p>
|
|
</td>
|
|
<td width="128">
|
|
<p align="right"> CHANGES<br /><br /><br /><br /><br /><br /> </p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td width="216">
|
|
<p><br /><br />TEXT_LEFT</p>
|
|
</td>
|
|
<td width="128">
|
|
<p align="right">TEXT_RIGHT<br />YYYY-MM-DD<br />HH:MM:SS </p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="text_right"></a> text_right </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: %Y-%m-%d\n%T</li>
|
|
</ul>
|
|
<p></p>
|
|
User defined text overlaid on each in the lower right corner.
|
|
Use A-Z, a-z, 0-9, " / ( ) @ ~ # < > \ , . : - + _ \n and conversion specifiers
|
|
<p></p>
|
|
If the option is not defined no text is displayed at this position.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> to define this field and also include
|
|
a new line specifier as \n and spaces if this option is enclosed in quotes.
|
|
<p></p>
|
|
<p></p>
|
|
By combining spaces and new lines '\n' you can place
|
|
your text anywhere on the picture. When setting the text using http remote control the text
|
|
must be URL encoded. The browser does this for you. If you need
|
|
to set it with a command line tool, use a browser first and let it make the encoded URL for you. Then
|
|
you can copy paste it to your script file or cron line or whatever you want to use.
|
|
<p></p>
|
|
A major difference from text_left is that if this option is undefined the
|
|
default is %Y-%m-%d\n%T which displays the date in ISO format YYYY-MM-DD and below the
|
|
time in 24 hour clock HH:MM:SS.
|
|
<p></p>
|
|
This is how the overlaid text is located.
|
|
<p></p>
|
|
<table border="1" width="354">
|
|
<tr>
|
|
<td width="344">
|
|
<table cellpadding="0" cellspacing="0" width="344">
|
|
<tr>
|
|
<td width="216">
|
|
<p> <br /><br /><br /><br /><br /><br /> </p>
|
|
</td>
|
|
<td width="128">
|
|
<p align="right"> CHANGES<br /><br /><br /><br /><br /><br /> </p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td width="216">
|
|
<p><br /><br />TEXT_LEFT</p>
|
|
</td>
|
|
<td width="128">
|
|
<p align="right">TEXT_RIGHT<br />YYYY-MM-DD<br />HH:MM:SS </p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="text_changes"></a> text_changes </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Turns the text showing changed pixels on/off.
|
|
By setting this option to 'on' the number of pixels that changed compared to the
|
|
reference frame is displayed in the upper right corner of the pictures. This is good for calibration and testing.
|
|
This is how the overlaid text is located.
|
|
<p></p>
|
|
<table border="1" width="354">
|
|
<tr>
|
|
<td width="344">
|
|
<table cellpadding="0" cellspacing="0" width="344">
|
|
<tr>
|
|
<td width="216">
|
|
<p> <br /><br /><br /><br /><br /><br /> </p>
|
|
</td>
|
|
<td width="128">
|
|
<p align="right"> CHANGES<br /><br /><br /><br /><br /><br /> </p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td width="216">
|
|
<p><br /><br />TEXT_LEFT</p>
|
|
</td>
|
|
<td width="128">
|
|
<p align="right">TEXT_RIGHT<br />YYYY-MM-DD<br />HH:MM:SS </p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<p></p>
|
|
|
|
<h3><a name="text_event"></a> text_event </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Default: %Y%m%d%H%M%S</li>
|
|
</ul>
|
|
<p></p>
|
|
This option is special in that it defines the conversion specifier %C which can be used both for text
|
|
display and for filenames. This option defines the value of the special event conversion specifier %C.
|
|
You can use any conversion specifier in this option except %C. Date and time values are from the timestamp
|
|
of the first image in the current event. The idea is that %C can be used filenames and text_left/right for
|
|
creating a unique identifier for each event. Option text_event defines the value %C which then can be used in
|
|
filenames and text_right/text_left. The text_event/%C uses the time stamp for the first image detected in a new
|
|
event. %C is an empty string when no event is in progress (gap period expired). Pre_captured and
|
|
minimum_motion_frames images are time stamped before the event happens so %C in text_left/right does not
|
|
have any effect on those images.
|
|
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> to define this field (except for
|
|
this option itself)
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="text_double"></a> text_double </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Draw characters at twice normal size on images.
|
|
This option makes the text defined by text_left, text_right and text_changes twice the normal size.
|
|
This may be useful when using large picture formats such as 1280 x 720.
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_Motion_Detection"></a>Motion Detection</h3>
|
|
<ul>
|
|
<p></p>
|
|
<h3><a name="emulate_motion"></a> emulate_motion </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: on off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Always save images even if there was no motion
|
|
<p></p>
|
|
|
|
<h3><a name="threshold"></a> threshold </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 2147483647</li>
|
|
<li> Default: 1500</li>
|
|
</ul>
|
|
<p></p>
|
|
Threshold for declaring motion. The threshold is the number of changed
|
|
pixels counted after noise filtering, masking, despeckle, and labelling.
|
|
The 'threshold' option is the most important detection setting. When motion runs it compares
|
|
the current image frame with the previous and counts the number of changed pixels after having
|
|
processed the image with noise filtering, masking, despeckle and labeling. If more pixels than defined
|
|
by 'threshold' have changed we assume that we have detected motion. Set the threshold as low as possible
|
|
so that you get the motion you want detected but large enough so that you do not get detections from noise
|
|
and plants moving. Note that the larger your frames are, the more pixels you have. So for large picture frame
|
|
sizes you need a higher threshold.
|
|
Use the -s (setup mode) command line option and/or the text_changes config file option to experiment to find
|
|
the right threshold value. If you do not get small movements detected (see the mouse on the kitchen floor) lower
|
|
the value. If motion detects too many birds or moving trees, increase the number. (Unless of course
|
|
you are one of the many many users who use Motion to bird watch!)
|
|
Practical values would be from a few hundred to thousands.
|
|
<p></p>
|
|
|
|
<h3><a name="threshold_tune"></a> threshold_tune </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Activate the automatic tuning of threshold level.
|
|
This feature makes Motion continuously adjust the threshold for declaring motion.
|
|
The threshold setting is ignored when activating this feature. It may give different results depending
|
|
on your camera, light conditions, indoor/outdoor, the motion to be detected etc. If it does not work well,
|
|
deactivate the 'threshold_tune' option and use the manual setting of threshold instead.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="noise_level"></a> noise_level </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 255</li>
|
|
<li> Default: 32</li>
|
|
</ul>
|
|
<p></p>
|
|
The noise level is used as a threshold for distinguishing between noise and motion.
|
|
This is different from the threshold parameter. This is changes at pixel level. The purpose is to
|
|
eliminate the changes generated by electric noise in the camera. Especially in complete darkness
|
|
you can see the noise as small grey dots that come randomly in the picture. This noise can create
|
|
false motion detection. What this parameter means is that the intensity of a pixel must change more
|
|
than +/- the noise threshold parameter to be counted.
|
|
<p></p>
|
|
|
|
<h3><a name="noise_tune"></a> noise_tune </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
Activates the automatic tuning of noise level.
|
|
This feature makes Motion continuously adjust the noise
|
|
threshold for distinguishing between noise and motion.
|
|
The 'noise_level' setting is ignored when activating this feature.
|
|
It may give different results depending on camera and light conditions.
|
|
<p></p>
|
|
|
|
<h3><a name="area_detect"></a> area_detect </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
Detect motion in predefined areas (1 - 9) and when Motion is detected in the area, execute the script. All of
|
|
motion detection still continue. This option is only to execute the on_area_detect script.
|
|
<p></p>
|
|
Areas are numbered like
|
|
<ul>
|
|
<li>1 2 3</li>
|
|
<li>4 5 6</li>
|
|
<li>7 8 9</li>
|
|
</li>
|
|
</ul>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="mask_file"></a> mask_file </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and filename for the masking pgm file.
|
|
If needed, the mask will be resized to match the width and height of the frames being
|
|
captured.
|
|
If you have one or more areas of the camera image in which you do NOT want motion detected (e.g. a tree that
|
|
moves in the wind or a corner of the picture where you can see cars/pedestrians passing by) you need a mask file.
|
|
This file is a picture that you create in your favorite photo editing program. The areas that you want detected must
|
|
be white. The area that you want ignored must be black. The pgm image should be the same size (number of pixels high
|
|
and wide) as the pictures that are taken by the camera so you can define the correct area to mask.
|
|
You can adjust sensitivity by using gray tones.
|
|
If you do not have a mask file disable this option by not having it in the config file or comment
|
|
it out.
|
|
If you are using the <code>rotate</code> or <code>flip_axis</code> options, note that the mask is
|
|
applied <em>after</em> the rotation.
|
|
<p></p>
|
|
<strong>Detailed Description</strong>
|
|
<p></p>
|
|
The mask file must be a pgm format image file (portable gray map). Note that you must choose the BINARY format.
|
|
<p></p>
|
|
To use this feature create an image of exact the same size as the ones you get from your camera.
|
|
Then make it purely white for the areas you want detected and
|
|
black for the areas you want ignored. You can also make gray areas where
|
|
you want to lower the sensitivity to motion. Normally you will stick to pure black and white.
|
|
<p></p>
|
|
One method for generating the mask file is as follows.
|
|
<p></p>
|
|
Take a motion captured picture, edit it with black and white for the mask and export it as a pgm file.
|
|
with a program such as gimp.
|
|
|
|
If you cannot save in this format save as a grayscale jpg and then you can convert it to pgm format with
|
|
<p></p>
|
|
<code>djpeg -grayscale -pnm [inputfile] > mask.pgm</code>
|
|
|
|
<p></p>
|
|
(assuming you have djpeg installed - part of the jpeg lib package).
|
|
<p></p>
|
|
Note that the mask file option masks off the detection of motion. The entire picture is still shown on the picture.
|
|
This means that you cannot use the feature to mask off an area that you do not want people to see. Instead
|
|
use the mask_privacy option.
|
|
<p></p>
|
|
Below are an example of a webcam picture and a mask file to prevent the detection cars in the street.
|
|
<p></p>
|
|
Normal picture. Notice the street is visible through the hedge.
|
|
<p></p>
|
|
<img alt="normal.jpg" src="normal.jpg" />
|
|
<p></p>
|
|
Mask file (converted to png format so it can be shown by your web browser)
|
|
<p></p>
|
|
<table style="border-width:1px;" cellspacing="0" cellpadding="0" border="1">
|
|
<tr >
|
|
<td bgcolor="#ffffff" valign="top" style="vertical-align:top;" >
|
|
<img alt="mask1.png" src="mask1.png" />
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<p></p>
|
|
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="mask_privacy"></a> mask_privacy </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and filename for the privacy masking pgm file. This file works like
|
|
the <a href="#mask_file">mask_file</a> as
|
|
described above. The difference with this parameter is that while the mask_file excludes the section from
|
|
detecting motion, this file excludes the section of the image completely.
|
|
<p></p>
|
|
mask_privacy is applied before detection so no motion will ever be detected in the excluded area.
|
|
This parameter could however still be used with the mask_file. e.g. This file could exclude the
|
|
neighbors yard and the <a href="#mask_file">mask_file</a> would exclude the blowing tree from motion
|
|
detection. The resulting
|
|
pictures/movies would show solid black in place of the neighbors yard but the tree would still be in
|
|
the pictures/movies.
|
|
<p></p>
|
|
|
|
<h3><a name="smart_mask_speed"></a> smart_mask_speed </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 10</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Speed for the smart mask. Default is 0 = DISABLED. 1 is slow, 10 is fast.
|
|
Smartmask is a dynamic, self-learning mask. Smartmask will disable sensitivity
|
|
in areas with frequent motion (like trees in the wind). Sensitivity is turned
|
|
on again after some time of no more motion in this area. The built mask is a bit
|
|
larger at the borders than the actual motion was. This way smartmask works more
|
|
reliable when sudden moves occur under windy conditions.
|
|
<p></p>
|
|
Fast means here that the mask is built quick, but it is also not staying very long with no more motion.
|
|
Slow means that it takes a while until the mask is built but it also stays longer. A good start value
|
|
for smart_mask_speed is 5. This setting is independent from the <a href="#framerate">framerate</a>. The
|
|
attack and decay time
|
|
is constant over all available framerates.
|
|
When smartmask is enabled and motion is also configured to either write motion-images or motion-mpegs,
|
|
the current smartmask is copied as an overlay into the black/white motion-pictures/mpegs in red colour.
|
|
Same thing happens to the webcam stream when Motion runs in <code><a href="#setup_mode">setup_mode</a></code>.
|
|
That way you can
|
|
easily adjust smart_mask_speed.
|
|
<p></p>
|
|
The <code>mask_file</code> option provides a static mask to turn off sensitivity in certain areas.
|
|
This is very useful to mask a street with cars passing by all day long etc...
|
|
<p></p>
|
|
But imagine a scenario with large bushes and big trees where all the leaves are moving
|
|
in the wind also triggering motion from time to time even with <a href="#despeckle">despeckle</a> turned on. Of
|
|
course you can also define a static mask here, but what if the bushes are growing during
|
|
spring and summer? Well, you have to adapt the mask from time to time. What if the camera
|
|
position moves slightly? What if someone grows new plants in your garden? You always have to setup a new static mask.
|
|
<p></p>
|
|
The answer to this problem is the smart mask feature A dynamic, self-learing mask.
|
|
<p></p>
|
|
Smart mask will disable sensitivity in areas with frequent motion (like trees in the wind).
|
|
Sensitivity is turned on again after some time of no more motion in this area. The built mask
|
|
is a bit larger at the borders than the actual motion. This way smartmask works more reliably
|
|
when sudden moves occur under windy conditions.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="lightswitch"></a> lightswitch </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 100</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Ignore sudden massive light intensity changes given as a percentage of the picture area that changed intensity.
|
|
The value defines the picture areas in percent that will trigger the lightswitch condition. When lightswitch is
|
|
detected motion detection is disabled for 5 picture frames. This is to avoid false detection when light conditions
|
|
change and when a camera changes sensitivity at low light.
|
|
<p></p>
|
|
|
|
<h3><a name="minimum_motion_frames"></a> minimum_motion_frames </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 1000s</li>
|
|
<li> Default: 1</li>
|
|
</ul>
|
|
<p></p>
|
|
Picture frames must contain motion at least the specified number of frames in a row before they are
|
|
detected as true motion. At the default of 1, all motion is detected. Valid range is 1 to thousands,
|
|
but it is recommended to keep it within 1-5.
|
|
Note that the picture frames are buffered by Motion and once motion is detected also the first frames
|
|
containing motion are saved so you will not miss anything.
|
|
The feature is used when you get many false detections when the camera changes light sensitivity or light changes.
|
|
Even though Motion accepts large values you should set this to a relatively low number
|
|
(below 10). For each step larger than 1 Motion reserves space in RAM for the picture frame buffer. If you have a
|
|
large value Motion will miss many frames from the camera while it is processing the all the pictures in the buffer.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="event_gap"></a> event_gap </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 60</li>
|
|
</ul>
|
|
<p></p>
|
|
The seconds of no motion detection that triggers the end of an event.
|
|
An event is defined as a series of motion images taken within a short timeframe.
|
|
The value -1 is allowed and disables
|
|
events causing all Motion to be written to one single movie file and no pre_capture.
|
|
If set to 0, motion is running in gapless mode. An
|
|
event ends right after no more motion is detected and post_capture is over.
|
|
|
|
Disabling events has bad side effects on
|
|
noise_tune and smartmask. Both features can only work properly outside an event.
|
|
When event_gap is set to -1, both features don't work properly anymore.
|
|
An event is defined as a series of motion images taken within a short timeframe.
|
|
E.g. a person walking through the room is an event that may have caused 10 single
|
|
jpg images to be stored. This option defines how long a pause between detected motions
|
|
that is needed to be defined as a new event.
|
|
The timer starts after the last motion is detected and <a href="#post_capture">post_capture</a> images
|
|
have been saved and appended to open movie files.
|
|
Any motion detected before the gap timer times out resets the gap timer so it starts counting over again.
|
|
The option 'event_gap' is important. It defines how long a period of no motion detected it takes before we say an event is over. An event is defined as a series of motion images taken within a short timeframe. E.g. a person walking through the room is an event that may have caused 10 single jpg images to be stored. Motion detected includes post_captured frames set by the 'post_capture' option. The 'gap' option defines how long a pause between detected motions that is needed to be defined as a new event. A good starting value is 60 seconds.
|
|
The way 'gap' works in more technical terms is:
|
|
<ul>
|
|
<li> A timer that timeouts 'event_gap' seconds after the last video frame with motion is detected.</li>
|
|
<li> If <a href="#post_capture">post_capture</a> is activated then the gap timer starts counting after the last image of the <a href="#post_capture">post_capture</a> buffer has been saved.</li>
|
|
<li> The event_gap timer is reset and starts all over each time new motion is detected, so you will not miss any action by having a short 'gap' value. It will just create more events (e.g. more mpegs files)</li>
|
|
</ul>
|
|
The event_gap value impacts many functions in Motion.
|
|
<ul>
|
|
<li> When the timer runs out the event number is increased by one next time motion is detected.
|
|
When you use the %v conversion specifier in filenames or text features this means that the
|
|
number in filename or text increased by one.</li>
|
|
<li> The <a href="#pre_capture">pre_capture</a> feature only works at the beginning of an event. So if you have a very large 'event_gap'
|
|
value <a href="#pre_capture">pre_capture</a> is not working very often.</li>
|
|
<li> When you make movies using the ffmpeg features a new movie file is started at the beginning of an event
|
|
when the first motion is detected. When 'event_gap' seconds has passed without motion (and post_captured frames
|
|
saved) the movie files are completed and closed.</li>
|
|
<li> Do not use large event_gap values to generate one large movie file.
|
|
If Motion stops working this movie file never gets properly completed and closed
|
|
you will not be able to view it.</li>
|
|
<li> Some of the tracking features sets the camera back to the center position when an event is over.</li>
|
|
</ul>
|
|
|
|
Note that 'event_gap' and 'minimum_gap' have nothing to do with each other.
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_Scripts"></a> Script Execution </h3>
|
|
<ul>
|
|
<p></p>
|
|
Motion can execute external commands based on the motion detection and related events.
|
|
They are described in the sections below.
|
|
<p></p>
|
|
<strong>Security Warning!</strong>
|
|
<p></p>
|
|
These features mean you have to pay attention to the following.
|
|
<ul>
|
|
<li> Anyone with access to the remote control port (http) can execute any command on your computer with
|
|
the same privileges as the user running Motion.
|
|
Anyone can access your control port if you have not either limited access to localhost or
|
|
limited access using firewalls in the server.
|
|
You should always have a router between a machine running Motion with remote control
|
|
enabled and the Internet and make sure the Motion control port is not accessible from the outside.
|
|
</li>
|
|
<li> If you limit control port to localhost you still need to take care of any user logging into the server
|
|
with any kind of GUI or terminal session. All it takes is a browser or single command line execution to
|
|
change settings in Motion.
|
|
</li>
|
|
<li> It is a good idea to run Motion as a harmless user. Not as root!!</li>
|
|
</ul>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_event_start"></a> on_event_start </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the program/script to be executed at the start of an event.
|
|
An event starts at first motion detected after a
|
|
period of no motion defined by gap.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_event_end"></a> on_event_end </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the program/script to be executed when a event ends.
|
|
An event ends after the event_gap has expired.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_picture_save"></a> on_picture_save </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the program/script to be executed when a picture is saved.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
Use %f for passing filename (with full path) to the command.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_motion_detected"></a> on_motion_detected </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the program/script to be executed when motion is detected.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_area_detected"></a> on_area_detected </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the program/script to be executed when motion is
|
|
detected in the predefined area indicated in the area_detect option.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_movie_start"></a> on_movie_start </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the program/script to be executed when a
|
|
new movie is being created.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
Use %f for passing filename (with full path) to the command.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_movie_end"></a> on_movie_end </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined</li>
|
|
</ul>
|
|
<p></p>
|
|
<p></p>
|
|
The full path and file name of the program/script to be executed after a new
|
|
movie was created.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
Use %f for passing filename (with full path) to the command.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_camera_lost"></a> on_camera_lost </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the command to be executed when a camera can't be opened or if it is lost.
|
|
<br />Note that there are situations when motion doesn't detect a lost camera. It is
|
|
dependent upon the camera and driver and it is advised that this option be tested
|
|
for each configuration. It has also been observed that there are also
|
|
situations in which the disconnection of the camera even hangs the PC in which
|
|
case this script will not be executed.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="on_camera_found"></a> on_camera_found </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The full path and file name of the command to be executed when a lost camera is found
|
|
If motion fails to detect a lost camera, it will also fail to know it found one.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
and spaces as part of the command. This can be any type of program or script.
|
|
Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash
|
|
also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
</ul>
|
|
|
|
<h3><a name="Options_Output_General"></a>Output - General Options</h3>
|
|
<ul>
|
|
|
|
<p></p>
|
|
<h3><a name="quiet"></a> quiet </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Be quiet, don't output beeps when detecting motion.
|
|
Only works in non-daemon mode.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="pre_capture"></a> pre_capture </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 100s</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Specifies the number of pre-captured (buffered) pictures from before motion
|
|
was detected that will be output at motion detection.
|
|
The recommended range is 0 to 5. It is not recommended to use large values.
|
|
Large values will cause Motion to skip video frames and cause unsmooth movies.
|
|
<p></p>
|
|
This is because Motion is processing all the buffered images including saving jpegs,
|
|
encoding the movie, writing to databases and executing external programs immediately
|
|
after the first image is detected as Motion.
|
|
<p></p>
|
|
Motion will not grab another image until this is done. This means that even moderate values for pre_capture combined
|
|
with high framerates will mean that you will probably miss many frames of Motion.
|
|
<p></p>
|
|
To create smooth movies use larger values of <a href="#post_capture">post_capture</a> instead.
|
|
<p></p>
|
|
Motion buffers the number of picture frames defined by 'pre_capture'. When motion is detected the pictures in the
|
|
buffer are included in the movie. The effect is that it seems the program knew in advance
|
|
that the event was going to take place and started the recording before it actually happened.
|
|
This is a nice feature that give more complete video clips of an event.
|
|
<p></p>
|
|
If pre_capture is set to 0 the feature is disabled. The recommended value would be approx 0.5 second of
|
|
video so the value should be defined so it fits the framerate and the desired pre-capture time.
|
|
You can in theory have up to 100s of pre-captured frames but naturally this makes motion leave a larger footprint in
|
|
the memory of the computer.
|
|
<p></p>
|
|
It is therefore recommended to use relatively small values for pre_capture.
|
|
Depending on your chosen framerate and depending on the features enabled values from 1-5 are sensible.
|
|
<p></p>
|
|
To get a smooth movie use a large value for <a href="#post_capture">post_capture</a> which does not cost any performance hit or RAM
|
|
space.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="post_capture"></a> post_capture </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Specifies the number of frames to be captured after motion has been detected.
|
|
The purpose of this is mainly to create smooth video clips each time motion is detected. Use it to you personal
|
|
taste (and disk space)..
|
|
This option is the preferred way to create continuous movies. Post_capture does not consume extra RAM and it
|
|
does not create pauses in the movie even with large values.
|
|
If you only store movies and do not have output_normal on, then the recommended post_capture value is what is
|
|
equivalent to 1-5 seconds (Don't forget to multiply the seconds desired by the framerate for this parameter)
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="target_dir"></a> target_dir </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not defined = current working directory</li>
|
|
</ul>
|
|
<p></p>
|
|
The full path for the target directory for picture and movie files to be saved.
|
|
The default is the current working directory. This is the target directory for all snapshots,
|
|
images files and movie files.
|
|
You will normally always want to specify this parameter as an absolute path.
|
|
<p></p>
|
|
Note that the file name options are all saved relative to this target_dir
|
|
This means in principle that you can specify target_dir as '/' and be 100% flexible. But this is
|
|
NOT recommended. It is recommended that this directory be specified as deep as possible.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
</ul>
|
|
|
|
<h3><a name="Options_Pictures"></a>Output - Picture Options </h3>
|
|
<ul>
|
|
|
|
<p></p>
|
|
Motion can output different types of pictures. The normal picture is indicated below.
|
|
<p></p>
|
|
<img alt="outputnormal1.jpg" src="outputnormal1.jpg" />
|
|
<p></p>
|
|
The motion type picture or also referred to as a debug picture is shown
|
|
below. Note that the largest area is blue and only this is counted as Motion.
|
|
<p></p>
|
|
The Motion image shows how Motion maintains a "reference frame" which is not just the last picture frame
|
|
but a mathematical calculation of the past images. This enlarges real Motion and ensures that it is not easy to
|
|
sneak in slowly.
|
|
<p></p>
|
|
<img alt="outputmotion1.jpg" src="outputmotion1.jpg" />
|
|
<p></p>
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="output_pictures"></a> output_pictures </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: on, off, first, best</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
This option controls the output of the normal image.
|
|
<p></p>
|
|
'on' is the usual selection.
|
|
<p></p>
|
|
'first' is Motion saves only the first motion detected picture per event.
|
|
<p></p>
|
|
"best" requires a little more CPU power and resources compared to "first".
|
|
If you set it to "best" Motion saves the picture with most changed pixels during the event.
|
|
This may be useful if you store movies on a server and want to present a jpeg to show the content of the movie
|
|
on a webpage.
|
|
<p></p>
|
|
'off' to don't write pictures
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="output_debug_pictures"></a> output_debug_pictures </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Output pictures with only the moving object.
|
|
This feature generates the special motion type movies where you only see the pixels that
|
|
changes as a graytone image. If labelling is enabled you see the largest area in blue.
|
|
<p></p>
|
|
If a Smartmask is specified, it is shown in red.
|
|
<p></p>
|
|
This option is good for tuning and testing but probably not very interesting for the general public.
|
|
<p></p>
|
|
Default is not to store these motion images.
|
|
Motion pictures are stored the same place and with the same filename as normal motion
|
|
triggered pictures except they have an "m" appended at the end of the filename before
|
|
the .jpg or .ppm. E.g. the name can be 01-20020424232936-00m.jpg.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="quality"></a> quality </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 100</li>
|
|
<li> Default: 75</li>
|
|
</ul>
|
|
<p></p>
|
|
The quality for the jpeg or webp images in percent.
|
|
100 means hardly compressed. A small number means a much smaller file size but also a poorer
|
|
quality image to look at.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="picture_type"></a> picture_type </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies the type of picture file to output. The recommendation is to always use jpg except
|
|
if you have a specific need to store high quality pictures without any quality loss.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="snapshot_interval"></a> snapshot_interval </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
This parameter specifies the number of seconds between each snapshot
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="snapshot_filename"></a> snapshot_filename </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: %v-%Y%m%d%H%M%S-snapshot</li>
|
|
</ul>
|
|
<p></p>
|
|
This option indicates the file name and optionally the path for the snapshots (jpeg or ppm) relative to target_dir.
|
|
<p></p>
|
|
The file extension .jpg or .ppm is automatically added.
|
|
<p></p>
|
|
A symbolic link called lastsnap.jpg (or lastsnap.ppm) is created in the target_dir and will always
|
|
point to the latest snapshot, unless snapshot_filename is exactly 'lastsnap'
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> in this option.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="picture_filename"></a> picture_filename </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: %v-%Y%m%d%H%M%S-%q</li>
|
|
</ul>
|
|
<p></p>
|
|
This option indicates the file name and optionally the path for the pictures (jpeg or ppm) relative to target_dir.
|
|
<p></p>
|
|
The file extension .jpg or .ppm is automatically added.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> in this option.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="exif_text"></a> exif_text </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
Use this option to specify the text to include in a JPEG EXIF comment
|
|
The EXIF timestamp is included independent of this text.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> in this option.
|
|
<p></p>
|
|
<p></p>
|
|
</ul>
|
|
|
|
<h3><a name="Options_Movies"></a>Output - Movie Options</h3>
|
|
<ul>
|
|
<p></p>
|
|
<h3><a name="max_movie_time"></a> max_movie_time </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 (infinite) - 2147483647</li>
|
|
<li> Default: 3600</li>
|
|
</ul>
|
|
<p></p>
|
|
The maximum length of a movie in seconds. Set this to zero for unlimited length.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="ffmpeg_output_movies"></a> ffmpeg_output_movies </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Use ffmpeg libraries to encode movies of the motion. This option
|
|
generates a new movie at the beginning of each new event and appends to the
|
|
movie for each motion detected within the same event.
|
|
The current event ends when the time defined by the 'event_gap' option has passed with no motion detected.
|
|
At the next detection of motion a new movie is started.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="ffmpeg_output_debug_movies"></a> ffmpeg_output_debug_movies </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Use ffmpeg libraries to encode motion type movies where you only see the pixels that changes.
|
|
Works like ffmpeg_output_movies but outputs motion pixel type pictures instead.
|
|
This feature generates the special motion type movie where you only see the pixels
|
|
that changes as a graytone image. If labeling is enabled you see the largest area in blue.
|
|
Smartmask is shown in red. The filename given is the same as the normal movies except they
|
|
have an 'm' appended after the filename.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="ffmpeg_bps"></a> ffmpeg_bps </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 9999999</li>
|
|
<li> Default: 400000</li>
|
|
</ul>
|
|
<p></p>
|
|
Bitrate of movies produced by ffmpeg. Bitrate is bits per second.
|
|
A higher value means better quality and larger files if the camera is on a fixed bitrate setting.
|
|
Experiment to get the desired quality. The better quality the bigger files.
|
|
This option is ignored if ffmpeg_variable_bitrate is not 0 (disabled).
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="ffmpeg_variable_bitrate"></a> ffmpeg_variable_bitrate </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 100</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Enables and defines a variable bitrate for the ffmpeg encoder.
|
|
The option of ffmpeg_bps is ignored if variable bitrate is enabled.
|
|
A value of 0 disables this option while values 1 - 100 varies the quality
|
|
of the movie. The value of 1 means worst quality and 100 is the best quality.
|
|
<p></p>
|
|
Experiment for the value that gives you the desired compromise between size and quality.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="ffmpeg_video_codec"></a> ffmpeg_video_codec </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: mpeg4, msmpeg4, swf, flv, ffv1, mov, ogg, mp4, mkv, hevc</li>
|
|
<li> Default: mpeg4</li>
|
|
</ul>
|
|
<p></p>
|
|
Container/Codec to be used for the video.
|
|
<p></p>
|
|
<ul>
|
|
<li>mpeg4 or msmpeg4 - gives you files with extension .avi</li>
|
|
<li>swf - gives you a flash film with extension .swf</li>
|
|
<li>flv - gives you a flash video with extension .flv </li>
|
|
<li>ffv1 - FF video codec 1 for Lossless Encoding </li>
|
|
<li>mov - QuickTime </li>
|
|
<li>mp4 - MPEG-4 Part 14 H264 encoding</li>
|
|
<li>mkv - Matroska container with H264 encoding</li>
|
|
<li>hevc -MP4 container with H.265 / HEVC (High Efficiency Video Coding)</li>
|
|
</ul>
|
|
|
|
<p></p>
|
|
Note that certain containers can handle different codecs than the defaults indicated above. For example, the
|
|
mkv container can handle virtually any codec. Motion can optionally take an additional specification with this
|
|
parameter. By specifying the container (mkv) and then appending a semicolon and the ffmpeg codec name Motion
|
|
will attempt to use the specified codec for the container. This permits options such as encoding the h265 codec
|
|
into a mkv container instead of mp4 by specifying the option as <code>mkv:h265</code>
|
|
<p></p>
|
|
|
|
<h3><a name="ffmpeg_duplicate_frames"></a> ffmpeg_duplicate_frames </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: on/off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
When specified, if the CPU can not keep up with the requested frame rate for the movies,
|
|
frames will be duplicated in order to keep up with the frame rate. Use this option with care
|
|
since the resulting movies will have the same frame sent multiple times and therefore the
|
|
movie may appear to "stall" and look terrible.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="movie_filename"></a> movie_filename </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: %v-%Y%m%d%H%M%S</li>
|
|
</ul>
|
|
<p></p>
|
|
File path for motion triggered movies relative to target_dir. Note that the file
|
|
extension is automatically added to the name based upon the codec selected.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> in this option.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="timelapse_filename"></a> timelapse_filename </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: %v-%Y%m%d-timelapse</li>
|
|
</ul>
|
|
<p></p>
|
|
File path for the timelapse videos relative to target_dir. Note that the file
|
|
extension is automatically added to the name based upon the codec selected.
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> in this option.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="timelapse_interval"></a> timelapse_interval </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Create a timelapse video saving a picture frame at the interval in seconds set by this parameter.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="timelapse_mode"></a> timelapse_mode </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: hourly, daily, weekly-sunday, weekly-monday, monthly, manual</li>
|
|
<li> Default: daily</li>
|
|
</ul>
|
|
<p></p>
|
|
The file rollover mode of the timelapse video.
|
|
Note that it is important that you use the <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
in timelapse_filename that ensure that the new timelapse file indeed is a new file. If the filename
|
|
does not change Motion will simply append the timelapse pictures to the existing file.
|
|
<br />The value 'Manual' means that Motion does not automatically rollover to a new filename. You can do it
|
|
manually using the http control interface by setting the option
|
|
<a href="#timelapse_interval">timelapse_interval</a> to 0 and then back to your chosen value.
|
|
<p></p>
|
|
The value 'hourly' rolls over on the full hour. Value 'daily' which is the default
|
|
rolls over at midnight. There are two weekly options because depending on where you come from a week
|
|
may either start on Sunday or Monday. And 'monthly' naturally rolls over on the 1st of the month.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="timelapse_codec"></a> timelapse_codec </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: mpg, mpeg4</li>
|
|
<li> Default: mpg</li>
|
|
</ul>
|
|
<p></p>
|
|
Container/Codec to be used by timelapse video.
|
|
<p></p>
|
|
<ul>
|
|
<li>mpg - Creates mpg file with mpeg-2 encoding. If Motion is shutdown and restarted, new pics will be appended
|
|
to any previously created file with name indicated for timelapse.</li>
|
|
<li>mpeg4 - Creates avi file with the default encoding. If Motion is shutdown and restarted, new pics will
|
|
create a new file with the name indicated for timelapse.</li>
|
|
</ul>
|
|
<p></p>
|
|
Note that different containers are NOT planned for this option since the nature of recording a timelapse
|
|
is not what typical movies containers and codecs are designed to do. Users desiring a different container/codec
|
|
can use ffmpeg directly to either re-encode a finished timelapse video or output the timelapse as jpg picture
|
|
files and use ffmpeg to encode those jpgs into a movie.
|
|
<p></p>
|
|
|
|
<h3><a name="timelapse_fps"></a> timelapse_fps </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 30</li>
|
|
</ul>
|
|
<p></p>
|
|
The frame per second rate to use in the playback of the timelapse video.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
|
|
</ul>
|
|
|
|
<h3><a name="Options_Pipe"></a>Output - Pipe Options</h3>
|
|
<ul>
|
|
|
|
<p></p>
|
|
There are two pipe variations available with Motion. The first option is a v4l2loopback device.
|
|
Using this pipe option, the video that is captured from the v4l2 device is piped into a new
|
|
v4l2 device using the v4l2loopback software. This piping is desired when the user wishes to
|
|
use the video device at the same time as Motion is using the same device. By default, only
|
|
one application can have a device open at one time. Unlike a physical device, the videoloopback
|
|
devices take both input and output. The module simply takes anything that comes on its input
|
|
and send it out at the output.
|
|
<p></p>
|
|
When you install the video loopback device it will create a new device for example /dev/video1 while
|
|
the actual webcam device would be /dev/video0. You can then tell motion to open the physical
|
|
device (/dev/video0) and "pipe" the video signal to the /dev/video1. You will then be able to open
|
|
the /dev/video1 device with external videoplayers such as VLC and and look at the pictures live.
|
|
VLC is "fooled" to think it is looking at a real camera.
|
|
<p></p>
|
|
<strong>Installing</strong>
|
|
<p></p>
|
|
The video loopback device can be added installed via apt in many distributions. The package tested
|
|
with Motion is v4l2loopback-dkms. Once the package is installed, you just need to run
|
|
<code><strong>sudo modprobe v4l2loopback</strong></code>. This will add a new video device that you
|
|
can use for the loopback. It is believed that there are additional options associated with the
|
|
v4l2loopback that allows for adding more than one device. See the documentation of the v4l2loopback
|
|
project for additional details.
|
|
<p></p>
|
|
To activate the vloopback device in Motion set the 'video_pipe' option in the motion.conf file to the
|
|
device name associated with the one created by v4l2loopback.
|
|
<br />You can also view the special motion pictures where you see the changed pixels by setting the option
|
|
'motion_video_pipe' in motion.conf. When setting the video_pipe and/or motion_video_pipe options
|
|
specify the input device as e.g. /dev/video1.
|
|
<p></p>
|
|
De-activating should be done with this command
|
|
<p></p>
|
|
<code>sudo modprobe -r v4l2loopback</code>
|
|
<p></p>
|
|
The second type of pipe available in Motion is the extpipe. This option sets up a pipe to which it sends
|
|
images which can then be picked up by external recording applications.
|
|
<p></p>
|
|
|
|
|
|
|
|
<h3><a name="video_pipe"></a> video_pipe </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
Default: not set
|
|
The video4linux video loopback device for normal images. The device would be specified
|
|
in the format like /dev/video1
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="motion_video_pipe"></a> motion_video_pipe </h3>
|
|
<p></p> <ul>
|
|
<li> Type: String
|
|
</li> <li> Range / Valid values: Max 4095 characters
|
|
</li> <li> Default: Not defined
|
|
</li></ul>
|
|
<p></p>
|
|
The video4linux video loopback device for motion images. The device would be specified
|
|
in the format like /dev/video1
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="use_extpipe"></a> use_extpipe </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies whether to send the output to a
|
|
pipe for external encoding into a movie.
|
|
<p></p>
|
|
Piping raw video to stdout has some advantages comparing to using built-in ffmpeg encoder.
|
|
<br />First, you can use any encoder that supports RAW frames from stdin so you are not limited to the formats
|
|
that are currently implemented in motion. See examples in <a href="#extpipe">extpipe</a>
|
|
<br />Second, external encoders utilize separate cpu core(s) on multi-core systems so movie encoding
|
|
is offloaded from main motion thread to separate core(s) giving noticeable performance boost
|
|
<p></p>
|
|
Note that this option does not require the install or configure of the videoloopback software.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="extpipe"></a> extpipe </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies the program name and options for the
|
|
program that will receive and process the images during a movie event.
|
|
<p></p>
|
|
Note that this option does not require the install or configure of the videoloopback software.
|
|
<p></p>
|
|
Sample:
|
|
<p></p>
|
|
extpipe mencoder -demuxer rawvideo -rawvideo w=%w:h=%h:i420 -ovc x264 -x264encopts bframes=4:frameref=1:subq=1:scenecut=-1:nob_adapt:threads=1:keyint=1000:8x8dct:vbv_bufsize=4000:crf=24:partitions=i8x8,i4x4:vbv_maxrate=800:no-chroma-me -vf denoise3d=16:12:48:4,pp=lb -of avi -o %f.avi - -fps %fps
|
|
<p></p>
|
|
extpipe x264 - --input-res %wx%h --fps %fps --bitrate 2000 --preset ultrafast --quiet -o %f.mp4
|
|
<p></p>
|
|
extpipe mencoder -demuxer rawvideo -rawvideo w=%w:h=%h:fps=%fps -ovc x264 -x264encopts preset=ultrafast -of lavf -o %f.mp4 - -fps %fps
|
|
<p></p>
|
|
extpipe ffmpeg -y -f rawvideo -pix_fmt yuv420p -video_size %wx%h -framerate %fps -i pipe:0 -vcodec libx264 -preset ultrafast -f mp4 %f.mp4
|
|
<p></p>
|
|
<p></p>
|
|
|
|
|
|
</ul>
|
|
|
|
<h3><a name="Options_Stream_Webcontrol"></a> Stream and Webcontrol</a> </h3>
|
|
<ul>
|
|
|
|
Motion has simple webcam server built in. The server can be configured to
|
|
stream both the images as well allow for a very basic http control of Motion parameters.
|
|
<p></p>
|
|
Each camera can have its own stream and it is enabled by specifying
|
|
the port number. If there are multiple cameras, each camera must have
|
|
its own unique port number.
|
|
<p></p>
|
|
The webserver generates a stream in "multipart jpeg" format (mjpeg). Some browsers can not display
|
|
images fed in this method. The most straight forward around this limitation is to create a local
|
|
HTML page that references the raw stream(s).
|
|
|
|
<p></p>
|
|
Open up a text editor and paste in the following.
|
|
<p></p>
|
|
<code><strong>
|
|
<html>
|
|
<body bgcolor=000000>
|
|
<img src=http://yourmotionpc:yourstreamport/ border="0" width=25%></a>
|
|
</body>
|
|
</html>
|
|
</strong></code>
|
|
<p></p>
|
|
Change the yourmotionpc with the IP or name of the computer running Motion. Also revise the port
|
|
number to be the one referenced for the stream.
|
|
<p></p>
|
|
Save the file and then open it in your browser.
|
|
<p></p>
|
|
<p></p>
|
|
It may also be possible to view the stream via regular stream players such as VLC, mplayer, ffplay, avplay, etc.
|
|
by specifying the network stream as
|
|
<code>
|
|
http://localhost:myportnumber/stream.mjpg
|
|
</code>
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
Motion can be remote controlled via the simple http interface.
|
|
<p></p>
|
|
Some Motion configuration options can be changed while Motion is running while others require
|
|
that the options be saved and Motion be restarted.
|
|
<p></p>
|
|
The most obvious tool to use to remote control Motion is any web browser.
|
|
All commands are sent using the http GET method which simply means that the information is
|
|
sent via the URL and maybe a query string. You can use any browser (Firefox, Mozilla, Internet Explorer
|
|
, etc). You can also use the text based browser lynx to control Motion from a console.
|
|
It navigates fine through the very simple and minimalistic http control interface of Motion.
|
|
<p></p>
|
|
<p></p>
|
|
But it is probably simpler to connect to the control port with a browser, navigate to the function
|
|
you want, and copy the URL from the browser URL entry line.
|
|
If your <code>webcontrol_port</code> is 8080 and you browse from the same machine
|
|
on which Motion runs simply look up
|
|
<a href="http://localhost:8080/" rel="nofollow" target="_top">http://localhost:8080/</a> and navigate around.
|
|
Connecting from a remote machine can be done by using a domain name (example
|
|
<a href="http://mydomain.com:8080/" rel="nofollow" target="_top">http://mydomain.com:8080/</a>) or the
|
|
IP address of the machine (example
|
|
<a href="http://192.168.1.4:8080/" rel="nofollow" target="_top">http://192.168.1.4:8080/</a>).
|
|
The option <code>webcontrol_localhost</code> must be off to allow connection from a remote machine.
|
|
<p></p>
|
|
If you want to use a script or cron to automatically change Motion settings while Motion runs you use a
|
|
program that can fetch a webpage. We simply just throw away the html page that Motion returns. Programs
|
|
commonly available on Linux machines are wget and lwp-request. Here is an example of how to start and
|
|
stop motion detection via cron. These two lines are added to /etc/crontab.
|
|
<p></p>
|
|
<pre>
|
|
0 9 * * * root /usr/bin/lwp-request http://localhost:8080/0/detection/start > /dev/null
|
|
0 18 * * * root /usr/bin/lwp-request http://localhost:8080/0/detection/pause > /dev/null
|
|
</pre>
|
|
<p></p>
|
|
If you want to use the http remote control from your own software (for example your own PHP front end)
|
|
you can set the motion.conf option <a href="#webcontrol_html_output">webcontrol_html_output</a> off. Then
|
|
Motion answers back with very basic text only without html around it.
|
|
<p></p>
|
|
To remote control Motion from a web pages you can for example use PHP.
|
|
In PHP it takes this simple code line to send a remote commend to Motion.
|
|
Here we pause motion detection for camera 2
|
|
<p></p>
|
|
<code>readfile('http://localhost:8080/2/detection/pause');</code>
|
|
<p></p>
|
|
|
|
</p>
|
|
<strong>ALERT!</strong> Security Warning! This feature also means you have to pay attention
|
|
to the following.
|
|
<ul>
|
|
<li> Anyone with access to the remote control port (http) can alter the values of options
|
|
and save files anywhere on your server with the same privileges as the user running Motion.
|
|
They can execute any command on your computer with the same privileges as the user running Motion.
|
|
Anyone can access your control port if you have not either limited access to localhost or limited
|
|
access using firewalls in the server. You should always have a router between a machine running
|
|
Motion with remote control enabled and the Internet and make sure the Motion control port is not
|
|
accessible from the outside.</li>
|
|
<li> If you limit control port to localhost you still need to take care of any user logging
|
|
into the server with any kind of terminal session.</li>
|
|
<li> Run Motion as a harmless user. DO NOT RUN AS ROOT!!</li>
|
|
</ul>
|
|
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="ipv6_enabled"></a> ipv6_enabled </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
Listen to IPv6 localhost instead of IPv4 (default: off)
|
|
<p></p>
|
|
|
|
<h3><a name="stream_port"></a> stream_port </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 65535</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
The TCP port that Motion will send the main stream.
|
|
Each camera must have its own unique port number and it must
|
|
also be different from the webcontrol_port number.
|
|
A good value to select is 8081 for camera 1, 8082 for camera 2, 8083 for camera 3 etc.
|
|
<p></p>
|
|
This must be placed in the camera config file (unless you only have
|
|
one camera, in which case it can be placed in motion.conf).
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="substream_port"></a> substream_port </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 65535</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
TCP Port to use for providing a 50% scaled down "substream".
|
|
The substream shares all the same settings as main stream and only scales the image
|
|
down to reduce the required bandwidth.
|
|
<p></p>
|
|
Each camera must have its own unique port number and it must
|
|
also be different from the webcontrol_port number.
|
|
<p></p>
|
|
This must be placed in the camera config file (unless you only have
|
|
one camera, in which case it can be placed in motion.conf).
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="stream_quality"></a> stream_quality </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 100</li>
|
|
<li> Default: 50</li>
|
|
</ul>
|
|
<p></p>
|
|
Quality setting in percent for the mjpeg picture frames transferred over the webcam connection.
|
|
Keep it low to restrict needed bandwidth.
|
|
<br />The mjpeg stream consists of a header followed by jpeg frames separated by content-length
|
|
and the boundary string.
|
|
<br />The quality level defines the size of the individual jpeg pictures in the mjpeg stream.
|
|
If you set it too high you need a lot of bandwidth to view the stream.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="stream_motion"></a> stream_motion </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
When set to 'on', slow down the stream to 1 picture per second when no motion is detected.
|
|
When motion is detected the stream runs as defined by <a name="stream_maxrate"></a> stream_maxrate
|
|
<p></p>
|
|
When 'off' the stream always runs as defined by <a name="stream_maxrate"></a> stream_maxrate.
|
|
Use this option to save bandwidth when there is not anything important to see from the camera anyway.
|
|
<p></p>
|
|
|
|
<h3><a name="stream_maxrate"></a> stream_maxrate </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 1 - 100</li>
|
|
<li> Default: 1</li>
|
|
</ul>
|
|
<p></p>
|
|
Limit the framerate of the stream in frames per second. Set the value to 100 for practically unlimited.
|
|
Don't set this parameter too high unless you only use it on the localhost or on an internal LAN.
|
|
<p></p>
|
|
|
|
<h3><a name="stream_localhost"></a> stream_localhost </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
Limits the access to the stream to the localhost.
|
|
By setting this to on, the stream can only be accessed on the same machine on which Motion is running.
|
|
<p></p>
|
|
|
|
<h3><a name="stream_limit"></a> stream_limit </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This parameter limits the maximum number of images per connection and is
|
|
determined by multiplying actual stream rate by desired number of seconds
|
|
<p></p>
|
|
|
|
<h3><a name="stream_auth_method"></a> stream_auth_method </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 to 2</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
This parameter establishes desired authentication method for the stream and
|
|
web control ports. The parameters have the following meaning.
|
|
<ul>
|
|
<li>0 = disabled </li>
|
|
<li>1 = Basic authentication </li>
|
|
<li>2 = MD5 digest (the safer authentication) </li>
|
|
</ul>
|
|
<p></p>
|
|
Note that if you are enabling the webcontrol feature of Motion, you really really really ... should
|
|
enable security authentications. No. Seriously. You really should. See the security warnings in this
|
|
document regarding how it completely opens up your system.
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="stream_authentication"></a> stream_authentication </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
This parameter establishes the username and password to use for the stream.
|
|
The syntax is username:password
|
|
<p></p>
|
|
|
|
<h3><a name="stream_preview_scale"></a> stream_preview_scale </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values:</li>
|
|
<li> Default: 25</li>
|
|
</ul>
|
|
<p></p>
|
|
If the webcontrol page has HTML enabled, Motion displays all of the streams on the home webcontrol page in HTML
|
|
format so that all the images can be viewed by standard browsers.
|
|
<p></p>
|
|
This parameter indicates the percentage to scale the stream image when it is placed on the page.
|
|
Note that this is scaled on the browser side, Motion will keep sending full frame.
|
|
<p></p>
|
|
Numbers greater than 100 are permitted.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="stream_preview_newline"></a> stream_preview_newline </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: string</li>
|
|
<li> Range / Valid values:on / off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
If the webcontrol page has HTML enabled, Motion displays all images of the streams on the home webcontrol page
|
|
in HTML format so that all the images can be viewed by standard browsers.
|
|
<p></p>
|
|
This parameter determines whether the image is placed on a new line in the webcontrol web page.
|
|
<p></p>
|
|
Preview images are placed on to the webcontrol home page in camera id number order.
|
|
This parameter allows the user some flexibility in organizing the images on the page.
|
|
<p></p>
|
|
Setting this parameter to off will set the image to the right of any image from a lower numbered thread number.
|
|
Setting it to 'on' will place the image on the start of the next line(below).
|
|
<p></p>
|
|
Full customization of the webcontrol page is NOT planned in the Motion development. Users that require
|
|
a more polished and customized preview page are encouraged to create their own local HTML page that references
|
|
the streams.
|
|
<p></p>
|
|
|
|
<h3><a name="webcontrol_port"></a> webcontrol_port </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 65535</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Sets the port number for the http based control of the Motion parameters.
|
|
This option must be placed in the motion.conf file and not in a camera config file.
|
|
Port numbers below 1024 normally require that you have root privileges.
|
|
The port 8080 is the typical selection of the port for this purpose.
|
|
<p></p>
|
|
|
|
<h3><a name="webcontrol_localhost"></a> webcontrol_localhost </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
This option restricts the control of the Motion parameters to the localhost.
|
|
This option must be placed in motion.conf and not in a camera config file.
|
|
By setting this to on, the control using http (browser) can only be accessed on the
|
|
same machine on which Motion is running.
|
|
<p></p>
|
|
|
|
<h3><a name="webcontrol_html_output"></a> webcontrol_html_output </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
Enable HTML in the answer sent back to a browser connecting to the webcontrol_port.
|
|
This option must be placed in motion.conf and not in a camera config file.
|
|
The recommended value for most is "on" which means that you can navigate and control
|
|
Motion with a normal browser. By setting this option to "off" the replies are in plain
|
|
text which may be easier to parse for 3rd party programs that control Motion.
|
|
<p></p>
|
|
|
|
<h3><a name="webcontrol_authentication"></a> webcontrol_authentication </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This parameter establishes the username and password to use for the stream.
|
|
The syntax is username:password
|
|
<p></p>
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="webcontrol_parms"></a> webcontrol_parms </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 3</li>
|
|
<li> Default: 0 (disabled)</li>
|
|
</ul>
|
|
<p></p>
|
|
Sets the type of parameters that will be listed on the webcontrol page and available for
|
|
modification.
|
|
<ul>
|
|
<li> 0: None - No configuration parameters will be available.</li>
|
|
<li> 1: Limited- A limited list of parameters will be available. </li>
|
|
<li> 2: Advanced - The advanced list of parameters will be available. These typically require Motion to be restarted to become effective.</li>
|
|
<li> 3: Restricted - User IDs, passwords and "On" commands.</li>
|
|
</ul>
|
|
The default for this parameter is 0 none to enhance the security of the web interface. The setting of the
|
|
webcontrol_parms is NEVER included on the web interface and this parameter must be specified via the configuration file.
|
|
Care should be exercised when using level restricted level because if the webcontrol is compromised,
|
|
it may compromise the computer.
|
|
<p></p>
|
|
|
|
</ul>
|
|
|
|
<h3><a name="Options_Database"></a>Database</h3>
|
|
<ul>
|
|
|
|
Motion can be compiled with MySQL, PostgreSQL or SQLite3 database support.
|
|
When enabled Motion can be configured to add a record to a table in the database
|
|
as specified by the sql_query. The query can contain the fields that are used and the
|
|
values are given by using <a href="#conversion_specifiers">Conversion Specifiers</a> for dynamic data like
|
|
the filename, time, number of detected pixels etc.
|
|
Motion does not place any binary images in the database and it cannot remove old records.
|
|
<p></p>
|
|
Motion only adds records to the database when files are created.
|
|
The database contains records of saved files which means to get a
|
|
record in the database the feature that enables for example motion
|
|
detection, timelapse, snapshots etc must be enabled.
|
|
The sql_log options define which types of files are logged in the database.
|
|
<p></p>
|
|
The following are sample create table queries for different databases.
|
|
<p></p>
|
|
Mysql : CREATE TABLE security (camera int, filename char(80) not null, frame int, file_type int, time_stamp timestamp(14), event_time_stamp timestamp(14));
|
|
<p></p>
|
|
Postgresql : CREATE TABLE security (camera int, filename char(80) not null, frame int, file_type int, time_stamp timestamp without time zone, event_time_stamp timestamp without time zone);
|
|
<p></p>
|
|
MySQL to use the dbeventid, sql_query_start
|
|
<p></p>
|
|
CREATE TABLE security_file (file_id int primary key auto_increment, event_id int foreign key, filename text not null, frame int, file_type int, time_stamp timestamp(14));\n"
|
|
<p></p>
|
|
|
|
|
|
<p></p>
|
|
<h3><a name="sql_log_picture"></a> sql_log_picture </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
Log to the database when Motion triggers a image file to be saved.
|
|
<p></p>
|
|
|
|
<h3><a name="sql_log_snapshot"></a> sql_log_snapshot </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: on</li>
|
|
</ul>
|
|
<p></p>
|
|
Log to the database when creating a snapshot image file.
|
|
<p></p>
|
|
|
|
<h3><a name="sql_log_movie"></a> sql_log_movie </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Log to the database when creating motion triggered movie file.
|
|
<p></p>
|
|
|
|
<h3><a name="sql_log_timelapse"></a> sql_log_timelapse </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Log to the database when creating timelapse movie file
|
|
<p></p>
|
|
|
|
<h3><a name="sql_query"></a> sql_query </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
SQL query string that is sent to the database when the sql_log_* item is triggered.
|
|
<p></p>
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a>
|
|
within the query.
|
|
<p></p>
|
|
<p></p>
|
|
Sample Queries (depend upon the table created)
|
|
<p></p>
|
|
<br />insert into security(camera, filename, frame, file_type, time_stamp, text_event) values('%t', '%f', '%q', '%n', '%Y-%m-%d %T', '%C')
|
|
<br />insert or ignore into images (camera_nbr, file_name, year, month, day, hour, minute) values (8, '%f', '%Y','%m','%d','%H','%M')
|
|
<br />insert into security_file(camera, event_id, filename, frame, file_type, time_stamp) values('%t', '%{dbeventid}', '%f', '%q', '%n', '%Y-%m-%d %T')"
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="sql_query_start"></a> sql_query_start </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
SQL query that executes against the event table which tracks the unique events of motion.
|
|
<p></p>
|
|
Once the new record is added to this table, the mysql function <code><b>mysql_insert_id</b></code> is then
|
|
executed to provide the key back into the <code><b>dbeventid</b></code> specifier.
|
|
<p></p>
|
|
The <code><b>dbeventid</b></code> specifier can then be used in the <code><b>sql_query</b></code> as a parameter
|
|
to that query for inserting into the table.
|
|
<p></p>
|
|
Although this query is run for all the different database options, the <code><b>dbeventid</b></code> is
|
|
only set for mysql databases. For the other databases, the <code><b>dbeventid</b></code> is always set
|
|
to zero.
|
|
<p></p>
|
|
<p></p>
|
|
You can use <a href="#conversion_specifiers">Conversion Specifiers</a> within the query.
|
|
<p></p>
|
|
<p></p>
|
|
Sample Query
|
|
<p></p>
|
|
insert into security_events(camera, event_time_stamp) values('%t', '%Y-%m-%d %T')"
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="database_type"></a> database_type </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: mysql, postgresql, sqlite3</li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
This option specifies the database type.
|
|
<p></p>
|
|
|
|
<h3><a name="database_dbname"></a> database_dbname </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: Not Defined</li>
|
|
</ul>
|
|
<p></p>
|
|
The name of the database. For Sqlite3, the full path and name to the database.
|
|
<p></p>
|
|
|
|
<h3><a name="database_host"></a> database_host </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: localhost</li>
|
|
</ul>
|
|
<p></p>
|
|
The host on which the database is located
|
|
<p></p>
|
|
|
|
<h3><a name="database_user"></a> database_user </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The user account name for database
|
|
<p></p>
|
|
|
|
<h3><a name="database_password"></a> database_password </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The user password for database
|
|
<p></p>
|
|
|
|
<h3><a name="database_port"></a> database_port </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: </li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
The port number that is used for the database. Typical values are: mysql=3306 and postgresql=5432
|
|
<p></p>
|
|
|
|
|
|
<h3><a name="database_busy_timeout"></a> database_busy_timeout </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: </li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
If the database is busy when the request is issued, this parameter indicates the time to
|
|
wait before issuing a timeout message.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
</ul>
|
|
|
|
<h3><a name="Options_Tracking"></a>Tracking</h3>
|
|
<ul>
|
|
|
|
<p></p>
|
|
This is <strike>still</strike> permanently at the experimental stage.
|
|
<p></p>
|
|
Motion can move the camera to a fixed position given in degrees pan (left-right) and tilt (down-up).
|
|
Movement can be set with absolute coordinates or relative to current position. There is also an auto tracking
|
|
feature for the Logitech Quickcam Sphere/Orbit but it is not very mature. Review and revise the Motion code
|
|
regarding tracking if these features are required. The Motion developers do not have any tracking cameras
|
|
so it is unlikely that tracking features will be developed in any way. (We have no way to test anything!)
|
|
<p></p>
|
|
<p></p>
|
|
|
|
|
|
<p></p>
|
|
<h3><a name="track_type"></a> track_type </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Discrete Strings</li>
|
|
<li> Range / Valid values: 0 (none), 1 (stepper), 2 (iomojo), 3 (pwc), 4 (generic), 5 (uvcvideo)</li>
|
|
<li> Default: 0 (None)</li>
|
|
</ul>
|
|
<p></p>
|
|
Type of tracker.
|
|
<p></p>
|
|
Motion has special tracking options which use either a serial stepper motor controller,
|
|
an iomojo smile cam or a Philips WebCam driver compatible pan/tilt camera such as
|
|
the Logitech Quickcam Sphere or Orbit.
|
|
<p></p>
|
|
To disable tracking, set this to 0 and the other track options are ignored.
|
|
<p></p>
|
|
Value 1 is for the special Motion Tracking project using a stepper motor and a home made controller.
|
|
<p></p>
|
|
Value 2 is for the iomojo smilecam
|
|
<p></p>
|
|
Value 3 is for pwc type USB tracking cameras such as the Logitech Quickcam Sphere/Orbit which is driven
|
|
by the pwc (Philips WebCam) driver. To use this camera your version of pwc must be at least 8.12.
|
|
<p></p>
|
|
Value 4 is the generic track type. Currently it has no other function than enabling some of the
|
|
internal Motion features related to tracking.
|
|
<p></p>
|
|
Value 5 is for uvcvideo type USB tracking cameras such as the Logitech Quickcam Sphere/Orbit MP which is driven
|
|
by the uvcvideo driver.
|
|
<p></p>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_auto"></a> track_auto </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Boolean</li>
|
|
<li> Range / Valid values: on, off</li>
|
|
<li> Default: off</li>
|
|
</ul>
|
|
<p></p>
|
|
Enable auto tracking
|
|
Requires a tracking camera type supported by Motion.
|
|
<p></p>
|
|
|
|
<h3><a name="track_port"></a> track_port </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: String</li>
|
|
<li> Range / Valid values: Max 4095 characters</li>
|
|
<li> Default: </li>
|
|
</ul>
|
|
<p></p>
|
|
This is the device name of the serial port to which the stepper motor interface is connected.
|
|
Only used for stepper motor tracking.
|
|
<p></p>
|
|
|
|
<h3><a name="track_motorx"></a> track_motorx </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
The motor number that is used for controlling the x-axis.
|
|
Only used for stepper motor tracking.
|
|
<p></p>
|
|
|
|
<h3><a name="track_motorx_reverse"></a> track_motorx_reverse </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Description
|
|
<p></p>
|
|
|
|
<h3><a name="track_motory"></a> track_motory </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
The motor number that is used for controlling the y-axis.
|
|
Only used for stepper motor tracking.
|
|
<p></p>
|
|
|
|
<h3><a name="track_motory_reverse"></a> track_motory_reverse </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_maxx"></a> track_maxx </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
The maximum position for servo x.
|
|
Only used for stepper motor tracking.
|
|
<p></p>
|
|
|
|
<h3><a name="track_minx"></a> track_minx </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_maxy"></a> track_maxy </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
The maximum position for servo y.
|
|
Only used for stepper motor tracking.
|
|
<p></p>
|
|
|
|
<h3><a name="track_miny"></a> track_miny </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_homex"></a> track_homex </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_homey"></a> track_homey </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_iomojo_id"></a> track_iomojo_id </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Use this option if you have an iomojo smilecam connected to the serial port instead
|
|
of a general stepper motor controller.
|
|
Only used for iomojo camera.
|
|
<p></p>
|
|
|
|
<h3><a name="track_step_angle_x"></a> track_step_angle_x </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Angle in degrees the camera moves per step on the X-axis with auto tracking. Currently only used with pwc type cameras.
|
|
Requires a tracking camera type pwc.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_step_angle_y"></a> track_step_angle_y </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Angle in degrees the camera moves per step on the Y-axis with auto tracking. Currently only used with pwc type cameras.
|
|
Requires a tracking camera type pwc.
|
|
<p></p>
|
|
<p></p>
|
|
|
|
<h3><a name="track_move_wait"></a> track_move_wait </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Delay during which tracking is disabled after auto tracking has moved the camera.
|
|
Delay is defined as number of picture frames.
|
|
The actual delay is depending on the chosen framerate.
|
|
If you want the camera to move maximum once every 2 seconds and the framerate is 10 then you
|
|
need to set the track_move_wait value to 2 * 10 = 20.
|
|
<p></p>
|
|
|
|
<h3><a name="track_speed"></a> track_speed </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Speed to set the motor to.
|
|
Only used for stepper motor tracking.
|
|
|
|
<p></p>
|
|
|
|
<h3><a name="track_stepsize"></a> track_stepsize </h3>
|
|
<p></p>
|
|
<ul>
|
|
<li> Type: Integer</li>
|
|
<li> Range / Valid values: 0 - 2147483647</li>
|
|
<li> Default: 0</li>
|
|
</ul>
|
|
<p></p>
|
|
Number of steps to make.
|
|
Only used for stepper motor tracking.
|
|
<p></p>
|
|
</ul>
|
|
|
|
</ul>
|
|
|
|
</ul> |