since I would like to start working on learning more about opencv and machine vision, I am trying to get my ps3eye working with OF. I am running Ubuntu 11.04, 64 bits and using OF v0062_linux64_FAT.
The camera works fine with guvcview. Though I cannot disable auto-iris (which I would really like to). However, both running examples and using own apps, the application compiles but hangs at startup, hangs for about 10 seconds, then returns a segmentation fault ('Process returned 139 (0x8B). The red led on the camera does light up during these 10 seconds, so something is going on.
Has anyone been succesful using ps3eye in this way? Should I use different drivers or so?
Maybe it is worthwhile noting that camera capure does work in Processing, using the gsvideo lib. However, I wish to explore OF further…
Any help appreciated. Bye, Menno.
it should work with OF, ive been using it recently and had no problem. last time i tested 0062 didn’t worked with ubuntu 11.04, did you changed something to make it work? perhaps try with 007, the version in github
I experienced problems with ps3 too…will try it today evening! if you don’t get a response from me, post again!
ok its just a problem with the example code.
comment line 10 in movieGrabberExample/src/testApp.cpp:
and it should work.
tested it on ubuntu 11.04 64bit, 2.6.38-10-generic with recent master branch from github
can you confirm this?
That’s strange. We had several projects projects on linux that used the PS3 camera and never had any problems. We even used two of them within the same application. we even had a 10 meter usb extension cable… Apps ran on ubuntu 10.10 and ubuntu 11.04. 32 and 64 bit, I think…
haha ok. I just tried the movieGrabberExmaple and as it turns out, I get the following error: couldnt create pipeline: could not link video_source to ffmpegcsp0 even with idGrabber.setDeviceID(1); commented out…
perhaps some update to gstreamer has broken this, don’t have the ps3 with me so can’t really test
OF 00062 runs fine here, and using a cheap Logitech cam also the movieGrabber works fine (except for the inverted image which is distorted, keeps flickering).
The OF version from github has no codeblock project files. I tried installing the ofProject.py, which kind of failed, still it created a project, but also vcxproj. I do not know how to manually create a OF codeblocks project (hence i posted this in the beginners thread :-). The wizard for Codeblocks gives me: “The wizard is missing the following mandatory wizard page: Project path selection Execution aborted…”
The verbose for movieGrabber in 0062 gives me this:
OF_NOTICE: Probing devices with udev...
OF_NOTICE: Found device 1415:2000, getting capabilities...
OF_NOTICE: Detected v4l2 device: USB Camera-B4.09.24.1
OF_NOTICE: Driver: ov534, version: 134144
OF_NOTICE: Capabilites: 0x05000001
Process returned 139 (0x8B) execution time : 10.332 s
Maybe it has to do with the driver. However, the same driver does work with guvcview…
Processing neither works with the ps3eye now. I cannot however decipher Java errors.
EDIT: processing does work, made a syntax mistake…
Don’t really know what to make of this…
ok if you have cloned Of from github, then run install_dependencies.sh for installing missing packages and compiling OF. after this you can run
in the scripts/linux folder to create codeblocks projectfiles for all examples.
did you install something custom? gstreamer or something like this?
@arturo: full updated ubuntu 11.04 works for me. but archlinux does not with following error:
OF: OF_LOG_NOTICE: ofGstUtils: selected device: USB Camera-B4.04.27.1
OF: OF_LOG_NOTICE: ofGstUtils: selected format: 320x240 video/x-raw-yuv framerate: 125/1
OF: OF_LOG_NOTICE: gstreamer pipeline: v4l2src name=video_source device=/dev/video0 ! video/x-raw-yuv,width=320,height=240,framerate=125/1 ! ffmpegcolorspace ! appsink name=sink caps=“video/x-raw-rgb, width=320, height=240, depth=24, bpp=24”
OF: OF_LOG_ERROR: couldnt create pipeline: could not link video_source to ffmpegcsp0
gst-launch-0.10 v4l2src name=video_source device=/dev/video0 ! video/x-raw-yuv,width=320,height=240,framerate=125/1 ! ffmpegcolorspace ! xvimagesink
works (changed only the framerate):
gst-launch-0.10 v4l2src name=video_source device=/dev/video0 ! video/x-raw-yuv,width=320,height=240,framerate=30/1 ! ffmpegcolorspace ! xvimagesink
tried to change framerate in the example app with
but this doesn’t set framerate to this. did we loose this functionality with an update?
Thank you, I got the OF version from Github up and running.
However, the results are identical: the video (though not inverted video) works with the small logitech webcam, but hangs and crashes after 10 seconds with the ps3eye. That is the same for for example movieGrabber or openCV apps.
I am wondering if it has to do with some particular aspect of my system, however the verbose doesn’t give me much info. Maybe tomorrow I have time to try on another, 32bits, ubuntu system.
a fast workaround, if you have a tight schedule:
camWidth = 640; // try to grab at this size.
camHeight = 480;
because ps3eye can capture this size only with 60fps max, which works with recent OF.
this works for me even on archlinux, maybe it helps you too.
The schedule is not too tight
Tried to change the resolution, to no avail. I commented everything out, to find out where things go wrong. The app hangs when calling the initGrabber method of the ofVideoGrabber object, so it never gets beyong the setup method of testApp, into update or draw.
I tried combining both 320x240 and 640x480 with various framerates (setDesiredFramerate method), but the app keeps quiting with a segmentation fault after 10 seconds (red led on pd3 eye is lit during this time).
I tried your gst-launch commands in bash; i get the same error with the first command, in Ubuntu 11.04. With the other command, the ps3 works fine. Error after the first command:
WARNING: erroneous pipeline: could not link video_source to ffmpegcsp0
Just did a quick test as well. Ubuntu 11.04 64bit.
Using the video size of 640x480 worked for me. I had the video running for about 5 minutes and no crash.
ok this is kind of akward. i fixed my problem: plugging in the ps3eye in an onboard usb port instead of a port on a hub did the trick… beginner’s mistake thanks for the help!
Hello, I have similar problems with OF and webcams.
- on my laptop computer with Ubuntu 11.04 (64 and 32bits) ps3eye and other webcams work OK.
- on my stationary PC with Ubuntu 11.04 (32bits) ps3eye and few other webcams don’t work with movieGrabberExample, but do work with Cheese and Luvcview:
- one very cheap webcam works with both Cheese/Luvcview and movieGrabber
- few other (e.g. Creative) webcams work with Cheese but 95% of trials get segmentation fault in movieGrabber
- ps3eye works with Cheese but always gets segmentation fault in movieGrabber.
The webcams were connected directly into onboard USB ports (without any hub).
The OF was downloaded from github on Tuesday.
Is there anything I could try to make it work (especially the ps3eye)?
Does anybody have any news about this? We’re experiencing a different kind of problem. The PS3 cam just takes one image in the beginning and then won’t update anymore… Resolution 640x480, various framerates and usb ports.
I didn’t get deep in this. but you can try to alter the gst pipeline and get rid of the deprecated ffmpegcolorspace module.
Here I have not had any firther trouble with the ps3eye. It works well under Ubuntu 11.04 64bits, also on Windows 7 Home Premium 64bits with the CL driver.
@underdoeg: does the ps3eye work for you under guvcview? If yes, are you sure this not a problem inside the update() or draw() methods of your app?
no, it turned out that in this case, there was something wrong with the camera itself. Replaced it did some plugging in and out and then it worked…
But I think there is something off with the gst pipeline. Because it doesn’t support all the resolution it should. Still, when you know the limitations, I can confirm that the ps3 camera is fully production ready on ubuntu