From nobody Sat Apr 09 16:44:33 2022 X-Original-To: hardware@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id E69C61A9F71F for ; Sat, 9 Apr 2022 17:33:40 +0000 (UTC) (envelope-from tomek@cedro.info) Received: from mail-oa1-x29.google.com (mail-oa1-x29.google.com [IPv6:2001:4860:4864:20::29]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KbMfX17y1z3JRs for ; Sat, 9 Apr 2022 17:33:40 +0000 (UTC) (envelope-from tomek@cedro.info) Received: by mail-oa1-x29.google.com with SMTP id 586e51a60fabf-d6ca46da48so12894518fac.12 for ; Sat, 09 Apr 2022 10:33:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cedro.info; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=GktcNr0pYBSe2UlE+xjONvPOrycT6qRPHcV7qsDqiJ4=; b=GYPziQ8NhPSTWn7sQXVC9WDn6L6FOFUEjQ5I3rGNtawDGJuVOAkGrI7hLI0ahGwDqA XsA8hhZ5pLlQDN/WvBqvnAr5IKgfs3UYVK/KivmN8O51x1xKM9kvPKirxaOQxObFiXbj ersnoZbIsEOrEFkVDrLbe2GWrOFKSb+u1hHFaFTBZgW8+7gbrVJB5YjRld0i7yGkHP5B FbEX4TnjIh3WLAcs529n4WThaE/ylgxfQ1UGmOrhM8NcavkIv2UnAxe+bWazJLpzYy87 +PbM2Gxf2ba2uPlB9GMktwltEn4AIykO4ufX1MuH3ElssJQIENkdApTgKUaAx46yVQZd GVzg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=GktcNr0pYBSe2UlE+xjONvPOrycT6qRPHcV7qsDqiJ4=; b=WVKVl7lL+75OEFpic62HnyDqddcYlvPCnshbIRG9FRIB7nLgeKdCbkwX3KgKrm8o66 hWmgki6DladPWfrEAsvZxaCttko/YeEI8hW9kE7fJ/CUJl+Y+j5e2ekFSMkoYWDce3Ig I8U0e4M5AdQYz6mRGwbcTiouKLsIdmCeIltHRMpV7Szq7XJ0UJgCvn9CZ16hOEvpGvNI d+xRt0ctMgOsBYt0CBh1Ml6EkUyJWtzibSLZS6Rl01dGbggbwAOmMEhHMhVVa8Nz0Yh+ jI41/VI4rhejd35tco11I1F0mUpuvMCTUWTRsA2YRUuu33S83k099Hbwqhv7vdeA9kzY O8Lg== X-Gm-Message-State: AOAM533E7gVPUGk3bHVa+beBwwyYEj5MXQEGYpVf0j/ytuedoy9nnRFi a/zMrBZVNxEvNmIPYKbHibvogBLKTyxM+JpR X-Google-Smtp-Source: ABdhPJzm24pnhlRl2nrYSvY156d6xTR4gXMJFHN08hieuwzuZmQhNBJZiG8PT8e1R/ZJk35XXl9PtA== X-Received: by 2002:a05:6870:b69b:b0:e2:a6e6:d16b with SMTP id cy27-20020a056870b69b00b000e2a6e6d16bmr1532807oab.287.1649525619369; Sat, 09 Apr 2022 10:33:39 -0700 (PDT) Received: from mail-oi1-f170.google.com (mail-oi1-f170.google.com. [209.85.167.170]) by smtp.gmail.com with ESMTPSA id o187-20020a4a2cc4000000b00324f07ed8basm9599833ooo.32.2022.04.09.10.33.28 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 09 Apr 2022 10:33:28 -0700 (PDT) Received: by mail-oi1-f170.google.com with SMTP id q189so11918036oia.9 for ; Sat, 09 Apr 2022 10:33:28 -0700 (PDT) X-Received: by 2002:aca:1e16:0:b0:2ef:4b94:2cda with SMTP id m22-20020aca1e16000000b002ef4b942cdamr2067213oic.149.1649525608318; Sat, 09 Apr 2022 10:33:28 -0700 (PDT) List-Id: General discussion of FreeBSD hardware List-Archive: https://lists.freebsd.org/archives/freebsd-hardware List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-hardware@freebsd.org MIME-Version: 1.0 References: <3A781DFA-1E2C-41A5-8053-C90A806244DC@Chaos1.DE> <34a747ea-2ee5-660f-71c6-dc00d5de337f@selasky.org> <9334c4f0-3ecf-c046-420f-516e39379981@selasky.org> <976BDBEB-8B57-4541-A0B7-3F2C89498DC6@Chaos1.DE> <7190bdde-22bc-79ee-06d0-d0114a3ffbad@selasky.org> <7CDFB049-241F-4C31-A7B1-A7D6BDE6A002@Chaos1.DE> <24AA646A-698B-4D41-9668-3F9F99732D02@Chaos1.DE> <1A94816D-E3C1-4488-A5A9-784BAC68AE74@Chaos1.DE> In-Reply-To: From: Tomek CEDRO Date: Sat, 9 Apr 2022 18:44:33 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: timeouts on USB ISP programmer To: Axel Rau Cc: Hans Petter Selasky , hardware@freebsd.org Content-Type: multipart/alternative; boundary="000000000000ee8e3f05dc3c1b33" X-Rspamd-Queue-Id: 4KbMfX17y1z3JRs X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=pass header.d=cedro.info header.s=google header.b=GYPziQ8N; dmarc=none; spf=none (mx1.freebsd.org: domain of tomek@cedro.info has no SPF policy when checking 2001:4860:4864:20::29) smtp.mailfrom=tomek@cedro.info X-Spamd-Result: default: False [-1.36 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[cedro.info:s=google]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_DN_SOME(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[hardware@freebsd.org]; DMARC_NA(0.00)[cedro.info]; NEURAL_SPAM_SHORT(0.93)[0.935]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[cedro.info:+]; RCVD_IN_DNSWL_NONE(0.00)[209.85.167.170:received,2001:4860:4864:20::29:from]; MLMMJ_DEST(0.00)[hardware]; R_SPF_NA(0.00)[no SPF record]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ASN(0.00)[asn:15169, ipnet:2001:4860:4864::/48, country:US]; RCVD_TLS_ALL(0.00)[] X-ThisMailContainsUnwantedMimeParts: N --000000000000ee8e3f05dc3c1b33 Content-Type: text/plain; charset="UTF-8" Two importan things I have noted while reading AVR datasheets: 1. Programming voltage is 5V. Unless reset is disabled then 12V is required on reset line. This is important if we program bare chip or chip on the board surrounded by components (that may not be 5V tolerant). 2. There are various programming protocols and interfaces for various avr chips. For instance Xplained416XNANO uses DebugWIRE protocol and connection to target MCU. From ATTiny85 datasheet it also looks it uses DebugWIRE for flashing and debug. But Xplained104XNANO uses TWI connection and protocol (the same as ATTiny10). I am working on using Xplained104XNANO to program ATtiny10, I have connection to Programmer, but simple rewire does not work (yet) to communicate with ATtiny10. Looks like knowing datasheet details and schematics of the hardware should not be skipped :-) -- CeDeROM, SQ7MHZ, https://www.tomek.cedro.info --000000000000ee8e3f05dc3c1b33 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Two importan things I have noted while reading AVR datash= eets:

1. Programming voltage is 5V. = Unless reset is disabled then 12V is required on reset line. This is import= ant if we program bare chip or chip on the board surrounded by components (= that may not be 5V tolerant).

2. There are various programming protocols and interfaces for various= avr chips. For instance Xplained416XNANO uses DebugWIRE protocol and conne= ction to target MCU. From ATTiny85 datasheet it also looks it uses DebugWIR= E for flashing and debug. But Xplained104XNANO uses TWI connection and prot= ocol (the same as ATTiny10).

I am working on using Xplained104XNANO to program ATtiny10, I have con= nection to Programmer, but simple rewire does not work (yet) to communicate= with ATtiny10.

Looks li= ke knowing datasheet details and schematics of the hardware should not be s= kipped :-)

--
CeDeROM, SQ7MHZ, https://www.tomek.cedro.info
--000000000000ee8e3f05dc3c1b33--