Straight as a laser beam!
All the keys line up nearly perfectly. There’s a couple of ‘iffy’ ones that need re-soldering, but I’m far too excited to bother with little things like that
And. here’s the first fit…………..(complete with Spectrum magazine mouse mat!)
All that’s great that the hardware’s complete – But, the software will make this work.
Fortunately, the arduino has some great examples out there that turn a conventional C64 keyboard into a USB Keyboard!
https://github.com/dabonetn/C64USBKey/tree/master/C64Key3-ProMicro
http://www.lemon64.com/forum/viewtopic.php?t=55650
are a couple that I’ve found – it should have been as simple as use my own schematic / matrix mapping – very easy – There’s enough pins on theArduino Pro Micro that I’m using for a 9×9 matrix – So, we get to have Restore also!
Keyboard matrixes are ‘fun’ when they don’t work first time….I’m not brand new to Arduino stuff but i’m no expert either, I just muddle through and try to figure out as I go along, Youtube’s great, as are dozens of other sources…
Arduino’s are ‘fun’ in that each pin has multiple pseudonyms depending on what’s doing the programming
I’ve found a superb link which proved extremely useful much later on in getting this going
https://deskthority.net/wiki/Arduino_Pro_Micro#Pinout
And, the main culprit –
The original Arduino map had the following in for the rows and columns, this 8×10 matrix has enough positions to allow joysticks to work also –
The code below simply says which pin of the arduino connects to which pin on the keyboard matrix above!
//int RowPinMap[8] = {12, 6, 7, 8, 9, 10, 11, 5};
//int ColPinMap[10] = {13, 14, 15, 20, 17, 18, 19, 16, 1, 2};
And, after much, much trial, error, swapping numbers around and head scratching……This is what I needed to change my code to
int RowPinMap[8] = {9, 3, 4, 5, 6, 7, 8, 2};
int ColPinMap[10] = {10, 16, 14, 21, 18, 19, 20, 15, 1, 0};
Which, resulted in the Arduino being recognised in Windows and………..
Buzzing! – BUT, there’s a bit of a problem.
This code doesn’t work with the C64 Mini!
For some reason, the Mini’s mini-linux OS won’t recognise the Arduino’s USB ID and, Basic brings up nothing…..
Back to Google