List,
I'm having a peculiar problem accessing my webcam within PD using PDP. The camera works fine outwith PD (using mplayer, for example). My camera is a Logitech Quickcam Pro 4000 and I'm running PDP 0.12.2 (from the sourceforge CVS - I had the same problem with 0.13), PD 0.38-4 and the most recent pwc driver (10.0.7a) on a 2.6.12 kernel.
The symptoms: as soon as I try to open the device from within PD and send the output to pdp_xv, top says PD is using 60% of the cpu, an xv window is created but is black. I get the following message in the PD window:
pdp_xvideo: grabbed port 64 on adaptor 0 pdp_v4l: no device opened pdp_v4l: attempting auto open pdp_v4l: opening /dev/video0 pdp_v4l: cap: name Logitech QuickCam Pro 4000 type 1 channels 1 maxw 640 maxh 480 minw 160 minh 120 pdp_v4l: picture: brightness 36864 depth 24 palette 15 pdp_v4l: channel 0 name Webcam type 2 flags 0 pdp_v4l: switched to channel 0 pdp_v4l: buffer size 925696, frames 2, offset 0 462848 pdp_v4l: using VIDEO_PALETTE_YUV420P pdp_v4l: frame 0 0, format 15, width 320, height 240 pdp_v4l: Opened video connection (320x240) pdp_v4l: detected pwc pdp_v4l: camera framerate set to 27 fps
This all looks pretty good does it not?! PD CPU usage stays at 60% until I quit the patch. When I use mplayer to access the device at the same resolution and fps (320x240 @ 27fps), it uses about the same amount of CPU. (I'm using a 600mhz machine).
But, dmesg shows that my webcam driver was giving the following output:
pwc set_video_mode(320x240 @ 27, palette 15). pwc decode_size = 3. pwc Using alternate setting 6. pwc frame_size=31800, vframes=27, vsize=3, vsnapshot=0, vbandlength=530 pwc Frame buffer underflow (31808 bytes); discarded. pwc Frame buffer underflow (4 bytes); discarded. pwc Frame buffer underflow (29692 bytes); discarded. pwc Frame buffer underflow (15520 bytes); discarded. pwc Frame buffer underflow (31808 bytes); discarded. pwc Frame buffer underflow (4 bytes); discarded. ... [and so on while the patch is running, I guess] ... pwc Frame buffer underflow (16205 bytes); discarded. pwc Closing video device: 2424 frames received, dumped 0 frames, 180 frames with errors.
I don't get these errors when accessing the device using mplayer.
So - I think the problem lies with pdp_xv. It outputs video from pdp_noise fine, but only if I have not yet tried to output pdp_v4l in that session. pdp_glx, does produce output from the camera but increases my cpu usage to 100% and makes the system extremely unresponsive.
Any ideas?! I hope that this is enough information for someone to have an idea about what's going wrong. Any help would be much appreciated!
Cheers,
Andrew.
-- Andrew Cavers andy@mution.com www.mution.com
Hi Andrew,
I've always had bad luck with the reverse-engineered PWC drivers + PDP. Perhaps you could try the USB-PWCX binary drivers from Phillips and see if they work better?
http://www.smcc.demon.nl/webcam/
good luck, d.
Derek,
Thanks for the tip - that makes sense actually as I previously had the webcam working with PD when I was using a 2.4 kernel. I can't remember, but I suspect this was with the old PWC driver.
I'll try that this evening and report back!
Andrew.
On 7/5/05, derek holzer derek@x-i.net wrote:
Hi Andrew,
I've always had bad luck with the reverse-engineered PWC drivers + PDP. Perhaps you could try the USB-PWCX binary drivers from Phillips and see if they work better?
http://www.smcc.demon.nl/webcam/
good luck, d.
-- derek holzer ::: http://www.umatic.nl ---Oblique Strategy # 184: "Where is the edge?"
Ok, I looked at installing the old PWC/PWCX driver last night. Only problem is that as the PWCX driver is closed-source, there are only versions for a couple of specific kernels. Unsurprisingly, 2.6.12 is not one of them. I can force the module to load even on this kenel (can't I?), but will it still work? I can try that.
But ideally, i'd like to get the camera working with the latest reverse-engineered drivers. I know very little about these things, but it makes sense to me that the problem lies in the fact that PDP forces the camera to run at 320x240 @27fps. I only want 160x120 @ 10/15 fps (I have a slow CPU and I want it to be doing lots of other things at the same time). Apparently, PDP has some "extra features" for webcams using PWC but as far as I can tell all it does is lock the camera to this resolution and frame rate...
I know nothing about c programming at all, but I'm considering poking around in the PDP source code and trying to disable all the PWC specfic stuff (by commenting it out?) and then recompiling. Is this a really stupid idea?! Probably.
Opinions on this approach would be appreciated before I try it!
Andrew.
On 7/5/05, Andrew Cavers andrew.cavers@gmail.com wrote:
Derek,
Thanks for the tip - that makes sense actually as I previously had the webcam working with PD when I was using a 2.4 kernel. I can't remember, but I suspect this was with the old PWC driver.
I'll try that this evening and report back!
Andrew.
On 7/5/05, derek holzer derek@x-i.net wrote:
Hi Andrew,
I've always had bad luck with the reverse-engineered PWC drivers + PDP. Perhaps you could try the USB-PWCX binary drivers from Phillips and see if they work better?
http://www.smcc.demon.nl/webcam/
good luck, d.
-- derek holzer ::: http://www.umatic.nl ---Oblique Strategy # 184: "Where is the edge?"
--
Andrew Cavers andy@mution.com www.mution.com
Ok - problem solved. Here's what I did. It should be of use to other users of PDP with PWC-based webcams too.
http://zwizwa.fartit.com/pd/pdp/pdp-0.12.4.tar.gz
188-247 and 488-489.
height. I don't think you'll need to change this but I only want to use 160x120.
My Logitech Quickcam Pro 4000 works like a dream now with the most recent reverse-engineered open source PWC driver (10.0.7a) from http://www.saillard.org/linux/pwc/
It seems like the problem was that PDP was using very specific features from the old pwc/pwcx driver that are no longer compatible with the new reverse-engineered driver. Is Tom still updating PDP? I think that this should be changed in the next release, or at least commented on in the readme.
Anyway, hope this helps some people.
Andrew.
On 7/6/05, Andrew Cavers andrew.cavers@gmail.com wrote:
Ok, I looked at installing the old PWC/PWCX driver last night. Only problem is that as the PWCX driver is closed-source, there are only versions for a couple of specific kernels. Unsurprisingly, 2.6.12 is not one of them. I can force the module to load even on this kenel (can't I?), but will it still work? I can try that.
But ideally, i'd like to get the camera working with the latest reverse-engineered drivers. I know very little about these things, but it makes sense to me that the problem lies in the fact that PDP forces the camera to run at 320x240 @27fps. I only want 160x120 @ 10/15 fps (I have a slow CPU and I want it to be doing lots of other things at the same time). Apparently, PDP has some "extra features" for webcams using PWC but as far as I can tell all it does is lock the camera to this resolution and frame rate...
I know nothing about c programming at all, but I'm considering poking around in the PDP source code and trying to disable all the PWC specfic stuff (by commenting it out?) and then recompiling. Is this a really stupid idea?! Probably.
Opinions on this approach would be appreciated before I try it!
Andrew.
On 7/5/05, Andrew Cavers andrew.cavers@gmail.com wrote:
Derek,
Thanks for the tip - that makes sense actually as I previously had the webcam working with PD when I was using a 2.4 kernel. I can't remember, but I suspect this was with the old PWC driver.
I'll try that this evening and report back!
Andrew.
On 7/5/05, derek holzer derek@x-i.net wrote:
Hi Andrew,
I've always had bad luck with the reverse-engineered PWC drivers + PDP. Perhaps you could try the USB-PWCX binary drivers from Phillips and see if they work better?
http://www.smcc.demon.nl/webcam/
good luck, d.
-- derek holzer ::: http://www.umatic.nl ---Oblique Strategy # 184: "Where is the edge?"
--
Andrew Cavers andy@mution.com www.mution.com
--
Andrew Cavers andy@mution.com www.mution.com