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]!
BlixTerm Brings Full-Speed YouTube Video to the Commodore PET
Source: Manila Flash Report
0 Comments