I spent a number of hours working on getting the LifeCam HD to do what I wanted. It was easy to get it to display on the SmartDashboard, but I couldn’t get any appreciable change when I used the setBrightness() or setExposureManual() commands. I have finally figured out how to make it work and why it doesn’t normally.
It doesn’t work because the USBCamera class normalizes the exposure range to 0-100 INTEGER. The ACTUAL range is 5 - 20,000 (yes you read that right, 20 THOUSAND). This means that normalized 0 is 5, normalized 1 is actual 200. So I duplicated the USBCamera class in my own code and removed the normalization so I could write raw values. It turns out that anything above about 30 raw is way too bright. This means that the only USBCamera normalized value that would work is 0. I’m keeping my duplicate class and writing raw values. It’s a bit of a pain because I can’t pass my class references in to CameraServer, but it’s the only way to get the kind of exposure control needed.
Anybody know how to report bugs on the WPI code?