Commodore 64

Introduction

One of the most famous microcomputers of its time, and one of the best selling, it's no wonder that the Commodore 64 (C64) was so popular (and is still today if you're a fan of retro) considering how well it was made. Released in 1982, the C64 is an 8-bit microcomputer that succeeded the VIC-20 and is based around the 6502 compatible 6510 CPU running at about 1MHz. There were three versions of the C64; the original 'breadbin' design, the newer model C64C, and a portable 'C64' called the SX-64, featuring built-in 5 inch CRT and 1541 floppy drive.

Please note that screenshots on this page were taken using the composite video output of a C64 upscaled, unless otherwise stated.

Overview

As was usual for microcomputers of the time, the C64 has a built-in keyboard, which features a number of function keys to the right of the main keys. Unfortunately, the cursor keys for navigating text (such as a program) are on just 2 keys side-by-side, so are awkward to use. Other Commodore microcomputers, such as the Commodore Plus/4 released in 1984, have arrow keys in a more logical arrangement (diamond shape) although still removed from the arrow keys we are used to on modern computer keyboards. You can see a C64, the newer redesigned (PAL) C64C model, below:

At the right side of the computer are the two control ports (for connecting joysticks), the power switch and power connector. The ports on the back are: the expansion port (for cartridges - software, RAM expansion, and more), RF channel switch (labelled 'L-H' and covered by a sticker on my C64), RF connector, video connector, serial port, cassette connector and user port.

The C64 features an 8-bit 6502 CPU, 64KB of RAM (although only about 38K spare for BASIC programs), sprites and great sound, and as well as running the expected utilities, productivity software and games, it also has some notable software including a graphical, interactive environment called GEOS, and CP/M via an add-on Z80 cartridge. Like with most microcomputers of the time, programs could be loaded from an external cassette tape player such as Commodore's own cassette unit called the Datasette (also, spelt Datassette), or a third party equivalent, or floppy disk drive (via the serial port), using a disk drive, the CBM 1541 being an example (please see the 1541 Disk Drive section for more information). Fortunately, there are a number of modern storage solutions that are compatible with the C64, such as the SD2IEC; please see the Accessories section for some examples. Programs were also available in cartridge format, which were more expensive than cassette and floppy programs at the time, but had the advantage of much faster operation since there was no loading involved, but the programs were read only.

The built-in BASIC, V2, was quite poor in that it had no support for certain functions such as drawing shapes or for creating sprites (as available with other microcomputers), which was not exactly welcoming to users buying a system marketed for these advanced features. Instead, sprites, high resolution graphics and other advanced features had to be accessed using the BASIC 'POKE' command which wrote a value to memory (RAM). Fortunately, additional BASIC commands could be added by way of a plug-in cartridge, such as Simons' BASIC (please see the relevant section for more information).

When you turn the C64 on you are greeted with the following screen, which declares that BASIC V2 is being used, that the is 64K total RAM but only 38,911 is available to the BASIC programmer (by using machine code it's possible to use more of the 64K):

There is also the 'ready' prompt with flashing cursor, meaning you can type in commands, which will be executed immediately when RETURN is pressed, or by preceding commands with a line number, programs can be written, with each line stored in memory, allowing for program execution after the RUN command is given.

There are three distinct areas on screen; the border, which defaults to light blue, the background, which has a dark blue colour at power on, and the text, which has the same colour as the border by default. Since the above screen was captured from a real 'breadbin' C64 using its composite video connection, the colours may appear different to other images found online, which may be from an emulator, which likely will represent colours differently to a real C64. In fact, the colours varied somewhat between different C64 computers as well as between motherboard revisions, similar to how each C64 produced sound slightly different due to Commodore not able to replicate component qualities perfectly each time.

Unfortunately, the video output of the C64 is quite poor, even using the composite video connection (which is a lot better than RF), with certain colour combinations (that is text/background) clashing, creating almost unreadable characters. Changing the background colour to black or white helps somewhat, and that can be seen in the example program that follows:

As mentioned, Commodore skimped with the C64's built-in BASIC, neglecting to add much needed keywords, such as to change the colour of the various graphic elements. If we look at line 5 we 'POKE' (write to memory) RAM location 53281 with 0, which changes the background colour to black; using a different value from 1 to 15 will set the background to a different colour.

On line 10 we 'PRINT' (that is, display on the screen) the text 'THIS IS THE DEFAULT TEXT COLOUR.' but you may notice before the first 'T' a reversed diamond symbol, which represents changing the text colour to light blue. We can change the text colour by pressing either CTRL and a number from 1 to 8 or by pressing the Commodore key ('C=') and a number from 1 to 8. If we change the text colour outside of double quotes you'll see the effect immediately, but within double quotes a symbol appears as to mark the change of colour within the text string either when the program is RUN or if executed immediately without a line number.

The colour key combinations are as follows:

Key number With CTRL With C= key

1 Black Orange

2 White Brown

3 Red Light red

4 Cyan Grey 1

5 Purple Grey 2

6 Green Light green

7 Blue Light blue

8 Yellow Grey 3

Note that although in the program we change the colour to light blue, which is the default colour for text, it's always a good idea to set the colour even if it's the default in case it was changed by a previous program, for example.

On line 20 it's the same idea as on line 10 but with different text and other colour changes: '16' appears in white, and each letter of 'COLOURS' is red, yellow, cyan, green, blue, orange, and light green respectively. For reference. this is what the output will look like when the program is RUN:

Accessories

Commodore 1541

Please go to Commodore 1541.

LOAD-IT!

LOAD-IT! is a third party alternative to Commodore's Datasette, having model number PM 4403. It has an LED bar graph display for indicating status and an adjustment knob. The product comes with a user’s guide, which seems to be for a generic 'Datasette', and a leaflet specific to LOAD-IT!, which describes the bar graph display and adjustment knob. The user’s guide is a very close copy of the Commodore 1530 Datasette user guide with a number of changes, and the front cover has a photo of a generic Datasette (not even the LOAD-IT! unit).

This site has information about how the bar graph display display works:

https://www.lemon64.com/forum/viewtopic.php?t=43257

Interestingly, that site shows a photo of the LOAD-IT! with a Commodore badge on the datasette whereas mine has PHONEMARK branding. Looking online, listings can be found for other PHONEMARK peripherals for Commodore machines. The Wikipedia page for the Commodore Datasette mentions the PM 4403, saying it was one of the few clones, but the photo doesn’t have the bar graph display nor an adjustment knob, instead resembling the generic Datasette shown on the user’s guide:

https://en.wikipedia.org/wiki/Commodore_Datasette

SD2IEC

Please go to SD2IEC.

Simons' BASIC

Released in 1983, Simons' BASIC by David Simons, was a cartridge which extended the C64's built-in BASIC 2.0 by adding 114 new BASIC keywords, allowing for more easier manipulation of sprites, high resolution graphics, and sound, as well as aiding the programmer with general programming tasks such as writing programs and debugging. On the downside, because of the way the cartridge is mapped into memory, there is 8KB less RAM available to the user compared to without the cartridge connected.

Note that Simons' BASIC was at times mistook to be Simon's BASIC and as consequence early versions of Simons' BASIC has the misspelling on the cartridge's label.

The following image shows the boot screen with the Simons' BASIC cartridge inserted into the computer.

Note how there is only 30,719 bytes free for BASIC programs as opposed to the usual 38,911 bytes.

In the next screenshot you can see that I have written a program that prints out the 10 times table:

Following the program is a demonstration of the FIND keyword provided by Simons' BASIC which searches a program and reports all line numbers in which a specific code or character string occurs.  Lines 20 and 30 are reported by FIND because they both contain the 'PRINT' keyword that it was told to search for. Note that what you want FIND to look for doesn't need to be in quotes - such as the example of 'PRINT' - however, what FIND searches for begins immediately after the keyword, which is why there is no space between the 'D' in FIND and the 'P' in PRINT.

The TRACE keyword that Simons' BASIC puts at the programmer's disposal, when turned on, prints in the top right-hand corner of the window the current line being processed, showing a maximum of six lines:

In the example above I have used 'TRACE 10' to enable the trace from line 10 and then run the program showing the 10 times table as already mentioned. You can use the Commodore key to step through the program line by line by holding the key down. To disable trace, after the program finishes, use 'TRACE 0'.

Now for a simple demonstration of creating graphics along with text by use of Simons' BASIC which makes such programming so much easier than with standard C64 BASIC:

We have an outline of a rectangle, a circle (which takes quite a few seconds to be drawn due to the calculations required), a filled in square (it is actually a square as the C64 pixels aren't square) and some text (Hello). To make it clearer how the graphics were created check out the program:

I won't go into great detail how the program works as the Simons' BASIC guide explains the keywords in detail but it should be clear that we start by entering high resolution mode using 'HIRES', then a rectangle is drawn using 'REC', a circle with 'CIRCLE', a filled in square with 'BLOCK' and text with 'TEXT'.  Note that CTRL + A (shown as an inverted 'A') sets upper case and CTRL + B (shown as an inverted 'B') sets lower case. The PAUSE keyword pauses the program for a specified number of seconds so that we can actually see the graphics since they will be lost when the program terminates.

An additional extension to the original Simons' BASIC, Simons' BASIC Extension (a.k.a. Simons' BASIC 2), was released on floppy disk and cassette in 1983, and added another 91 commands and required the Simons' BASIC cartridge to work.

Here is a link to the manual for the Simons' BASIC which was originally sold with it:

https://archive.org/details/SimonsBASIC

For a list of commands, memory map and other useful information regarding Simons' BASIC please see:

https://www.c64-wiki.com/wiki/Simons%27_BASIC

W&T Parallel Printer Interface


I bought this printer adapter from eBay for £6 which adds support for standard parallel printers to a VIC-20/C64/C128 rather than having to use a serial printer. The adapter has two cables, one for connection to the Commodore's serial port (note that the connector doesn’t have pin 6), and the other for connection to the computer’s datassette port, as to provide power to the printer interface. The datassette lead has two stickers with German writing, one on the datassette connector PCB which translates as ‘Do not place any metal parts on this connector!’, and the other, attached to the cable reads ‘Danger! Only insert or remove this plug when the computer is switched off!’.


The adapter with its cables can be viewed below:

The printer adapter has a diagram on it showing the interface being connected to a computer and a printer and being powered by 5V +/5%. There is text that says ‘Standard DIP setting=S1, S3+S7 on, all others off.’, referring to the interface switch settings accessible on the interface PCB (requires opening up the adapter). There is also text that reads ‘C64/C128 Printer Interface OK’ and ‘EAN 40 10344 92000 7’. On the side of the adapter is a 2.5mm audio-like socket for the power cable; the tip is +5V and the sleeve GND. On the back of the interface it states ‘Made in W.-Germany’ and at the front is a 36 pin Centronics male connector to plug into a printer.


I did some looking online and this appears to be the original W&T page:

https://www.wut.de/e-32000-ww-daus-000.php

Which has more information about the interface (scroll down to the #92000 section). Putting the URL into Archive.org shows the earliest date of 2007 but even then the page says the product is no longer sold.


I also found a cached version of a German site that has some photos of the interface and the manual:

https://webcache.googleusercontent.com/search?q=cache:F0fOwAFaD3UJ:https://retroport.de/hardware-b-c/+&cd=17&hl=en&ct=clnk&gl=uk

Go to the ‘Centronics Printer Interface (92000) (W&T Interfaces)’ section to read about the adapter. The two page manual is in multiple languages but only gives DIP settings. 


This site has a lot more information about the adapter including how to use the interface with BASIC:

http://www.devili.iki.fi/pub/Commodore/docs/Project64/hw/wtpara10.txt

The site reveals that some printers provide power on pin 18 of the Centronics port, eliminating the need to power the interface from the Commodore datassette port, but plugging in the external power connector cuts out the power on pin 18 if present (as a safety feature). Although there is a sticker wrapped around the datassette interface connector, the site suggests you can plug an actual datassette into the PCB (but, of course, you would have to remove the sticker).


To open up the adapter, which is required to access the DIP settings, carefully unclip the four clips with your fingernail so you can pull the two plastic pieces apart. The PCB has an Intel/W&T 3143 chip, which is an Intel P8050 8-bit microcontroller (masked ROM), going by an image I found online of the interface PCB. There are also a few capacitors, the 8 DIP switches, the power connector, and Centronics connector. There is a sticker that has a date of 01-1993, which is late in the C64’s life, and printed on the PCB is ‘92G 07AUG91’, indicating that the product was first designed/released in 1991. The 5 wires of the serial lead connect to contacts on the bottom of the PCB and the pinout is as follows (warning: colours may vary) with serial port pin numbers included:


Black: GND (2). Also connected to the connector metal shield.

Orange: same as black. This would be the SERIAL SRQ (1) line but is not normally used by Commodore computers or devices.

White: SERIAL ATN (3).

Purple: SERIAL CLK (4).

Green: SERIAL DATA (5).

ChatGPT

Since its release back in November 2022, ChatGPT - the OpenAI chatbot - has caused quite a buzz both in a positive and negative way, but when I heard that one of its specially designed features was to generate computer code I had to try it out. ChatGPT currently has a free version, which did slow down and even come to a halt at times when I used it, but if anything the slowness (when not too slow) made it seem like the AI was actually thinking things through as it delivered its responses. I didn't just ask the AI to generate code - which I'll cover in a moment - I also got it to generate stories, a poem and song lyrics, which was quite impressive.

When it came time to ask for code, I started by asking ChatGPT to create a simple program to add two numbers together using BASIC and it returned with code that should run on any modern version of the programming language, along with an explanation of how the code works. Next, I requested the same but for the Commodore 64, hoping to trip it up, but ChatGPT indeed came back with C64 BASIC code, even referencing the previous, similar program I had asked for.

This is what it came up with:

10 PRINT "Enter the first number: ";
20 INPUT num1
30 PRINT "Enter the second number: ";
40 INPUT num2
50 sum = num1 + num2
60 PRINT "The sum of "; num1; " and "; num2; " is "; sum
70 END

ChatGPT tried to be clever by putting ‘END’ on the last line which isn’t strictly needed on the last line. Unfortunately, the program doesn't work as intended because the C64 only uses the first two characters of a variable name, thus num1 and num2 are the same variable. To fix the program, change num1 to n1 and num2 to n2. If we want to be picky, we can also improve the program by getting rid of the PRINT statements on lines 10 and 30 and instead prompting the user for the numbers as part of the INPUT statements on lines 20 and 40:

20 INPUT "Enter the first number: "; n1

40 INPUT "Enter the second number: "; n2

Next, I asked ChatGPT to write a C64 program to fill the screen with the letter 'J' and it returned with:

10 FOR I=1 TO 25
20 FOR J=1 TO 40
30 PRINT "J";
40 NEXT J
50 PRINT
60 NEXT I

Oddly, there is an unnecessary blank line between each row because of line 50, removing that line fixes the issue. To further make the program run better we could add a screen clear like this:

5 PRINT CHR$(147);

The semicolon at the end of line 5 ensures the first 'J' starts at the top left of the screen. However, the screen will scroll when the last 'J' is printed and it's tricky to get around that without a different approach so I asked ChatGPT for the same program but using POKE, and it answered with:

10 FOR I=1024 TO 2023
20 POKE I,74
30 NEXT I

As to be expected, the program writes directly to the screen memory (addresses 1024 to 2023) and ChatGPT pointed out how, in the Commodore character set, '74' represents the letter 'J', which indeed it does. But the program doesn't display the correct character if the C64 is in its default upper case mode, but if we first switch to lower/uppercase mode it works and we can add an additional line to do it automatically:

5 POKE 53272,23

There is no doubt ChatGPT is a useful tool and perhaps I was a little harsh by asking for code that would run on an old computer but as with anything generated by AI, use what it gives you with caution, there is no substitute for human experience - it's helpful to at least have a rough idea of the correct implementation. Taking the example programs that ChatGPT came up with you can easily see how a less knowledgeable person could have come up with the same or similar code but it does provide a quick starting point, especially when it comes to working low level with memory addresses, for example, which otherwise you may need to have reached out to Google for.

Accessing ChatGTP from a modern computer is one thing but it is possible to also use it from a retro computer, which YouTuber Dan Wood gives a demonstration of both using a C64 and Amiga:

Please note that neither of the solutions to accessing ChatGPT on the featured retro computers is free.

Emulation

It's always a good idea to experience hardware in its original form if possible but failing that emulators can be used, which are software that aim to reacreate the same environment as a C64 but on modern hardware. They aren't perfect but some come very close to behaving like an original C64 and there are advantages over a real C64, such as easier to setup and use, clearer images, easier to take screenshots, simpler to develop software for, and so on.

VICE

Probably the most well known C64 emulator, VICE, also supports emulating many other Commodore computers, earning its name VersatIle Commodore Emulator. VICE is available for a wide range of platforms, from the usual Windows, Linux and Mac, to the more obscure, such as Amiga and RISC, doesn't cost a penny and is easy to get running. VICE can be downloaded from:

https://vice-emu.sourceforge.io/

The main help page can be found at:

https://vice-emu.sourceforge.io/vice_toc.html

The many different emulators that come as part of the VICE package can be run from command line or the executable can be started in the more normal way (from Windows explorer, for example).

You can read about invoking the emulators at:

https://vice-emu.sourceforge.io/vice_3.html

When I first tried out VICE, of particular interest to me was C64 emulation, of which it provides two versions; the fast version (x64), and the accurate alternative (x64sc), which is the one I tried out. 

I downloaded and ran VICE 3.7 (64bit GTK3) on Windows 10, you can see it running in the following screenshot:

By default VICE emulates CRT scanlines, which isn't to everyone's tastes and can be turned off in the settings, but it gives a more realistic look to what someone back in the day would have experienced. The various menu options are available above the C64 'screen' and below are a number of indicators showing the state of the C64 and any attached peripherals.

VICE has a wealth of settings accessed through Preferences->Settings..., which you can see below:

I have selected the Machine->Model option, which lets you choose exactly the type of Commodore 64 you want to be emulated, allowing you to experience even the less well known variations, like the MAX and C64 GS. To highlight another example of the variety of customisations available, you can choose the type of disk you want emulated by clicking Peripheral devices->Drive (e.g., 1541) with options including mimicking the sounds the drive made, whether it has RAM expansion, and should the drive be emulated low level for best compatibility with existing software (True drive emulation). This was particularly useful to me as I was trying to write a test piece of software to run on a real 1541 but I couldn't get it working until I had debugged the code using VICE.

You can paste text into VICE (Edit->Paste) from another program, which is very handy for quickly inputting program listings from the net or an OCR'd magazine or book but the process isn't as straightforward as you would think. If the program text that was copied was in lowercase it'll appear correctly in VICE but if it was in uppercase it will appear as graphics symbols in VICE, so you would have to first convert to lowercase (using a word processing app or online program) and then copy and paste into VICE.

You can copy the entire screen text only from VICE by selecting Edit->Copy, which will copy the text to the clipboard in lowercase. It will copy as displayed on the virtual C64 screen, meaning that where a basic line overflows, those characters will appear on the next line when you paste into another program, which will become a problem should you copy and paste it back into VICE (it will treat the characters as if on separate line). Thus, you would need to backspace to remove the newline to get the overflowed character(s) back on the same line.

Although the nature of emulating a system makes accessing user files easier, VICE supports snapshots (see the Snapshot menu), providing a means to save and and reload the exact state of the machine at any point of time so you can pick up exactly where you left off even if you haven't saved the program you were working on. This also lets you, for example, continue playing a game from where you last left it even if the game has no support for saving player progress.

If you want to take screenshots, record the virtual computer screen or sounds then the Snapshot menu allows you to do that via Snapshot->Save/Record media… This will bring up a window with tabs containing options for Screenshot, Sound recording and Video recording:

After selecting the necessary option(s) click the Save button, choose a file and click Save again. This is handy for capturing the C64 screen itself rather than the whole window, but keep in mind that it will record at the C64’s natural resolution, rather than the higher resolution of the main window.

Here's a screenshot I took using VICE's built-in screenshot facility (I've enlarged the image):

Another very useful feature of VICE is its built-in machine code monitor (File->Activate Monitor) that lets you work low level with the emulated computer, to view memory and registers, setup breakpoints, assemble instructions, perform disk operations, and so on. You can see an example monitor window where I've listed IO registers and displayed some memory contents:

The emulated computer is frozen while the monitor is active, so you will need to close the monitor window to return to the C64 so that it responds again. The monitor proved very useful in debugging a simple piece of code (as previously mentioned) to run on a 1541 as VICE's monitor allows you to view the 1541's memory. Please see the help page for more information about the monitor:

https://vice-emu.sourceforge.io/vice_12.html

In my experience of using VICE it did crash a lot running on Windows 10 although to be fair I was testing custom code running on an attached virtual 1541 disk drive, so it may have been my code that was causing VICE to stop working. Other than that, VICE is a very useful tool for convenience, providing a very clean video output, programming and debugging Commodore programs, and experiencing almost every setup of a large variety of Commodore computers but at zero cost.

Programming

Information and tutorials about programming the C64 using various programming languages.

BASIC

I Am The C-64: Tutorial Series, Volumes 1-3:

I Am The C-64: Advanced Tutorial Series, Volumes 4-6:

Forth

Programming in FORTH on Commodore 64:

Resources

Assembly Language Programming with the Commodore 64 (Brady Communications Company):

https://archive.org/details/Assembly_Language_Programming_With_the_Commodore_64_1984_Brady_Communications_Company

C64 manuals:

https://archive.org/details/commodore_c64_manuals

Commodore 64 - GAMES BOOK (Melbourne House):

https://archive.org/details/commodore-64-games-book

Commodore 64 EXPOSED (Melbourne House):

https://archive.org/details/commodore-64-exposed

Commodore 64 graphics and sound (Granada):

https://archive.org/details/commodore-64-graphics-and-sound

Commodore 64 - Machine language for the absolute beginner:

https://archive.org/details/Machine_Language_for_the_Absolute_Beginner_1984_Melbourne_House

Commodore 64 Programmer’s Reference Guide (CBM):

http://cini.classiccmp.org/pdf/Commodore/C64%20Programmer's%20Reference%20Guide.pdf

C64 service manual:

http://www.robotsandcomputers.com/computers/manuals/c64_sm85.pdf

C64/C64C service manual:

https://www.retro-kit.co.uk/user/custom/Commodore/C64/manuals/C64C_Service_Manual.pdf

Commodore 64 User’s Guide (CBM):

https://archive.org/details/commodore-64-user-guide

Commodore Horizons magazine archive:

https://archive.org/details/commodore-horizons

Compute!’s VIC-20 Commodore 64 Tool kit Basic (Compute!):

https://archive.org/details/Compute_s_Vic-20_Commodore_64_Tool_kit_Basic

First Book of Commodore 64: Applications, utilities, tutorials, and general information for users of the Commodore 64 home computer (Compute!):

https://archive.org/details/COMPUTES_First_Book_of_Commodore_64_1983_COMPUTE_Publications

Machine Language for the Commodore 64 and Other Commodore Computers (Brady Communications Company):

http://www.1000bit.it/support/manuali/commodore/c64/ML_for_the_C64_and_Other_Commodore_Computers.pdf

Mapping the Commodore 64 & 64C (Compute!):

https://archive.org/details/Compute_s_Mapping_the_64_and_64C

Mastering The Commodore 64 (Ellis Horwood Books In Computing):

https://archive.org/details/masteringcommodo0000jone

More Than 32 Basic Programs For The Commodore 64:

https://archive.org/details/More_Than_32_BASIC_Programs_for_the_Commodore_64

The Commodore 64 Program Book (Phoenix Pub. Associates):

https://archive.org/details/the-commodore-64-program-book/mode/2up

The working Commodore 64 : a library of practical subroutines and programs (Sunshine Books):

https://archive.org/details/the-working-commodore-64

Your Commodore magazine archive:

https://archive.org/details/your-commodore-magazine

Successors

The Commodore 128 has almost 100% backward compatibility with the C64; please see Commodore 128.

The C64 is a modern, emulated Commodore 64 and VIC-20 hybrid with built-in games; for more information please see The C64.

The Ultimate C64 is a modern iteration of the C64 emulated in an FPGA but with 'real' C64 I/O connectors as well as modern connections, such as wifi, etc.:

https://ultimate64.com/

Technical

In depth information about the inner workings of the C64.

BASIC/KERNAL

C64 BASIC & KERNAL ROM Disassembly:

https://www.pagetable.com/c64ref/c64disasm/

C64 BASIC: creating accurate time delays:

VIC

Albert Charpentier discusses the VIC chip and the design of the Commodore C64 (with Bil Herd & Ben Jordan):

Troubleshooting

C64 Dead Test Diagnostic cartridge 8 in 1

When you have a C64 that doesn't boot or does start up but you suspect there could still be faults (bad SID, for e.g.), a test cartridge which plugs into the computer's expansion port helps diagnose a C64. One such example I bought from ebay, a 'C64 Dead Test Diagnostic cartridge 8 in 1' for £13 (~$16), which is based on the OpenC64Cart design, which can be found at:

https://github.com/SukkoPera/OpenC64Cart

Although the 'cartridge' is actually just a PCB you can print your own case if you want, which does help with removing the board from the expansion port.

The Dead Test Diagnostic cartridge has 8 cartridge images that are selected using the various jumpers on the PCB (only change them while the power is off), the configuration is as following (taken from the ebay listing):

586220+               ROM:LO, ExROM,  A15:LO, A14:LO, A13:LO 

DeadTest              ROM:HI, GAME, A15:LO, A14:LO, A13:HI 

1541                     ROM:LO, ExROM, A15:LO, A14:HI, A13:LO 

C64 Diag              ROM:LO, ExROM, A15:LO, A14:HI, A13:HI 

C64 Diag 4.1.1     ROM:LO, ExROM, A15:HI, A14:LO, A13:LO 

C128 785260       ROM:LO, ExROM, A15:HI, A14:LO, A13:HI 

Doktor64              ROM:LO, ExROM, A15:HI, A14:HI, A13:LO 

Burn-in Test          ROM:LO, ExROM, A15:HI, A14:HI, A13:HI

There are variations of the dead test PCB that use switches instead of jumpers, which makes selection of the ROM image easier.

Some of the images test the C64 as a whole, such as 586220+ and DeadTest, which requires a wire harness (loopback) to fully test all features. Other images do more specific types of testing, like 1541, which is for testing a connected disk drive. To use the cartridge, select the configuration and plug the PCB it into the C64’s expansion port while the power is off (I found it quite difficult to get in) along with the harness if you have it. Power on the C64 and after a few seconds the test will be carried out and will repeat indefinitely in the case of the images that test all the features. The cartridge handily has a reset switch, something missing from a standard C64, but be careful not to press it down too hard so as to not disturb the cartridge. Now looking at some of the cartridge tests in more detail:

C-64 diagnostic rev 586220+

The testing takes about a minute to run and the tests will keep repeating with a count kept bottom left; during the sound test various notes will play, provided there is a working SID, of course. The following screenshot shows the results on one of my own C64s:

Since no harness was connected some tests couldn't be completed, resulting in a 'BAD' result for cassette, control port, serial port, user port and interrupt even though they are working.

1541 diag/test cart

Unfortunately I don't have a 1541 disk drive but have included a screenshot to give an idea of the features included:

C64 diagnose & test

Test various hardware of the C64,  shows paddle/controller port values, repeats the tests continually and keeps a count near top of the screen (highlighted in blue), as below:

After performing the test it shows various colours on the screen briefly before returning to the main tests screen. Oddly, I found that the tests caused a high pitched sound from my breadbin C64 when checking the main ram, labelled as 64-KBRAM in the test list. Looks like it needs the test harness to test a C64 completely.

Commodore-64 diagnostic

Does various tests in turn on different screens, with example screen below:

 It's likely a test harness is needed to fully complete the testing, since I found it appeared to hang on the cassette port test reporting it to be bad, without a harness fitted.

Misc.

C64 common problems and how to fix them:

https://retrocomputerverzamelaar.nl/commodore-64-problems/

The various types of signals in a C64 as viewed on an oscilloscope, which can be helpful in fixing a C64:

http://tech.guitarsite.de/c64_scope.html

?OUT OF MEMORY ERROR IN 0

Unfortunately, old electronics decays over time and a common problem with retro computers is that various chips, such as the RAM, goes bad and needs replacing, with the '?OUT OF MEMORY ERROR IN 0' seen on a C64 being a common indication of faulty RAM. The computer will boot but likely you won't get the normal startup message and instead be greeted with the previously mentioned error. Random, extra, characters may be visible on the screen as well as other characters appearing and disappearing in a glitchy manner, but even with the problems the C64 may still be usable to a point although of course the issues need fixing, For reference, here is an example '?OUT OF MEMORY ERROR IN 0' screen:

Notice the '$' symbol near the middle as well as the one toward the bottom, which on my machine, appears and disappears.

All content of this and related pages is copyright (c) James S. 2007-2023