View Single Post
  #1   Spotlight this post!  
Unread 02-02-2017, 21:48
Justin Buist Justin Buist is offline
Registered User
FRC #4003 (TriSonics)
Team Role: Mentor
 
Join Date: Feb 2015
Rookie Year: 2015
Location: Allendale, MI
Posts: 27
Justin Buist is an unknown quantity at this point
Re: ioctl Errors and Intermediate Vision sample not working

Quote:
Originally Posted by avayner View Post
We seem to be having the same issue.

We are just trying to initialize the USB camera (using Java) by doing this:

camera = CameraServer.getInstance().startAutomaticCapture()

and we are getting this:


CS: ERROR: ioctl VIDIOC_S_EXT_CTRLS failed at UsbCameraProperty.cpp:66: Input/output error (UsbUtil.cpp:122)
Exception in thread "NTListener" VideoException [edu.wpi.cscore.VideoException: property write failed]
at edu.wpi.cscore.CameraServerJNI.setProperty(Native Method)
at edu.wpi.cscore.VideoProperty.set(VideoProperty.jav a:68)
at edu.wpi.first.wpilibj.CameraServer.lambda$new$1(Ca meraServer.java:498)
at edu.wpi.first.wpilibj.CameraServer$$Lambda$2/3326003.apply(Unknown Source)
CS: USB Camera 0: set FPS to 0
Ehhh.. take a look at that last line. You aren't trying to set your FPS rate to 0 anywhere, are you? I could see why the ioctl call would pitch a fit if you did.

On the topic of camera stream properties we had a horrible time trying to set exposure and white balance through wpilib last year. This year we've put v4l-utils on the roboRio and are calling out to the shell to set them via v4l2-ctl instead. Works much better and you can run through them on the command line and get a lot better information about what's a valid setting and what isn't. One example being wpilib says exposure goes from 0 to 100 in the JavaDocs. It doesn't... it's not even constant across cameras. The Logitechs we use go from 3 to 2047.
Reply With Quote