From nobody Mon Feb 9 23:03:59 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1594146911; cv=none; d=zohomail.com; s=zohoarc; b=capxRK7jyrd1vOaXiK2716S3hnFBefPz4ZTHJzrYf70/ZVOMSTYnbTqBfzkaca5PNUodMgaaoGdbRECRiaJc/gEDdmMt6RDbqi1a2Sb+Jk7gHdWcobV4Ld3f7KH6rGQY3++HHgahDVFw9o8rYvASQ369agp9P4nX/Tp9qhiwoqY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1594146911; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=IBIliU2TvqhuT2+YwakVDSLtJXEXe6zfG/AsoZOUvLc=; b=h17gZnUf9dCcBynMNzrBJgo/bKnE8LPeaE4SgpC0J2FK6nABS7VBrEPY49UHn3zjVYxojhmymjpEdx3ciVn80K8pX69TmbkvUeJXKrcMxVFwUG7Rq1Glw1jlJlbPEdu/EwpgiW+pky6h211wKpMxVgDPms6MxvPCFzDQ3JPjruc= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1594146911454300.39815725922256; Tue, 7 Jul 2020 11:35:11 -0700 (PDT) Received: from localhost ([::1]:49346 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jssQw-0001x5-3f for importer@patchew.org; Tue, 07 Jul 2020 14:35:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35816) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jssAM-0000GJ-LJ for qemu-devel@nongnu.org; Tue, 07 Jul 2020 14:18:02 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:46884) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jssAK-0002xj-GM for qemu-devel@nongnu.org; Tue, 07 Jul 2020 14:18:01 -0400 Received: by mail-wr1-x443.google.com with SMTP id r12so46172992wrj.13 for ; Tue, 07 Jul 2020 11:18:00 -0700 (PDT) Received: from localhost.localdomain (138.red-83-57-170.dynamicip.rima-tde.net. [83.57.170.138]) by smtp.gmail.com with ESMTPSA id 65sm2253337wma.48.2020.07.07.11.17.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jul 2020 11:17:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=IBIliU2TvqhuT2+YwakVDSLtJXEXe6zfG/AsoZOUvLc=; b=a5FnimvEMyGyCAvdKKmK+xMV79vaP5p6TKHmucn504j05Tc3QVZVLwCTxl5dgI3nPj ssP0jTIgq2GiBzCdW9t4iqtOrVO7c3jIr7ErA0Znjks1bHudrJ5PwQ3yIbvlNVhWMN5b Yx2Lmoo8wDJDNmT641rgN5bUSyuJYhvnZ9V+KCBtTW7MLfXRJ85/YLXLC/IAtKscgA9e fbhgXBvFhA45F+qVZRNXZNM5GBzUx7uGpqrHeMtxWmUBDEo3NhNbcVii4X9iWnLNBM7Z U8LE8oQZUTmxuzUs+VNXhOHkNxmkoI65EtLOYV3+HidtYokITuRjv0pKMjXWOeErx1Fw eb5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=IBIliU2TvqhuT2+YwakVDSLtJXEXe6zfG/AsoZOUvLc=; b=kuG59xDb8lbozxeSOJzMTv3CiETa4IgforU7qHcUx5MOAPDLxd/4r0qpu2gTGRaHMe PwjXV8Aw7GYpWDSO5tfChETMQR0FNsBjbFqeiLAZA8ibhyVqe0o0o9Adup6KO7yttOjn cxQtD8yahxWRjwE/0p9+fSMoDfAGc9johwC+AFnzNqFRe0F6LXfPSeqt9WxTtiSOSDt7 uDGOv+lMR0ameAMm+EEJkPq12lwm0DPYzY8K4z7rvOjuPoyjEXBUh+W/HgsQnLkWv+Z4 xOecanveV6irTSG3yEcd7xlG1WCC65rMMM8N8EbJNYnQ08Jklrzq5yDwvBZCteCmfgxn vI4A== X-Gm-Message-State: AOAM5315lAlJCGWKL6bh+CfpYN7m0ImKfXWQtiW/eJkRCsrRM1UkOnUC Yq2qplHMuDGEUHdW0LOarBBXQTgP X-Google-Smtp-Source: ABdhPJxg1de/lvq0mJ1/gRowZ/SK+G14W454NwpG/npo7vEgPoXKdVFqB0oiot2F4l3JSGDJfaSGdA== X-Received: by 2002:a5d:630c:: with SMTP id i12mr60574398wru.158.1594145878971; Tue, 07 Jul 2020 11:17:58 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PULL 29/32] target/avr: Add section into QEMU documentation Date: Tue, 7 Jul 2020 20:17:07 +0200 Message-Id: <20200707181710.30950-30-f4bug@amsat.org> X-Mailer: git-send-email 2.21.3 In-Reply-To: <20200707181710.30950-1-f4bug@amsat.org> References: <20200707181710.30950-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: 0 X-Spam_score: 0.0 X-Spam_bar: / X-Spam_report: (0.0 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=1, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Laurent Vivier , Sarah Harris , Eduardo Habkost , Thomas Huth , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Cleber Rosa , Markus Armbruster , Wainer dos Santos Moschetta , Thomas Huth , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Michael Rolnik , Paolo Bonzini , Pavel Dovgalyuk , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Thomas Huth The new section explains basic ways of using AVR target in QEMU. Signed-off-by: Michael Rolnik [thuth: Converted doc from texi to Sphinx syntax] Signed-off-by: Thomas Huth Message-Id: <20200705140315.260514-31-huth@tuxfamily.org> Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- docs/system/target-avr.rst | 37 +++++++++++++++++++++++++++++++++++++ docs/system/targets.rst | 1 + 2 files changed, 38 insertions(+) create mode 100644 docs/system/target-avr.rst diff --git a/docs/system/target-avr.rst b/docs/system/target-avr.rst new file mode 100644 index 0000000000..dc99afc895 --- /dev/null +++ b/docs/system/target-avr.rst @@ -0,0 +1,37 @@ +.. _AVR-System-emulator: + +AVR System emulator +------------------- + +Use the executable ``qemu-system-avr`` to emulate a AVR 8 bit based machin= e. +These can have one of the following cores: avr1, avr2, avr25, avr3, avr31, +avr35, avr4, avr5, avr51, avr6, avrtiny, xmega2, xmega3, xmega4, xmega5, +xmega6 and xmega7. + +As for now it supports few Arduino boards for educational and testing purp= oses. +These boards use a ATmega controller, which model is limited to USART & 16= -bit +timer devices, enought to run FreeRTOS based applications (like +https://github.com/seharris/qemu-avr-tests/blob/master/free-rtos/Demo/AVR_= ATMega2560_GCC/demo.elf +). + +Following are examples of possible usages, assuming demo.elf is compiled f= or +AVR cpu + + - Continuous non interrupted execution: + ``qemu-system-avr -machine mega2560 -bios demo.elf`` + + - Continuous non interrupted execution with serial output into telnet win= dow: + ``qemu-system-avr -machine mega2560 -bios demo.elf -serial + tcp::5678,server,nowait -nographic`` + and then in another shell + ``telnet localhost 5678`` + + - Debugging wit GDB debugger: + ``qemu-system-avr -machine mega2560 -bios demo.elf -s -S`` + and then in another shell + ``avr-gdb demo.elf`` + and then within GDB shell + ``target remote :1234`` + + - Print out executed instructions: + ``qemu-system-avr -machine mega2560 -bios demo.elf -d in_asm`` diff --git a/docs/system/targets.rst b/docs/system/targets.rst index 99435a3eba..560783644d 100644 --- a/docs/system/targets.rst +++ b/docs/system/targets.rst @@ -19,3 +19,4 @@ Contents: target-xtensa target-s390x target-rx + target-avr --=20 2.21.3