When I start up jAER with the ch.unizh.ini.jaer.chip.multicamera.MultiDVS128 class to merge multiple DVS cameras, it does not open the DVS cameras I have attached to my machine. I can select each individual one from the interface menu, but once one is selected the other cannot be selected, and I see only the output from the first one.
When I choose the interface, I get the following exception:
java.lang.IllegalStateException: deviceHandlePointer is not initialized
at de.ailis.usb4java.libusb.LibUsb.getConfiguration(Native Method)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2.openLibUsb(CypressFX2.java:1724)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2.open(CypressFX2.java:1637)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2DVS128HardwareInterface.open(CypressFX2DVS128HardwareInterface.java:69)
at net.sf.jaer.stereopsis.MultiCameraHardwareInterface.open(MultiCameraHardwareInterface.java:500)
at net.sf.jaer.graphics.AEViewer.openAEMonitor(AEViewer.java:1435)
at net.sf.jaer.graphics.AEViewer.access$1200(AEViewer.java:158)
at net.sf.jaer.graphics.AEViewer$ViewLoop.grabInput(AEViewer.java:1961)
at net.sf.jaer.graphics.AEViewer$ViewLoop.run(AEViewer.java:1632)
To recreate this bug, you need to redefine:
public static final int NUM_CAMERAS=2; //MultiCameraEvent.java:21
And plug in two DVS cameras. It doesn't happen with 1 DVS and the same AEChip interface. Similarly, pressing the 'Multi-Input Mode' button immediately crashes with a similar error.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
For the moment please use the UsbIo driver and that should work fine on
windows with multiple devices - been using that since 2007 in CAVIAR for
multiple devices and tested it recently.
It would also be great to get this working with libUSB but if you just
want to work right now, change the camera driver to the UsbIo driver, in
/drivers\windows/
Tobi
On 7/8/2013 8:48 PM, Danny Neil wrote:
Hi all,
When I start up jAER with the ch.unizh.ini.jaer.chip.multicamera.MultiDVS128 class to merge multiple DVS cameras, it does not open the DVS cameras I have attached to my machine. I can select each individual one from the interface menu, but once one is selected the other cannot be selected, and I see only the output from the first one.
When I choose the interface, I get the following exception:
java.lang.IllegalStateException: deviceHandlePointer is not initialized
at de.ailis.usb4java.libusb.LibUsb.getConfiguration(Native Method)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2.openLibUsb(CypressFX2.java:1724)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2.open(CypressFX2.java:1637)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2DVS128HardwareInterface.open(CypressFX2DVS128HardwareInterface.java:69)
at net.sf.jaer.stereopsis.MultiCameraHardwareInterface.open(MultiCameraHardwareInterface.java:500)
at net.sf.jaer.graphics.AEViewer.openAEMonitor(AEViewer.java:1435)
at net.sf.jaer.graphics.AEViewer.access$1200(AEViewer.java:158)
at net.sf.jaer.graphics.AEViewer$ViewLoop.grabInput(AEViewer.java:1961)
at net.sf.jaer.graphics.AEViewer$ViewLoop.run(AEViewer.java:1632)
To recreate this bug, you need to redefine:
public static final int NUM_CAMERAS=2; //MultiCameraEvent.java:21
And plug in two DVS cameras. It doesn't happen with 1 DVS and the same AEChip interface. Similarly, pressing the 'Multi-Input Mode' button immediately crashes with a similar error.
I don't have two DVSs here, so I can't test it myself right now.
But I've found something that may be the cause of the error, in any case it was a bug: when close()ing a device I didn't reset the deviceHandle to null, so if you later tried to reopen the same device, it would skip the LibUsb.open() call and crash as you've see here. I've committed a fix for that now, but it might be that you're seeing a slightly different issue.
Regarding the second exception you mention for Multi-Input mode, ticket [#2] is already tracking that particular failure, which happens when the hardwareinterface gets touched while running.
Right now multi-input/stereo with the LibUsb driver is not supported at all.
The LibUsb driver is still experimental, and will be worked on in the near future. It started out as a better alternative to the in-kernel DVS128-only driver for Linux, and it has already pretty much reached that level.
Right now I'm revamping most of the basic UI and how multiple devices are handled, and I'll update the LibUsb driver to support the new way things will happen to be done. I won't be fixing multiple device handling on the current code specifically, it would be mostly duplicate work that would quickly become obsolete once the new UI is ready, and I simply don't have the time for that.
Thanks for the responses. Annoyingly, SF didn't email me when you posted, but I figured out the same issue. Fixing the close did in fact fix the issue. Thanks!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi all,
When I start up jAER with the ch.unizh.ini.jaer.chip.multicamera.MultiDVS128 class to merge multiple DVS cameras, it does not open the DVS cameras I have attached to my machine. I can select each individual one from the interface menu, but once one is selected the other cannot be selected, and I see only the output from the first one.
When I choose the interface, I get the following exception:
java.lang.IllegalStateException: deviceHandlePointer is not initialized
at de.ailis.usb4java.libusb.LibUsb.getConfiguration(Native Method)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2.openLibUsb(CypressFX2.java:1724)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2.open(CypressFX2.java:1637)
at net.sf.jaer.hardwareinterface.usb.cypressfx2libusb.CypressFX2DVS128HardwareInterface.open(CypressFX2DVS128HardwareInterface.java:69)
at net.sf.jaer.stereopsis.MultiCameraHardwareInterface.open(MultiCameraHardwareInterface.java:500)
at net.sf.jaer.graphics.AEViewer.openAEMonitor(AEViewer.java:1435)
at net.sf.jaer.graphics.AEViewer.access$1200(AEViewer.java:158)
at net.sf.jaer.graphics.AEViewer$ViewLoop.grabInput(AEViewer.java:1961)
at net.sf.jaer.graphics.AEViewer$ViewLoop.run(AEViewer.java:1632)
To recreate this bug, you need to redefine:
public static final int NUM_CAMERAS=2; //MultiCameraEvent.java:21
And plug in two DVS cameras. It doesn't happen with 1 DVS and the same AEChip interface. Similarly, pressing the 'Multi-Input Mode' button immediately crashes with a similar error.
For the moment please use the UsbIo driver and that should work fine on
windows with multiple devices - been using that since 2007 in CAVIAR for
multiple devices and tested it recently.
It would also be great to get this working with libUSB but if you just
want to work right now, change the camera driver to the UsbIo driver, in
/drivers\windows/
Tobi
On 7/8/2013 8:48 PM, Danny Neil wrote:
--
Tobi Delbruck - office +41 44 635 3038 cell +41788757600
http://www.ini.uzh.ch/~tobi
I don't have two DVSs here, so I can't test it myself right now.
But I've found something that may be the cause of the error, in any case it was a bug: when close()ing a device I didn't reset the deviceHandle to null, so if you later tried to reopen the same device, it would skip the LibUsb.open() call and crash as you've see here. I've committed a fix for that now, but it might be that you're seeing a slightly different issue.
Regarding the second exception you mention for Multi-Input mode, ticket [#2] is already tracking that particular failure, which happens when the hardwareinterface gets touched while running.
Right now multi-input/stereo with the LibUsb driver is not supported at all.
The LibUsb driver is still experimental, and will be worked on in the near future. It started out as a better alternative to the in-kernel DVS128-only driver for Linux, and it has already pretty much reached that level.
Right now I'm revamping most of the basic UI and how multiple devices are handled, and I'll update the LibUsb driver to support the new way things will happen to be done. I won't be fixing multiple device handling on the current code specifically, it would be mostly duplicate work that would quickly become obsolete once the new UI is ready, and I simply don't have the time for that.
Related
Tickets:
#2Hi all,
Thanks for the responses. Annoyingly, SF didn't email me when you posted, but I figured out the same issue. Fixing the close did in fact fix the issue. Thanks!