FLOSS Game Dev

Enabling Creativity

Update: 6-1-20

Leave a comment

Howdy, folks! πŸ˜€

I’ve recently received my Pinebook Pro, and so far I am really enjoying it! The machine has a 1920×1080 display, operates at 5V, and has a pretty streamlined Manjaro Linux OS pre-installed.

All of that being said, I realized that if I want to play some games on this machine, I will have to resort to emulation of some sort. I found out that there’s already a Linux distribution called Recalbox which contains everything a ROM enthusiast could ever hope for.

However, seeing as I am hopelessly obsessed with Hardware Independence, and want to flex my mind-muscles a little, I thought it would be fun to write my own emulator from scratch. To make things even more interesting, I’m not going to try writing an emulator in software, no, no, no…

…I’m going to attempt to create one in “Hardware”!

That’s right! During my time in school I’ve already been exposed to FPGA development using Verilog, and I realized that if I want to get even better at creating my own circuits, then I need to start up some projects relating to digital circuit design. Spinning up my own game console capable of emulating the systems I grew up with sounds like a perfect way to kill two birds with one stone:

  1. I get to learn more about digital design and hardware development.
  2. I get to entertain myself with my new hardware that can play games!
  3. Everything is Open-Source! (So, I guess that makes it “three birds”.)

*ahem*

So, what I’m noticing as I dive into the process of writing hardware with Verilog is that there is plenty of source code, but very few tutorials gluing everything together. So, while this is a little uncomfortable for me, I realize that there is also an opportunity here to fulfill a need. I am going to document the process of creating a game console from scratch with Verilog, which I intend to simulate with Verilator.

So, what is Verilator? Verilator provides a cycle-accurate model of your design as well as C++ hooks so you can add additional functionality to your model while evaluating your circuit as a userspace application. I’ve discovered from my initial research that it is possible to incorporate the SDL2 library into a design, which means that I can leverage the SDL2 library to handle user-facing devices while interfacing with the simulated device model at the same time.

So now the question is… what “game console” am I going to develop?

Right now I have my eyes fixed upon the original 8-bit NES, due to its simpler CPU and Graphics Processing capabilities. This is knowledge that I want to develop regardless, and it makes sense to pick a project that will give me some foundational knowledge that I can begin to build upon. Once complete, there are other directions I can go; I can cover the Gameboy series of hardware, or I can look at other consoles, but regardless of whatever I choose, I think I would like to graduate my knowledge to a point where I can implement something on-par with the original Sony Playstation. This is a piece of hardware that has a much more comprehensive GPU implementation, and is more feature-complete when compared with competitive modern graphics architectures we see on the market today. At this point, I would be happy to design my own System-on-a-Chip from scratch!

*whew*

I’m very excited by the opportunities here! I will begin posting as soon as I make headway with this new project. Expect tutorials on project planning, specifications, formal verification, and the like in the near future.

Until next time!

Cheers! πŸ™‚

Author: Michael J. Brodeur

I love computer and video games! I support my unending love for this craft with a devotion to both Free Software and Free Hardware Design. Cats rule! >^_^<

Leave a comment