DGoldDragon28
30-01-2016, 14:28
Using the LifeCam-3000, we are attempting to send a feed to the SmartDashboard. To do this, we grab from it using the IMAQdx methods of com.ni.vision.NIVision. We also need to alter the exposure of the camera, so added the line: (new USBCamera("cam0")).setExposureManual(20);
The issue is that using both on the same camera leads to the following error:
ERROR Unhandled exception: VisionException [com.ni.vision.VisionException: IMAQdxError: -1074360310: Camera is already in use.] at
[com.ni.vision.NIVision._IMAQdxOpenCamera(Native Method),
com.ni.vision.NIVision.IMAQdxOpenCamera(NIVision.j ava:30334),
edu.wpi.first.wpilibj.vision.USBCamera.openCamera( USBCamera.java:72),
edu.wpi.first.wpilibj.vision.USBCamera.<init>(USBCamera.java:63),
org.usfirst.frc.team1719.robot.Robot.robotInit(Rob ot.java:78),
edu.wpi.first.wpilibj.IterativeRobot.startCompetit ion(IterativeRobot.java:72),
edu.wpi.first.wpilibj.RobotBase.main(RobotBase.jav a:241)]
WARNING: Robots don't quit!
There is no way that we found to use the IMAQdx session to change the exposure, so we ask here for aid.
The issue is that using both on the same camera leads to the following error:
ERROR Unhandled exception: VisionException [com.ni.vision.VisionException: IMAQdxError: -1074360310: Camera is already in use.] at
[com.ni.vision.NIVision._IMAQdxOpenCamera(Native Method),
com.ni.vision.NIVision.IMAQdxOpenCamera(NIVision.j ava:30334),
edu.wpi.first.wpilibj.vision.USBCamera.openCamera( USBCamera.java:72),
edu.wpi.first.wpilibj.vision.USBCamera.<init>(USBCamera.java:63),
org.usfirst.frc.team1719.robot.Robot.robotInit(Rob ot.java:78),
edu.wpi.first.wpilibj.IterativeRobot.startCompetit ion(IterativeRobot.java:72),
edu.wpi.first.wpilibj.RobotBase.main(RobotBase.jav a:241)]
WARNING: Robots don't quit!
There is no way that we found to use the IMAQdx session to change the exposure, so we ask here for aid.