Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Feb 2022 20:18:40 +1030
From:      "Daniel O'Connor" <darius@dons.net.au>
To:        Daniel Braniss <danny@cs.huji.ac.il>
Cc:        freebsd- <hackers@freebsd.org>, "usb@freebsd.org" <usb@FreeBSD.org>
Subject:   Re: usb CH9102 serial chip
Message-ID:  <D227A4C0-8870-422E-BED5-0B173AB13345@dons.net.au>
In-Reply-To: <17E09096-A45B-43F5-BFE4-7645E8A2275D@cs.huji.ac.il>
References:  <C8258774-B183-48DD-905F-260F5999152C@cs.huji.ac.il> <7DD6E1FA-3EA4-44D9-A272-9E51FB9F2BFC@dons.net.au> <C07DE6BE-65AB-43FA-8C52-2A7D0197767E@cs.huji.ac.il> <013FB4BA-7D32-4FFB-AFD3-E594CF638A66@dons.net.au> <17E09096-A45B-43F5-BFE4-7645E8A2275D@cs.huji.ac.il>

next in thread | previous in thread | raw e-mail | index | archive | help


> On 17 Feb 2022, at 20:04, Daniel Braniss <danny@cs.huji.ac.il> wrote:
>> On 17 Feb 2022, at 11:30, Daniel O'Connor <darius@dons.net.au> wrote:
>>=20
>>> On 17 Feb 2022, at 19:50, Daniel Braniss <danny@cs.huji.ac.il> =
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

According to the docs the 'U' variant doesn't have a serial chip on it. =
If you look at the schematic the USB +/- pins go straight to the MCU.

I suspect it has a boot loader which emulates the CH9102, when your code =
is running it is whatever that does with the USB port, so if there is a =
bug or whatever then it will exhibit weird behaviour.

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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?D227A4C0-8870-422E-BED5-0B173AB13345>