All of lore.kernel.org
 help / color / mirror / Atom feed
From: Johan Hovold <johan@kernel.org>
To: Russell Senior <russell@personaltelco.net>
Cc: Johan Hovold <johan@kernel.org>,
	Aidan Thornton <makosoft@gmail.com>,
	Linux USB Mailing List <linux-usb@vger.kernel.org>,
	Grigori Goronzy <greg@chown.ath.cx>,
	Karl Palsson <karlp@tweak.net.au>,
	Eddi De Pieri <eddi@depieri.net>, stable <stable@vger.kernel.org>
Subject: Re: [PATCH 06/13] USB: serial: ch341: fix initial line settings
Date: Tue, 20 Dec 2016 09:42:40 +0100	[thread overview]
Message-ID: <20161220084240.GA26724@localhost> (raw)
In-Reply-To: <CAHP3WfMDqk0sROFYoT6ZNy1V-dUqPFdTMHsP+V3vgwcy0Ehb4Q@mail.gmail.com>

On Mon, Dec 19, 2016 at 08:40:53AM -0800, Russell Senior wrote:
> On Mon, Dec 19, 2016 at 2:58 AM, Johan Hovold <johan@kernel.org> wrote:
> > On Sat, Dec 17, 2016 at 03:27:43AM -0800, Russell Senior wrote:
> >> All testing is with minicom.
> >
> > Thanks for this through report.
> >
> >> Starting with 00013-gc510871:
> >>
> >>   In 8-bit mode, interoperates correctly with pl2303.  Switching to
> >> 5-bit mode on both sides (I get unicode boxes of indeterminate
> >> values).  Switching back to 8-bit mode on both sides, I get correct
> >> text out both sides.  Switching just the ch341 side back to 5-bit
> >> mode, I get 0xff's out on the pl2303 side (still in 8-bit mode).  This
> >> would seem to imply that byte-size changes are working on this
> >> version.  Changing baud rate also works.
> >
> > Can you verify also what comes through in 5-bit mode is indeed what's
> > expected (e.g. 'a' -> 0x01, 'b' -> 0x02, ...)?
> >
> > You can enable usb-serial debugging to get a log of what is received:
> >
> >         modprobe usbserial dyndbg==p
> >
> 
> Yes, it does seem that I'm getting the 5-bit truncation.  Here is an
> excerpt from the prodigious logs, in this case sending a 'Z' from
> pl2303 and receiving an 0x5a on the ch341.  The same sort of thing,
> e.g. 'A' (0x41) from the ch341 lands as an 0x01 on the pl2303, 0x42 ->
> 0x02, etc.

Thanks for confirming.

> > Ok, so the init command cannot be used to switch baud rate for these
> > devices.
> >
> > Could you see if you can communicate using 19200 baud (when using this
> > or the next commit), which is the default baud rate for the devices I
> > have (i.e. default settings are 19200 8N1).
> 
> 19200 8N1 on this commit does not work.

Ok.

Johan

      parent reply	other threads:[~2016-12-20  8:42 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20161214152810.14682-1-johan@kernel.org>
2016-12-14 15:27 ` [PATCH 01/13] USB: serial: ch341: fix initial modem-control state Johan Hovold
2016-12-14 15:27 ` [PATCH 02/13] USB: serial: ch341: fix open and resume after B0 Johan Hovold
2016-12-14 15:28 ` [PATCH 03/13] USB: serial: ch341: fix modem-control and B0 handling Johan Hovold
2016-12-14 15:28 ` [PATCH 04/13] USB: serial: ch341: fix open error handling Johan Hovold
2016-12-14 15:28 ` [PATCH 05/13] USB: serial: ch341: fix resume after reset Johan Hovold
2016-12-14 15:28 ` [PATCH 06/13] USB: serial: ch341: fix initial line settings Johan Hovold
2016-12-16 13:19   ` Aidan Thornton
2016-12-16 14:46     ` Johan Hovold
2016-12-16 16:04       ` Russell Senior
2016-12-16 16:13         ` Johan Hovold
2016-12-16 17:30           ` Johan Hovold
2016-12-17 11:27             ` Russell Senior
2016-12-19 10:58               ` Johan Hovold
2016-12-19 16:40                 ` Russell Senior
2016-12-19 22:12                   ` Russell Senior
2016-12-20  9:13                     ` Johan Hovold
2016-12-20 12:38                       ` Russell Senior
2016-12-20 16:07                         ` Johan Hovold
2016-12-20 16:13                           ` Johan Hovold
2016-12-20 20:09                           ` Russell Senior
2016-12-20 20:49                             ` Johan Hovold
2017-01-09 13:51                               ` Johan Hovold
2017-01-12 14:49                                 ` Johan Hovold
2016-12-20 15:31                       ` Russell Senior
2016-12-20 15:52                         ` Johan Hovold
2016-12-20 20:05                           ` Russell Senior
2016-12-20  8:42                   ` Johan Hovold [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161220084240.GA26724@localhost \
    --to=johan@kernel.org \
    --cc=eddi@depieri.net \
    --cc=greg@chown.ath.cx \
    --cc=karlp@tweak.net.au \
    --cc=linux-usb@vger.kernel.org \
    --cc=makosoft@gmail.com \
    --cc=russell@personaltelco.net \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.