home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!ogicse!uwm.edu!zaphod.mps.ohio-state.edu!think.com!unixland!rmkhome!rmk
- From: rmk@rmkhome.UUCP (Rick Kelly)
- Newsgroups: comp.os.linux
- Subject: Re: 57.6Kbps under Linux -- some results...
- Message-ID: <9209130031.59@rmkhome.UUCP>
- Date: 13 Sep 92 05:31:50 GMT
- Article-I.D.: rmkhome.9209130031.59
- References: <!nwn!6h.harp@netcom.com>
- Reply-To: rmk@rmkhome.UUCP (Rick Kelly)
- Organization: The Man With Ten Cats
- Lines: 77
-
- In article <!nwn!6h.harp@netcom.com> harp@netcom.com (Gregory O. Harp) writes:
- >Well, since I opened my big mouth and said that 57.6Kbps probably
- >wasn't possible, I ended up doing some experimenting with exactly
- >that.
- >
- >I'll summarize for those who don't want to read the whole thing. I
- >can _almost_ do 57.6Kbps with my 50Mhz 486DX. I only have 16450
- >UARTs, so those of you with 16550A UARTs and very fast machines should
- >be able to do it.
- >
- >[WARNING! Kernel-hacking ahead!]
- >
- >First, I had to hack the kernel serial code to handle that speed.
- >Linux currently only supports 38.4Kbps as "shipped." BTW, I'm working
- >with version 0.97pl4 of the code, if you want to follow along. It's a
- >matter of modifying the table on lines 328-330 of
- >kernel/chr_drv/serial.c. This is the baud rate divisor table.
- >
- >Anyway pick an entry like the value 384, which is 300bps, and change
- >it to 2, which is the divisor for 57600bps. You might want to replace
- >a less-common baud rate like 50 baud (the divisor to change is 2304),
- >but most terminal software won't support that. BTW, if you really
- >want to try it, the divisor for 115Kbaud is 1, but good luck! ;)
- >
- >If you want to figure it out for yourself, the formula is:
- >
- > divisor = 1843200 / (baud * 16)
- >
- >Once you rebuild the kernel (Remember to back up! Oops, am I too
- >late? ;) ) and reboot, you should be able to tell any software that
- >you want to use 300 baud (or whichever entry you modified) and you
- >will actually be set up for 57.6Kbaud.
- >
- >Now, I tried hooking up to my Amiga 3000 at this rate. I had some
- >success, but the file I downloaded was corrupted somewhat and I only
- >pulled about 4K/sec out of the transfer.
- >
- >My next experiement was to null-modem my two serial ports together
- >and do the following:
- >
- > cat </dev/ttys0 >foo2 &
- > cat foo >/dev/ttys1
- >
- >I transferred a 1430343 byte file in 4 minutes and 9 seconds, meaning
- >I pulled 5744 bytes per second! 57.6Kbaud!
- >
- >Now, once again, the file was a little corrupted, but tar was able to
- >identify it as a compressed archive and it at least made it through a
- >hundred K or so before crapping out.
- >
- >I'd be really interested in seeing what a 486DX50 with 16550A UARTs on
- >it can do. If someone out there has one (or they want to swap I/O
- >cards with me ;) ) send me mail at harp@netcom.com and we'll talk.
- >
- >BTW, the reason I keep saying 16550A and not just 16550 is because a
- >glance at the code tells me that Linux is only enabling the FIFO if
- >the UART is the 16550A (refer to lines 265-272 of serial.c). Linus,
- >can you tell us why you don't use the FIFO on the 16550? I've
- >personally never used the FIFO because my projects were for 16450
- >UARTs, but I'm not aware of any problems.
- >
- >Oh well... Gotta go. Glad the weather's nice here in Dallas. Gonna
- >be a nice afternoon for some horseriding!
-
-
- The NS16550 has broken FIFOs, they don't work correctly. The NS16550A or
- NS16550AFN have had the bugs fixed. The N in AFN means a ceramic case for
- better cooling. JDR Microdevices has the NS16550AFN in stock with the part
- number listed as NS16550A. I suspect that most reputable chip dealers sell
- the correct part.
-
- There are also some Western Digital chips that claim to be 16550A compatible,
- but they are broken also.
-
- --
-
- Rick Kelly rmk@rmkhome.UUCP unixland!rmkhome!rmk rmk@frog.UUCP
-