Difference between revisions of "USB Surveillance Camera"

From LinuxMCE
Jump to: navigation, search
 
 
(17 intermediate revisions by 8 users not shown)
Line 1: Line 1:
To setup a USB Camera is not straightforward at all, this is because LinuxMCE currently does not and can not directly talk with the camera, however an intermediate script called Motionwrapper constantly captures from the camera, detects motion and saves all the images and AVI timelapse video.
+
{{Versioninfo}}
 +
[[Category: Cameras]]
 +
[[category: tutorials]]
  
First you must insure that you have the correct driver for your camera correctly installed. That process is beyond the scope of this document, however it should be noted thhave confired works with .43 as long as you have installed the linux-header package and you have created a at the gspca driver supports 200+ cameras. I have confired works with .43 as long as you have installed the linux-header package and you have created a symlink from /lib/modules/2.6.x.x-pluto-2-686/build to /usr/src/linux-headers-2.6.x.x-pluto-2-686. This also assumes that your device driver creates a /dev/videox file. In addtion your webcam might create a /dev/audiox using the snd-usb-audio driver.
+
LinuxMCE does not talk directly to a USB camera. Instead, an intermediate script called [[Motionwrapper]] constantly captures images from the camera, detecting motion and saving the images and AVI-timelapse videos.
  
  1. Login to LinuxMCE-admin site.
+
== Install a USB Camera==
  2. Click "Show devices in tree" at the bottom of the left-side navigation frame.
+
  3. A list of top-level devices is shown, click on the name of the device to which the camera is connected.
+
  4. A new page will load on the right frame, click "Create Child Device."
+
  5. Enter a name for the new device in the "Description" field and click "Pick Device Template"
+
  6. A new window will pop up, select "Motion Wrapper" from the dropdown "Device Template" menu.
+
  7. Window closes, a new device with the name you selected is created and you are taken to its properies page,
+
  8. The default device data "(null),1,1,8" is the correct setting for a USB camera, click "Create Child Device;" Create a child device as per steps { x - x} using the "Generic Analog Camera" template.
+
  9. The device data for the new camera device must be configured, set the "Device" as a single digit, Device Number of /dev/videoX.
+
  10. Devices are initialized when the router starts up, therefore you must go to Wizard -> Restart and click "Quick Reload Router." You will be prompted to regenerate the screens, do this so that you will have a button for the camera.
+
  
Further development needs to be done on LinuxMCE, when adding a surveillance camera the motion wrapper should at least be created, better yet motion wrapper should be included into the cameras and a clear distinction should be made between cameras for communications and cameras for security, IE: there should be an option to enable or disable motionwrapper.
+
# Login to [[LinuxMCE Admin Website]]-->Show devices in tree
 +
# A list of top-level devices is shown, click on the name of the device to which the camera is connected.
 +
# Click "Create Child Device."
 +
# Enter a name for the new device in the "Description" field and click "Pick Device Template"
 +
# Select "Motion Wrapper" from the dropdown "Device Template" menu.
 +
# A new device with the name you selected is created. You are taken to its properties page,
 +
# Make sure that on the "properties" page that the correct device data "(null),1,1,8" is displayed for the USB camera.
 +
# "Create Child Device;" Create a child device per steps { x - x} using the "Generic Analog Camera" template.
 +
# The device data for the new camera device must be configured, set the "Device" as a single digit, Device Number of /dev/videoX.
 +
# Devices are initialized when the router starts up. You must go to Wizard-->Restart-->"Quick Reload Router." You will be prompted to regenerate the screens.
 +
 
 +
==Troubleshooting==
 +
 
 +
You may have to ensure that you have the correct driver for your USB camera. That process is beyond the scope of this document. The gspca driver supports over 200 cameras however, and is included in the current linux-header package. Therefore, many cameras will work automatically.
 +
 
 +
You may need a symlink from /lib/modules/2.6.x.x-pluto-2-686/build to /usr/src/linux-headers-2.6.x.x-pluto-2-686. This assumes that your device driver creates a /dev/videox file. In addition your webcam might create a /dev/audiox using the snd-usb-audio driver.
 +
 
 +
===No Picture===
 +
 
 +
Sometimes you still get no picture with older cameras, you can try the following
 +
 
 +
Under the motion wrapper there are Motion Parameters... try changing the resolution to a lower resolution for older webcams they might not support 640x480 (default) so make it 320x240.
 +
 
 +
Also these parameters seem to help get a picture if nothing can be seen.
 +
 
 +
  minimum_motion_frames 2
 +
  snapshot_interval 2
 +
 
 +
You will have to reboot your core after this, just restarting motion didn't help

Latest revision as of 16:08, 15 July 2010

Version Status Date Updated Updated By
710 Unknown N/A N/A
810 Unknown N/A N/A
1004 Unknown N/A N/A
1204 Unknown N/A N/A
1404 Unknown N/A N/A
Usage Information

LinuxMCE does not talk directly to a USB camera. Instead, an intermediate script called Motionwrapper constantly captures images from the camera, detecting motion and saving the images and AVI-timelapse videos.

Install a USB Camera

  1. Login to LinuxMCE Admin Website-->Show devices in tree
  2. A list of top-level devices is shown, click on the name of the device to which the camera is connected.
  3. Click "Create Child Device."
  4. Enter a name for the new device in the "Description" field and click "Pick Device Template"
  5. Select "Motion Wrapper" from the dropdown "Device Template" menu.
  6. A new device with the name you selected is created. You are taken to its properties page,
  7. Make sure that on the "properties" page that the correct device data "(null),1,1,8" is displayed for the USB camera.
  8. "Create Child Device;" Create a child device per steps { x - x} using the "Generic Analog Camera" template.
  9. The device data for the new camera device must be configured, set the "Device" as a single digit, Device Number of /dev/videoX.
  10. Devices are initialized when the router starts up. You must go to Wizard-->Restart-->"Quick Reload Router." You will be prompted to regenerate the screens.

Troubleshooting

You may have to ensure that you have the correct driver for your USB camera. That process is beyond the scope of this document. The gspca driver supports over 200 cameras however, and is included in the current linux-header package. Therefore, many cameras will work automatically.

You may need a symlink from /lib/modules/2.6.x.x-pluto-2-686/build to /usr/src/linux-headers-2.6.x.x-pluto-2-686. This assumes that your device driver creates a /dev/videox file. In addition your webcam might create a /dev/audiox using the snd-usb-audio driver.

No Picture

Sometimes you still get no picture with older cameras, you can try the following

Under the motion wrapper there are Motion Parameters... try changing the resolution to a lower resolution for older webcams they might not support 640x480 (default) so make it 320x240.

Also these parameters seem to help get a picture if nothing can be seen.

 minimum_motion_frames 2
 snapshot_interval 2

You will have to reboot your core after this, just restarting motion didn't help