Close Menu
    National News Brief
    Thursday, April 30
    • Home
    • Business
    • Lifestyle
    • Science
    • Technology
    • International
    • Arts & Entertainment
    • Sports
    National News Brief
    Home»Technology

    Build Your Own Commodore 64 Cartridge

    Team_NationalNewsBriefBy Team_NationalNewsBriefSeptember 28, 2025 Technology No Comments6 Mins Read
    Share
    Facebook Twitter LinkedIn Pinterest Email


    Have you ever thought “IEEE Spectrum is terrific, but I just wish I had a way to experience even more of it, perhaps at a local science and technology museum?” Well, I am pleased to say that your very specific wish has been granted! In collaboration with the IEEE History Center and the IEEE Global Museum and the support of generous donors, Spectrum’s Chip Hall of Fame has been adapted into a traveling exhibit that has just begun making its way around U.S. museums, and, hopefully, the world.

    Our Chip Hall of Fame celebrates microchips that have had a significant impact. Six of the chips from the hall were chosen to be part of the “Chips That Shook The World” exhibit, along with artifacts embodying how each was used. One of the chosen was the 8-bit 6502 processor, so naturally we thought a Commodore 64 home computer, which used a 6502 variant, should be one of the artifacts. Which led to another thought: Why not have the C64 run a program demonstrating an 8-bit CPU in action?

    That’s how I ended up, 35 years after I last programmed a C64, sitting at my office desk creating a brand-new plug-in cartridge.

    The C64 supported plug-in cartridges as a way of distributing software, and our demo program needed to be put on one. Each morning, the museum curator can just turn on the exhibit and presto! The demo program instantly begins running. The alternatives would have required the curator to type in commands to load the demo manually.

    But this convenience comes with two big caveats: One, the demo has to fit into just 16 kilobytes, the maximum size of a cartridge. Even by the standards of the 1980s, this is small, as some C64 titles spanned hundreds of kilobytes by loading data in chunks from disk or tape. Two, the demo would have to be written in 6502 assembly and control the C64 video hardware directly.

    Cartridges require only a few components: a printed circuit board [bottom right], programmable memory chip [bottom middle], and some resistors, diodes, and a capacitor [top middle]. They are mounted in a 3D-printed shell [top left and right]. To make the video output compatible with modern screens, we used a RetroTink-2X Pro adapter [bottom left].James Provost

    Fortunately, from attending Vintage Computer Federation events over the years, I knew there were a lot of free or inexpensive resources that would make it easier than ever before to do this sort of thing.

    The first step was to figure out just how much I could do in 16 KB. The C64’s graphics hardware was groundbreaking in its day, capable of displaying images of up to 320 by 200 pixels with a palette of 16 colors. It could also display eight sprites at once; each sprite is a moveable single-color 24-by-21 pixel bitmap. The price for this power was complexity. The video chip’s control registers, screen bitmaps, text-screen data, default and custom character sets, sprites, and color information all live in different locations scattered across memory, with some data actually living in separate RAM and ROM chips.

    So I sat down with the detailed memory maps and video hardware programming guides available for the C64. (This abundance of information is in stark contrast to the 1980s, when documentation was scant, even from Commodore itself). I worked out that I could cram in nine screens of explanatory text, animated graphics, and sprites. Creating these screens, including the custom character sets and sprites they rely on, was greatly simplified thanks to the online C64 graphics editor at petscii.krissz.hu. The editor can output some results as stand-alone assembly programs, which I adapted as subroutines in my demo code.

    I had just enough space remaining for a lucky find. I wanted to display at least one full-screen bitmapped image, but a prerendered image would have required 8 KB of data, half the cartridge’s capacity. Instead I decided to use a classic hack of programmers since the days of games like Rogue and Elite: pulling free data out of the structure of mathematics by way of procedural generation.

    Here’s where I got lucky: I came across the work of Marcello M., who had published the source for a C64 assembly program that quickly created a multicolor fractal Mandelbrot set using just 3.3 KB of code. With Marcello’s blessing, I incorporated his code as another subroutine.

    Modern Tools For Writing C64 Software

    The coding was done using the free IDE 65xx and Kick Assembler desktop software. I was able to test the code using the popular C64 Vice emulator, which allowed me to do handy things like examining live memory contents to find runtime bugs.

    A diagram showing 64 kilobytes of RAM with a Kernal ROM occupying the top 8 KB, followed by 4 KB of character ROM, and then 8 KB of Basic ROM. Another column shows I/O and color RAM mapped to the same position as the character ROM, and two shadow ROM locations in lower memory. Finally a third column shows a 16 KB cartridge ROM overlapping the Basic ROM and the memory below it. Regions of the Commodore 64’s RAM were mapped to things like the system ROMs, video-color memory, and the bitmaps of characters, the latter of which were actually mapped to multiple locations in RAM when accessed by the video hardware. Some of these mappings overlapped: Inserting a 16-KB cartridge automatically disabled the ROM storing the Basic interpreter. James Provost

    The next step was to make a physical cartridge. Again, there’s modern help, this time in the form of US $5 printed circuit boards that need just a handful of components soldered in to make a cartridge. These components include a programmable ROM chip that I picked up for $3 on eBay. I burned my code to the memory chip with my trusty TL866 programmer and mounted it to the PCB, which in turn was mounted into a 3D-printed cartridge case.

    Then came the moment of truth. It probably won’t come as a surprise to regular readers that I already own an original C64, which I connect to modern flat-screen displays via a RetroTink-2X Pro adapter. So I carefully pushed the cartridge into its slot and turned the machine on.

    Naturally, my C64 immediately froze up. I had forgotten to remove a little bit of memory-management code that made the demo work in the Vice emulator by disabling the ROM that stores the C64’s Basic interpreter. On the real hardware, this snippet ended up disabling half the cartridge’s memory. A quick edit and a trip back to the TL866 and I was ready to try again. Success! I was finally literally ready to ship some software, all the way to Upland Exhibits, the people building our traveling display.

    I hope you get a chance to see my little demo and our “Chips That Changed The World” exhibit in person: We’ll post current and upcoming locations on the Chip Hall of Fame page. But in the meantime, whether you used the C64 back in the day, or are just looking for a fun coding challenge, I recommend trying your hand at programming this 8-bit classic, now that so many of the original pain points have been reduced!

    From Your Site Articles

    Related Articles Around the Web





    Source link

    Team_NationalNewsBrief
    • Website

    Keep Reading

    A.I. Spending Sets a Record, With No End in Sight

    The FPGA Chip Is an IEEE Milestone

    Sparse AI Hardware Slashes Energy and Latency

    Tech Life – Sharing the road with driverless cars

    Tech Life – A hologram to remember: Pam and Bill’s love story

    Tech Life – The workers in the engine room of big tech

    Add A Comment

    Comments are closed.

    Editors Picks

    SoftBank in Talks to Invest Up to $25 Billion in OpenAI

    February 1, 2025

    Can you and your family solve these mind-bending scientific riddles?

    December 23, 2024

    RF Over Fiber: A New Era in Data Center Efficiency

    December 27, 2025

    Mark Cuban continues to throw money at the Indiana Hoosiers

    January 10, 2026

    Despite antiwar MAGA wing, Trump gets Republican support for Iran strikes | Donald Trump News

    March 1, 2026
    Categories
    • Arts & Entertainment
    • Business
    • International
    • Latest News
    • Lifestyle
    • Opinions
    • Politics
    • Science
    • Sports
    • Technology
    • Top Stories
    • Trending News
    • World Economy
    About us

    Welcome to National News Brief, your one-stop destination for staying informed on the latest developments from around the globe. Our mission is to provide readers with up-to-the-minute coverage across a wide range of topics, ensuring you never miss out on the stories that matter most.

    At National News Brief, we cover World News, delivering accurate and insightful reports on global events and issues shaping the future. Our Tech News section keeps you informed about cutting-edge technologies, trends in AI, and innovations transforming industries. Stay ahead of the curve with updates on the World Economy, including financial markets, economic policies, and international trade.

    Editors Picks

    Russia Pledges To Support Tehran

    April 30, 2026

    Insider Claims Reason Behind Key & Peele Split

    April 30, 2026

    Trump says the US is reviewing a potential reduction of its troops in Germany

    April 30, 2026

    Carney ‘strong’ in year one, now must deliver on promises in Canada | Donald Trump News

    April 30, 2026
    Categories
    • Arts & Entertainment
    • Business
    • International
    • Latest News
    • Lifestyle
    • Opinions
    • Politics
    • Science
    • Sports
    • Technology
    • Top Stories
    • Trending News
    • World Economy
    • Privacy Policy
    • Disclaimer
    • Terms and Conditions
    • About us
    • Contact us
    Copyright © 2024 Nationalnewsbrief.com All Rights Reserved.

    Type above and press Enter to search. Press Esc to cancel.