User`s manual

AW00049313000 Standard Features
Basler runner 195
Creating a Shading Set and Uploading It to the Camera
To create a user shading set file and to upload it to the camera, you must take the steps listed below.
We strongly recommend that you read through all of the steps and read all of the other information
in this section before you attempt to do shading correction.
1. Adjust the lighting, optics, line rate, exposure time control mode, exposure time, gain, and
camera temperature as you would for normal operation.
2. Place a uniform white target in the field of view of the camera.
3. Set the camera’s X Offset and Width parameters so that the entire width of the sensor lines will
be used during frame acquisition.
4. Perform several frame acquisitions and examine the pixel values returned from the camera.
The pixel values for the brightest pixels in each line should be about 90 to 95 % of maximum
(i.e., if the camera is set for 8 bit output, the pixels should be from 90 to 95 % of 255).
a. If the values for the brightest pixels are at 90 to 95 % of maximum, go on to step 5.
b. If the values for the brightest pixels are not at 90 to 95 % of the maximum, adjust your
lighting and/or lens aperture to achieve 90 to 95%
c. If you can not achieve 90 to 95 % output by adjusting the lighting and/or lens aperture, then
adjust the gain settings to achieve the correct output.
5. Perform several frame acquisitions and examine the pixel values returned from the camera. In
each line, the values for the darkest pixels must be greater than 1/4 of the values for the
brightest pixels. (If the values for the darkest pixels are less than 1/4 of the values for the
brightest, the camera will not be able to fully correct for shading variations.)
a. If the values for the darkest pixels are greater than 1/4 of the values for the brightest, go on
to step 6.
b. If the values for the darkest pixels are less than 1/4 of the values for the brightest pixels, it
usually indicates extreme variations in lighting or poor quality optics. Make corrections as
required.
6. Capture a frame that contains approximately 60 line acquisitions.
7. Using the pixel data from the acquired frame, carry out the following routine for each line of the
sensor’s pixels:
a. In the line with the averaged pixel values, find the average value for each pixel in the
captured lines (For example, if you captured 60 lines, add the 60 pixel 0 values together
The steps below are intended to give you the basic knowledge needed to create
a shading set and to upload it to the camera. A code sample that includes the
complete details of how to create a shading set file, how to upload the file to
your camera, and how to enable and configure shading correction on a
runner camera is included with the Basler pylon SDK.
The procedure below assumes that a sensor with three lines of pixels is present
as applies to runner color cameras. However, the procedure applies equally to
runner mono cameras where only one line of pixels is present.