Changing the NSLU2 Webcam Setup

I have found a way to solve the webcam bandwidth problem on my NSLU2. The physical setup is like this:

  • USB hub connected to the Disk 1 connector on the NSLU2
  • The flash memory disk connected to port 1 of the external USB hub. This leaves room for my 1-wire soil moisture sensor in port 2.
  • Webcam connected to the Disk 2 connector

Now the USB devices look like this:

$ lsusb
Bus 003 Device 003: ID 05a9:0511 OmniVision Technologies, Inc. OV511 Webcam
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 004: ID 1307:0165 Transcend Information, Inc. 2GB/4GB Flash Drive
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 0409:005a NEC Corp. HighSpeed Hub

The difference is that the webcam jumped to bus 003 and now there is enough bandwidth for the webcam.

As a side note, bus 002 and 003 are USB 1.1 types and bus 001 is a USB 2.0 type.

Now I just need to find and configure the appropriate software packages to be able to show you some pictures from my garden.

NSLU2 Webcam Test

I’m testing another way of joining my three USB cables together. The joint is going to be placed outside so it needs some kind of weather protection. I’m considering using ordinary Ethernet cable instead, but I’m not sure what that would do to the USB signal from the webcam to the NSLU2 computer. Using an Ethernet cable I would have a single, long piece of cable instead of three short USB cables joined together.

Five pieces of heat shrink are used as primary cover for the USB wires. One thin blue piece on each of the four USB wires inside the cable, and one larger white piece on the outside:

And on top of that a piece of duct tape:

The connectors from the second and third cable is wrapped in duct tape too:

Hopefully the duct tape will keep the water out.

A preliminary test setup:

I brought my laptop outside to ease calibration of the webcam. The webcam is connected to the laptop through a USB hub:

After the calibration I brought the USB hub back in and placed it in the windowsill behind the NSLU2 computer:

A quick test of the webcam, now connected to the NSLU2, resulted in an error:

$ webcam
reading config file: /home/thomas/.webcamrc
v4l2: open /dev/video0: No space left on device
v4l2: open /dev/video0: No space left on device
v4l: open /dev/video0: No space left on device
no grabber device available

I did some research and it seems to be related to the fact that the webcam is sharing a USB bus with other devices:
$ lsusb
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 006: ID 05a9:0511 OmniVision Technologies, Inc. OV511 Webcam
Bus 001 Device 005: ID 0409:005a NEC Corp. HighSpeed Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 1307:0165 Transcend Information, Inc. 2GB/4GB Flash Drive

The webcam needs more bandwidth than it can get with other devices on the same bus.

I just need a way to force the webcam on to another USB bus, or maybe lower the bandwidth requirements of the webcam. I didn’t expect installing a webcam to be that difficult, as I’m pretty sure I had it up and running a couple of years ago.

Mounting a Webcam Outside

I want to show you what I’m doing in my garden in this very moment, and to be able to do this I’m setting up a webcam connected to my small NSLU2 computer. I have mounted the webcam in a plastic box and then mounted the box on top of a pole with a screw:

As you can tell it’s just a cheap and plain plastic box from the supermarket that I’m using as webcam cabinet:

A cable binder is securing the cable and a piece of masking tape is covering the hole I made in order to get the USB connector out:

Just to be sure that no rain will get in I have covered the hole on the outside with silicone:

And the webcam is ready for live transmission:

The USB cable to the NSLU2 computer was to short so I had to connect two USB extension cables together. I made a simple cover from a plastic bag sealed by two cable binders:

But fast forward a couple of days: My webcam suddenly stopped responding – and now I know why ;-) :

The plastic bag with cable binders turned out to be a very poor cover for the USB connectors, and the USB interface probably short circuited :-(

Hopefully the NSLU2 computer is okay – I’ll have to make a better connection to get the camera up and running.