now | writings | rss | github | twitter | contact

WiFi232 with a Macintosh 512ke

posted to writings on jun 23rd, 2017 with tags mac and nerd, last updated on jun 18th, 2017

Back in 2015, I created a BBS for Lobsters that worked in a web browser via WebSockets. After getting an old Mac earlier this year, I wanted a way to access the BBS from the Mac as natively as I could. Adding telnet and SSH frontends to the BBS was not too difficult, but being able to login from my Mac took a bit of work.

Macintosh 512k Enhanced

In January I got a Macintosh 512ke on eBay and spent some time fixing it up. The screen would occasionally flicker and shut off, but banging on the side of the case would sometimes bring it back. Some research pointed me to the analog board needing some capacitors replaced, which has completely solved the problem.

The Mac had obviously come from a smoker's house so I was hesitant to even store it in my office because it smelled so bad. I took everything apart including the keyboard and mouse, scrubbed everything that wasn't electronic, and used zeolite rocks to remove the smell. I did a light retr0bright treatment on everything, though these early Apple computers originally came in a beige color before Apple switched to a more greyish "platinum" color, so the restoration was not very dramatic.

Communicating With a 30-Year-Old Computer

Instead of constantly swapping floppy disks, I got the wonderful Floppy Emu that plugs into the drive port on the back of the Mac and set it to emulate an HD20 hard drive. This also makes it relatively easy to transfer data between the Mac 512ke and my MacBook by swapping the Floppy Emu's microSD card into my MacBook and using Mini vMac on macOS to boot a virtualized Mac environment off the HD20 disk image on the SD card.

With MacTerminal installed, I set up the Mac as a serial terminal for an OpenBSD computer running on a BeagleBone Black. This took some time to figure out because these early Macs use RS422 serial ports instead of RS232, so I had to make a custom pin conversion between the Mac and the BBB's serial port.

Once connected to OpenBSD, I was able to SSH into the Lobsters BBS, but I wanted a more authentic experience for the Mac.

A Detour Into LocalTalk

As memory constrained as the Mac 512ke is, it is supposedly capable of doing native TCP/IP over Ethernet. I found an Asante Talk bridge on eBay and tried setting up TOPS Terminal and its TOPS TCP/IP stack. Unfortunately I was never able to get this working as I could never get the Asante Talk device to send any AppleTalk traffic to my network.

Despite being "native" TCP/IP, this type of setup needs a lot of external components, not the least of which is a separate AppleTalk gateway that has to be running on a local network server to unencapsulate the TCP/IP traffic.

WiFi232

Soon after being defeated by LocalTalk, I discovered the excellent WiFi232 which is a small WiFi-enabled board with an RS232 DB25 serial interface that emulates a Hayes-compatible modem. Instead of using ATDT 5551212 to dial a phone number through a modem, the WiFi232 allows one to do ATDT lobste.rs and establish a telnet connection over TCP/IP. The computer (and any associated terminal/modem software) thinks it's talking to a serial modem and the WiFi232 does all of the legwork of connecting to WiFi, getting an IP via DHCP, and doing telnet negotiation over TCP/IP. It even has an AT-compatible settings menu, firmware upgrades, and a web server for more configuration, though I never bothered to set that up.

The WiFi232 can do proper telnet negotiation with the ATNET1 configuration setting, and negotiates a TTYPE of ANSI. MacTerminal doesn't support the 437 codepage, so most BBS line graphics look wrong, though I did transfer over an old copy of Z-Term which does support 437. Unfortunately since the Mac's monitor is black and white, ANSI colors don't gracefully degrade so most large graphic areas (like the Lobsters BBS welcome screen) look solid black. I was able to fix some telnet negotiation bugs in my telnet daemon that I came across while playing with the WiFi232, but due to the limitation of the Mac's screen, I've disabled telnet negotiation for now with ATNET0 so I get the ASCII version of the Lobsters BBS. Perhaps I'll add an ANSI-without-color version to Lobsters after prompting the user if they want color, like many other BBS packages do.

One configuration setting I wish the WiFi232 did have was a way to keep telnet negotiation enabled but change the TTYPE that it reports. The WiFi232 creator was quick to implement being able to set a new TTYPE with a new AT$TTY=n setting. Highlighting another great feature of the WiFi232: updating to a new firmware is as easy as just issuing an ATUPDATE command.

Using the WiFi232 with the Mac still required my RS422-to-RS232 wiring mess, and now also required a DB9-to-DB25 adapter. The whole contraption was getting a bit messy and eventually I wanted a more elegant solution.

Apple Modem 300/1200

For the early compact Macs and the ][, Apple made an external 300/1200 baud modem. Eventually I found one on eBay but it was in rough shape and had no AC adapter, though it did include a genuine Apple serial cable. Since the modem is pretty long (to accommodate a telephone placed on top of it), I thought it would make a nice housing for my Wifi232 and rats nest of wires.

Unlike my Mac, the modem was very yellowed and a couple retr0bright sessions lightened it up quite a bit. Unfortunately I left it outside in the sun a bit too long without moving it, so there appears to be a bit of bleaching in some areas.

Before and after retr0brighting with 40-volume developer creme

Initially I had planned on removing the modem's entire circuit board, but I decided to retain the original phone jacks and other ports on the back even if they weren't going to be used. Since these ports are attached to the circuit board and the board is held into place through the screw holes in the case, I would have had to make a new board out of metal or wood, cut it to size, de-solder all of the components from the circuit board, and then attach them to the new platform in the precise location to fit in the slots in the rear of the case.

Since the modem is not very useful as vintage hardware without an AC adapter and is limited to 1200 baud anyway, I decided just to cut the circuit board to be able to retain the rear ports and still give room for the WiFi232. While the modem originally had a strange 4-pin AC adapter connector, the WiFi232 uses mini-USB for power so I added a mini-USB extension cable and glued it in place of the original port.

The WiFi232 installed, the modem's new rear ports, and USB power and serial cables

The original modem board had a green LED that shined through the front case when powered, but I had cut off that section of the board. I soldered some leads to the WiFi232's power pads and then hooked up a new green LED and resistor to them to restore the power light.

The modem also had a toggle switch in addition to the AC port, and in the future I'd like to wire in a new toggle switch to kill power from the micro-USB cable. Right now I have to remove the micro-USB cable to power down the modem each time. The Mac actually sends 12V of power through one of the RS422 port pins so it might be possible to just power the WiFi232 off it whenever the Mac is turned on, but for some silly reason that seems less genuine.

Now that the WiFi232 is completely enclosed in the Apple modem case and only has a micro-USB power cable and Apple serial cable coming out of it, I think it fits in nicely with my Mac.

I recently acquired a Western Electric 2500MM telephone to put on top of the modem like it was designed to accommodate.

Comments? Contact me via Twitter or e-mail.