Jump to content

Banner.jpg.b89429c566825f6ab32bcafbada449c9.jpg

HD Webcam Modification


George

Recommended Posts

  • Replies 151
  • Created
  • Last Reply

Well, I have spent today learning more about USB video capture than I ever expected to know, and have come up with some information...

* You're not going to get RGB24 or YUY2 capture at 30fps at 1280x720 over USB2. Peak bandwidth for USB2 is 480 Mb/s (mega *bits* per second). Reasoning : Even for YUY2, which uses 2 bytes per pixel, you would need 442 Mb/s to achieve this - the sustained bandwidth achievable is much less than this unfortunately. For 30fps @ 1280x720, MJPG is the only way to go.

* Updated drivers *are not* going to fix the low framerates people are worried about - the framerates come from the hardware, not the driver. Reasoning : I get the same framerates for each resolution in Linux as I do in Windows, and I can look at the Linux driver source code and see that it gets the frame rates available are extracted from data sent back from the device. Reasoning (2) : You can view the frame rates that the device returns using the 'UVCview.exe' program from the Windows driver development kit.

* The device *may* work better under Windows 7 than Windows XP/Vista - this is because it is (as far as I can tell) a USB Video Class 1.1 device, and version 1.1 is only supported in Windows 7. Older windows versions will treat it as a v1.0 device. Note that much of the new enhancements of USB Video Class 1.1 seem not to be available to capture programs like Amcap that use the 'DirectShow' capture API. There is a new API called Media Foundation that MS are pushing. This can (seemingly) only save captured video to m4p and wmv.

* The device's natural capture formats are YUY2 and MJPG. Reasoning : The MediaFramework API reports the 'NativeFormat' for the device to be YUY2; the MS Drivers register a 'YUYToRGB' filter. This means that there is no advantage to the RGB24 format over YUY2 on this camera in terms of image information. However, if you happen to get higher frame rates at RGB24, or you want to use the MS noise reduction feature, there isn't a problem with using RGB24 over YUY2.

* Zooming to maximum when using a smaller capture area (say 640x360) gives an identical image to a crop of the full 1280x720 capture area. Data : Test shots taken of terrestrial targets show this.

There are still some things unexplained - on my laptop, for instance, Windows and Linux produce exactly the same frame rates; as does Linux on my Desktop. Windows on my desktop machine can produce higher frame rates for some reason. I am not planning to investigate much further, since I think there are good solutions for both lunar and planetary imaging.

Lunar Imaging : Use MJPG at 1280x720 * 30fp/s. The continuous shades of grey of lunar images should work well in MJPG. If the seeing is steady enough to cope, change to YUY2 and use the maximum frame rate available.

Planetary Imaging : Use YUY2 and the largest capture area that gets you 30 fp/s (640x360 probably). Use the zoom function to bring this back up to a full resolution crop. If you have a big enough scope to more than fill this resolution with a planetary image, you can probably afford a better camera :eek:

On a different note, I've also had my IR block filter (Revealation, thanks Harrison Telescopes) and my Orion Shorty Plus barlow (thanks SCS Astro) arrive today. If the weather actually clears as predicted tomorrow I'll have another go at mars. Based on terrestrial imaging I can say that the IR block filter does help a lot with the colour balance, and seems to reduce the overall 'washout' effect I was getting before.

Hope this is helpful,

Robin

Link to comment
Share on other sites

Interesting.. and very useful.

so USB3.0/GigE or Frame buffering and dedicated frame grab PCI cards or 1394 is really the only way to go..

And you're not looking at £35 from PC world for one of those. :-)

I tested the Prosilica ICX285 cams which did 30fps last year (RAW frames at 30fps), which were IEEE1394 and GigE options, unbeatbale spec, but £2000 a pop

If someone could implement this chipset against a better board, could be in the right ballpark price wise against say the Lumenera or IS cameras

Link to comment
Share on other sites

Thanks for all that info Robin, one thing thats not adding up is Gary Honis says hes hetting 30fps AT 1280X720 NO DROPED FRAMES using the huffyuv codec, I read a thread where someone was saying to Gary that he could not be getting 30 fps at this resolution other than mjpg, but Gary was adamant that he was, so im a little lost on that, Cant remember what pc he was using though ? but think it was usb2 ?

Another thing thats interesting is your exposure explanation seems right, i havent tested it yet but the one thing that i was doing different outside, compared to the tests indoors, was exposure, and i noticed the more i slowed the exposure down the more it was dropping frames. At high mags, with a 10" scope i had no choice, so thats a downer too. need to get my 12" up and running again.

Link to comment
Share on other sites

Thanks folks, glad you found the info helpful. I forgot to mention a couple of things...

First that there is presumably some microcontroller chip in the camera that acts as an interface between the USB side and the sensor - this chip is what is determining the available frame rates, etc. It's just possible that this chip has upgradeable firmware, like some of the philips cams have.

Second, when the driver queries the camera for available controls, the camera replies 'no' to having a gain control. The sensor chip *does* have gain control (it's on the spec sheet somewhere). I suspect that the camera has some sort of built in automatic gain control.

As to 1280x720 @30fps, I just can't see it happening because of the bandwidth issue unless you have selected MJPG in the 'Video PIN' dialog. Of course, if you do this you can still select something like huffyuv2 for compression, but the image has already been MJPG'd on the way over the USB link, so there's not much point in saving it in a lossless format after that.

Anyway, on a practical side I've just been out filling my hard disk with movies of mars. I had brief period where the dreaded brightness reset problem haunted me, but after tinkering with some settings, it went away. Unfortunatly I'm not quite sure what (if anything) that I did got rid of the probem. If it happens again I'll keep a better track of things I try. Somehow, capturing at 640x360 wasn't happy - kept getting a black capture, but 800x448 @20fps (YUY2) worked nicely.

I've definitely got some better images this time, the IR block filter has given much more even colour - the polar cap is now white rather than orange like the rest of the planet! Capturing at ~f/24 using a 2x barlow I found that exposure -6 and brightness ~110 gave good results.

Off to try some initial processing now :eek:

Robin

Link to comment
Share on other sites

so USB3.0/GigE or Frame buffering and dedicated frame grab PCI cards or 1394 is really the only way to go..

And you're not looking at £35 from PC world for one of those. :-)

Like these you mean? Startech 2 Port PCI Express SuperSpeed USB3.0 Card Adapter - Ebuyer

eta: another one here http://www.overclockers.co.uk/showproduct.php?prodid=CC-000-SH&tool=3

Thanks Robin, very interesting :)

Link to comment
Share on other sites

Won't be a long wait.

Point Grey | The World's First USB 3.0 Camera

Plus it seems they will likely be cheaper than present cameras, as they won't need the compression circuitry?

Well its only a prototype so I should imagine it wont be available until the later part of the year, also looking at the specs I'll be guessing it will be expensive.

Link to comment
Share on other sites

Well its only a prototype so I should imagine it wont be available until the later part of the year, also looking at the specs I'll be guessing it will be expensive.

It was due to come to market in late 2009 or early 2010. So is getting towards a 'this is late being delivered' stage.

I imagine there'll be plenty of others in the process of producing USB 3 webcams (some might even become compatible with a firmware flash upgrade?), so it'll be like waiting for a bus - nothing for ages, then everything arrives at once. :)

Personally I'll be giving it 6 months from launch, to allow bugs and drivers to be worked out properly (not just for the webcams, but for the USB 3 interfaces also), as well as initial pricing to drop into the realm of reality.

There's going to be a lot of competition in this market, that's for sure, and with the improved bandwidth, I wouldn't be surprised to see all sorts of new features being added to the capabilities of webcams.

Cheap 3D facilities by hooking up two? I can imagine a certain unsavoury but very profitable industry throwing a lot of money in that direction . . . . .

So what could be done with a duo mount and 'two' telescopes set up side by side? Or even 'three'?

What might such an arrangement allow to be captured that possibly hasn't been accessible to see before? With different filters on each OTA?

Might need a quadcore laptop with a lot of ram and a big external USB 3 hard drive for the files though (the basics of which are already cheap enough I suppose).

Hehe, just had a thought, remember the 'Stalin Organ/Nebelwerfer' WW2 rocket launchers that were rows of tubes? Any chance of making a tracking OTA mount out of one of them? :(

eta: came across this which may be useful for someone looking to get a bit more USB cable length cheap http://www.getusb.info/diy-create-usb-dongle-to-run-usb-over-cat5-cable/

Link to comment
Share on other sites

Good points there Nick, my wish list is here, just the droping frames issue, and brightness problems mentioned, is the main faults.

I have just put some new capture software I have written on the forum in this thread : http://stargazerslounge.com/diy-astronomer/98474-new-webcam-capture-software.html

If anyone can get the brightness problem to happen consistently, I'd be interested to hear the results of them trying this software. In particular...

a) does the bug happen with SharpCap?

:) does it happen when pressing the start capture menu item or when pressing 'ok' on the 'press enter to start capturing' dialog?

With a bit of luck I'll be able to work out where the brightness goes AWOL and work around it.

cheers,

Robin

Link to comment
Share on other sites

  • 5 weeks later...

I hade a play capturing mars last night with my Lifecam and consistently got the brightness problem happening to me, although it was oddly getting dimmer rather than brighter when the capture started.

Working through what was going on, it was clear that the change was happening when the start capture button is first pressed, rather than when you confirm the start by pressing 'OK' on the 'press to start' message box. This means that the thing that is causing the change is the stopping the camera preview and re-starting it in capture mode.

My take on this is that there is an automatic gain control built into the camera (as we know, there's no manual gain control). Somehow this is linked to the value of the brightness that is set, possibly to present average users with a single control that works as a brightness control rather than a possibly confusing gain/brightness combination. I think that whenever the camera is switched from preview mode to capture mode, it re-runs its automatic gain procedure, quite possibly leading to a different actual gain to the one before the switch.

Fortunately, there's a way to work around the problem - there's nothing to stop you from adjusting the brightness while the capture is running (or while it's paused between pressing the 'start capture' button and pressing 'ok'), although some capture software may not allow it. My experiments last night showed that by doing this I could easily get back to a sensible brightness value by adjusting the value up/down as appropriate. I've now included this functionality into v1.0.8 of SharpCap (http://stargazerslounge.com/diy-astronomer/98474-new-webcam-capture-software-2.html#post1407090).

Hope this info is helpful,

Robin

Link to comment
Share on other sites

I just got an update to v3.21 of the Lifecam software (driver 3.20) when I plugged in my camera. It now seems top support 1280x720x30fps in RGB24 mode. The frame rates I can get in YUY2 if I uninstall the software are unchanged from previous driver versions.

Not sure how it manages this - 1280x720x30fps x 2bytes/pixel (YUY2 encoding) exceeds the practical 40Mbytes/s bandwidth of the USB2 bus, however the frame rate is definitely correct and noticeably better, so it's not just packing out duplicate frames. If I was being cynical I might suggest that the data is being tranferred from the camera to the PC in MJPG format and then decoded to RGB24 - not easy to tell though.

Robin

Link to comment
Share on other sites

I see that there's firmware update available too... Not sure I fancy trying it however, they seem a little vague as to what it "fixes". Still, it's potentially good to know that they are prepared to update the firmware if issues are found, but I guess it depends on how recent this firmware is?

Microsoft LifeCam Cinema Webcam Firmware Update

The download file is named CinemaFW1033_3.20.exe, do we have any idea what version of firmware comes at retail time?

Link to comment
Share on other sites

The firmware update bumped the revision of my camera from 0100 to 0105 (look in the HardwareIds item in the details of the camera device properties).

So far, I can't see any change in behaviour with the new firmware, frame rates with and without the MS drivers installed are unchanged.

Robin

Link to comment
Share on other sites

  • 4 weeks later...
Anyone? Can you use this HD webcam as a guide cam? Anyone tried it yet? :)

There's no known long exposure mod yet available for this cam so you would be limited to fairly bright stars, not much use if your target area is devoid of them.

Link to comment
Share on other sites

  • 2 months later...

Okey i`ve just trawled through the postings but i have a question which may be silly. What model Lifecam is it as i`ve found three or four different types on Google. i may well have missed it on here somewhere.:mad:

Thanks

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. By using this site, you agree to our Terms of Use.