wok-6.x view motion/stuff/motion.conf @ rev 21033

updated hdparm (9.37 -> 9.58)
author Hans-G?nter Theisgen
date Mon Mar 11 13:14:36 2019 +0100 (2019-03-11)
parents
children
line source
1 # Rename this distribution example file to motion.conf
2 #
3 # This config file was generated by motion 3.2.12
6 ############################################################
7 # Daemon
8 ############################################################
10 # Start in daemon (background) mode and release terminal (default: off)
11 daemon on
13 # File to store the process ID, also called pid file. (default: not defined)
14 process_id_file /run/motion/motion.pid
16 ############################################################
17 # Basic Setup Mode
18 ############################################################
20 # Start in Setup-Mode, daemon disabled. (default: off)
21 setup_mode off
23 ###########################################################
24 # Capture device options
25 ############################################################
27 # Videodevice to be used for capturing (default /dev/video0)
28 # for FreeBSD default is /dev/bktr0
29 videodevice /dev/video0
31 # v4l2_palette allows to choose preferable palette to be use by motion
32 # to capture from those supported by your videodevice. (default: 8)
33 # E.g. if your videodevice supports both V4L2_PIX_FMT_SBGGR8 and
34 # V4L2_PIX_FMT_MJPEG then motion will by default use V4L2_PIX_FMT_MJPEG.
35 # Setting v4l2_palette to 1 forces motion to use V4L2_PIX_FMT_SBGGR8
36 # instead.
37 #
38 # Values :
39 # V4L2_PIX_FMT_SN9C10X : 0 'S910'
40 # V4L2_PIX_FMT_SBGGR8 : 1 'BA81'
41 # V4L2_PIX_FMT_MJPEG : 2 'MJPEG'
42 # V4L2_PIX_FMT_JPEG : 3 'JPEG'
43 # V4L2_PIX_FMT_RGB24 : 4 'RGB3'
44 # V4L2_PIX_FMT_UYVY : 5 'UYVY'
45 # V4L2_PIX_FMT_YUYV : 6 'YUYV'
46 # V4L2_PIX_FMT_YUV422P : 7 '422P'
47 # V4L2_PIX_FMT_YUV420 : 8 'YU12'
48 v4l2_palette 8
50 # Tuner device to be used for capturing using tuner as source (default /dev/tuner0)
51 # This is ONLY used for FreeBSD. Leave it commented out for Linux
52 ; tunerdevice /dev/tuner0
54 # The video input to be used (default: 8)
55 # Should normally be set to 0 or 1 for video/TV cards, and 8 for USB cameras
56 input 8
58 # The video norm to use (only for video capture and TV tuner cards)
59 # Values: 0 (PAL), 1 (NTSC), 2 (SECAM), 3 (PAL NC no colour). Default: 0 (PAL)
60 norm 0
62 # The frequency to set the tuner to (kHz) (only for TV tuner cards) (default: 0)
63 frequency 0
65 # Rotate image this number of degrees. The rotation affects all saved images as
66 # well as mpeg movies. Valid values: 0 (default = no rotation), 90, 180 and 270.
67 rotate 0
69 # Image width (pixels). Valid range: Camera dependent, default: 352
70 width 320
72 # Image height (pixels). Valid range: Camera dependent, default: 288
73 height 240
75 # Maximum number of frames to be captured per second.
76 # Valid range: 2-100. Default: 100 (almost no limit).
77 framerate 2
79 # Minimum time in seconds between capturing picture frames from the camera.
80 # Default: 0 = disabled - the capture rate is given by the camera framerate.
81 # This option is used when you want to capture images at a rate lower than 2 per second.
82 minimum_frame_time 0
84 # URL to use if you are using a network camera, size will be autodetected (incl http:// ftp:// or file:///)
85 # Must be a URL that returns single jpeg pictures or a raw mjpeg stream. Default: Not defined
86 ; netcam_url value
88 # Username and password for network camera (only if required). Default: not defined
89 # Syntax is user:password
90 ; netcam_userpass value
92 # The setting for keep-alive of network socket, should improve performance on compatible net cameras.
93 # 1.0: The historical implementation using HTTP/1.0, closing the socket after each http request.
94 # keep_alive: Use HTTP/1.0 requests with keep alive header to reuse the same connection.
95 # 1.1: Use HTTP/1.1 requests that support keep alive as default.
96 # Default: 1.0
97 ; netcam_http 1.0
99 # URL to use for a netcam proxy server, if required, e.g. "http://myproxy".
100 # If a port number other than 80 is needed, use "http://myproxy:1234".
101 # Default: not defined
102 ; netcam_proxy value
104 # Set less strict jpeg checks for network cameras with a poor/buggy firmware.
105 # Default: off
106 netcam_tolerant_check off
108 # Let motion regulate the brightness of a video device (default: off).
109 # The auto_brightness feature uses the brightness option as its target value.
110 # If brightness is zero auto_brightness will adjust to average brightness value 128.
111 # Only recommended for cameras without auto brightness
112 auto_brightness off
114 # Set the initial brightness of a video device.
115 # If auto_brightness is enabled, this value defines the average brightness level
116 # which Motion will try and adjust to.
117 # Valid range 0-255, default 0 = disabled
118 brightness 0
120 # Set the contrast of a video device.
121 # Valid range 0-255, default 0 = disabled
122 contrast 0
124 # Set the saturation of a video device.
125 # Valid range 0-255, default 0 = disabled
126 saturation 0
128 # Set the hue of a video device (NTSC feature).
129 # Valid range 0-255, default 0 = disabled
130 hue 0
133 ############################################################
134 # Round Robin (multiple inputs on same video device name)
135 ############################################################
137 # Number of frames to capture in each roundrobin step (default: 1)
138 roundrobin_frames 1
140 # Number of frames to skip before each roundrobin step (default: 1)
141 roundrobin_skip 1
143 # Try to filter out noise generated by roundrobin (default: off)
144 switchfilter off
147 ############################################################
148 # Motion Detection Settings:
149 ############################################################
151 # Threshold for number of changed pixels in an image that
152 # triggers motion detection (default: 1500)
153 threshold 1500
155 # Automatically tune the threshold down if possible (default: off)
156 threshold_tune off
158 # Noise threshold for the motion detection (default: 32)
159 noise_level 32
161 # Automatically tune the noise threshold (default: on)
162 noise_tune on
164 # Despeckle motion image using (e)rode or (d)ilate or (l)abel (Default: not defined)
165 # Recommended value is EedDl. Any combination (and number of) of E, e, d, and D is valid.
166 # (l)abeling must only be used once and the 'l' must be the last letter.
167 # Comment out to disable
168 despeckle EedDl
170 # Detect motion in predefined areas (1 - 9). Areas are numbered like that: 1 2 3
171 # A script (on_area_detected) is started immediately when motion is 4 5 6
172 # detected in one of the given areas, but only once during an event. 7 8 9
173 # One or more areas can be specified with this option. (Default: not defined)
174 ; area_detect value
176 # PGM file to use as a sensitivity mask.
177 # Full path name to. (Default: not defined)
178 ; mask_file value
180 # Dynamically create a mask file during operation (default: 0)
181 # Adjust speed of mask changes from 0 (off) to 10 (fast)
182 smart_mask_speed 0
184 # Ignore sudden massive light intensity changes given as a percentage of the picture
185 # area that changed intensity. Valid range: 0 - 100 , default: 0 = disabled
186 lightswitch 0
188 # Picture frames must contain motion at least the specified number of frames
189 # in a row before they are detected as true motion. At the default of 1, all
190 # motion is detected. Valid range: 1 to thousands, recommended 1-5
191 minimum_motion_frames 1
193 # Specifies the number of pre-captured (buffered) pictures from before motion
194 # was detected that will be output at motion detection.
195 # Recommended range: 0 to 5 (default: 0)
196 # Do not use large values! Large values will cause Motion to skip video frames and
197 # cause unsmooth mpegs. To smooth mpegs use larger values of post_capture instead.
198 pre_capture 0
200 # Number of frames to capture after motion is no longer detected (default: 0)
201 post_capture 0
203 # Gap is the seconds of no motion detection that triggers the end of an event
204 # An event is defined as a series of motion images taken within a short timeframe.
205 # Recommended value is 60 seconds (Default). The value 0 is allowed and disables
206 # events causing all Motion to be written to one single mpeg file and no pre_capture.
207 gap 60
209 # Maximum length in seconds of an mpeg movie
210 # When value is exceeded a new mpeg file is created. (Default: 0 = infinite)
211 max_mpeg_time 0
213 # Always save images even if there was no motion (default: off)
214 output_all off
217 ############################################################
218 # Image File Output
219 ############################################################
221 # Output 'normal' pictures when motion is detected (default: on)
222 # Valid values: on, off, first, best, center
223 # When set to 'first', only the first picture of an event is saved.
224 # Picture with most motion of an event is saved when set to 'best'.
225 # Picture with motion nearest center of picture is saved when set to 'center'.
226 # Can be used as preview shot for the corresponding movie.
227 output_normal on
229 # Output pictures with only the pixels moving object (ghost images) (default: off)
230 output_motion off
232 # The quality (in percent) to be used by the jpeg compression (default: 75)
233 quality 75
235 # Output ppm images instead of jpeg (default: off)
236 ppm off
239 ############################################################
240 # FFMPEG related options
241 # Film (mpeg) file output, and deinterlacing of the video input
242 # The options movie_filename and timelapse_filename are also used
243 # by the ffmpeg feature
244 ############################################################
246 # Use ffmpeg to encode mpeg movies in realtime (default: off)
247 #ffmpeg_cap_new on
249 # Use ffmpeg to make movies with only the pixels moving
250 # object (ghost images) (default: off)
251 #ffmpeg_cap_motion off
253 # Use ffmpeg to encode a timelapse movie
254 # Default value 0 = off - else save frame every Nth second
255 #ffmpeg_timelapse 0
257 # The file rollover mode of the timelapse video
258 # Valid values: hourly, daily (default), weekly-sunday, weekly-monday, monthly, manual
259 #ffmpeg_timelapse_mode daily
261 # Bitrate to be used by the ffmpeg encoder (default: 400000)
262 # This option is ignored if ffmpeg_variable_bitrate is not 0 (disabled)
263 #ffmpeg_bps 500000
265 # Enables and defines variable bitrate for the ffmpeg encoder.
266 # ffmpeg_bps is ignored if variable bitrate is enabled.
267 # Valid values: 0 (default) = fixed bitrate defined by ffmpeg_bps,
268 # or the range 2 - 31 where 2 means best quality and 31 is worst.
269 #ffmpeg_variable_bitrate 0
271 # Codec to used by ffmpeg for the video compression.
272 # Timelapse mpegs are always made in mpeg1 format independent from this option.
273 # Supported formats are: mpeg1 (ffmpeg-0.4.8 only), mpeg4 (default), and msmpeg4.
274 # mpeg1 - gives you files with extension .mpg
275 # mpeg4 or msmpeg4 - gives you files with extension .avi
276 # msmpeg4 is recommended for use with Windows Media Player because
277 # it requires no installation of codec on the Windows client.
278 # swf - gives you a flash film with extension .swf
279 # flv - gives you a flash video with extension .flv
280 # ffv1 - FF video codec 1 for Lossless Encoding ( experimental )
281 # mov - QuickTime ( testing )
282 #ffmpeg_video_codec mpeg4
284 # Use ffmpeg to deinterlace video. Necessary if you use an analog camera
285 # and see horizontal combing on moving objects in video or pictures.
286 # (default: off)
287 #ffmpeg_deinterlace off
290 ############################################################
291 # Snapshots (Traditional Periodic Webcam File Output)
292 ############################################################
294 # Make automated snapshot every N seconds (default: 0 = disabled)
295 snapshot_interval 0
298 ############################################################
299 # Text Display
300 # %Y = year, %m = month, %d = date,
301 # %H = hour, %M = minute, %S = second, %T = HH:MM:SS,
302 # %v = event, %q = frame number, %t = thread (camera) number,
303 # %D = changed pixels, %N = noise level, \n = new line,
304 # %i and %J = width and height of motion area,
305 # %K and %L = X and Y coordinates of motion center
306 # %C = value defined by text_event - do not use with text_event!
307 # You can put quotation marks around the text to allow
308 # leading spaces
309 ############################################################
311 # Locate and draw a box around the moving object.
312 # Valid values: on, off and preview (default: off)
313 # Set to 'preview' will only draw a box in preview_shot pictures.
314 locate off
316 # Draws the timestamp using same options as C function strftime(3)
317 # Default: %Y-%m-%d\n%T = date in ISO format and time in 24 hour clock
318 # Text is placed in lower right corner
319 text_right %Y-%m-%d\n%T-%q
321 # Draw a user defined text on the images using same options as C function strftime(3)
322 # Default: Not defined = no text
323 # Text is placed in lower left corner
324 ; text_left CAMERA %t
326 # Draw the number of changed pixed on the images (default: off)
327 # Will normally be set to off except when you setup and adjust the motion settings
328 # Text is placed in upper right corner
329 text_changes off
331 # This option defines the value of the special event conversion specifier %C
332 # You can use any conversion specifier in this option except %C. Date and time
333 # values are from the timestamp of the first image in the current event.
334 # Default: %Y%m%d%H%M%S
335 # The idea is that %C can be used filenames and text_left/right for creating
336 # a unique identifier for each event.
337 text_event %Y%m%d%H%M%S
339 # Draw characters at twice normal size on images. (default: off)
340 text_double off
343 ############################################################
344 # Target Directories and filenames For Images And Films
345 # For the options snapshot_, jpeg_, mpeg_ and timelapse_filename
346 # you can use conversion specifiers
347 # %Y = year, %m = month, %d = date,
348 # %H = hour, %M = minute, %S = second,
349 # %v = event, %q = frame number, %t = thread (camera) number,
350 # %D = changed pixels, %N = noise level,
351 # %i and %J = width and height of motion area,
352 # %K and %L = X and Y coordinates of motion center
353 # %C = value defined by text_event
354 # Quotation marks round string are allowed.
355 ############################################################
357 # Target base directory for pictures and films
358 # Recommended to use absolute path. (Default: current working directory)
359 target_dir /var/lib/motion/cam1
361 # File path for snapshots (jpeg or ppm) relative to target_dir
362 # Default: %v-%Y%m%d%H%M%S-snapshot
363 # Default value is equivalent to legacy oldlayout option
364 # For Motion 3.0 compatible mode choose: %Y/%m/%d/%H/%M/%S-snapshot
365 # File extension .jpg or .ppm is automatically added so do not include this.
366 # Note: A symbolic link called lastsnap.jpg created in the target_dir will always
367 # point to the latest snapshot, unless snapshot_filename is exactly 'lastsnap'
368 snapshot_filename %v-%Y%m%d%H%M%S-snapshot
370 # File path for motion triggered images (jpeg or ppm) relative to target_dir
371 # Default: %v-%Y%m%d%H%M%S-%q
372 # Default value is equivalent to legacy oldlayout option
373 # For Motion 3.0 compatible mode choose: %Y/%m/%d/%H/%M/%S-%q
374 # File extension .jpg or .ppm is automatically added so do not include this
375 # Set to 'preview' together with best-preview feature enables special naming
376 # convention for preview shots. See motion guide for details
377 jpeg_filename %v-%Y%m%d%H%M%S-%q
379 # File path for motion triggered ffmpeg films (mpeg) relative to target_dir
380 # Default: %v-%Y%m%d%H%M%S
381 # Default value is equivalent to legacy oldlayout option
382 # For Motion 3.0 compatible mode choose: %Y/%m/%d/%H%M%S
383 # File extension .mpg or .avi is automatically added so do not include this
384 # This option was previously called ffmpeg_filename
385 #movie_filename %v-%Y%m%d%H%M%S
387 # File path for timelapse mpegs relative to target_dir
388 # Default: %Y%m%d-timelapse
389 # Default value is near equivalent to legacy oldlayout option
390 # For Motion 3.0 compatible mode choose: %Y/%m/%d-timelapse
391 # File extension .mpg is automatically added so do not include this
392 #timelapse_filename %Y%m%d-timelapse
395 ############################################################
396 # Live Webcam Server
397 ############################################################
399 # The mini-http server listens to this port for requests (default: 0 = disabled)
400 webcam_port 8081
402 # Quality of the jpeg (in percent) images produced (default: 50)
403 webcam_quality 50
405 # Output frames at 1 fps when no motion is detected and increase to the
406 # rate given by webcam_maxrate when motion is detected (default: off)
407 webcam_motion off
409 # Maximum framerate for webcam streams (default: 1)
410 webcam_maxrate 1
412 # Restrict webcam connections to localhost only (default: on)
413 webcam_localhost on
415 # Limits the number of images per connection (default: 0 = unlimited)
416 # Number can be defined by multiplying actual webcam rate by desired number of seconds
417 # Actual webcam rate is the smallest of the numbers framerate and webcam_maxrate
418 webcam_limit 0
421 ############################################################
422 # HTTP Based Control
423 ############################################################
425 # TCP/IP port for the http server to listen on (default: 0 = disabled)
426 control_port 8080
428 # Restrict control connections to localhost only (default: on)
429 control_localhost on
431 # Output for http server, select off to choose raw text plain (default: on)
432 control_html_output on
434 # Authentication for the http based control. Syntax username:password
435 # Default: not defined (Disabled)
436 ; control_authentication username:password
439 ############################################################
440 # Tracking (Pan/Tilt)
441 ############################################################
443 # Type of tracker (0=none (default), 1=stepper, 2=iomojo, 3=pwc, 4=generic, 5=uvcvideo)
444 # The generic type enables the definition of motion center and motion size to
445 # be used with the conversion specifiers for options like on_motion_detected
446 track_type 0
448 # Enable auto tracking (default: off)
449 track_auto off
451 # Serial port of motor (default: none)
452 ; track_port value
454 # Motor number for x-axis (default: 0)
455 track_motorx 0
457 # Motor number for y-axis (default: 0)
458 track_motory 0
460 # Maximum value on x-axis (default: 0)
461 track_maxx 0
463 # Maximum value on y-axis (default: 0)
464 track_maxy 0
466 # ID of an iomojo camera if used (default: 0)
467 track_iomojo_id 0
469 # Angle in degrees the camera moves per step on the X-axis
470 # with auto-track (default: 10)
471 # Currently only used with pwc type cameras
472 track_step_angle_x 10
474 # Angle in degrees the camera moves per step on the Y-axis
475 # with auto-track (default: 10)
476 # Currently only used with pwc type cameras
477 track_step_angle_y 10
479 # Delay to wait for after tracking movement as number
480 # of picture frames (default: 10)
481 track_move_wait 10
483 # Speed to set the motor to (stepper motor option) (default: 255)
484 track_speed 255
486 # Number of steps to make (stepper motor option) (default: 40)
487 track_stepsize 40
490 ############################################################
491 # External Commands, Warnings and Logging:
492 # You can use conversion specifiers for the on_xxxx commands
493 # %Y = year, %m = month, %d = date,
494 # %H = hour, %M = minute, %S = second,
495 # %v = event, %q = frame number, %t = thread (camera) number,
496 # %D = changed pixels, %N = noise level,
497 # %i and %J = width and height of motion area,
498 # %K and %L = X and Y coordinates of motion center
499 # %C = value defined by text_event
500 # %f = filename with full path
501 # %n = number indicating filetype
502 # Both %f and %n are only defined for on_picture_save,
503 # on_movie_start and on_movie_end
504 # Quotation marks round string are allowed.
505 ############################################################
507 # Do not sound beeps when detecting motion (default: on)
508 # Note: Motion never beeps when running in daemon mode.
509 quiet on
511 # Command to be executed when an event starts. (default: none)
512 # An event starts at first motion detected after a period of no motion defined by gap
513 ; on_event_start value
515 # Command to be executed when an event ends after a period of no motion
516 # (default: none). The period of no motion is defined by option gap.
517 ; on_event_end value
519 # Command to be executed when a picture (.ppm|.jpg) is saved (default: none)
520 # To give the filename as an argument to a command append it with %f
521 ; on_picture_save value
523 # Command to be executed when a motion frame is detected (default: none)
524 ; on_motion_detected value
526 # Command to be executed when motion in a predefined area is detected
527 # Check option 'area_detect'. (default: none)
528 ; on_area_detected value
530 # Command to be executed when a movie file (.mpg|.avi) is created. (default: none)
531 # To give the filename as an argument to a command append it with %f
532 ; on_movie_start value
534 # Command to be executed when a movie file (.mpg|.avi) is closed. (default: none)
535 # To give the filename as an argument to a command append it with %f
536 ; on_movie_end value
538 # Command to be executed when a camera can't be opened or if it is lost
539 # NOTE: There is situations when motion doesn't detect a lost camera!
540 # It depends on the driver, some drivers don't detect a lost camera at all
541 # Some hang the motion thread. Some even hang the PC! (default: none)
542 ; on_camera_lost value
544 ############################################################
545 # Common Options For MySQL and PostgreSQL database features.
546 # Options require the MySQL/PostgreSQL options to be active also.
547 ############################################################
549 # Log to the database when creating motion triggered image file (default: on)
550 #sql_log_image on
552 # Log to the database when creating a snapshot image file (default: on)
553 #sql_log_snapshot on
555 # Log to the database when creating motion triggered mpeg file (default: off)
556 #sql_log_mpeg off
558 # Log to the database when creating timelapse mpeg file (default: off)
559 #sql_log_timelapse off
561 # SQL query string that is sent to the database
562 # Use same conversion specifiers has for text features
563 # Additional special conversion specifiers are
564 # %n = the number representing the file_type
565 # %f = filename with full path
566 # Default value:
567 # insert into security(camera, filename, frame, file_type, time_stamp, text_event) values('%t', '%f', '%q', '%n', '%Y-%m-%d %T', '%C')
568 #sql_query insert into security(camera, filename, frame, file_type, time_stamp, event_time_stamp) values('%t', '%f', '%q', '%n', '%Y-%m-%d %T', '%C')
571 ############################################################
572 # Database Options For MySQL
573 ############################################################
575 # Mysql database to log to (default: not defined)
576 ; mysql_db value
578 # The host on which the database is located (default: localhost)
579 ; mysql_host value
581 # User account name for MySQL database (default: not defined)
582 ; mysql_user value
584 # User password for MySQL database (default: not defined)
585 ; mysql_password value
588 ############################################################
589 # Database Options For PostgreSQL
590 ############################################################
592 # PostgreSQL database to log to (default: not defined)
593 ; pgsql_db value
595 # The host on which the database is located (default: localhost)
596 ; pgsql_host value
598 # User account name for PostgreSQL database (default: not defined)
599 ; pgsql_user value
601 # User password for PostgreSQL database (default: not defined)
602 ; pgsql_password value
604 # Port on which the PostgreSQL database is located (default: 5432)
605 ; pgsql_port 5432
608 ############################################################
609 # Video Loopback Device (vloopback project)
610 ############################################################
612 # Output images to a video4linux loopback device
613 # The value '-' means next available (default: not defined)
614 ; video_pipe value
616 # Output motion images to a video4linux loopback device
617 # The value '-' means next available (default: not defined)
618 ; motion_video_pipe value
621 ##############################################################
622 # Thread config files - One for each camera.
623 # Except if only one camera - You only need this config file.
624 # If you have more than one camera you MUST define one thread
625 # config file for each camera in addition to this config file.
626 ##############################################################
628 # Remember: If you have more than one camera you must have one
629 # thread file for each camera. E.g. 2 cameras requires 3 files:
630 # This motion.conf file AND thread1.conf and thread2.conf.
631 # Only put the options that are unique to each camera in the
632 # thread config files.
633 ; thread /usr/local/etc/thread1.conf
634 ; thread /usr/local/etc/thread2.conf
635 ; thread /usr/local/etc/thread3.conf
636 ; thread /usr/local/etc/thread4.conf