inspirit / PS3EYEDriver

PS3EYE Camera Driver for OSX and Windows
Other
316 stars 92 forks source link

Access violation reading location after a couple hundred of captures #16

Closed backinside closed 9 years ago

backinside commented 9 years ago

Hi,

Are you still maintaining this project? I get an Access violation reading location after a couple hundred of captures It might be a driver issue, I'm using the latest drivers from codelaboratories, and it shows similar issues Please let me know if you're still interested What information do you need? How can I help?

backinside commented 9 years ago

Using libusb fixed the issue

inspirit commented 9 years ago

i wonder how u were able to use it without libusb...

backinside commented 9 years ago

with drivers from codelaboratories :)

cboulay commented 9 years ago

libusb enumerates any USB device it sees and it will attempt to open any such device that has the same PID and VID as the PSEye, so I'm not surprised you were able to open it. I am a bit surprised you were able to transfer any data at all. I guess the fact that the libusb protocols work with the CL drivers suggests that the CL driver is probably not much more than a wrapper around a libusb driver.

The CL driver is buggy (as you experienced), Windows 32-bit only, non-free, and (from what I hear) not really supported any more. Also, the non-SDK (non-multicam) version uses registry entries to change the camera parameters. One advantage it does have is that it exposes the PS3Eye to Windows as a regular webcam so it can be used with Skype and the like.

If someone were to take it upon themselves to write a custom WinUSB (or alternative) driver that wraps PS3EYEDriver then the community could have a free web-cam-enabled PS3Eye driver for windows. But I have no idea how to write drivers.

backinside commented 9 years ago

Thanks @cboulay for the detailed explanation, I was not aware of a working PS3EYEDriver version, when I tried the codelaboratories drivers, it's definitely much higher quality, open source and working, compared to the alternatives :)

cboulay commented 9 years ago

PS3EYEDriver is a bit of a misnomer. it's not actually a driver. It's more of a convenience layer for using the libusb driver. It still does quite a bit though! PS3EYEDriver handles a lot of low-level communication with the camera that would normally be handled by a driver, only it does it through libusb. For someone that knew how to write Windows or Mac drivers, it probably wouldn't be too much work to modify PS3EYEDriver so it was an installable driver that made the camera readable from the OS as a regular webcam. Indeed, that's how the PS3Eye works in Linux. And, if someone did this, it would make the psmoveapi so much easier to maintain.

As it is now, you need to use libusb to do the actual device communication. For Windows, I presume you installed the libusb driver using Zadig?

I use the PS3EYEDriver with the psmoveapi for an Unreal Engine 4 plugin. I made a small guide for setting up the PS3Eye here.

backinside commented 9 years ago

Unfortunately I have no experience writing drivers, so I won't be any help in that any time soon But if we end up using the PSEye in our projects, I might dive into them :) Right now, this is the easiest way to get raw access to a low latency 60FPS camera, but it might not be enough for us resolution wise :) I did use your guide for setting everything up with Zadig But if I can help to test any code on Windows, let me know :) I have a bunch of Win 7 - 8 - 10 computers around :)