[meta-freescale] OV5640 autofocus kernel+gstreamer+Qt implementation

Nikita Yushchenko nyushchenko at dev.rtsoft.ru
Sun Oct 4 23:50:01 PDT 2015


Hi Dmitry.
Sorry missed your mail (I'm not at list)

>> Kernel patches are against imx_3.14.28_1.0.0_ga branch.
>>
>> First patch is generic mxc_v4l2_capture cleanup. Unfortunately driver
>> was quite racy and did not survive even streaming stop+start from within
>> Qt. Had to do some cleanup to mitigate that.
>>
>> Second patch contains actual implementation of focus-related v4l ioctls.
>>
>> Autofocus firmware embedded into patch was taken from
>>   http://crewrktablets.arctablet.com:8080/opendev/kernel_rockchip.git,
>>   branch rockchip-3.10-rk3288
>>   file drivers/media/video/ov5640_af_firmware.c
>> and converted to format that existing driver uses. I've tried different
>> firmwares found over the net, this one shows the best behaviour.
>>
> 
> Interesting, you seem to have better implementation of AF than
> https://github.com/boundarydevices/linux-imx6/blob/boundary-imx_3.10.53_1.1.1_ga/drivers/media/platform/mxc/capture/ov5640_mipi.c#L120

I've seen that, but it is incomplete, single AF only, no notifications, etc.

My implementation does not have manual adjustment ...  but I do not like
idea to use custom command for that, V4L has
V4L2_CID_FOCUS_ABSOLUTE / V4L2_CID_FOCUS_RELATIVE for that.


Also, I did the full stack - from Qt through gstreamer to kernel.  This
is what I believe is not yet available in opensource ... at least I was
not able find any GstPhotography implementation in the net, just
mentions that it was used in Maemo and probably is used in some closed
projects.


>> *) Legal status of AF firmware is unclear.
>>
> 
> Boundarydevices and Arrow (Wandcam) distribute the above mentioned source
> of AF firmware for long time now.
> Should not be a problem, since they already licensed it. Another question
> is if you changed it or distribute unknown Chinese unlicensed manufacturer
> firmware.

Firmware version that I got from crewrktablets kernel_rockchip repo has
working continuous AF.  BoundaryDevices version does not.

Internally, we are working with OmniVision to get official supported
firmware - but that will likely be under NDA and thus I won't be able to
share it.  By re-distributing firmware from crewrktablets repo, I just
publish what is already available.

>> *) Setting camera parameters is not implemented. Camera always captures
>> at 640x480 with all default settings.
> 
> boundarydevices implemented that
> https://github.com/boundarydevices/linux-imx6/blob/boundary-imx_3.10.53_1.1.1_ga/drivers/media/platform/mxc/capture/ov5640_mipi.c#L56

Thanks for the link, will check.

>> *) 'imx-ipuv3 2400000.ipu: IPU Warning - IPU_INT_STAT_5 = 0x00000001'
>> message sometimes appears
>>
> 
> Carlos might know? I remember seeing something like this when using gst-imx.

Any hint here will be useful...


> 
> 
>> Any comments on all this are welcome.
>>
>> Nikita Yushchenko,
>> System Software Engineer at Software Development Center, RTsoft
> 
> 
> BR,
> Dmitriy Beykun
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://lists.yoctoproject.org/pipermail/meta-freescale/attachments/20150930/4a44bfb6/attachment.html>
> 



More information about the meta-freescale mailing list