From owner-freebsd-arm@freebsd.org Sun Dec 18 15:52:12 2016 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D03E1C87658 for ; Sun, 18 Dec 2016 15:52:12 +0000 (UTC) (envelope-from ticso@cicely7.cicely.de) Received: from raven.bwct.de (raven.bwct.de [195.149.99.3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "raven.bwct.de", Issuer "raven.bwct.de" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 64DEBD25 for ; Sun, 18 Dec 2016 15:52:11 +0000 (UTC) (envelope-from ticso@cicely7.cicely.de) Received: from mail.cicely.de ([10.1.1.37]) by raven.bwct.de (8.15.2/8.15.2) with ESMTPS id uBIFq7ML099743 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Sun, 18 Dec 2016 16:52:07 +0100 (CET) (envelope-from ticso@cicely7.cicely.de) Received: from cicely7.cicely.de (cicely7.cicely.de [10.1.1.9]) by mail.cicely.de (8.14.5/8.14.4) with ESMTP id uBIFq46Q027560 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 18 Dec 2016 16:52:04 +0100 (CET) (envelope-from ticso@cicely7.cicely.de) Received: from cicely7.cicely.de (localhost [127.0.0.1]) by cicely7.cicely.de (8.15.2/8.15.2) with ESMTP id uBIFq4M8032770; Sun, 18 Dec 2016 16:52:04 +0100 (CET) (envelope-from ticso@cicely7.cicely.de) Received: (from ticso@localhost) by cicely7.cicely.de (8.15.2/8.15.2/Submit) id uBIFq3jI032769; Sun, 18 Dec 2016 16:52:03 +0100 (CET) (envelope-from ticso) Date: Sun, 18 Dec 2016 16:52:03 +0100 From: Bernd Walter To: Kyle Evans Cc: ticso@cicely.de, freebsd-arm@freebsd.org, Adrian Chadd Subject: Re: Arduino Due Message-ID: <20161218155203.GE30676@cicely7.cicely.de> Reply-To: ticso@cicely.de References: <20161211034602.3fylwnxfbgl4ehgx@hal9000.meka.no-ip.org> <1752cc8d-fad7-141d-4950-37bb5dde9561@passap.ru> <20161215111151.geyecaxakyn6feau@hal9000.meka.no-ip.org> <20161218094238.GD30676@cicely7.cicely.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: FreeBSD cicely7.cicely.de 10.2-RELEASE amd64 User-Agent: Mutt/1.5.11 X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED=-1, BAYES_00=-1.9, RP_MATCHES_RCVD=-1.507 autolearn=ham version=3.3.0 X-Spam-Checker-Version: SpamAssassin 3.3.0 (2010-01-18) on spamd.cicely.de X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Dec 2016 15:52:12 -0000 On Sun, Dec 18, 2016 at 09:13:43AM -0600, Kyle Evans wrote: > On Dec 18, 2016 03:42, "Bernd Walter" wrote: > > > On Sun, Dec 18, 2016 at 01:41:52AM -0600, Kyle Evans wrote: > > > On Sun, Dec 18, 2016 at 1:14 AM, Adrian Chadd > > wrote: > > > > > I would have liked it if this detail was completely moved into > > > devel/bossa, which is actually programming the device, but that idea > > > has since been rejected upstream. I'm not entirely convinced that it's > > > really doing the open/close properly or that there's not simply too > > > much delay between triggering the bootloader and devel/bossa connecting. > > > > Not sure about the arduino case, but with the ESP8266 I saw some USB > > uarts worked fine (CP2102) and others (CH340) failed to start programming. > > Adding some retries for the init handshake helped. > > No idea what happens exactly, because the data itself looked fine when I'd > > traced it with another USB uart. > > There might be some timing differences. > > The ESP8266 is devel/bossa supported as well, yeah? That's an interesting > datapoint. Does it require the 1200 bps init to erase and reboot in > bootloader mode? In my case I'm using esptool.py for the ESP8266. >From memory it just opens the tty without anything fancy and tries to handshake with 115200bps. I even traced the signals on the line and nothing was wrong. Still it almost always failed with the CH340 and always worked with a CP2102. I've never found out what exactly went wrong, just that a few more retries (well I'd raised it to 100) helped. When I first had to programm Atmel ARMs bossa wasn't available. I'd used a Linux programm called sam7_pgm, which I had to fix to be compiled on FreeBSD, but it worked fine for all the AT91SAM7*. With the newer Atmel ARMs I'd switched over to the Atmel-ICE and openocd. -- B.Walter http://www.bwct.de Modbus/TCP Ethernet I/O Baugruppen, ARM basierte FreeBSD Rechner uvm.