If you’ve ever used a home computer from the late 1970s or early 1980s, you’ll no doubt be familiar with the slow speed of their user interfaces. Even listing the contents of a BASIC program from RAM could take several seconds, with the screen updating one line at a time. Video games were completely optimized for speed, but could still handle just a few slowly-moving objects at the same time. Clearly, playing anything resembling full-motion video on hardware from that era would be absolutely impossible – or so you might think.
In fact, [Thorbjörn Jemander] has managed to persuade a Commodore PET to play YouTube videos at a completely reasonable 30 frames per second. He describes the process of designing the “BlixTerm” hardware and software in his video (embedded below), along with lots of useful information on how to push digital systems to their absolute limits.
Naturally, the PET needs a bit of assistance from modern hardware, in this case a Raspberry Pi Zero 2 W hooked up to the “User” expansion port. The Pi connects to YouTube through WiFi and loads the requested video, then downconverts it to a 640×200 grayscale stream and transforms each frame to an 80×25 grid of characters, using those from the PET’s ROM that most closely resemble the pattern needed.
While it took quite some effort to squeeze enough performance out of the Pi to do all of this in real time, the trickiest bit was getting the resulting character stream into the PET’s video memory fast enough. To do this, [Thorbjörn] designed a special interface card with 2 KB of dual-port SRAM, which enabled the Pi to store its video frames as soon as they were ready on one side, and the PET to load them at its own pace from the other side. With just sixteen microseconds available to process each byte, the PET’s CPU can execute only four or five machine code instructions; barely enough to load and store a single character and jump to the next memory address.
The end result, as you can see in the video, is really impressive. Even within the constraints of the Commodore character set, the resulting image is clearly recognizable, while the frame rate seems to defy the hardware’s limitations.
If you’re a Commodore aficionado and wondering what the hell that weird PET 600 model is all about, [Thorbjörn] made a video about that too; it’s a rebadged 8296 aimed at the Swedish market. We’ve actually seen a project to generate live video on the PET before, although at a much lower frame rate. Thanks for the tip, [Keith Olson]!
This is the content I’m here for.
I have a very similar PET, but it doesn’t say Pet 600 and the keyboard is detached.
Now that’s a hack
“It took the poor Pi zero 15 hours to compile”
I wonder how long it would have taken the PET?
The contrast throughout between a modern device costing less than an expensive coffee and a computer costing a months wages is stark. We are definitely living in the future. [1]
[1] And it’s a future that my generation didn’t expect to see, at least at one point. I recall a class survey (admittedly just after watching “Protect and Survive” at school) where I was the only kid in my class who didn’t expect to die in a nuclear war within 5 years. And I think that I was just choosing to be optimistic.
Imagine if we could do this with Star Wars movie, and then bring it back in the past to 1980 and show this at Commodore? Full video on a PET, lots of minds blown.
They’ll be like “Meh, we had the Xerox PARC labs tour too.”
I thought this was going to be about using the PET monitor to view video from a VCR or whatever. I remember one project from the time about overlayig a screen over a video feed.
That probably would have been a lot easier!
Let’s see Bad Apple!
“The Pi connects to YouTube through WiFi and loads the requested video, then downconverts it to a 640×200 grayscale stream and transforms each frame to an 80×25 grid of characters, using those from the PET’s ROM that most closely resemble the pattern needed.”
Kind of like the Matrix screensaver.
I’d recommend to watch this to the end. Well explained.
Why, is there a link to some actual documentation at the end?
i wonder if he coult tweak the visuals with some sort of dct table as custom character rom