As mentioned before, there’s loads of ‘keyboard matrix’ tutorials out there, so, i’m going to not bother with any of those yet and work backwards a bit.
IF i’m making a micro C64 Keyboard for a mini C64, I mayaswell make the thing backwards compatible so that it could be used on a real C64…
The C64 Matrix…………(image pinched from THIS PAGE)
This it’s quite quick to knock this up in EasyEDA
The Shift Lock key looks a bit ‘odd’ as it just parallels up with the shift key.
I’ve thrown in some Debounce diodes also – because all the top mechanical keyboards have it, so why can’t I (no idea if this is a good idea yet, but easily removed before I get a PCB finalised) I’m not too worried about the Arduino bits yet – i’ll bolt on the decoding circuitry later – this is still just an excercise to see if it’s possible!
This isn’t the first version – The pic shows the newest footprint before I figured out the issue below
After creating my own custom SMT switch footprint / component and arranging the parts on the board – I hit a few snags – Have a look at the layout below…. you’ll see that the SMT legs just stick too far out
Easy enough, rotate every other switch so some are ‘up / down’ , some are ‘left / right’ with the pads.
That does fit – just, BUT, i’m going to have to cut a leg off 5 or more switches to stop them mechanically fouling and electrically shorting!……D’oh!, Possibly back to the drawing board with the switch choice?
The diodes i’ve chosen (for now) are a larger SOD123 package, about 2.6 x 1.5mm or so…one of the larger packages and I just happen to have a few in the shed (somewhere!)
The row of connectors on the right is just a generic 2.54mm space 20 way header. This’ll probably not be populated in my ‘final’ version that sits inside the Mini, BUT, i’ll leave the pads on the PCB so it could be turned into a genuine working C64 Keyboard 🙂