blob: 22a579eace2c10949b1178684292f3c54bd74a0a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
TODO
====
atomisp
-------
1. Items which MUST be fixed before the driver can be moved out of staging:
* Remove/disable custom v4l2-ctrls
* Remove unnecessary/unwanted module parameters
* Remove abuse of priv field in various v4l2 userspace API structs
* Refactor the codebase (random cleanups won't achieve this)
2. Items which SHOULD also be fixed eventually:
* Support ISP parameter passing via parameter buffers (see
drivers/media/v4l2-core/v4l2-isp.c).
* The driver is intended to drive the PCI exposed versions of the device.
It will not detect those devices enumerated via ACPI as a field of the
i915 GPU driver (only a problem on BYT).
There are some patches adding i915 GPU support floating at the Yocto's
Aero repository (so far, untested upstream).
* Ensure that the driver will pass v4l2-compliance tests
sensor drivers
--------------
* Use v4l2-cci for register access
* Implement enable_streams and disable_streams pad ops (use s_stream
compat helper)
* Implement Runtime PM support (see e.g. ov8856 driver)
* Use sub-device state and remove state related fields from device context
structs
* Implement modern V4L2 camera sensor controls (see
Documentation/userspace-api/media/drivers/camera-sensor.rst) or even
Common Raw Sensor Model (which isn't in upsteam yet though; see
<URL:https://gitlab.freedesktop.org/linux-media/users/sailus/-/tree/metadata?ref_type=heads>).
Testing
=======
Since libcamera support is not available yet, the easiest way to test for
now is using v4l2-ctl to select the input and gstreamer for streaming.
To select the input run:
v4l2-ctl -i <input>
Where <input> is 0 (front cam) or 1 (back cam).
The simplest gstreamer pipeline for testing running the sensor
at its max resolution is:
gst-launch-1.0 v4l2src ! videoconvert ! xvimagesink sync=false
To select e.g 640x480 as resolution use:
gst-launch-1.0 v4l2src ! video/x-raw,format=YV12,width=640,height=480 ! \
videoconvert ! xvimagesink sync=false
And to show fps use:
gst-launch-1.0 v4l2src ! video/x-raw,format=YV12,width=640,height=480 ! \
videoconvert ! fpsdisplaysink video-sink=xvimagesink sync=false
Often the image will be over / under exposed. This can be fixed by using
v4l2-ctl on the sensor subdev to tweak the exposure ctrl; or by using a GUI
app for v4l2-controls which also supports subdev such as the Fedora patched
gtk-v4l tool.
|