This is the coolest thing I've seen posted on HN in years, very cool work.
I've been playing with Atari 2600 programming on and off for the past few years and it is so fun programming directly against the specific hardware. I can't help but occasionally wonder if I could piece together a similar system, but I have 0 experience with electronics. I can only imagine how satisfying it must be to actually pull it off.
It really is super satisfying to get this far, I still turn it on sometimes just to check if it really works.
And I also had zero experience with electronics (and I still don't know as much as I should...), so yeah I think you could piece together something like this. :)
> I still turn it on sometimes just to check if it really works.
I feel this on a personal level, albeit on my much smaller, less complicated projects. Thanks for the amazing write-up, you are an inspiration to us all.
There is something weirdly satisfying about doing something purely for the sake of doing it. So many people start projects hoping they can turn it into a business or gain stars in Github - you see less and less people hacking stuff together just for personal enjoyment.
I think we need more of that too. Everyone seems to be on a quest for perfection: perfect code, 3D printed casing, everything intellectualised to the nth degree. There's a lot to be said for the "rough and ready" approach of experimentation. However to do that you really need to be on a pursuit for personal gratification because the internet is a harsh bitch for pointing out ones mistakes.
As much as I enjoy quickly building circuits on a breadboard like in many of the photos, they’re hell to debug, because there’s so much that can go subtly wrong. It’s much easier with digital than analog circuits, of course, but it still can be crazy hard to logic-probe every connection to get it all to work. I have spent far too much time fixing little bugs in breadboarded circuits. The toughest issue I encountered was when someone melted through part of a big, expensive breadboard with a soldering iron and it caused shorts on the other side of the board. I couldn’t even trust that the holes that were supposed to be connected were in that case, and I sure wasn’t going to copy over the project onto a new breadboard.
However, I’m not sure if there is an easier way to get quickly prototype electronics. Opting for more ICs and a lower BoM count helps, because there’s less wiring to do in the first place.
I would argue that with the extremely low cost of PCB manufacturing (and... if you have access to it... assembly) it's easier now to just lay out a PCB and get it made. The trick is to build up a library of circuit "modules" (like... power supply section, battery charging, video output, etc) that get copy-pasted together.
Of course there's the delay in waiting for the PCBs, which could be frustrating for a hobby project (I was lucky enough to live in SZ for a while where getting PCBs back 2 days after ordering is standard). But parallelising projects can be an effective way of dealing with that, and the variety on working on different things (and the joy of getting a PCB in the mail) can help to mitigate that.
I totally agree.
The reason I stuck to DIP ICs was because I could fit them into breadboards and I thought that was easier than any alternative.
I was incredibly lucky on how all the breadboards were functional.
And there were a few times where I would accidentally disconnect a wire and spend the next 2 hours trying to figure out what was wrong.
All this without having a logic analyser and not even an oscilloscope until much later in the build (they are not that cheap).
And yes the project sure is complex, too complex, but I guess I was lucky, and I'm glad it's working :).
FYI: saelae makes an affordable logic probe. chinese clones are available for ~$10 and usually work with saelae's official software or with sigrok. a logic analyzer is really a game-changing tool.
Cardboard is a fantastic material. You can draw the schematic on, and then run copper tape along the schematic. It's easy to annotate, since you just need to use a pen. It's able to handle much more current than a breadboard, since the copper tape has a lot more metal than thin wires. You can solder directly to it, and with tape (or some other insulating material) you can cross wires without having them short.
You can also work with SMT ICs. Using a pair of scissors, you can make your own pads and solder to them. I connected an SO8 to read off the SPI data using copper tape. I built an amplifier using a spare Novena amplifier IC on cardboard with copper tape. And I have a level shifter done on cardboard with copper tape.
For those interested in working with wire wrap: ebay/aliexpress/whatnot all sell old-new-stock wire wrap wire and the manual wrapping tools. Wire wrap works perfectly on standard headers, but the extra-long headers you sometimes see on arduino shields and such give you a couple more connections per pin: 5 vs 3 if I recall correctly.
It's a really nice way to work, you solder your components onto one of those pcbs with a lot of holes, solder the pins next to em, and from that point on you can wire, unwire, and rewire to your hearts content. Its great to easily be able to undo a connection when you make a mistake.
I've kept this project to myself and would only describe it occasionally to some coworkers and friends. I never thought that many people would find it cool. And always thought that people with more knowledge than me would find a lot of flaws.
So it's really awesome to read yours and all the other comments. :)
I don't think I could write a book, but I have though in writing other posts, giving more detail in certain aspects of the console.
There's really a lot I could say about it and I only realised how much there was to say when I started writing this.
>And always thought that people with more knowledge than me would find a lot of flaws.
Firstly, anyone who nitpicks on a totally handbuilt computer has almost certainly not built their own, so their criticisms can be taken with a pinch of salt (that is to say while they may be valid, can probably be ignored... they're bust criticizing other people's work while you are actually getting on with building something)
secondly if they HAVE designed/built their own computer (not just built up an arduino into a thing) then they are probably more likely to help you ("Hey, have you tried.... to get around..." etc.) than try and fault you. so the only reason to hide your project is to protect it from someone "stealing" it. but I don't think that is a concern, nor is anyone planning on releasing a new design of 8-bit computer/console that's not compatible with anything that's come before.
what I'm trying to say in a long-winded way, is that this is an amazing project, and keep at it as it obviously brings you a lot of joy.
my electronics projects are all currently stalled and finding the motivation to carry them forward it hard right now, so I applaud you!
Just adding to the chorus saying they’d buy a kit and/or book. For branding, play on your introduction for PGG: Portuguese Guy Gaming. Either way though, you definitely should write more posts if it’s something you’d be interested in, you definitely have an excited and willing audience.
Well, I'm glad the response has been so positive! And I'm always afraid of that too, but getting something done and out there is better than not doing anything. Plus, I think most people are supportive, and if there is any constructive feedback, hopefully it's coming from a place of just wanting to help rather than tear down.
I think most people are just amazed at what you accomplished :) I am!
Please consider writing a book or blog posts or at least something! But if you don't I totally understand, don't feel bad about not doing something requested, or anything else either. It's your life and your project :D
We are here just to support you and say thanks for inspiring us!
This is amazing. I'd also love to read a book on this. Electronics is always something i've thought was cool and played around with a little bit, but never really thought something like this was possible with a bunch of slapped together parts. I feel I learned a bunch just reading the bit od your process described in your article and it really made it feel like something accessible for the average person with a bit of technical knowledge and patience. Thanks for sharing that.
You won't know until you start. It's not about writing book, it's just about putting your hardwork in words. You mentioned in your writeup that you used to think same way about building a console.
I have zero knowledge about electronics, consoles, or any of this and I am fascinated by what you did with your free time. Please write a book and publish it here. I'm sure lot and lots of people would love to read it.
Start writing a book and keep writing posts on some of the details and use them to collect emails of people interested in buying the book once it comes out. Also, get on twitter for the same reason.
He wrote a great, thick book called The Black Art of Video Game Console Design. It walks you through making your own game console from scratch. It's a mini EE/CE program in a book. Definitely a great jumping-off point for those looking to learn this stuff.
It is sad that TAB books is no longer a thing, they totally would have published the "BUILD YOUR OWN VIDEO GAME" book. That said, I bet that you could get NoStarch Press to publish it.
Yeah, absolutely. Especially coming from a modern software developers POV. I always think it would be fun to get into electronics, but it just seems so much to take in.
I would pay up to around $50 for a well-produced, high quality, and comprehensive hard copy book that documented the entire process. $30 feels reasonable for an ebook version of same high quality. What would be even cooler is if he partnered with a seasoned EE, who could chime in with contextual commentary on what they would’ve done differently and why. That would be even more valuable to me.
Oh to built 20Mhz systems again! ... no picosecond timing skews to stress over, no ground plane worries, no trace-related design rule violations, no harmonic noise issues, no dynamic bus inversions to prevent victim/attacker degradation, no thermal issues... I spend so much time debugging GHz multi-layer circuit boards that I forget how "easy" 20MHz digital circuits can be. This guy's project is truly inspiring!
I would love to learn more and be able to work with faster circuits like you.
Yes it's way easier to work with "slow" digital circuits I had very little issues using breadboards and really long wires, that probably look cringy to you and others.
Note I put "easy" in quotes because your project was by no means "easy", especially with no tools at your disposal but the internet!
Can I ask how you incrementally tested the video circuit as you built it? Did you have a test pattern generator or something? I know very little about TV signals, I spent some time trying to wire up an analog camera and just ragequit because I lacked a good fundamental debug process.
I've reading up about the architectures and programming of computers and consoles from the 80s and early 90s lately, and have been itching to do a similar project of my own, but have been kind of floundering on where to get started. The fact that you pulled this off inspires that this sorta thing can be done.
Have you considered doing a series of blog posts going into more detail on each section of the console and your journey in getting each bit working, describing failures and successes both? I think such would be instructional to other people who want to do some similar homebrew computer/console hacking.
I was kind of surprised that your PPU design was frame buffered instead of line buffered, but I suppose I perhaps shouldn't be. I imagine the PPU chips of old were line-buffered because RAM was expensive in the 80s, and it was a good enough interface to control a scanline-based display. In my recent reading about the architecture of 3rd, 4th, and 5th gen consoles, I noticed that the 5th gen systems became fully frame buffered, as memory had become cheap and fast enough in the early-mid 90s. And a frame buffer certainly feels a bit simpler and more intuitive to think with than a scanline buffer.
I am considering doing a series of blog posts, I don't know how often I could write them or if I could keep them going, but I will try.
I'm not big in social media and I have never written any posts or anything like before this one, which is weird, I'll admit it, so all this is kind of new, but I think I'll give it go.
Old systems used line-buffers like the Neo Geo or no buffers like the NES, for example.
So yeah, going with a frame-buffered approach was definitely easier, but this was not the only reason I chose this way.
I had a lot of restrictions, I was learning a lot of stuff, I didn't know how to work with FPGAs and I stuck with DIP package ICs that I could put on breadboards and experiment. And that's why I picked the AVR microcontrollers, which are awesome but have their disavantages. They have good performance (20Mhz), but not many pins and I had to bit-bang things like external RAM access (actually the PPU accesses 3 RAMs with only 32 IO pins available), which meant that it takes "some time" to access external memory.
That's why I chose 2 microcontrollers for video instead of just one, one of them could take "all the time in the world" (one frame) to fetch information and write a frame to the frame buffer while the other would generate the video signal and dump the a frame to the TV. Connecting the two, I felt a double buffer was better.
I definitely would have preferred doing a more "traditional" non-buffered render system, but this was the solution I found with what I had to work with.
I hope serves as a good explanation and maybe I'll get to explain these details better in another post :).
I know this has been said before but this is one of the coolest things I've seen posted here on HN. My undergrad is in computer engineering and this post brought back a flood of writing VHDL and doing design in Mentor Graphics.
I'm going to read this a few more times. It's like reading a good book about my hopes and dreams.
Thanks :) (I don't mind people saying it over and over again, believe me :P)
I actually started building a much smaller video game console with a cheap Cyclone II FPGA board (a friend of mine wanted one and I tried to figure it out how I could make something smaller and cheaper but still retro and cool) and I'm using VHDL, it's not exactly easy to learn but it's pretty cool, and I find it really hard to find good resources to learn from.
If I was to start all over again, I would use an FPGA for the graphics, for sure, at the time I just didn't know how.
You could use a Zynq FPGA that has a built-in dual core ARM processor. It has 512K of L2 cache and 256K of memory, more than enough to basically copy the same architecture into that design. It also has ADCs built in so you can implement analog joysticks too. It's also probably fast enough to build a graphics processor in logic. Only thing you may want to keep is the sound processor because there is no built-in DAC so you would need to implement that anyway.
This is a wonderful project. Well done. You might just inspire this software engineer to take his first crack at hardware. :)
One somewhat personal question, if you don't mind. You say you are Portuguese. Is English a second language for you? I don't see the telltale signs of a Portuguese -> English speaker (I have a lot of experience interacting with Portuguese speakers, and their English mistakes are pretty uniform due to the specific differences between the languages, esp regarding prepositions and tense). Your article, as many have noted, is beautifully written even for a native English speaker.
Thank you, if it's something you like, you should try a hardware project, for sure :)
And yes I am Portuguese, born and raised and I do know what you mean, there are mistakes that are somewhat common for Portuguese speaking English and I do make an effort not to make the same mistakes. However I know my English is far form perfect and it's always easier when it's in written form.
I think that the fact that I've always spent too much time watching american/british movies and TV shows made me pay more attention to how English should be spoken :).
But anyway, thank you for saying I speak perfect English, it's actually a great compliment. :)
I can see how that remark could have felt bad, but there are plenty of opportunities not to take it that way. This is why we have a site guideline that asks all of us to "Please respond to the strongest plausible interpretation of what someone says, not a weaker one that's easier to criticize. Assume good faith."
Who said anything about Portuguese people as a uniform block? That doesn't even make any sense as it's not only Portuguese people that speak Portuguese lol. I only referenced those who have either chosen or were involuntarily exposed to English as a second language who speak Portuguese natively.
It's interesting how this kind of project has come into the realm of possibility of an individual's pet project (a smart individual, sure, but not a company).
I guess that the availability of information and materials through the internet has helped a lot. And also more people have knowledge in electronics and programming.
I agree (and thanks for calling me a smart individual :) )
Nowadays is so much easier to get information on how to build something apparently very complex. You don't need to go to a library or seek out and go talk to experts, you actually have access to all that through the internet in forums, articles, posts and videos.
Also it's easy nowadays to order all the things you need for a project online.
Also the access to a massive library of freely shared code libraries and examples. While working with arduino stuff its amazing how when I buy some random part off ebay I can find someone who has already spent a week writing a library that makes everything super easy to use. If I had to do it all myself this would take forever.
Interestingly enough, looking at the HW, there is not much there that wouldn't have been feasible for hobbyist a decade ago. But of course the community and information has absolutely exploded during that period
I've been playing with Atari 2600 programming on and off for the past few years and it is so fun programming directly against the specific hardware. I can't help but occasionally wonder if I could piece together a similar system, but I have 0 experience with electronics. I can only imagine how satisfying it must be to actually pull it off.
It really is super satisfying to get this far, I still turn it on sometimes just to check if it really works.
And I also had zero experience with electronics (and I still don't know as much as I should...), so yeah I think you could piece together something like this. :)
I feel this on a personal level, albeit on my much smaller, less complicated projects. Thanks for the amazing write-up, you are an inspiration to us all.
Is it fast enough for multi-input / multi-player?
I know that feeling ;)
I think we need more of that too. Everyone seems to be on a quest for perfection: perfect code, 3D printed casing, everything intellectualised to the nth degree. There's a lot to be said for the "rough and ready" approach of experimentation. However to do that you really need to be on a pursuit for personal gratification because the internet is a harsh bitch for pointing out ones mistakes.
However, I’m not sure if there is an easier way to get quickly prototype electronics. Opting for more ICs and a lower BoM count helps, because there’s less wiring to do in the first place.
- Being able to detect noise from the system clock crystal oscillator all cross the breadboard (using my oscilloscope)
- Seeing certain I/O pins float to a bit too high of a voltage, when they were supposed to be "low", probably due to breadboard capacitance
- Accidentally making an AM radio when I forgot to connect a wire on an LM386 I was testing as an audio amplifier
Things got a lot cleaner when I went to a PCB, but I did make it all work on breadboards first.
Cardboard is a fantastic material. You can draw the schematic on, and then run copper tape along the schematic. It's easy to annotate, since you just need to use a pen. It's able to handle much more current than a breadboard, since the copper tape has a lot more metal than thin wires. You can solder directly to it, and with tape (or some other insulating material) you can cross wires without having them short.
You can also work with SMT ICs. Using a pair of scissors, you can make your own pads and solder to them. I connected an SO8 to read off the SPI data using copper tape. I built an amplifier using a spare Novena amplifier IC on cardboard with copper tape. And I have a level shifter done on cardboard with copper tape.
Bunnie has a good article on it here, including an example power regulator that's handling 2A on cardboard: https://www.bunniestudios.com/blog/?p=5259
(It seems like it's still a thing in fact http://www.nutsvolts.com/magazine/article/wire_wrap_is_alive...)
It's a really nice way to work, you solder your components onto one of those pcbs with a lot of holes, solder the pins next to em, and from that point on you can wire, unwire, and rewire to your hearts content. Its great to easily be able to undo a connection when you make a mistake.
Great job
I've kept this project to myself and would only describe it occasionally to some coworkers and friends. I never thought that many people would find it cool. And always thought that people with more knowledge than me would find a lot of flaws. So it's really awesome to read yours and all the other comments. :)
I don't think I could write a book, but I have though in writing other posts, giving more detail in certain aspects of the console. There's really a lot I could say about it and I only realised how much there was to say when I started writing this.
Firstly, anyone who nitpicks on a totally handbuilt computer has almost certainly not built their own, so their criticisms can be taken with a pinch of salt (that is to say while they may be valid, can probably be ignored... they're bust criticizing other people's work while you are actually getting on with building something) secondly if they HAVE designed/built their own computer (not just built up an arduino into a thing) then they are probably more likely to help you ("Hey, have you tried.... to get around..." etc.) than try and fault you. so the only reason to hide your project is to protect it from someone "stealing" it. but I don't think that is a concern, nor is anyone planning on releasing a new design of 8-bit computer/console that's not compatible with anything that's come before. what I'm trying to say in a long-winded way, is that this is an amazing project, and keep at it as it obviously brings you a lot of joy. my electronics projects are all currently stalled and finding the motivation to carry them forward it hard right now, so I applaud you!
That's what you thought about building a video game console from scratch, and look how that turned out :) Awesome work!
I think most people are just amazed at what you accomplished :) I am!
Please consider writing a book or blog posts or at least something! But if you don't I totally understand, don't feel bad about not doing something requested, or anything else either. It's your life and your project :D
We are here just to support you and say thanks for inspiring us!
I have zero knowledge about electronics, consoles, or any of this and I am fascinated by what you did with your free time. Please write a book and publish it here. I'm sure lot and lots of people would love to read it.
Start writing a book and keep writing posts on some of the details and use them to collect emails of people interested in buying the book once it comes out. Also, get on twitter for the same reason.
Great work!
He wrote a handful of game programming books in the 90’s as well.
I would love to learn more and be able to work with faster circuits like you. Yes it's way easier to work with "slow" digital circuits I had very little issues using breadboards and really long wires, that probably look cringy to you and others.
Can I ask how you incrementally tested the video circuit as you built it? Did you have a test pattern generator or something? I know very little about TV signals, I spent some time trying to wire up an analog camera and just ragequit because I lacked a good fundamental debug process.
I've reading up about the architectures and programming of computers and consoles from the 80s and early 90s lately, and have been itching to do a similar project of my own, but have been kind of floundering on where to get started. The fact that you pulled this off inspires that this sorta thing can be done.
Have you considered doing a series of blog posts going into more detail on each section of the console and your journey in getting each bit working, describing failures and successes both? I think such would be instructional to other people who want to do some similar homebrew computer/console hacking.
I was kind of surprised that your PPU design was frame buffered instead of line buffered, but I suppose I perhaps shouldn't be. I imagine the PPU chips of old were line-buffered because RAM was expensive in the 80s, and it was a good enough interface to control a scanline-based display. In my recent reading about the architecture of 3rd, 4th, and 5th gen consoles, I noticed that the 5th gen systems became fully frame buffered, as memory had become cheap and fast enough in the early-mid 90s. And a frame buffer certainly feels a bit simpler and more intuitive to think with than a scanline buffer.
I am considering doing a series of blog posts, I don't know how often I could write them or if I could keep them going, but I will try. I'm not big in social media and I have never written any posts or anything like before this one, which is weird, I'll admit it, so all this is kind of new, but I think I'll give it go.
Old systems used line-buffers like the Neo Geo or no buffers like the NES, for example. So yeah, going with a frame-buffered approach was definitely easier, but this was not the only reason I chose this way. I had a lot of restrictions, I was learning a lot of stuff, I didn't know how to work with FPGAs and I stuck with DIP package ICs that I could put on breadboards and experiment. And that's why I picked the AVR microcontrollers, which are awesome but have their disavantages. They have good performance (20Mhz), but not many pins and I had to bit-bang things like external RAM access (actually the PPU accesses 3 RAMs with only 32 IO pins available), which meant that it takes "some time" to access external memory. That's why I chose 2 microcontrollers for video instead of just one, one of them could take "all the time in the world" (one frame) to fetch information and write a frame to the frame buffer while the other would generate the video signal and dump the a frame to the TV. Connecting the two, I felt a double buffer was better.
I definitely would have preferred doing a more "traditional" non-buffered render system, but this was the solution I found with what I had to work with.
I hope serves as a good explanation and maybe I'll get to explain these details better in another post :).
I'm going to read this a few more times. It's like reading a good book about my hopes and dreams.
I actually started building a much smaller video game console with a cheap Cyclone II FPGA board (a friend of mine wanted one and I tried to figure it out how I could make something smaller and cheaper but still retro and cool) and I'm using VHDL, it's not exactly easy to learn but it's pretty cool, and I find it really hard to find good resources to learn from.
If I was to start all over again, I would use an FPGA for the graphics, for sure, at the time I just didn't know how.
And thanks again for the comment :)
One somewhat personal question, if you don't mind. You say you are Portuguese. Is English a second language for you? I don't see the telltale signs of a Portuguese -> English speaker (I have a lot of experience interacting with Portuguese speakers, and their English mistakes are pretty uniform due to the specific differences between the languages, esp regarding prepositions and tense). Your article, as many have noted, is beautifully written even for a native English speaker.
And yes I am Portuguese, born and raised and I do know what you mean, there are mistakes that are somewhat common for Portuguese speaking English and I do make an effort not to make the same mistakes. However I know my English is far form perfect and it's always easier when it's in written form. I think that the fact that I've always spent too much time watching american/british movies and TV shows made me pay more attention to how English should be spoken :).
But anyway, thank you for saying I speak perfect English, it's actually a great compliment. :)
https://news.ycombinator.com/newsguidelines.html
I guess that the availability of information and materials through the internet has helped a lot. And also more people have knowledge in electronics and programming.
Great job, Sérgio. É muito giro.
Nowadays is so much easier to get information on how to build something apparently very complex. You don't need to go to a library or seek out and go talk to experts, you actually have access to all that through the internet in forums, articles, posts and videos.
Also it's easy nowadays to order all the things you need for a project online.
Thanks :)