Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #274157
| From | Joe <joe@jretrading.com> |
|---|---|
| Newsgroups | linux.debian.user |
| Subject | Re: battery tester |
| Date | 2024-10-29 20:10 +0100 |
| Message-ID | <JCZLj-59JJ-5@gated-at.bofh.it> (permalink) |
| References | (1 earlier) <JBcWl-3YAB-1@gated-at.bofh.it> <JBkTT-43Jp-7@gated-at.bofh.it> <JCWaK-57tl-5@gated-at.bofh.it> <JCWkp-57wx-1@gated-at.bofh.it> <JCXq9-589i-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue, 29 Oct 2024 17:36:18 +0100 tomas@tuxteam.de wrote: > On Tue, Oct 29, 2024 at 04:28:14PM +0100, tomas@tuxteam.de wrote: > > On Tue, Oct 29, 2024 at 11:13:28AM -0400, Stefan Monnier wrote: > > [...] > > > > The CH340 is a real USB<->serial converter, so somewhere inside > > > the device is a real serial connection which speaks at a specific > > > speed and the CH340 probably has to match that speed if we want > > > to get valuable output, I suspect. IOW, I think it's not "just > > > an abstraction layer". > > > > Hmmm. An interesting point. Yet another rabbit hole =:-o > > Yep, after thinking a bit and poking the interwebs for good measure, > I'm convinced now that you are right. The stty sets the UART "at the > other end" of the USB. So it better be right. > > Of course one might hope it starts up with a sensible value, but hey. > > Cheers If the serial parameters are wrong, garbage characters will appear, there won't be nothing at all. You play with the numbers until it isn't garbage any more. This does require that the unknown source provides continuous or at least frequent transmissions without getting proper returns or handshaking. There are systems which will automatically recognise baud rate by assuming the shortest mark or space represents the rate, but this needs fairly good signal strength and reasonable jitter to work. It generally can't be done well through the UART, it needs a separate comparator to bypass the UART's processing. These days serial is usually one wire in each direction and a ground, in earlier days it might be necessary to deal with hardware handshaking lines, which had standard functions in the telephone business but were often used elsewhere for proprietary signalling. I once needed to deal with a serial remote control system which used the parity bit as a flow control system, something which utterly chokes a standard UART. I needed to convert this to standard usage to send it through a conventional serial link and back again at the other end. -- Joe
Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: battery tester "Roy J. Tellason, Sr." <roy@rtellason.com> - 2024-10-24 20:10 +0200
Re: battery tester Joe <joe@jretrading.com> - 2024-10-24 22:50 +0200
Re: battery tester <tomas@tuxteam.de> - 2024-10-25 07:20 +0200
Re: battery tester Stefan Monnier <monnier@iro.umontreal.ca> - 2024-10-29 16:20 +0100
Re: battery tester <tomas@tuxteam.de> - 2024-10-29 16:30 +0100
Re: battery tester tomas@tuxteam.de - 2024-10-29 17:40 +0100
Re: battery tester Stefan Monnier <monnier@iro.umontreal.ca> - 2024-10-29 20:10 +0100
Re: battery tester Joe <joe@jretrading.com> - 2024-10-29 20:10 +0100
Re: battery tester Charles Curley <charlescurley@charlescurley.com> - 2024-10-30 03:00 +0100
csiph-web