man motion Command

Man page for apt-get motion Command

Man Page for motion in Linux

Ubuntu Man Command : man motion

Man Motion  Command

This tutorial shows the man page for man motion in linux.

Open terminal with 'su' access and type the command as shown below:
man motion

Result of the Command Execution shown below:

MOTION(1)                                                          Motion Options and Config Files                                                         MOTION(1)



NAME
motion Detect motion using a video4linux device

SYNOPSIS
motion [ hns ] [ c config file path ] [ d level ] [ p process_id_file ]

DESCRIPTION
Motion uses a video4linux device to detect motion. If motion is detected both normal and motion pictures will be taken. Motion can also take actions to
notify you if needed. Creation of automated snapshots is also possible.

OPTIONS
c Full path and filename of config file. E.g. /home/kurt/motion.conf. Default is /usr/local/etc unless specified differently when building Motion. Many
RPMs and debian packages will most likely use /etc or /etc/motion as default.

h Show help screen.

n Run in non daemon mode.

s Run in setup mode. Also forces non daemon mode

d level
Run in debug mode, level 1 9.

p Full path and filename for process id file (pid file). E.g /var/run/motion.pid. Default is not defined. Pid file is only created when Motion is
started in daemon mode.


CONFIG FILE OPTIONS
These are the options that can be used in the config file. They are overridden by the commandline! All number values are integer numbers (no deci Äê
mals allowed). Boolean options can be on or off (values "1", "yes" and "on" all means true and any other value means false).


auto_brightness boolean
Values: on, off / Default: off
Let motion regulate the brightness of a video device. Only recommended for cameras without auto brightness

brightness integer
Values: 0 255 / Default: 0 (disabled)
The brightness level for the video device.

contrast boolean
Values: 0 255 / Default: 0 (disabled)
The contrast level for the video device.

control_authentication string
Values: Max 4096 characters / Default: Not defined
To protect HTTP Control by username and password, use this option for HTTP 1.1 Basic authentication. The string is specified as username:password. Do
not specify this option for no authentication. This option must be placed in motion.conf and not in a thread config file.

control_html_output boolean
Values: on, off / Default: on
Enable HTML in the answer sent back to a browser connecting to the control_port. This option must be placed in motion.conf and not in a thread config
file.

control_localhost boolean
Values: on, off / Default: on
Limits the http (html) control to the localhost. This option must be placed in motion.conf and not in a thread config file.

control_port integer
Values: 0 65535 / Default: 0 (disabled)
Sets the port number for the http (html using browser) based remote control. This option must be placed in motion.conf and not in a thread config
file.

daemon boolean
Values: on, off / Default: off
Start in daemon (background) mode and release terminal. This option must be placed in motion.conf and not in a thread config file.

despeckle string
Values: EedDl / Default: Not defined
Despeckle motion image using combinations of (E/e)rode or (D/d)ilate. And ending with optional (l)abeling.

ffmpeg_bps integer
Values: 0 9999999 / Default: 400000
Bitrate of mpegs produced by ffmpeg. Bitrate is bits per second. Default: 400000 (400kbps). Higher value mans better quality and larger files. Option
requires that ffmpeg libraries are installed.

ffmpeg_cap_motion boolean
Values: on, off / Default: off
Use ffmpeg libraries to encode motion type mpeg movies where you only see the pixels that changes.

ffmpeg_cap_new boolean
Values: on, off / Default: off
Use ffmpeg libraries to encode mpeg movies in realtime.

ffmpeg_deinterlace boolean
Values: on, off / Default: off
Use ffmpeg to deinterlace video. Necessary if you use an analog camera and see horizontal combing on moving objects in video or pictures.

ffmpeg_timelapse boolean
Values: 0 2147483647 / Default: 0 (disabled)
Create a timelapse movie saving a picture frame at the interval in seconds set by this parameter. Set it to 0 if not used.

ffmpeg_timelapse_mode discrete strings
Values: hourly, daily, weekly sunday, weekly monday, monthly, manual / Default: daily
The file rollover mode of the timelapse video.

ffmpeg_variable_bitrate integer
Values: 0, 2 31 / Default: 0 (disabled)
Enables and defines variable bitrate for the ffmpeg encoder. ffmpeg_bps is ignored if variable bitrate is enabled. Valid values: 0 (default) = fixed
bitrate defined by ffmpeg_bps, or the range 2 31 where 2 means best quality and 31 is worst.

ffmpeg_video_codec discrete strings
Values: mpeg1 (ffmpeg 0.4.8 only), mpeg4, msmpeg4, swf, flv, ffv1 / Default: mpeg4
Codec to be used by ffmpeg for the video compression. Timelapse mpegs are always made in mpeg1 format independent from this option.

framerate integer
Values: 2 100 / Default: 100 (no limit)
Maximum number of frames to be captured from the camera per second.

frequency boolean
Values: 0 999999 / Default: 0 (Not set)
The frequency to set the tuner to (kHz). Valid range: per tuner spec, default: 0 (Don't set it)

gap integer
Values: 0 2147483647 / Default: 60
Gap is 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.

height integer
Values: Device Dependent / Default: 288
The height of each frame in pixels.

hue integer
Values: 0 255 / Default: 0 (disabled)
The hue level for the video device.

input integer
Values: 0 7, 8 = disabled / Default: 8 (disabled)
Input channel to use expressed as an integer number starting from 0. Should normally be set to 1 for video/TV cards, and 8 for USB cameras.

jpeg_filename string
Values: Max 4095 characters / Default: %v %Y%m%d%H%M%S %q
File path for motion triggered images (jpeg or ppm) relative to target_dir. Value 'preview' makes a jpeg filename with the same name body as the asso Äê
ciated saved mpeg movie file.

lightswitch integer
Values: 0 100 / Default: 0 (disabled)
Ignore sudden massive light intensity changes given as a percentage of the picture area that changed intensity.

locate boolean
Values: on, off, preview / Default: off
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 mpeg
movie.

low_cpu integer
Values: 0 100 / Default: 0 (disabled)
When this option is not zero motion will be in a low cpu mode while not detecting motion. In low cpu mode Motion reduces the framerate to the value
given for this option. Value zero means disabled.

mask_file string
Values: Max 4095 characters / Default: Not defined
PGM file to use as a sensitivity mask. This picture MUST have the same width and height as the frames being captured and be in binary format.

max_mpeg_time integer
Values: 0 (infinite) 2147483647 / Default: 3600
The maximum length of an mpeg movie in seconds. Set this to zero for unlimited length.

minimum_frame_time integer
Values: 0 2147483647 / Default: 0
Minimum time in seconds between the capturing picture frames from the camera. Default: 0 = disabled the capture rate is given by the camera framer Äê
ate.

minimum_motion_frames boolean
Values: 1 1000s / Default: 1
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.

motion_video_pipe string
Values: Max 4095 characters / Default: Not defined
The video4linux video loopback input device for motion images. If a particular pipe is to be used then use the device filename of this pipe, if a dash
' ' is given motion will use /proc/video/vloopback/vloopbacks to locate a free pipe. Default: not set

movie_filename string
Values: Max 4095 characters / Default: %v %Y%m%d%H%M%S
File path for motion triggered ffmpeg movies (mpeg) relative to target_dir. This was previously called ffmpeg_filename.

mysql_db string
Values: Max 4095 characters / Default: Not defined
Name of the MySQL database.

mysql_host string
Values: Max 4095 characters / Default: localhost
IP address or domain name for the MySQL server. Use "localhost" if motion and MySQL runs on the same server.

mysql_password string
Values: Max 4095 characters / Default: Not defined
The MySQL password.

mysql_user string
Values: Max 4095 characters / Default: Not defined
The MySQL user name.

netcam_proxy string
Values: Max 4095 characters / Default: Not defined
URL to use for a netcam proxy server, if required. The syntax is http://myproxy:portnumber

netcam_url string
Values: Max 4095 characters / Default: Not defined
Specify an url to a downloadable jpeg file or raw mjpeg stream to use as input device. Such as an AXIS 2100 network camera.

netcam_userpass string
Values: Max 4095 characters / Default: Not defined
For network cameras protected by username and password, use this option for HTTP 1.1 Basic authentication. The string is specified as username:pass Äê
word. Do not specify this option for no authentication.

night_compensate boolean
Values: on, off / Default: off
When this option is set the noise threshold will be lowered if the picture is dark. This will improve the sensitivity in dark places. However it might
also increase the number of false alarms since most cameras also increase light sensitivity with their AGC (Automatic Gain Control) and this will
increase noise.

noise_level integer
Values: 1 255 / Default: 32
The noise level is used as a threshold for distinguishing between noise and motion.

noise_tune boolean
Values: on, off / Default: on
Activates the automatic tuning of noise level.

norm discrete strings
Values: 0 (PAL), 1 (NTSC), 2 (SECAM), 3 (PAL NC no colour) / Default: 0 (PAL)
Select the norm of the video device. Values: 0 (PAL), 1 (NTSC), 2 (SECAM), 3 (PAL NC no colour). Default: 0 (PAL)

on_event_end string
Values: Max 4095 characters / Default: Not defined
Command to be executed when an event ends after a period of no motion. The period of no motion is defined by option gap. You can use Conversion Speci Äê
fiers and spaces as part of the command.

on_event_start string
Values: Max 4095 characters / Default: Not defined
Command to be executed when an event starts. An event starts at first motion detected after a period of no motion defined by gap. You can use Conver Äê
sionSpecifiers and spaces as part of the command.

on_motion_detected string
Values: Max 4095 characters / Default: Not defined
Command to be executed when a motion frame is detected. You can use Conversion Specifiers and spaces as part of the command.

on_movie_end string
Values: Max 4095 characters / Default: Not defined
Command to be executed when an ffmpeg movie is closed at the end of an event. You can use Conversion Specifiers and spaces as part of the command. Use
%f for passing filename (with full path) to the command.

on_movie_start string
Values: Max 4095 characters / Default: Not defined
Command to be executed when an mpeg movie is created. You can use Conversion Specifiers and spaces as part of the command. Use %f for passing filename
(with full path) to the command.

on_picture_save string
Values: Max 4095 characters / Default: Not defined
Command to be executed when an image is saved. You can use Conversion Specifiers and spaces as part of the command. Use %f for passing filename (with
full path) to the command.

output_all boolean
Values: on, off / Default: off
Picture are saved continuously as if motion was detected all the time.

output_motion boolean
Values: on, off / Default: off
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. Smartmask is shown in red.

output_normal discrete strings
Values: on, off, first, best / Default: on
Normal image is an image that is stored when motion is detected. It is the same image that was taken by the camera. I.e. not a motion image like
defined by output_motion. Default is that normal images are stored.

pgsql_db string
Values: Max 4095 characters / Default: Not defined
Name of the PostgreSQL database.

pgsql_host string
Values: Max 4095 characters / Default: localhost
IP address or domain name for the PostgreSQL server. Use "localhost" if motion and PostgreSQL runs on the same server.

pgsql_password string
Values: Max 4095 characters / Default: Not defined
The PostgreSQL password.

pgsql_port integer
Values: 0 65535 / Default: 5432
The PostgreSQL server port number.

pgsql_user string
Values: Max 4095 characters / Default: Not defined
The PostgreSQL user name.

post_capture integer
Values: 0 2147483647 / Default: 0 (disabled)
Specifies the number of frames to be captured after motion has been detected.

ppm boolean
Values: on, off / Default: off
Output ppm images instead of jpeg. This uses less CPU time, but causes a LOT of hard disk I/O, and it is generally slower than jpeg.

pre_capture integer
Values: 0 100s / Default: 0 (disabled)
Specifies the number of previous frames to be outputted at motion detection. Recommended range: 0 to 5, default=0. Do not use large values! Large val Äê
ues will cause Motion to skip video frames and cause unsmooth mpegs. To smooth mpegs use larger values of post_capture instead.

process_id_file string
Values: Max 4095 characters / Default: Not defined
File to store the process ID, also called pid file. Recommended value when used: /var/run/motion.pid

quality integer
Values: 1 100 / Default: 75
The quality for the jpeg images in percent.

quiet boolean
Values: on, off / Default: off
Be quiet, don't output beeps when detecting motion.

rotate discrete strings
Values: 0, 90, 180, 270 / Default: 0 (not rotated)
Rotate image the given number of degrees. The rotation affects all saved images as well as mpeg movies.

roundrobin_frames integer
Values: 1 2147483647 / Default: 1
Specifies the number of frames to capture before switching inputs, this way also slow switching (e.g. every second) is possible.

roundrobin_skip integer
Values: 1 2147483647 / Default: 1
Specifies the number of frames to skip after a switch. (1 if you are feeling lucky, 2 if you want to be safe).

saturation integer
Values: 0 255 / Default: 0 (disabled)
The colour saturation level for the video device.

setup_mode boolean
Values: on, off / Default: off
Run Motion in setup mode.

smart_mask_speed integer
Values: 0 10 / Default: 0 (disabled)
Slugginess of the smart mask. Default is 0 = DISABLED. 1 is slow, 10 is fast.

snapshot_filename string
Values: Max 4095 characters / Default: %v %Y%m%d%H%M%S snapshot
File path for snapshots (jpeg or ppm) relative to target_dir.

snapshot_interval integer
Values: 0 2147483647 / Default: 0 (disabled)
Make automated snapshots every 'snapshot_interval' seconds.

sql_log_image boolean
Values: on, off / Default: on
Log to the database when creating motion triggered image file.

sql_log_mpeg boolean
Values: on, off / Default: off
Log to the database when creating motion triggered mpeg file.

sql_log_snapshot boolean
Values: on, off / Default: on
Log to the database when creating a snapshot image file.

sql_log_timelapse boolean
Values: on, off / Default: off
Log to the database when creating timelapse mpeg file

sql_query string
Values: Max 4095 characters / Default: insert into security(camera, filename, frame, file_type, time_stamp, text_event) values('%t', '%f', '%q', '%n',
'%Y %m %d %T', '%C')
SQL query string that is sent to the database. The values for each field are given by using convertion specifiers

switchfilter boolean
Values: on, off / Default: off
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.

target_dir string
Values: Max 4095 characters / Default: Not defined = current working directory
Target directory for picture and movie files.

text_changes boolean
Values: on, off / Default: off
Turns the text showing changed pixels on/off.

text_double boolean
Values: on, off / Default: off
Draw characters at twice normal size on images.

text_event string
Values: Max 4095 characters / Default: %Y%m%d%H%M%S
This option defines the value of the speciel 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.

text_left string
Values: Max 4095 characters / Default: Not defined
User defined text overlayed on each in the lower left corner. Use A Z, a z, 0 9, " / ( ) @ ~


Related Topics

Apt Get Commands