Multi Argus cameras set sensor exposure issue

Hi Nvidia,
Orin Devkit, JP5.1.4
I have two raw cameras, and when opening video0(s56 30-001b)/video1(s56 30-001c) separately through the V4L2 program(qv4l2) and setting parameters like gain and exposure, the configuration is correctly written to each sensor.

The functions cam_gmsl_set_gain and cam_gmsl_set_exposure would be called in the driver like this.

static struct tegracam_ctrl_ops cam_gmsl_ctrl_ops = {
	.numctrls = ARRAY_SIZE(ctrl_cid_list),
	.ctrl_cid_list = ctrl_cid_list,
	.set_gain = cam_gmsl_set_gain,
	.set_exposure = cam_gmsl_set_exposure,
	.set_frame_rate = cam_gmsl_set_frame_rate,
	.set_group_hold = cam_gmsl_set_group_hold,
};

[ 4947.855645] bwmgr API not supported
[ 4955.405548] s56 30-001b: cam_gmsl_set_gain: addr=0xca1,val=0x08,
[ 4961.301525] s56 30-001b: cam_gmsl_set_exposure: addr=0xca3,val=0x00,
[ 4961.301531] s56 30-001b: cam_gmsl_set_exposure: addr=0xca2,val=0x16,
[ 4964.890440] bwmgr API not supported
[ 5058.541015] bwmgr API not supported
[ 5058.556734] s56 30-001c: cam_gmsl_set_gain: addr=0xca1,val=0x0c,
[ 5058.561256] s56 30-001c: cam_gmsl_set_exposure: addr=0xca3,val=0x0d,
[ 5058.561259] s56 30-001c: cam_gmsl_set_exposure: addr=0xca2,val=0x08,

However, when using argus_camera -d 0 or 1 to open any camera, the driver log shows that only the gain and exposure functions of video1 (s56 30-001c) are being called. and the displayed image is correctly.

[ 3569.110909] s56 30-001c: cam_gmsl_set_gain: addr=0xca1,val=0x08,
[ 3569.115495] s56 30-001c: cam_gmsl_set_exposure: addr=0xca3,val=0x0d,
[ 3569.115497] s56 30-001c: cam_gmsl_set_exposure: addr=0xca2,val=0x08,

In my opinion, when using argus_camera -d 0 command, driver log shows s56 30-001b like v4l2 methord,
I think this might be related to Argus. Please provide some suggestions. Thank you.

What’s the problem?

My problem is that in the case of multiple cameras, libargus is unable to correctly invoke the gain and exposure function of the corresponding sensor driver. but v4l2 is ok

That cold be the sensor driver problem. Like the gain/exposure not linearity.

BTW, single camera working well??

是的,
驱动中tegracam_ctrl_ops 下的增益及曝光函数,无论单相机或多相机,在v4l2调用时都可以正常调用到对应相机的驱动函数。
使用argus测试相机时,多相机存在时,只有最后一个相机的驱动增益曝光函数被自动调用到。
还是不能理解我的问题吗 :(

I don’t think that’s a problem.
AE alg set the gain/exposure depend on the scene light. You need to change the scene light to trigger the gain/exposure.

但是多相机同时点亮时,每个相机拍摄的场景不一样,不同相机需要调整的gain/exposure值自然不一样;
正常情况下不应该是每个相机像v4l2方式一样能调用自己的驱动去设置这些参数吗

Yes, I think the behavior is like you said. If not it could be your sensor driver problem.

因为我的sensor driver 增益/曝光的设置在V4L2方式下调用是正常的,所以我觉得可能不是sensor driver的问题

You can verify the setting like v4l2-ctl by set the gain/exposure range. Like set the gain range to 8 - 8 …

我前面提到了使用qv4l2程序测试,也就是v4l2方式验证是ok的;
后续我可以尝试使用多个imx219/imx477等mipi相机测试,看是否能复现我的问题

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.