C64 Dev with Relaunch64
So moving house has been an absolute pain in the plums. Monthly projects are on hiatus and until the start-of-term chaos has died down, I'm working on the odd piece of project here and there.
The first such project is doing some C64 development, which I've wanted to do for literally years. I bought an SD-card reader from the future was 8-bit and when it arrived, I dug out my C64 from storage and powered it on...
...and it was dead.
Not fully dead, just...weird. Blue border and blue background are fine but the screen is filled up with garbage text.
So step 1: order a new power supply. The PSU I was using wasn't a Commodore original, but a replacement from the late 80s. The problem could still be a b0rked or loose chip, but I got paranoid about using a vintage PSU anyways so I ordered one from Poland. If that doesn't fix it, I plan to follow some of the procedures here.
In the mean-time, I decided to search for an IDE that would run on linux and work with an emulator.
Relaunch64 fit the bill nicely.* It's a straight .jar file which runs under openJDK-11. I installed the jdk not jre because of a missing libawt, but there might've been other ways to fix that.
Setting up the compile and run script has to be the first step - that's outlined in the (English language) wiki here.
I then found an example asm file here to test out the tools. (Annoying that it has an upper-case 'D' in the message which converts into a graphics char on a C64)
I ended up with this script which worked and auto-ran the test file:
/usr/bin/acme --outfile ROUTFILE --format cbm RSOURCEFILE
/usr/bin/x64 -keybuf "sys49152\n" ROUTFILE
I found loads of command-line options for VICE/x64 here. That's where I found the -keybuf option to auto-run my asm program. Perhaps obviously, the 49152 will have to change if I change the *=$c000 program counter line in the asm file.
So now I can stagger around in a nostalgic daze, discovering how little I remember of how to program the C64! :D
* - It really boggles my mind why other C64 IDEs are written in .NET but not cross-platform...just WTF?
Comments
Post a Comment