From patchwork Mon Jun 13 14:28:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jean-Michel Hautbois X-Patchwork-Id: 16219 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 F3F5DC327B for ; Mon, 13 Jun 2022 14:29:12 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 563BC65658; Mon, 13 Jun 2022 16:29:12 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1655130552; bh=tBokIjL+Kgf/D3u4E77nHBWGNk/M5DqFYsM05lkiDyE=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=B3JA3zpCJKQMGTs+4WOTBtJ3nH0bZzXnACCt2RM42bOCJdO0JttOXs6hY8OoPTxmo mqGK8inYlHDwcgNHhDhjz1ZooVCqDM7M1oq2Vtlv85JLg6QdCYU7oTifBFzx0JPtaV /JrXXlN7pXamAPsrOvSyr4p4ywhg6w9Ry6PqPPI3Yyx8JNqZoDZq8RIDXrIYEV5CsE tpNmC1itAcUAUBECygirTwMFnFEH0QphaAxsLD040Fqij3Tc5VQ4J6GTjfwO352bBQ wH7CTq+lokYcqZUDXEMpEzALWa7pVMn7NV7aEW1wgVnFum5FF8pWmRkYvXyIXMquQ+ pc3kQu3bGzGag== Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 2DA6165645 for ; Mon, 13 Jun 2022 16:29:02 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="RJVNTYW0"; dkim-atps=neutral Received: from tatooine.ideasonboard.com (unknown [IPv6:2a01:e0a:169:7140:a1c7:c28c:7720:9b30]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id CE226835; Mon, 13 Jun 2022 16:29:01 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1655130541; bh=tBokIjL+Kgf/D3u4E77nHBWGNk/M5DqFYsM05lkiDyE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RJVNTYW0bZsbVXVdMFwy7WQVZ9Z/bZRJqEwbXt6PuA1EyQM/+OMDJUuavPhLb6vIy CrsSyveihH/HjADBL2hHwIeRb6qh2yvHtbDuNKC0EyhN0xK14uyIfFvI7GaRNSNqzJ m4NEP8piyy3BDKswyQFI8ljU4v063KVAkqwAe9wM= To: libcamera-devel@lists.libcamera.org Date: Mon, 13 Jun 2022 16:28:53 +0200 Message-Id: <20220613142853.98484-11-jeanmichel.hautbois@ideasonboard.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220613142853.98484-1-jeanmichel.hautbois@ideasonboard.com> References: <20220613142853.98484-1-jeanmichel.hautbois@ideasonboard.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 10/10] test: af: Introduce a capture script test file 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: , X-Patchwork-Original-From: Jean-Michel Hautbois via libcamera-devel From: Jean-Michel Hautbois Reply-To: Jean-Michel Hautbois Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" When testing the autofocus state machine, it is useful to know which state is expected for a given frame. Introduce a yaml file to set the AF controls at given points in time to ease debugging the state machine Signed-off-by: Jean-Michel Hautbois --- test/af/af-state-machine.yaml | 46 +++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 test/af/af-state-machine.yaml diff --git a/test/af/af-state-machine.yaml b/test/af/af-state-machine.yaml new file mode 100644 index 00000000..54da3fe2 --- /dev/null +++ b/test/af/af-state-machine.yaml @@ -0,0 +1,46 @@ +# SPDX-License-Identifier: CC0-1.0 + +# AF controls test script +# +# A capture script allows to associate a list of AF controls and their values +# to frame numbers. + +# Manual mode +# State should be AfStateIdle +# We can still change LensPosition +frames: + - 1: + AfMode: 0 + LensPosition: 0.0 + + - 5: + LensPosition: 100.0 + + - 10: + LensPosition: 500.0 + + - 15: + LensPosition: 0.0 + + - 50: +# Change to continuous mode +# State should immediately be AfStateScanning +# The algorithm should start a scan +# It will settle on AfStateFocused or AfStateFailed + AfMode: 2 + + - 80: +# Change to auto mode +# The Lens or state should not change until AfTrigger is received +# Entering this mode will report AfStateIdle + AfMode: 1 + - 90: +# Start the scan + AfTrigger: 0 + # - 110: +#Cancel the scan + AfTrigger: 1 + + - 100: +# Switch back to continuous + AfMode: 2