From 4388e63a472635f67d48793e92676b485a976132 Mon Sep 17 00:00:00 2001 From: Marcello Sylvester Bauer Date: Thu, 29 Jul 2021 08:48:33 +0200 Subject: [PATCH] Add udev rule TODO: * Integrate udev rule installation into autoconf Signed-off-by: Marcello Sylvester Bauer --- 37-ipu6-psys.rules | 1 + README.md | 27 ++++++++++++++++++++++----- 2 files changed, 23 insertions(+), 5 deletions(-) create mode 100644 37-ipu6-psys.rules diff --git a/37-ipu6-psys.rules b/37-ipu6-psys.rules new file mode 100644 index 0000000..949c32e --- /dev/null +++ b/37-ipu6-psys.rules @@ -0,0 +1 @@ +ACTION=="add", SUBSYSTEM=="intel-ipu6-psys", MODE="0660", GROUP="video" diff --git a/README.md b/README.md index 0aeb13c..b2a1b9f 100644 --- a/README.md +++ b/README.md @@ -16,23 +16,40 @@ This repository supports MIPI cameras through the IPU6 on Intel Tigerlake platfo ``` export CHROME_SLIM_CAMHAL=ON - ./autogen.sh + ./autogen.sh make sudo make install ``` - + +## UDEV rule configuration +To use the gstreamer plugin as user, you need RW access to `/dev/ipu-psys0`. This can be done +by changing its pemissions via udev rule. In addition, it is required to add your user to the +`video` group. + +### UDEV Setup +``` +sudo cp 37-ipu6-psys.rules /usr/lib/udev/rules.d/ +sudo udevadm control --reload +``` + +### user Setup +``` +sudo usermod -g -G video +``` +**NOTE:** If the user is currently logged in, they must log out and in again for the change to take effect. + ## Pipeline examples * Testpattern generator (no sensor) ``` -sudo -E gst-launch-1.0 icamerasrc device-name=tpg_ipu6 ! video/x-raw,format=YUY2,width=1280,height=720 ! videoconvert ! xvimagesink +gst-launch-1.0 icamerasrc device-name=tpg_ipu6 ! video/x-raw,format=YUY2,width=1280,height=720 ! videoconvert ! xvimagesink ``` * Sensor ov01a1s ``` -sudo -E gst-launch-1.0 icamerasrc device-name=ov01a1s-uf ! video/x-raw,format=YUY2,width=1280,height=720 ! videoconvert ! xvimagesink +gst-launch-1.0 icamerasrc device-name=ov01a1s-uf ! video/x-raw,format=YUY2,width=1280,height=720 ! videoconvert ! xvimagesink ``` * Sensor hm11b1 ``` -sudo -E gst-launch-1.0 icamerasrc device-name=hm11b1-uf ! video/x-raw,format=YUY2,width=1280,height=720 ! videoconvert ! xvimagesink +gst-launch-1.0 icamerasrc device-name=hm11b1-uf ! video/x-raw,format=YUY2,width=1280,height=720 ! videoconvert ! xvimagesink ```