Time flies. About a year and a half ago, I had an all too brief look at the BMC64 Commodore 64 emulator for the Raspberry Pi (and the corresponding ZX emulator).
Although the emulator was already impressive by then, I had some minor gripes with it. Now it's a time for another look.
On my Raspberry Pi 3B+, the system boots in a few seconds, comparable to a sluggish real C64. Nothing to complain here! Hit F12 to enter the menu.
The video options are now extensive, and I could get a good picture out of the 1084S monitor. It's worth mentioning the Y offset may need to be changed to 1, otherwise the scanlines are "between" the actual monitor lines and will look blurry and incorrect.
The picture is obviously a bit too perfect :) as it doesn't have the black bleeding and other C64-style artefacts. But it certainly doesn't have any moiré effects. (Any such in the images are result of the photo processing.)
Trying Buck Rogers again made me feel as if the lag had been further minimized. I could not really detect any significant amount of delay here.
Based on vice, the emulator now supports the other Commodore computers too, such as VIC-20, PET and Plus/4. I didn't try these yet, but it is possible these are not as perfected as the vice C64 emulation (Plus/4 people keep saying this) but it's a good bonus.
Although I don't remember this either, the sound may have been improved and there are likely more sound options than when I last looked, as seen from the above menu.
Still, SID emulation is tricky to perfect and this is an area where differences are easier to spot.
Real C64 keyboard
The overall impression was so good I was motivated to test a real Commodore keyboard. It can be wired to the Raspberry Pi GPIO connector with no additional electronics. Last time I only tried the 9-pin joystick.
A PCB design exists for just dropping in the keyboard connector and the joysticks (also a power switch), but now I could test it with breadboard wires.
Without such a PCB, it's not that obvious how to place the Raspberry in the case, but it's a start.
A tip for mounting a Raspberry on some surface. First drill through one hole, then screw the Rpi in place. Then drill another hole through the Rpi circuit board hole. Put that screw in place too and then drill the two remaining holes, again through the circuit board.
This way the holes will be more accurate than trying to mark positions for drill holes using the Rpi holes or with a ruler.
I got a bit sidetracked at first as although I had a loose C64C case and keyboard, I didn't find my keyboard mounting brackets.
So I had to improvise something. Luckily as the C64 board doesn't have to be there the shapes aren't that specific, as long as they hold the keyboard in the correct place.
I took the basic dimensions and some inspiration from crashmeplease's Ultimate64 Keyboard Mounting Brackets (https://www.thingiverse.com/thing:3051450) STL models, but of course my mounts are not 3D printed.
So what if the case is full of wires, what else I'd put there?
I took the wire order from here:
...and of course the GPIO numbering is not the same as pin order:
Later I might solder a proper connector between the Rpi and the keyboard connector, and also adjust the positioning a bit. The SD card isn't particularly accessible at the moment, I carved a crude trapdoor for changing it, though. No, I don't think every C64 case needs to be preserved in pristine condition. Damn those micro-SDs.
Starting the Pi, the C64 keyboard didn't work! But no worries, it needs to be activated first from the keyboard sub-menu, using the USB keyboard.
After this the C= and F7 key together activates the menu and it can be operated with the C64 cursor keys. Obviously it's a good idea to save the settings at this point.
I left the joysticks unconnected and this might need some additional figuring out.
I noticed that as the C64 keyboard is active, I seem to lose the possibility of using arrow keys as a joystick. In fact, if try to use the option Left Control/Arrow keys as joystick, I can no longer access the menu using C= and F7 and have to restart the Pi.
I had to test the one major advantage a real keyboard has over emulators, the PETSCII characters! I didn't have the patience to do anything larger, though... Shift Lock doesn't seem to work.
Without joystick, I was not that eager to test so many games, but Thrust (keyboard-based arcade game) worked rather well.
Trying the composite video with 1084S monitor and using this real keyboard, the feel is pretty good.
Unlike with THE 64 Maxi, there is no feel of delay from my keypresses to the on-screen characters in BASIC.
So, a definite multi-thumbs up from me and I'd say this looks like it is preferable over C64 Maxi, at least if you are prepared to do a bit of tinkering.
Keyboard project continued here