Commodore 64 commands

People frequently ask me for a list of common or useful Commodore 64 commands, including disk drive commands. Since the C-64’s built in operating system is more of a combination command line/Basic interpreter, it takes some getting used to if you didn’t grow up with it.

These commands assume a stock, unmodified C-64, freshly powered on. Many fast-load cartridges, ROM replacements, or so-called DOS wedge programs include shortcuts for these commands. But these commands work on any C-64 with a disk drive, modified or stock.

common Commodore 64 commands
Commodore 64 commands are pretty different from the commands you use on today’s computers.

Loading programs

LOAD “$”,8 – get the disk directory. Follow up with LIST to see. This is the equivalent of the DOS dir command or Unix ls command. Some people type LOAD “$”,8,1 but this is unnecessary.

LOAD “*”,8,1 – load the first file on the disk. I’ve talked about this command in depth too.

LOAD “filename”,8 – load a Basic program. Use the command RUN to execute after it finishes loading.

LOAD “filename”,8,1 – load a machine language program. It may auto-run or you may need a SYS command to launch it.

Other disk commands

SAVE “filename”,8 – save a Basic program to disk.

OPEN 15,8,15,”N0:DISK,I64″:CLOSE 15 – format (erase) the disk in drive 8.

OPEN 15,8,15,”N0:DISK”:CLOSE 15 – fast format the disk in drive 8. This only zeroes out the directory track.

OPEN 15,8,15,”I0:”:CLOSE 15 – Initialize the drive. This is non-destructive to the disk and helps when a drive is misbehaving.

OPEN 15,8,15,”S0:filename”:CLOSE 15 – Scratch (erase) a file from the disk.

Note that all of these program and disk commands assume a single disk drive. Commodore disk drives typically use device numbers 8-11. 8 is the default. Substitute the number 9 in these commands where you see the number 8 to use a second drive.

If you need help connecting disk drives, here’s how.

Memory management

LIST – list the Basic program in memory. Hit RUN STOP to stop the listing before the end. Hold the CTRL key to slow the listing down.

NEW – erase the Basic program in memory.

Program control

RUN STOP-RESTORE key combination – end whatever program is running and return you to Basic’s Ready prompt.

SYS 64738 – soft reset.

OPEN 4,4 : CMD 4 – redirect screen output to the printer. Follow with LIST to print a program or directory listing. CLOSE 4 to exit this mode.

That wraps up my list of common Commodore 64 commands. Many of them, as you can see, are disk drive commands. If I missed your favorite command, please feel free to mention it in the comments.

Leave a Reply

%d bloggers like this: