V4l2-ctrl is not listing the control control

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

V4l2-ctrl is not listing the control control

1,132 Views
jp4
Contributor III

Hi,

I am working on custom v4l2 driver for IMX662 sensor. I have below points to be clarified.

Point 1. While I am loading my driver modules, /dev/video3 is not creating, But after reloading imx8-media-dev.ko, I can see /dev/video3. I am not sure why it so. I need to find a way to get /dev/video3 node instantly when ever I am loading my driver.

Point 2. When I am executing v4l2-ctrl -d /dev/video3 --list-ctrls, It is not listing the v4l2 controls that I have added. But when i am executing v4l2-ctrl -d /dev/v4l-subdev1 --list-ctrls, I can see the controls that I have added. Please help to understand why it is not listing the controls in /dev/video3

Thanks in advance.

Below are the outputs that might be helpful to answer.

root@verdin-imx8mp-14777745:~# v4l2-ctl --list-device
():
/dev/v4l-subdev0

mxc-isi-cap (platform:32e00000.isi:cap_devic):
/dev/video3

mxc-isi-m2m (platform:32e00000.isi:m2m_devic):
/dev/video2

FSL Capture Media Device (platform:mxc-md):
/dev/media0

vsi_v4l2dec (platform:vsi_v4l2dec):
/dev/video1

vsi_v4l2enc (platform:vsi_v4l2enc):
/dev/video0

 

root@verdin-imx8mp-14777745:~# media-ctl -p
Media controller API version 5.15.148

Media device information
------------------------
driver mxc-md
model FSL Capture Media Device
serial
bus info
hw revision 0x0
driver version 5.15.148

Device topology
- entity 1: mxc_isi.0 (16 pads, 2 links)
type V4L2 subdev subtype Unknown flags 0
pad0: Sink
<- "mxc-mipi-csi2.0":4 [ENABLED]
pad1: Sink
pad2: Sink
pad3: Sink
pad4: Sink
pad5: Sink
pad6: Sink
pad7: Sink
pad8: Sink
pad9: Sink
pad10: Sink
pad11: Sink
pad12: Source
-> "mxc_isi.0.capture":0 [ENABLED]
pad13: Source
pad14: Source
pad15: Sink

- entity 18: mxc_isi.0.capture (1 pad, 1 link)
type Node subtype V4L flags 0
device node name /dev/video3
pad0: Sink
<- "mxc_isi.0":12 [ENABLED]

- entity 22: mxc-mipi-csi2.0 (8 pads, 2 links)
type Node subtype V4L flags 0
device node name /dev/v4l-subdev0
pad0: Sink
<- "imx662 2-0042":0 [ENABLED,IMMUTABLE]
pad1: Sink
pad2: Sink
pad3: Sink
pad4: Source
-> "mxc_isi.0":0 [ENABLED]
pad5: Source
pad6: Source
pad7: Source

- entity 31: imx662 2-0042 (1 pad, 1 link)
type V4L2 subdev subtype Sensor flags 0
device node name /dev/v4l-subdev1
pad0: Source
[fmt:SRGGB10_1X10/1920x1080 field:none colorspace:srgb xfer:srgb ycbcr:601 quantization:full-range]
-> "mxc-mipi-csi2.0":0 [ENABLED,IMMUTABLE]

 

root@verdin-imx8mp-14777745:~# v4l2-ctl -d /dev/video3 --list-ctrls

User Controls

horizontal_flip 0x00980914 (bool) : default=0 value=0
vertical_flip 0x00980915 (bool) : default=0 value=0
alpha_component 0x00980929 (int) : min=0 max=255 step=1 default=0 value=0

Image Processing Controls

test_pattern 0x009f0903 (menu) : min=0 max=4 default=0 value=0 (Disabled)

 

root@verdin-imx8mp-14777745:~# v4l2-ctl -d /dev/video3 --list-ctrls

User Controls

horizontal_flip 0x00980914 (bool) : default=0 value=0
vertical_flip 0x00980915 (bool) : default=0 value=0
alpha_component 0x00980929 (int) : min=0 max=255 step=1 default=0 value=0

Image Processing Controls

test_pattern 0x009f0903 (menu) : min=0 max=4 default=0 value=0 (Disabled)
root@verdin-imx8mp-14777745:~# v4l2-ctl -d /dev/v4l-subdev1 --list-ctrls

User Controls

exposure 0x00980911 (int) : min=60 max=16600 step=1 default=8000 value=8000
gain 0x00980913 (int) : min=0 max=240 step=1 default=0 value=0

Camera Controls

exposure_time_absolute 0x009a0902 (int) : min=60 max=16600 step=1 default=8000 value=8000

Image Source Controls

vertical_blanking 0x009e0901 (int) : min=1250 max=1250 step=1 default=1250 value=1250 flags=read-only
horizontal_blanking 0x009e0902 (int) : min=990 max=990 step=1 default=990 value=990 flags=read-only
analogue_gain 0x009e0903 (int) : min=0 max=240 step=1 default=0 value=0

Image Processing Controls

link_frequency 0x009f0901 (intmenu): min=0 max=0 default=0 value=0 (456000000 0x1b2e0200) flags=read-only
pixel_rate 0x009f0902 (int64) : min=0 max=2147483647 step=1 default=182400000 value=182400000 flags=read-only

0 Kudos
Reply
1 Reply

1,084 Views
joanxie
NXP TechSupport
NXP TechSupport

1) the sequence of your kernel driver  is imx8-media-dev-> camera? in fact, the kernel would load the imx8-media-dev automatically, did you load the driver manually?

2) maybe you can refer to the link as below

https://community.nxp.com/t5/i-MX-Processors/v4l2-ctl-no-control-available-no-brightness-no-exposure...

0 Kudos
Reply