From patchwork Tue Nov 30 21:34:10 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Scally X-Patchwork-Id: 14912 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 97EF2BF415 for ; Tue, 30 Nov 2021 21:34:35 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id EBD2C60726; Tue, 30 Nov 2021 22:34:33 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="nVM5R1nC"; dkim-atps=neutral Received: from mail-wr1-x42c.google.com (mail-wr1-x42c.google.com [IPv6:2a00:1450:4864:20::42c]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id BB9A3605C4 for ; Tue, 30 Nov 2021 22:34:31 +0100 (CET) Received: by mail-wr1-x42c.google.com with SMTP id a18so47508204wrn.6 for ; Tue, 30 Nov 2021 13:34:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:date:message-id:in-reply-to:references; bh=kTvLjJS9WG2McZQABpbwOF0yPio+OC/y+/XehGfEp3Q=; b=nVM5R1nCICdkvo2rr7pAS1T5vyvQS+Fdt5w1IB2K5PiGnxKNg5sQfkp9Gj8T/cU2h9 hZ3EtD7N/i9rQoLF92KnYkYWbXgGRbrkHbOQqezSSCWFE13N1WRDHZCQdyo48JOk2uSs U3wwDlIB5jDVb+W6megTE0wSsov5bCkftYeARVZ73FwFuuMcWKwvjE7H6YUN4EsTatlz Kb2vL7gvgjjCtruTh4stuJ09KAPrDKmMpByUmQNRfU9NEGWdv6TYwqMukxzCa0j+4TsH DQygtkvuW/8fxpV+5CDnTxsrqQ3sRes9Fwl265rdXwp9DXk0r0BdyUZ/54legrWhLNgk Gojw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=kTvLjJS9WG2McZQABpbwOF0yPio+OC/y+/XehGfEp3Q=; b=nzEadzIy0Mgr/TUJawLpVt4oNKXVSCAO8mVAn699LzY99stHZ9jvMSxiXAAegQelxu f9+D3wu0k1ofz+X6ENmcnwfkdVsoyX0Im9AQqr8sz0XqB2/kGBr3JJW7JQeiHBBpFd03 UwMkpmo5pUfjKYndqet8TcKXCEFW6lr6ZrIgBgcNxhoLRdUsbjoww3fb2T1OekLSvHMn cIvS3kqfzSXVNxYbfQnIvjsODFPhCkZQd9Dh+wd3qasdrslwYLj//av14QHWxRjlYdnK dOndZ6tZPSMr3ICUDV2qIvG5z7GIGjx7q0VQyV1PrhT7dGrma8jaceXOOwpZY74N7uev MOJQ== X-Gm-Message-State: AOAM5331L5EzNa8ifgBLZarZP/cpj1pzk6tHtdb8pBArrZ8apXTNOmGM 0Q3XXpE61actKfOIN6pHaB+UrkxNbrw= X-Google-Smtp-Source: ABdhPJx1cVRJ4aVopqo4YSBQ9Ltib3Cj3YKgUNmGC5Zj787b4wgXpfYPLVARbALCzTbHM0vMMb9B+w== X-Received: by 2002:adf:8b0e:: with SMTP id n14mr1601818wra.281.1638308071529; Tue, 30 Nov 2021 13:34:31 -0800 (PST) Received: from localhost.localdomain (cpc141996-chfd3-2-0-cust928.12-3.cable.virginm.net. [86.13.91.161]) by smtp.gmail.com with ESMTPSA id p13sm3519642wmi.0.2021.11.30.13.34.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Nov 2021 13:34:31 -0800 (PST) From: Daniel Scally To: libcamera-devel@lists.libcamera.org Date: Tue, 30 Nov 2021 21:34:10 +0000 Message-Id: <20211130213411.20149-2-djrscally@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211130213411.20149-1-djrscally@gmail.com> References: <20211130213411.20149-1-djrscally@gmail.com> Subject: [libcamera-devel] [PATCH 1/2] libipa: Add CameraSensorHelper for ov2680 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" Add a CameraSensorHelperOv2680 class. The OV2680 is found in concert with an IPU3 on the Lenovo Miix 510. The constants set are a bit of a guess, as the datasheet doesn't document the gain control field any further than giving its width in bits, but the default is 0x10 so we assume that to be 1x gain. Signed-off-by: Daniel Scally --- src/ipa/libipa/camera_sensor_helper.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/ipa/libipa/camera_sensor_helper.cpp b/src/ipa/libipa/camera_sensor_helper.cpp index 0b0eb503..fd951505 100644 --- a/src/ipa/libipa/camera_sensor_helper.cpp +++ b/src/ipa/libipa/camera_sensor_helper.cpp @@ -305,6 +305,16 @@ public: }; REGISTER_CAMERA_SENSOR_HELPER("imx258", CameraSensorHelperImx258) +class CameraSensorHelperOv2680 : public CameraSensorHelper +{ +public: + CameraSensorHelperOv2680() + { + analogueGainConstants_ = { AnalogueGainLinear, 1, 0, 0, 16 }; + } +}; +REGISTER_CAMERA_SENSOR_HELPER("ov2680", CameraSensorHelperOv2680) + class CameraSensorHelperOv5670 : public CameraSensorHelper { public: