Emulating the DCPU on an AVR

[skywodd] just finished his own DCPU emulator (French, translation) based on [notch]‘s upcoming game, 0x10c. The neat thing about [skywodd]‘s build is his emulator uses the lowly ATMega328, the same microcontroller found in (some) Arduinos.

The DCPU specification goes over the operations required of any DCPU emulator. There’s a lot of crazy stuff here – a division instruction that takes only 3 clock cycles, using an overflow for carry conditions, and a complete lack of a JMP instruction – but [skywodd] was able to tease something apart from DCPU studio and a VGA interface

Everything in this emulator is built on a solderless breadboard, but the ROM and RAM isn’t complete yet. As of now, everything is handled by the ‘328, using 478 bytes of RAM on the microprocessor.

We promised we would be holding a contest for the best physical implementation of the DCPU when we caught wind of 0x10c, and [skywodd]‘s build is starting to look like the beginnings of the winning entry. We honestly have no idea when we’ll be holding this contest, but it’ll probably be shortly after the first playable release. Go bug [notch] if you’d like to speed up the progress, because obviously Twitter abuse speeds up software development.


  1. anon says:

    Cool project.

    Re the contest: Would this really qualify as a physical implementation if it’s an emulator? If so, where is the line drawn between a hardware and software implementation?

    To me, it seems like a physical implementation would mean logic chips or an FPGA.

  2. jaromirs says:

    Now… which one DCPU specification is correct?



    I just started to implement DCPU emulator in dsPIC, however link here seems to be incorrect.

  3. jaromirs says:

    Which one DCPU specification is the corect one? I found v1.7 http://pastebin.com/raw.php?i=Q4JvQvnM

    I started to write emulator o DCPU on dsPIC, however I’m slightly confused about it. Changes to specs linked here are really huge.

  4. jwweather4 says:

    There’s a JMP equivalent instruction, just assign to PC.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


Get every new post delivered to your Inbox.

Join 96,467 other followers