An ASCII Serial keyboard using a Picaxe 08M

saunj

Senior Member
This home-made keyboard was used long ago with a home-built terminal which was used at my work with a Radio Shack XENIX computer, which used 8" floppies and a 10 megabyte drive!
Of course, the computer and terminal is long gone but I couldn't bear to scrap the keyboard because of the lovely mahogany case. Besides, it uses high-quality hall-effect keyswitches.
The keyboard originally had no additional circuitry, being connected by parallel wires to the terminal. I took pity on it when I needed key inputs to my projects, as an easier alternative to the picaxe basic KEYIN command, since this old keyboard is plain ASCII and needs no decoding. Besides, the KEYIN command is not available in all Picaxe chips. The adaptation is very simple, and an 08M does it easily. The keyboard uses two flip-flops to handshake with the keyboard strobe, prevent double and missed keystrokes, and clock the key code into a shift register. This gives a purely static interface with the 08M. This keyboard has no LEDs, since the shift lock key is mechanically bi-static, but I added a bi-color LED for fun. It is powered from the connected device using pins 1 and 6.
The output is RS-232 Serial at 2400 baud, using a direct connection. It was necessary to connect the serial input line only when programming to prevent input signals from resetting the Picaxe. When programming, an external null-modem and power source is intersposed bewteen the keyboard and the PC. This re-connects the serial input.
The code includes an option selected by the F2 key to output as two-hex instead of ASCII, which was put in mainly to find out what the function keys outputted. There are a lot of such codes, since the shift and control keys modify the output of most keys.
For more information, please see my web site:
http://www.worsleyassociates.com/Projects/SerialKeyboard/index.html
 

Brietech

Senior Member
I love the keyboard, that's some beautiful craftsmanship =) I actually had just the opposite problem, in that I had a computer from around 1984 (a Kaypro 2) that needs a 300 baud, TTL serial input for the keyboard, but I wanted to use a PS/2 keyboard with it. If I ever get around to it, I was thinking about just sticking an 18X waiting on "keyin" in between =)
 
Top