From nobody Thu Feb 17 09:34:27 2022 X-Original-To: usb@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 81F9819C6894; Thu, 17 Feb 2022 09:34:29 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.116.210]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4JzqR86BCzz4Y9D; Thu, 17 Feb 2022 09:34:28 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=cs.huji.ac.il; s=57791128; h=References:To:Cc:In-Reply-To:Date:Subject:Mime-Version:Content-Type:Message-Id:From; bh=O2dSlINkR+Uq8i7HYox8r8qe2hE34iflFkxAlCxrXc0=; b=Hphxj1y6vC63EM6uIE+VvAzWmtQCuc+ZqPO1yGaFCc8Bv7GjApS53iFoyYkpk6FoEUe2YpNOTvxYT270Un6UFGW+jM+CZT0rXd29ZuK9yLOBqBS0kDegQ1oejAvrhatWex20MPvzgHXokM/ovjMPmth28RpvdgMG2S4XIHvarFipM1xSFqZSTRLi+QlvF+EZpkJxGK4v3sPipE3j4f3TYr1M0FJ5J7iioMkJxckJr2BppQIj5zcSVFocj3IX8gBBMDqvN3TlkNyg8QFz8ZNXM0KteA5O6TR+xW3BRUERz5PIHwS1wU1LRNB4Ae0w4Ns02Hhrl1toEIzuPsqNH+Xc1Q==; Received: from bach.cs.huji.ac.il ([132.65.80.20] helo=smtpclient.apple) by kabab.cs.huji.ac.il with esmtp id 1nKdBD-00066v-5J; Thu, 17 Feb 2022 11:34:27 +0200 From: Daniel Braniss Message-Id: <17E09096-A45B-43F5-BFE4-7645E8A2275D@cs.huji.ac.il> Content-Type: multipart/alternative; boundary="Apple-Mail=_7CB45CB7-F310-4F07-8AC9-447C364B58C9" List-Id: FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-usb List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-usb@freebsd.org X-BeenThere: freebsd-usb@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.120.0.1.13\)) Subject: Re: usb CH9102 serial chip Date: Thu, 17 Feb 2022 11:34:27 +0200 In-Reply-To: <013FB4BA-7D32-4FFB-AFD3-E594CF638A66@dons.net.au> Cc: freebsd- , "usb@freebsd.org" To: Daniel O'Connor References: <7DD6E1FA-3EA4-44D9-A272-9E51FB9F2BFC@dons.net.au> <013FB4BA-7D32-4FFB-AFD3-E594CF638A66@dons.net.au> X-Mailer: Apple Mail (2.3654.120.0.1.13) X-Rspamd-Queue-Id: 4JzqR86BCzz4Y9D X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=cs.huji.ac.il header.s=57791128 header.b=Hphxj1y6; dmarc=pass (policy=none) header.from=huji.ac.il; spf=none (mx1.freebsd.org: domain of danny@cs.huji.ac.il has no SPF policy when checking 132.65.116.210) smtp.mailfrom=danny@cs.huji.ac.il X-Spamd-Result: default: False [-3.30 / 15.00]; TO_DN_EQ_ADDR_SOME(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[cs.huji.ac.il:s=57791128]; FREEFALL_USER(0.00)[danny]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; MV_CASE(0.50)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[cs.huji.ac.il:+]; DMARC_POLICY_ALLOW(-0.50)[huji.ac.il,none]; NEURAL_HAM_SHORT(-1.00)[-1.000]; MLMMJ_DEST(0.00)[hackers,usb]; R_SPF_NA(0.00)[no SPF record]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:378, ipnet:132.64.0.0/15, country:IL]; RCVD_COUNT_TWO(0.00)[2]; MID_RHS_MATCH_FROM(0.00)[] X-ThisMailContainsUnwantedMimeParts: N --Apple-Mail=_7CB45CB7-F310-4F07-8AC9-447C364B58C9 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > On 17 Feb 2022, at 11:30, Daniel O'Connor wrote: >=20 >=20 >=20 >> On 17 Feb 2022, at 19:50, Daniel Braniss wrote: >>=20 >>> If that is the case then the chip/driver are working fine since that = requires bidirectional communication etc.. >>>=20 >>=20 >> but that works only if I power up the board while pressing a button, = then it also appears as /dev/ttyU0, and >> so then I can flash, after reset, the device is gone and there are = errors ( BTW, the flashed image workes): >>=20 >> Feb 17 09:46:59 pampero kernel: usbd_setup_device_desc: getting = device descriptor at addr 4 failed, USB_ERR_IOERROR >> Feb 17 09:47:00 pampero kernel: usbd_req_re_enumerate: addr=3D4, set = address failed! (USB_ERR_IOERROR, ignored) >=20 > What sort of dev board is it? m5 stamp C3U = https://shop.m5stack.com/products/m5stamp-c3u-mate-with-pin-headers?_pos=3D= 2&_sid=3D3df9b5f0d&_ss=3Dr&variant=3D42341016633601 = >=20 > Seems very strange the USB UART would behave differently unless it's = wired up in an unusual way IMO. >=20 > -- > Daniel O'Connor > "The nice thing about standards is that there > are so many of them to choose from." > -- Andrew Tanenbaum >=20 >=20 --Apple-Mail=_7CB45CB7-F310-4F07-8AC9-447C364B58C9 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii

On 17 Feb 2022, at 11:30, Daniel O'Connor <darius@dons.net.au> = wrote:



On 17 Feb 2022, at 19:50, Daniel Braniss <danny@cs.huji.ac.il>= wrote:

If that is the case then the chip/driver are working fine = since that requires bidirectional communication etc..


but that works only if I power up = the board while pressing a button, then it also appears as /dev/ttyU0, = and
so then I can flash, after reset, the device is gone = and there are errors ( BTW, the flashed image workes):

Feb 17 09:46:59 pampero kernel: usbd_setup_device_desc: = getting device descriptor at addr 4 failed, USB_ERR_IOERROR
Feb 17 09:47:00 pampero kernel: usbd_req_re_enumerate: = addr=3D4, set address failed! (USB_ERR_IOERROR, ignored)

What sort of dev board is it?
m5 stamp C3U


Seems very strange the USB = UART would behave differently unless it's wired up in an unusual way = IMO.

--
Daniel O'Connor
"The nice thing about standards is that there
are= so many of them to choose from."
-- Andrew Tanenbaum



= --Apple-Mail=_7CB45CB7-F310-4F07-8AC9-447C364B58C9--