The Dialup Experience
28 May 2021 - faintshadows
Over the past week or so, I have been experimenting with giving my Acer Pentium 1 box a taste of the information superhighway, through emulating a modem over a null modem cable connected to a modern(ish) computer.
It was not fun. It never is with my projects, is it?
Join me as we go back in time, I'll keep things (somewhat) short. I have a null modem cable, and I've used it for a few years. It worked fine, but it had a fatal flaw. The RTS/CTS lines weren't crossed like they should be in a proper null modem. No worries I say, I'll use XON/XOFF. I thought this was part of the issues I was having, but it's never that simple.
I've always been fascinated by dial up, my grandmother had it when I was smol, and I thought the sounds were the coolest shit. Back at home we always had cable, so the concept of having like, internet?? Over the phone????? Crazy shit.
I had known about the tcpser
project for a while, and used it a few times, but not to much success,
usually not even able to get anything out of it, due to not knowing how to
disable RTS/CTS handshaking and use XON/XOFF. But this time around I was
directed to two different approaches. Both are centered around using the
Raspberry Pi's serial, which while I could have also done, I'd need to buy a
level converter or USB to serial adapter. But I looked at the programs, and
this was all just shell scripts and pppd
mostly. I could adapt it all to use
/dev/ttyS0
instead of /dev/ttyAMA0
or /dev/ttyUSB0
. And that's just what
I did.
I won't go into the details about setting it up, I'll link to those two
articles and those who don't know can take a look.1 2 But it's all set up,
and the daemons are awaiting the connection. Initially, I had to poke around
to make sure XON/XOFF was used and NOT RTS/CTS. That was easier said than
done. In the end, making sure Win95 was set in every place possible to use
XON/XOFF on the COM1 port, and to set tcpser's modem init string to &K4
would get the job done. So I connected, and I had real, TCP/IP, on Windows
95! I was able to visit my site (this site) in IE 3.0 and Netscape 3.0!
I thought it was all good, but then when I went to really try this out, and download DOOM from my local webserver, things fell apart fast. I couldn't download files larger than ~120K! They'd just… Stop downloading, and everything just stopped working. I tried 9600bps, I was at 38400 before (the highest Win95 would let me set this COM port to). Same result, but slower this time. Weird, I thought, so I tried without XON/XOFF, same thing. I was changing every setting I could that would maybe have an impact on the performance, nothing! Later I was able to get files to download to around 500-530K, before the same thing would happen.
I decided to grab Wireshark and look more into it, and WOW this is an awful connection! So many TCP errors! TCP Out-Of-Order, TCP Dup ACK, TCP Retransmission, TCP Window Full, all of it. It wasn't constantly that, but every few seconds of transfer there'd be a big batch of them, the download would look like it froze, and then it would continue on. Then at the magic number, right after 500K, I'd start getting a lot of retransmissions, and then everything stopped. And the server would just send a retransmission every minute or more with no response back from the Acer.
Interestingly enough, I would only really get all these TCP errors with binary files, not plaintext files! I'd get some but not nearly as many. Granted, the largest textfile that was in my DOOM folder was only around 120K which was doable, even with all the errors. I've yet to figure out why this is.
A few more hours of trying different settings, adding ferrite chokes to the serial cable, and screaming internally. I ordered another null modem cable off eBay. A week later, it shows up, and after checking the pins, it indeed does have the fabled RTS/CTS lines crossed. Great! I thought, this will fix all my issues!
Nothing changed!
Not a damn thing! It was the exact same behaviour as before! I'm at a loss at this point, and I'm trying other computers to act as the host, same issue. I tried my 386 with Arachne, which was godawful, don't ever use that on there. No luck. At that point, with everything else swapped around and tried out, I suspected maybe the software is to blame. So I switch from the tcpser setup to this other one 2 that just uses a shell script to emulate the hayes modem. Commands ready, Wireshark loaded up, I connect. And all seems fine, same experience. I go to download DOOM.EXE, which is around 700K. Remember, I've never gotten past 530K. Wireshark is losing it's mind, but the download continues to go on! It finished! No way!!
So I push my luck. If I can download the 700K file, what about DOOM.WAD
coming in at a massive 12MB. An hour later, it's done! Somehow, just
changing the program (which was still just using pppd
anyways), it errors
constantly but it can at least download a whole 12MB file without failing.
As long as I just don't look at wireshark and see the insane amount of bad packets, it's fine. I have ""dial up"" internet at 38,400bps. It could maybe be a little faster if I could get Win95 and pppd to negotiate a compression scheme, but so far I've yet to get that to work.
I am calling it here, I finally have a somewhat decent analog to dial up internet. It's not perfect, the dropped/resent packets are insane, but I can download DOOM.WAD. I'm not done with the experimenting though, I'd like to get 90s Linux (or Mac even) and see how those handle this janky setup. Those will likely go into their own posts, so be on the lookout for those!
My end goal for this dial up emulation extravaganza would be to obtain a phone line emulator, and either continue to use a computer as a host and use 56K modems, or get a modem module for my Cisco 1841, and finally have a use for that thing. That'll get me better speeds than 38,400bps, and much better software support and hopefully no dropped packets.
~faint