Egghead.page Logo

What Was the Function of the RESTORE Key on the Commodore 64?

The Commodore 64 remains one of the most iconic computers in history, featuring a unique keyboard layout that included a dedicated RESTORE key. This article explores the specific technical function of this key, explaining how it interacted with the system’s hardware and software to recover from crashes or halt programs. Readers will learn why this key was essential for developers and users alike during the 8-bit era.

Technical Mechanism of the RESTORE Key

Unlike standard keys that generate ASCII characters or specific command codes, the RESTORE key on the Commodore 64 triggered a hardware-level Non-Maskable Interrupt (NMI). When pressed, this signal was sent directly to the processor, demanding immediate attention regardless of what the CPU was currently executing. This design allowed the key to bypass standard software loops that might otherwise freeze the system, providing a critical lifeline when programs became unresponsive.

Default Behavior and Software Implementation

In the default Commodore 64 Kernal, pressing the RESTORE key did not automatically reset the machine to its power-on state. Instead, it jumped to a specific memory vector located at $FFFA-$FFFB. Unless software was programmed to handle this interrupt, the system would typically display a simple message or return to the BASIC prompt without clearing memory. Developers often utilized this vector to create custom reset routines, allowing users to exit runaway programs without needing to power cycle the hardware.

Practical Usage for Users and Developers

For everyday users, the RESTORE key was primarily a recovery tool. If a game or application locked up, pressing RESTORE was the first troubleshooting step before reaching for the power switch. Developers leveraged the key during programming to halt execution and inspect variables or memory states. Additionally, certain expansion cartridges hooked into the RESTORE function to provide a warm reset capability, making it a versatile component of the C64 ecosystem that bridged hardware interrupts with user control.