Features
Basler pilot 187
11.12.2Gain Auto
Gain Auto is an auto function and the "automatic" counterpart of the manual gain feature. The gain
auto function automatically carries out a Gain Raw (All) adjustment. When the gain auto function is
operational, the Gain Raw (All) parameter value is automatically adjusted within set limits, until a
target average gray value for the pixel data from Auto Function AOI1 is reached. Automatic
adjustments for Gain Raw Tap 1 and Gain Raw Tap 2 are not available.
The gain auto function uses Auto Function AOI1 and can be operated in the "once" and continuous"
modes of operation.
If Auto Function AOI1 does not overlap the Image AOI (see the "Auto Function AOI" section) the
pixel data from Auto Function AOI1 will not be used to control the image brightness. Instead, the
current manual setting of the Gain Raw parameter value will control the image brightness.
When the gain auto function is used, the exposure auto function can be used at the same time. In
this case, however, you must also set the auto function profile feature.
For more information about gain, see Section 11.1 on page 149.
For more information about the auto function profile feature, see Section 11.12.4 on page 191.
To use the gain auto function, perform the following steps:
1. Select Auto Function AOI1.
2. Set the postion and size of Auto Function AOI1.
3. Set the lower and upper limits for the Gain Raw (All) parameter value.
4. Set the target average gray value.
5. If necessary, set the auto function profile.
6. Enable the gain auto function by setting it to "once" or "continuous". You must choose the
"continuous" setting when using the auto function profile.
The currently settable limits for the Auto Gain Raw parameter value depend on the current pixel
data format, on the current settings for binning, and on whether or not the Gain Raw parameter
limits for the manually set gain feature are disabled.
The target average gray value may range from 0 (black) to 255 (white). Note that this range of
numbers applies to 8 bit and to 16 bit (12 bit effective) output modes. Accordingly, also for 16 bit
output modes, black is represented by 0 and white by 255.
You can carry out steps 1 to 6 from within your application software by using the pylon API. The
following code snippets illustrate using the API to set the parameter values:
Selecting and setting Auto Function AOI1
Setting the limits for the Auto Gain Raw parameter value. The currently accessible minimum
and maximum parameter values are chosen as examples
Setting the target average gray value. A medium gray value is chosen as an example
Enabling the gain auto function and selecting, for example, the "once" mode of operation