Skip to contentSkip to conversation

media: i2c: Add driver for mlx7502x ToF sensor

PATCH Superseded Volodymyr Kharuk 1 participant 1 message Jun 20, 2022 Media (V4L/DVB)

v1 of 6 Superseded Latest is v6 →

lore
Share & tools
lore
#0 lore raw

PATCH 6/6 media: i2c: Add driver for mlx7502x ToF sensor

From: Volodymyr Kharuk <[email protected]>
To: [email protected]
Cc: Volodymyr Kharuk <[email protected]>,
Andrii Kyselov <[email protected]>,
Mauro Carvalho Chehab <[email protected]>,
Rob Herring <[email protected]>,
Krzysztof Kozlowski <[email protected]>,
Hyun Kwon <[email protected]>,
Laurent Pinchart <[email protected]>,
Michal Simek <[email protected]>,
Kieran Bingham <[email protected]>, [email protected]
Subject: [PATCH 6/6] media: i2c: Add driver for mlx7502x ToF sensor
Date: Mon, 20 Jun 2022 19:24:37 +0300
Message-Id: <5d058b2564afe6ccd8c3f5ca182923a80cd293bc.1655738300.git.vkh@melexis.com>
X-Mailer: git-send-email 2.36.1
In-Reply-To: <[email protected]>
References: <[email protected]>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit

Melexis ToF 7502x sensors has a CSI-2 output. It supports 2 and 4 lanes, and mipi speeds are 300, 600, 704, 800, 904, 960Mbs. Supported format is RAW12.
Sensor 75026 is QVGA, while 75027 is VGA sensor.

The driver supports:
- Digital binning and cropping
- Horizontal and vertical flip
- phase shifts(up to 8)
- frequency modulation
- time integration
- internal temperature
- different trigger sources

---
 MAINTAINERS                  |    1 +
 drivers/media/i2c/Kconfig    |   13 +
 drivers/media/i2c/Makefile   |    1 +
 drivers/media/i2c/mlx7502x.c | 1949 ++++++++++++++++++++++++++++++++++
 4 files changed, 1964 insertions(+)
 create mode 100644 drivers/media/i2c/mlx7502x.c
MAINTAINERS +1 -0
index ce052a351fda..872094b7960e 100644
@@ -12677,6 +12677,7 @@ L:	[email protected]
 S:	Supported
 W:	http://www.melexis.com
 F:	Documentation/devicetree/bindings/media/i2c/melexis,mlx7502x.yaml
+F:	drivers/media/i2c/mlx7502x.c
 F:	include/uapi/linux/mlx7502x.h
 
 MELFAS MIP4 TOUCHSCREEN DRIVER
drivers/media/i2c/Kconfig +13 -0
index 2b20aa6c37b1..126f6bd458b7 100644
@@ -216,6 +216,19 @@ config VIDEO_IMX412
 config VIDEO_MAX9271_LIB
 	tristate
 
+config VIDEO_MLX7502X
+	tristate "Melexis ToF 75026 and 75027 sensors support"
+	depends on I2C && VIDEO_DEV
+	select MEDIA_CONTROLLER
+	select VIDEO_V4L2_SUBDEV_API
+	select V4L2_FWNODE
+	help
+	  This is a V4L2 sensor driver for the Melexis 75026 and 75027
+	  ToF sensors.
+
+	  To compile this driver as a module, choose M here: the
+	  module will be called mlx7502x.
+
 config VIDEO_MT9M001
 	tristate "mt9m001 support"
 	depends on I2C && VIDEO_DEV
drivers/media/i2c/Makefile +1 -0
index 3e1696963e7f..57c30859e537 100644
@@ -57,6 +57,7 @@ obj-$(CONFIG_VIDEO_M5MOLS) += m5mols/
 obj-$(CONFIG_VIDEO_MAX9271_LIB) += max9271.o
 obj-$(CONFIG_VIDEO_MAX9286) += max9286.o
 obj-$(CONFIG_VIDEO_ML86V7667) += ml86v7667.o
+obj-$(CONFIG_VIDEO_MLX7502X) += mlx7502x.o
 obj-$(CONFIG_VIDEO_MSP3400) += msp3400.o
 obj-$(CONFIG_VIDEO_MT9M001) += mt9m001.o
 obj-$(CONFIG_VIDEO_MT9M032) += mt9m032.o
drivers/media/i2c/mlx7502x.c new file +1949 -0

1,949 lines not on this page · raw message

Signature · 2 lines
BR,
Volodymyr Kharuk