Setting Camera Exposure on Jetson TX1

Hey CD,

We hooked up some Microsoft Lifecams to our jetson and when tracking for the lit LED tape, the HSV threshold would get everything that is super bright, including the surrounding areas of the tape.

I was wondering how to change the exposure of the camera to properly track the tape. I would assume I need cscore but we are using C++ on a Jetson.

Thanks,
Reset Robotics

cscore is written in C++, and has great support for this sort of thing.

Failing that, you can use v4l2-ctl to do it:


v4l2-ctl -c exposure_auto=1 -c exposure_absolute=10

Note that the lifecam is picky about exposure values, so if you pick the wrong ones then it’ll ignore what you told it.

According to this thread https://www.chiefdelphi.com/forums/showthread.php?t=155714

The jetson can’t compiler cscore because its a aarch64 device.
Is there a special way I have to do it or should I just try using v4l2-ctl.

Thanks.

Use v4l2-ctl, we are using it and it’s working very well.

Do I need to install something on the Jetson for v4l2-ctl? Also can it stream video back to the Driver Station? How would I integrate the v4l2-ctl in my C++ opencv code?

Thanks

Yep, you need to install it (http://www.techytalk.info/webcam-settings-control-ubuntu-fedora-linux-operating-system-cli/). We haven’t really worked much on getting a video stream back to the DS yet.

To integrate it into C++, here’s an example of what we did:

system("v4l2-ctl -d /dev/video2 -c exposure_auto=1 -c exposure_absolute=5 -c brightness=30");

Hope this helps!