Hacker News new | past | comments | ask | show | jobs | submit login
Let’s Build a Video Card (eater.net)
267 points by captn3m0 on Nov 9, 2020 | hide | past | favorite | 46 comments



I've been following his videos for some time now. He also built an 8-bit CPU from scratch on breadboards, as well as a 6502 based computer also on bread boards. He's recently started the process of using the video card he made to output video from the 6502 computer.

His videos are interesting and informative, and while he does offer kits to build all this stuff from his site, the part lists are there should you want to source your own (not always easy if you try to do it on the cheap and get your parts from the likes of Ali Express and Ebay).

Overall his projects are fascinating for anyone with interest in retro computing or learning how computers work at the lowest level, and the videos are easy to follow and more than just a "how to put this together" tutorial.


> Overall his projects are fascinating for anyone with interest in retro computing or learning how computers work at the lowest level

I'm on the RAM-building portion of the 8-bit breadboard computer for exactly this reason. I wanted to bridge the gap between (this is an electric circuit that lights an LED) and (this is how you can take a simple inverter and a logic gate to build a D flip flop, which can power registers, SRAM, and more) and (this is an 8-bit example of a Von Neumann Architecture computer).

His videos are perfect for that. Very well made and I don't have to take classes in circuit design or digital logic control & design at a college to learn the high level of how this works.


Ben Eater's entire catalog is gold, he gets right to the meat of things, clearly explains what's happening, and makes the subject matter accessible and entertaining.


His 8-bit CPU series made me finally understand how microcode works. His videos are very clear and well explained.


I will reiterate this. I dropped out of a CS program and had just a little knowledge, but I feel like this finally made the penny drop.


I'm curious how well that works out, building something that complex on a breadboard. I had an FM radio project that gave me a lot of trouble until I realized the breadboard was introducing a lot of parasitic capacitance.


It works well for a learning project that doesn't push clock rates. This lets the nose introduced by the breadboard to settle before each clock edge. Also, bypass capacitors are key.


I got caught up in all his videos and had the same question. Fortunately, he has a dedicated video where he answers this with testing on the scope: https://www.youtube.com/watch?v=fCbAafKLqC8

tl;dr is what the sibling comment already explained: low clock rates.


This post has the (2019) tag on it, but just to note - I think the reason it was submitted today is that he just released a whole new part where he is hooking it up to his 6502 breadboard computer... and the "world's worst video card" is now also available as a kit!


A mod probably added the year - we'll take it out. Thanks!

Previous thread for those who are curious: https://news.ycombinator.com/item?id=20614129


Another way to play around with a cheap "video card" is an ESP32 and the FabGL libraries. It's not retro-correct like the one in this post, but the cost is very low. LilyGo has an ESP32 board that already has VGA and PS/2 connectors for $11: https://www.tindie.com/products/ttgo/lilygor-ttgo-vga32_v14-...

It's pretty neat that we now have microcontrollers that are fast enough to drive VGA at decent resolutions.

The FabGL library: http://www.fabglib.org/


Here's an entire demoscene demo on a microcontroller.

https://youtu.be/sNCqrylNY-0


That's very neat, especially because it takes the demo idea and turns it into a tangible artifact!


Here's a video in his 6502 series where he hooks up the 6502 computer he's been building with this video card.

https://www.youtube.com/watch?v=2iURr3NBprc

I highly recommend his videos and kits. He's a great teacher.


VGA was designed for CRTs. I am amazed how well it has been supported by digital monitors. Still, I am left wondering, how hard would it be to make something similar for a modern digital interface, say, DVI?


DVI just encodes VGA signal in digital form :( Same for HDMI. Both are still sending pixels at VGA timings, Hsync/Vsync/blanking and all, with clocking locked to PixelClock.

DisplayPort is packetized, but not in a 100% sane way. You would expect that clean slate purely digital interface designers would at least optionally allow sending whole screen update at a time. Alas you are still sending same VGA formatted pixel stream (Hsync/Vsync/blanking), just chopped into TUs (32-64 symbol Transfer Units) with stuffing (aka never used garbage) between them, even when connected to eDP display supporting Panel Self-Refresh (own frame buffer inside display).


Sending the whole screen update at once is less than optimal, as it pushes bandwidth requirements through the roof. Better to stretch the transfer out over the entire frame to lower bandwidth requirements as much as possible.

The timings aren't 100% vga anymore. DVI and HDMI support reduced blanking mode, which shortens vblank to lower the wasted time lower the dotclock requirements for a given resolution.

Also, lcd panels are still scanned out pixel by pixel, line by line. There is no reason to put a much wider interface between the panel and the LCD controller.


How would it change BW requirements when 1 you are sending same data but without the stuffing garbage in between, and 2 DP link is already above the Pixelclock speed. If anything you could put link to sleep more often instead of sending garbage.


Technically less different than you might think, but it is much higher speed due to being bit-serial. The lowest pixel clock that must be supported by all devices is around 25 MHz (for VGA), which results in a bit rate of 250 MHz (8 payload bits per pixel per TMDS pair, encoded as 10 bits on the wire).


DVI is a very large spec. It supports everything from pure VGA over it's analog pins as well as full fledged HDMI (its actually the other way around, HDMI is secretly just DVI). Finding monitors which support all of the simpler modes is an issue, whereas finding monitors which support old school VGA is fairly easy.


>its actually the other way around, HDMI is secretly just DVI

HDMI signalling is actually extension of DVI, it embeds TERC4 data islands containing extra metadata and PCM audio during blanking interval. (yes, I was surprised at beginning but HDMI/DVI also have blanking periods just as VGA)

https://warmcat.com/hardware%20design/hdmi/fpga/2015/10/21/h...


It's a "barely digital" standard.

It doesn't have any error detection or correction. The timing of the signal is still based on CRT TV's.

Really the whole lot should be done away with and replaced with something properly bidirectional, and preferably IP based so it can be routed anywhere.


I think DisplayPort done away with this legacy and uses packetized transmission.


Packets that still have to encode and adhere to strict VGA timings (Hsync/Vsync/blanking), and you arent allowed to send anything useful between the packets unless its a blanking period.


Thank you! I've been looking for something like this for ages. It's extremely difficult to find decent resources on the hdmi/dvi protocol.




Interesting idea. Basic DVI is somewhat VGA with analog signal replaced with TDMS. I think if you limit yourself to only few predefined colors with 8b10b encoding hardwired in shift registers, it's doable. (for signal integrity you can only pick colors that have balanced encoding)

edit: as pointed in other comment, lowest bit clock is 250MHz, which might be a problem, it seems fastest discrete logic chips are topping out at ~150MHz


The TMDS signals are a little too fast to implement in breadboarded logic, but DVI/HDMI are pretty easy to implement on an FPGA, especially if you restrict the colors used.


Exactly the right amount of explaination for each step he does. I could perfectly follow along and learned alot.


Ben Eater singlehandedly got me into digital electronics. An incredible teacher!


Likewise. I was tinkering with Arduino already but his videos got me hooked.


Hmm. The 6502 is/was often set up to access the memory only half the time. For example a 1MHz CPU would be interfaced with 2MHz memory, and access every other cycle.

https://en.wikipedia.org/wiki/MOS_Technology_6502#Technical_...

I guess Ben knows this, but avoided it for some reason. Perhaps interleaving the timing on a breadboard isn't that easy? Never tried it myself.


I've been watching his videos for a long time and as far as I can see, the goal is never technical sophistication or doing things in a "production ready" way. Rather, it's making the innards of a computer understandable. The way that he did it here, he could easily explain when and how the CPU had control of the bus and when the video card did _and_ he had a picture that he could point at to visually explain what was happening.

I've also noticed that he'll start simple and then layer on more complex things as the series progresses. No idea if he's planning on doing that here, but a good example was with the 6502 computer where he implemented it out of the gate with no RAM so that the video could focus on getting things up and running.


> Rather, it's making the innards of a computer understandable.

Yes! Connected to this, he uses approaches that are biased toward simple implementation that 'mere mortals' can actually get working.


I find his voice extremely calming so that it makes me snooze whenever I try to watch his videos, which is annoying because I have to rewind back to where I fell asleep to take in the content, which is extremely interesting.


He's the Bob Ross of electronics. I find speeding up the video a tad helps keep my attention.


I've been having significant trouble sleeping the past few months. Even on calm-minded days, the second my head hits the pillow the stresses come back, I get worked up, and can't sleep. Rewatching his videos is one of the few things that has helped to quiet things down.


If I'm not in a hurry to learn something I love talks and explanations that I can watch multiple times and still learn something new because I didn't fully understand it the first time. That's why I also sometimes watch these kinds of videos while working.


I have his 6502 kit and the timer kit. They're both great!

The videos are well explained and the kits are a really easy way to follow along.


I wish there was a version of these videos with comments by Steve Wozniak.


Current submitted link (https://eater.net/vga) is broken:

> You need to enable JavaScript to view this site.


Link is working as intended. Maybe your browser is broken.


I think it was a tongue-in-cheek joke about requiring Javascript.


It's possible.

And mine was a joke about trying to browse the web with javascript turned off.


“I tried running your executable with all syscalls blocked and it didn’t work please fix”




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: