Jump to content

NLCbanner2024.jpg.2478be509670e60c2d6efd04834b8b47.jpg

PS3 Eye - low frame rates under Linux?


furrysocks2

Recommended Posts

Because they were £1.50 each, I got a couple of PS3 Eye cameras.

I'm unable to get them to appear in my Windows VM, but guvcview seems to work well under Linux.

I've read that the frame rate can be dropped to 0.1fps for 10s exposures, but I cannot set it to anything below 15fps.

 

Does anyone know how?

Link to comment
Share on other sites

5 hours ago, Bruce Leeroy said:

You may find some info under the "Video Astronomy" section, I found this thread which mentions a 10s exposure but reportedly a bit buggy.

https://stargazerslounge.com/topic/210686-moon-with-de-bayered-ps3-eye-cam/#comment-2248885

 

Thanks.

He uses a Windows driver and his own capture tool. I've got the former, but as I can't get the camera to register in Windows, I'm stuck.

I've seen a patch online for high frame rates added to the Linux driver for 320x240 (up to 187fps!) so provided I can work out the correct values to send to the controller, I should be able to mod the driver from low 640x480 frame rates. I'll see if I can compile my own.

I didn't realise you could debayer the sensor and read raw frames - I don't think the Linux driver supports that yet, so something to look into.

 

[Edit: high frame rate patch appears to work!]

highframerate.png

Link to comment
Share on other sites

OK, so I've modified the gspca_ov534 kernel module by adding a few more frame rates - currently 5, 2.5 and 1fps. I understand it will go to 0.1fps for 10s exposures - still to nail the maths but fudged the first few new frame rates.

A quick comparison below - camera approx 1 foot from an un-illuminated wall - the top half is slightly soft on focus.

  • exposure set to max
  • auto gain control
  • first is 25fps, noisy
  • second is 5fps, much less noise
  • last is 1fps, less noise than 5fps but I also had to reduce the exposure because 0 gain was still too bright.

fps_comparison.png

 

 

For reference, 

    struct rate_s {
        u8 fps;
        u8 r11; // ov7720 CLKRC Bit[5:0] Internal clock prescaler
        u8 r0d; // ov7220 COM4 Bit[7:6] PLL frequency control
        u8 re5; // ov534 CAMERA_CLK Bit[4:0] camera clock select
    };

    ...

    static const struct rate_s rate_0[] = { /* 640x480 */
        {60, 0x01, 0xc1, 0x04},
        {50, 0x01, 0x41, 0x02},
        {40, 0x02, 0xc1, 0x04},
        {30, 0x04, 0x81, 0x02},
        {15, 0x03, 0x41, 0x04},
        {5, 0x0B, 0x41, 0x04}, // mine
        {2, 0x0B, 0x41, 0x08}, // mine
        {1, 0x1D, 0x41, 0x08}, // mine
    };

http://www.yuanxinfeng.com/upload/OV538-B88.pdf

http://www.zhopper.narod.ru/mobile/ov7720_ov7221_full.pdf

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...

Now have a Windows laptop and driver for this camera - SharpCap seems quite happy to give my 75 down to 0.1fps at 640x480. Yet to work out how to configure it to give me RAW frames but I believe others have resorted to a custom image capture apps using the CodeLab SDK.

Unlikely to pursue any further Linux driver mods, as fun as reverse engineering register values was.

Link to comment
Share on other sites

  • 8 months later...

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.