From patchwork Tue Jun 21 23:08:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 16303 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 38036BD808 for ; Tue, 21 Jun 2022 23:08:50 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 31D786563E; Wed, 22 Jun 2022 01:08:48 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1655852928; bh=6pV7nNbcDYEYbk5M+t+WrGYwbzWlut2/W0e0IYso5As=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=VxNhgxAo+16a+KD2PnsFRtQ6xMljCUMyaNFyW+U5HMtRRvZvrRDIvTJAdIolSOrwf JdLAp8+YwViol0oA84dXki/OwSMZ5UTH2Mmts/JEZaSSydcxbB2VJ5HeSDXH41l/Fy It9nw3enf/ZpTbVaDzOAvg/uGOsn24jLwaBpsBNdUZhnhut7MQXG46/i8OHUMNlH1B IeEwDHUkWkD3g7iFTgiPGVi8oi1vMYj1elKphMfS777XfsOZ0xWs6lhfRXyJtXC/7K zGX0jzDQUvgEwGH+5GfzmGpTv1rPCZpd659DAYeBQEAOawaEhuqipl4JzpH18m74gS du+4P9iCYLrXg== Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 03D1C65631 for ; Wed, 22 Jun 2022 01:08:47 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="q54U/Ocs"; dkim-atps=neutral Received: from pendragon.lan (62-78-145-57.bb.dnainternet.fi [62.78.145.57]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 9297659D; Wed, 22 Jun 2022 01:08:46 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1655852926; bh=6pV7nNbcDYEYbk5M+t+WrGYwbzWlut2/W0e0IYso5As=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=q54U/OcsZRzZ5SPDQjkpXoAkjmxDyp3pkSp2FNmH4pHfFqPpA8crZ8ghIWlIhqqYk YSbWkE/lwLOH64g1vurN6cB0bsWFaliFW+YJYOI9f92qk/mrCCUS6zuJWwqM+Ysnhn A4H+tU0/7ITWo0LCAmIcoGbPOIjHGI0XK/wS2kW4= To: libcamera-devel@lists.libcamera.org Date: Wed, 22 Jun 2022 02:08:26 +0300 Message-Id: <20220621230826.23906-2-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220621230826.23906-1-laurent.pinchart@ideasonboard.com> References: <20220621230826.23906-1-laurent.pinchart@ideasonboard.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 2/2] README: Add short testing instructions with cam 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: Laurent Pinchart via libcamera-devel From: Laurent Pinchart Reply-To: Laurent Pinchart Cc: Pavel Machek Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The README.rst file contains the getting started instructions, but lacks a simple way to test libcamera. Add a short section about basic cam usage. Suggested-by: Pavel Machek Signed-off-by: Laurent Pinchart Reviewed-by: Kieran Bingham Reviewed-by: Jacopo Mondi --- Documentation/environment_variables.rst | 2 ++ README.rst | 15 +++++++++++++++ 2 files changed, 17 insertions(+) diff --git a/Documentation/environment_variables.rst b/Documentation/environment_variables.rst index f092cbbd29c5..dcfdb1a33a32 100644 --- a/Documentation/environment_variables.rst +++ b/Documentation/environment_variables.rst @@ -86,6 +86,8 @@ global environment: :~$ export LIBCAMERA_LOG_LEVELS='Camera:DEBUG,V4L2:DEBUG' :~$ cam --list +.. _log levels: + Log levels ~~~~~~~~~~ diff --git a/README.rst b/README.rst index f81d6e2e7867..578aa19f0f54 100644 --- a/README.rst +++ b/README.rst @@ -101,6 +101,21 @@ for android: [optional] for lc-compliance: [optional] libevent-dev +Basic testing with cam utility +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The ``cam`` utility can be used for basic testing. You can list the cameras +detected on the system with ``cam -l``, and capture ten frames from the first +camera and save them to disk with ``cam -c 1 --capture=10 --file``. See +``cam -h`` for more information about the ``cam`` tool. + +In case of problems, a detailed debug log can be obtained from libcamera by +setting the :ref:`LIBCAMERA_LOG_LEVELS ` environment variable: + +.. code:: + + :~$ LIBCAMERA_LOG_LEVELS=*:DEBUG cam -l + Using GStreamer plugin ~~~~~~~~~~~~~~~~~~~~~~