Download Khepera IV User Manual - K
Transcript
It is useful if you would like to change the autoexposure, hdr, autogain or
low_light parameters. You can test with the right combination of these
parameters in unloading the driver and reloading it with these parameters
in argument; example:
rmmod mt9v032
modprobe mt9v032 hdr=1
After compiling the module with bitbake, copy the file to the robot and
install it. You need to remove the kernel module before:
opkg remove --force-depends kernel-module-mt9v032
opkg install mt9v032-module_1.0-r97.6_overo.ipk
9.3.4
Changing colors levels (whitebalance)
You need the full toolchain (chapter 5.3) to change the colors levels.
For testing, modify on your computer in file:
/usr/local/khepera4-oetools/tmp/work/overo-angstrom-linux-gnueabi/
linux-omap3-2.6.34-r97/git/drivers/media/video/isp/isppreview.c
The structure ispprev_rgbtorgb contains the RGB blending, especially the
parameters RR, GG and BB with the matrix equation linking input to output
colors:
static struct ispprev_rgbtorgb
flr_rgb2rgb = {
{
// RGB-RGB Matrix gains
{RR, RG, RB },
{GR, GG, GB },
{BR, BG, BB}
},
// RGB Offset
{Rof, Gof, Bof}
};
Rout RR f
Gout GR f
B BR
out f
C code
RG f
GG f
BG f
RB f
GB f
BB f
Rin Rof f
Gin Gof f
B Bof
f
in
Equation
These parameters are integer values. They are coded in fixed-point numbers:
S12Q8 for the 9 gains and S10Q0 for the 3 offsets.
For converting the gains for the array, multiply by 256 and round the value.
For the offsets, just round the value:
Example:
RRf = 0.8 GGf = 1.0 BBf = 1.5 Roff = 10.5
=>
RR = 205 GG = 256 BB = 384 Rof = 11
By default, all the parameters are zeros except RR= 256, GG = 314 and BB =
498, which is for an incandescent light source.
Then recompile the kernel:
Khepera IV User Manual ver 1.1
73