[PATCH v1] libipa: camera_sensor_helper: Add OV5675 black level

Kieran Bingham kieran.bingham at ideasonboard.com
Tue Jul 23 16:52:43 CEST 2024


Quoting Quentin Schulz (2024-07-23 15:25:34)
> Hi Daniel,
> 
> On 7/23/24 4:17 PM, Daniel Semkowicz wrote:
> > Add black level value for OV5675 camera.
> > According to datasheet, default value is 0x10, 10 bits width.
> > 
> > Signed-off-by: Daniel Semkowicz <dse at thaumatec.com>
> 
> Yes.... but I just checked now the init sequence in the Linux kernel 
> driver and it's different from the default :/
> 
> The 10b value is stored in two registers: 0x4002 BLC[9:8] as LSBs and 
> 0x4003 for BLC[7:0]. The default value is indeed 0x00 and 0x10, BUT the 
> driver sets 0x4003 to 0x40 so I think this needs to be 0x40? Can you see 
> if this makes things better?

Yikes,

That means we really can't even trust the datasheet values and we should
be exposing that value from the kernel through the control framework and
reading it (or setting it ?) at runtime.

--
Kieran


More information about the libcamera-devel mailing list