From patchwork Mon Aug 10 17:46:09 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Cronin X-Patchwork-Id: 27731 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id C14DABE080 for ; Mon, 10 Aug 2026 17:46:16 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 414F56820C; Mon, 10 Aug 2026 19:46:15 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=stromback-com.20251104.gappssmtp.com header.i=@stromback-com.20251104.gappssmtp.com header.b="EVjdLaEY"; dkim-atps=neutral Received: from mail-wr1-x432.google.com (mail-wr1-x432.google.com [IPv6:2a00:1450:4864:20::432]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 39B9D681F3 for ; Mon, 10 Aug 2026 19:46:14 +0200 (CEST) Received: by mail-wr1-x432.google.com with SMTP id ffacd0b85a97d-47f7027ca11so1377440f8f.3 for ; Mon, 10 Aug 2026 10:46:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=stromback-com.20251104.gappssmtp.com; s=20251104; t=1786383973; x=1786988773; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to:content-type; bh=fsk+F4o40S1MesYSFif8bnk+DxTAl974ZbKE38K2vyc=; b=EVjdLaEYYL5giTuKFJrlPRdrt+hXyMwKiDwnLUNlsa0Dsv9GAP8h4xIwL7DihsJduv NyZ/+R3YyppqbAddCYMhZNmxu9Klv9jyfjPOWJdNwa+/ZyJRbRwpT1IsIi/RtXL1kax7 ha8XCmPpa666vSYEmfYI9QMyUj9FJBSxwyYYHqjrV2nPQsDD5u+/sE+v9K+5Z3LD8Pa/ ds8/af6AEmoAAQ8A6/ytofUy/e76BRSo4ditPtm+GBZpcbKHSbQseQ+HmV/TNhgSoHwf 7bDXtzfjMG19HtPsdnlmjtTlzDUF3a1c8TQ1MCmHJtRQrDQNcQanabTY2mXLb5qMrZBm Q6ZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786383973; x=1786988773; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=fsk+F4o40S1MesYSFif8bnk+DxTAl974ZbKE38K2vyc=; b=L0o9HuV2G/hUUNa0IQWZCdYAYO5/yaqNcQwEunJ90WsZ6lRyJYpGsKD/aOx/93pRuo mLyB8TOBY7Oe+aP8nk+ntC1LOAmPZEAo8pz4ELNoEY6I4hxWTcKc2vUiYQRhZo1WaHC7 ur4o0mOFrni5NdJIGG4Z0N0iCYbbGrcbQdeTEuAQM5XvWCGrsyUqVSCdQWh5N68vtaVl qmqDYINnEVxfmhRCsSfFRJUQqjaG7GOvVqzWz2hFuTE+LE+6L8dtDXjTEgJUbNwatWHn ZXe1ArytJYL9FBNFe1KT1CphAq//J5dujLi0ihI2N2mKVre05QECIaUmToVnR7/ObilY qzLw== X-Gm-Message-State: AOJu0Yy89GmWiRTM4zwl2LBqGLCF5q0A7apRD/dNGM6kPqn835LEOW5L jJcU+E4+1++xmGDYrnl8hU6LWqPf2qKvnsXe96GLZW3n5MsZZMJUHcYHOhn/MdWWHdT7unAu8Bl B88/+yoesxz+G X-Gm-Gg: AR+sD13YAYjjiUr/DWQeMgrBgqGP0jpI1ikJFMv1BwbReSsxgMgNAyKtofiulgDFPKO X+38X1tD+2z19ckvPyQNdc32AoZ9prqNnZElv4CojmPyGScOGwNz+I5Zn1z5r4o4n/OwWAszy/Y PbxyxKVwwQImzgFOdTAc2z0s51OYGjL/pDMlu6YFwmt9uaokYc6aJpwNM9f8pTUDHHP1B2cmxk4 0cmKBFx8KQEJMqBtVaVCsbDqh1yfir2LvXA6yWMLbAqg/UCsRtRl7+ACK7pGxs405/f/A5pp9ul BkZMwuqdu/7NrR/tJ/QB+XB/cb3ewamDpKOJAlT6lOekldZCK4SMVB54uoLxEl9jKAASEEWbOVB GXPZV0puj2rD6a2n/7nKvSy8xOAWihSXf0wKTthDzJpa5ODhfuL8DBx0KDAD04uze/jiHCZkLbg ho/s26GAxabVJkGuai+o4ds5M6iA8JfILTb41rODCd4Ts+/haTu7WvajQVTPyHlCGjSjE/i63tV XtM5gk/mBwqnQnSH1gX8IFBJLl+B6z1IIGXF2ruOQo86o60uFO4Z+Zhg2brUt4DbUWrAnfXNXmD 6fg5/aji892xenzVYprRW+q8vp/f4BGrlSmMvmBWu/n+8EQv2ty5Uyrn5arzyk4QVAfg6uSahRO dQ08542LGkTQAzvjKSkJxQ0RAlz4CpuVICIyeec8bBIpwOjE64+P99/aJQONym5InB2hPKnJdvW 2mQa0K X-Received: by 2002:a05:600c:b85:b0:496:c93d:e2f with SMTP id 5b1f17b1804b1-4995e0dff0amr311621735e9.15.1786383973327; Mon, 10 Aug 2026 10:46:13 -0700 (PDT) Received: from fedora.tail5f8cb3.ts.net (251-61.dsl.iskon.hr. [89.164.251.61]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-480021506desm35040583f8f.10.2026.08.10.10.46.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Aug 2026 10:46:12 -0700 (PDT) From: John Cronin X-Google-Original-From: John Cronin To: libcamera-devel@lists.libcamera.org Cc: laurent.pinchart@ideasonboard.com, jacopo.mondi@ideasonboard.com, barnabas.pocze@ideasonboard.com, stefan.klug@ideasonboard.com, John Cronin Subject: [PATCH v2 0/2] CameraSensorHelper measurement tool and guide Date: Mon, 10 Aug 2026 13:46:09 -0400 Message-ID: <20260810174611.2472046-1-john.cronin@opcenter.com> X-Mailer: git-send-email 2.55.0 MIME-Version: 1.0 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Hi, Thanks Laurent for the review of the v1 series, and for looping in Barnabas and Stefan. Changes since v1: - Do not install the measurement script (developer tool only; run from the libcamera source tree). Dropped the utils/meson.build install_data rule and the libcamera-measure-analogue-gain rename. - Documentation notes that the helper is not packaged and should be run as ./utils/measure-analogue-gain.py from a checkout. On longer-term direction: - camshark: happy to leave that for later if Stefan sees a fit for a plugin; this series keeps a small standalone utils script for now, as you suggested is fine for a first merge. - Setting analogue gain through libcamera rather than v4l2-ctl: agreed that is nicer. Happy to revisit once Barnabas AGC rework exposes raw AnalogueGain for sensors without a helper (or with one). The current tool documents the v4l2-ctl path that works today for soft-ISP helper bring-up. Patches below (v2). Thanks, John Cronin John Cronin (2): utils: Add measure-analogue-gain helper Documentation: Add Camera Sensor Helper guide Documentation/guides/camera-sensor-helper.rst | 148 ++++++ Documentation/index.rst | 1 + Documentation/meson.build | 1 + utils/measure-analogue-gain.py | 466 ++++++++++++++++++ 4 files changed, 616 insertions(+) create mode 100644 Documentation/guides/camera-sensor-helper.rst create mode 100755 utils/measure-analogue-gain.py