Archive for February, 2022

Northstar Advantage Keyboard tester and simulator

February 20, 2022

Many months ago my friend Louis told me about a couple of old computers he found and was wondering how to diagnose them. I mentioned a couple things, but being on the other side of the country there was a limited amount I could do to help. He solved that by buying them both and shipping them to me.

grungy

There’s a lot to go over with these machines, but I’ll start with the keyboards. They are “keytronic foam and foil’ keyboards, which means they use hard to find chips and are capacative. When I got mine the foam discs had entirely disintegrated, every single one. Luckily this is the same keyboard the original Compaq portable uses (same style, not same exact PCB) so there are reproduction foam pads you can buy. I went through the exhausting process of disassembling the entire keyboard, hand washing and scrubbing every part, drying, and reassembling them. I also stripped and scanned one of the PCBs in case anyone wants to recreate it. The scans are on the Internet Archive. Once I had the keyboards all cleaned up (oh yeah, I did this to two of them) it was time to test them. Frank and I used the working Northstar to watch the transactions on a ‘scope and were able to design an arduino based tester to poll the keyboard just like the northstar does. Because of the speed we wanted to go this code uses direct port manipulation and thus is not portable to different platforms like arduino code usually is. We built this tester on an arduino uno, but any atmega 328 (or possibly 168) board should be compatible.

also note the nice shiny new DIP-to-DIP ribbons I got from digikey

In building this tester I found one of the keyboards had a bad controller chip. These controllers are interesting because they capacatively sense the pins being pressed (seriously, look at the layout, that’s some analog wizardry), but also there’s two chips to do the key scanning. You present one of them with a column address to scan and then you get all the rows in parallel on the read. The timing for this doesn’t have to be super precise, but to make sure we were polling them just like the northstar we decided to tweak it to be pretty exact. There’s also two flip flops that drive the indicator LEDs on the keyboard that can be exercised by this code.

The next set of code was… harder. This is the code that simulates being the keyboard. It takes serial commands to put virtual keys up and down, then ques them up and outputs the current ‘state’ of the keyboard to the northstar when the 8035 peripheral processor polls the keyboard. This arduino code can be driven manually, but Frank wrote a python script that can stream keypresses to the northstar. It’s open loop, but fairly reliable. Combining this with the monitor rom in the northstar you can poke entire assembly programs into ram, then jump to execute them. It’s a little invasive because you have to take the keyboard out, but if you just found one of these the foam has probably collapsed and you have to do that anyway to fix it. This code can also serve as a base for a complete replacement keyboard. I have the PCB scan for mounting holes and key positions, you could replace the serial reading code with a matrix scan routine and make a custom keyboard using whatever key switches you like and never have to deal with falling apart foam or hard to find chips ever again. Speaking of chips, because it took so long to ship them I thought one got lost and ended up with more than I need. If anyone needs one or two 22-908-03B chips just ask and I’ll mail them to you. They aren’t the set of two you need to build one of these keyboards, just one half that might help fix a broken board.

the bootloader for this was streamed over the keyboard simulator

That’s the first part of repairing these machines, but there’s a lot more to come. They use hard sectored floppies and apparently HxC on a gotek can emulate that. I want to get an esp8266 talking to a serial card in synchronous mode so you can boot from that (or the network) from the initial boot menu, there’s a guy out there that has his own python program for talking to these machines and using them to read and write hard sectored discs, I made a replica serial board based on mine that I will have available if anyone wants it, I’m working on a replica hard drive controller and a replica parallel IO card as well. If you have any information on the Northstar Advantage 8088 card or the floating point card I’d like to replicate those. I’m also looking for information on the later motherboard with the extra I/O slot. No idea what that’s for.

Pictures above and beyond those embedded in this article are here.