A 6-pin mini-DIN connector can be used to connect a PS/2 PC-style keyboard directly to the PICAXE chip.
Read a keyboard key press code
This program will receive key presses from a PS/2 keyboard and display the key press code in the 'b1' variable.
Read a keyboard character
This program will receive key presses from a PS/2 keyboard and display the character in the 'b1' variable. Note that this example will only work with PICAXE-M2 chips which support the 'kbin #variable' command.
A PS/2 keyboard can be connected using two generic terminal block create modules to carry the data and clock signals required for the keyboard.
Bill of Materials
|6-pin mini-DIN socket||?||1||Buy Now|
|4k7 resistor (pack 100)||RES4K7||1||Buy Now|
Submit Your Own Code!
You must be logged in to submit code examples. Login now.