Automation For The NES

Old hardware might not be anywhere close to as powerful as modern technology, but it does have a few perks. Aesthetics can of course drive the popularity of things like retro gaming systems, but the ease of understanding the underpinnings of their inner workings is also critical. The Nintendo Entertainment System, now nearly four decades old, is a relatively simple machine by modern standards and this lends the system to plenty of modifications, like this controller that allows the system to be somewhat automated.

The original NES controller used a fairly simple shift register to send button presses to the system. The system outputted a latch signal to the controller, the shift register would take as input the current state of the buttons, and then would send them one-by-one to the system at a rate of around 1000 times per second. These signals can be sent without a controller easily enough, too. This build uses a CD4021 shift register, which is the same as the original controller, but instead of reading button states it accepts its inputs from a separate computer via a latching circuit. In this case, the separate computer is a custom design that came about through adapting cassette storage for a 6502-based computer, but it could come from anything else just as easily.

With this system in place, it’s possible to automate gameplay to some extent. Since the system can’t get feedback about the game in its current state, it requires some precise timing to get it to play the game well, and a lot of tuning needs to go into it. This isn’t just a one-off, either. Similar methods are how we get tool-assisted speedruns of games and although these are often done in emulators instead of on real hardware, they can result in some interesting exploits.

Continue reading “Automation For The NES”

Stuffing A 32-Pin Chip Into A 28-Pin Socket

What’s the difference between a 64k ROM in a 28-pin DIP and a 128k ROM in a 32-pin DIP? Aside from the obvious answers of “64k” and “four pins,” it turns out that these two chips have a lot in common, enough so that it only takes a little bodging to make them interchangeable — more or less.

For a variety of reasons revealed in the video below, [Anders Nielsen] use the SST39SF010, a Flash ROM in a 32-pin DIP, in place of the old standby W27C512, an EEPROM in a 28-pin DIP. To deal with those pesky extra pins on the Flash ROM, [Anders] dug into the data sheets and found that thanks to JEDEC standards, almost everything about the pinouts of the two chips is identical. The only real difference is the location of Vcc, plus the presence of a 16th address bus line on the more capacious Flash ROM.

Willing to sacrifice the upper half of the Flash chip’s capacity, [Anders] set about bodging the 32-pin chip to work in a 28-pin socket. The mods include a jumper from pin 32 to pin 30 on the Flash chip, which puts Vcc in the right place, and adding a couple of pull-up resistors for write-enable and A16. Easy enough changes, but unfortunately, [Anders] chose a Flash ROM with heavily oxidized pins, leading to some cold solder joints and intermittent problems while testing. There’s also the fact that not all boards have room for overhanging pins, a problem solved by adding a socket to create a little vertical clearance.

We found this to be a neat little hack, one that should make it a bit easier to use the wrong chip for the job. If you want to see where [Anders] is using these chips, check out his 6502 in an Arduino footprint or the bring-up of an old XT motherboard.

Continue reading “Stuffing A 32-Pin Chip Into A 28-Pin Socket”

MS-DOS Meets The Fediverse

By now, most Windows users are set up with decently functional machines running Windows 10 or 11. Of course there are a few legacy machines still lagging behind on Windows 7 or 8 and plenty of computers in industrial settings running ancient proprietary software on Windows XP. But only the most hardcore of IBM PC users are still running DOS, and if you have eschewed things like Unix for this command-line operating system this long you might want to try using it to get online in the Fediverse with Mastodon.

The first step is getting DOS 6.22, the most recent version released in 1994, set up with all the drivers and software needed to access the Internet. At the time of its release there were many networking options so the operating system didn’t include these tools by default. [Stephen] first sets up an emulated NE2000-compatible networking card and then installs the entire TCP/IP stack and then gets his virtual machine set up with an IP address.

With a working Internet connection set up, the next step on the path of exploring federated social media is to install DOStodon (although we might have favored the name “MastoDOS”) which is a Mastodon client specifically built for MS-DOS by [SuperIlu]. There are pre-compiled packages available on its GitHub page for easy installation in DOS but the source code is available there as well. And, if this is your first time hearing about the Fediverse, it is mostly an alternative to centralized social media like Facebook and Reddit but the decentralization isn’t without its downsides.

A Cycle-Accurate Sega Genesis With FPGA

The Field-Programmable Gate Array (FPGA) is a powerful tool that is becoming more common across all kinds of different projects. They are effectively programmable hardware devices, capable of creating specific digital circuits and custom logic for a wide range of applications and can be much more versatile and powerful than a generic microcontroller. While they’re often used for rapid prototyping, they can also recreate specific integrated circuits, and are especially useful for retrocomputing. [nukeykt] has been developing a Sega Genesis clone using them, with some impressive results.

The Sega Genesis (or Mega Drive) was based around the fairly common Motorola 68000 processor, but this wasn’t the only processor in the console. There were a number of coprocessors including a Z80 and several chips from Yamaha to process audio. This project reproduces a number of these chips which are cycle-accurate using Verilog. The chips were recreated using images of de-capped original hardware, and although it doesn’t cover every chip from every version of the Genesis yet, it does have a version of the 68000, a Z80, and the combined Yamaha processor working and capable of playing plenty of games.

The project is still ongoing and eventually hopes to recreate the rest of the chipset using FPGAs. There’s also ongoing testing of the currently working chips, as some of them do still have a few bugs to work out. If you prefer to take a more purist approach to recreating 90s consoles, though, we recently featured a project which reproduced a Genesis development kit using original hardware.

Thanks to [Anonymous] for the tip!

Apple III Slows Down To Smell The Roses

The most collectible items in the realm of vintage computers often weren’t the most popular of their era. Quite the opposite, in fact. Generally the more desireable systems were market failures when they first launched, and are now sought out because of a newly-appreciated quirk or simply because the fact that they weren’t widely accepted means there’s fewer of them. One of the retro computers falling into this category is the Apple III, which had fundamental hardware issues upon launch leading to a large recall and its overall commercial failure. [Ted] is trying to bring one of these devices back to life, though, by slowing its clock speed down to a crawl.

The CPU in these machines was a Synertek 6502 running at 1.8 MHz. With a machine that wouldn’t boot, though, [Ted] replaced it with his own MCL65+, a purpose-built accelerator card based on the 600 MHz Teensy 4.1 microcontroller in order to debug the motherboard. The first problem was found in a ROM chip which prevented the computer loading anything from memory, but his solution wouldn’t work at the system’s higher clock speeds. To solve that problem [Ted] disabled the higher clock speed in hardware, restricting the system to 1 MHz and allowing it to finally boot.

So far there haven’t been any issues running the computer at the slower speed, and it also helps keep the computer cooler and hopefully running longer as well, since the system won’t get as hot or unstable. This isn’t [Ted]’s first retrocomputing rodeo, either. His MCL chips have been featured in plenty of other computers like this Apple II which can run at a much faster rate than the original hardware thanks to the help of the modern microcontroller.

Retro Gadgets: The Real Desktop Computer

People argue about the first use of the computer desktop metaphor. Apple claims it. Xerox probably started it. Yet, when I think of computer desktops, I think of the NOVAL 760. Not a household name, to be sure, but a big ad spread in a June 1977 Byte magazine was proud to introduce it. At $2995, we doubt many were sold, but the selling point was… well… it was built into a “handsome wood desk, designed to compliment any decor.” The desk folded down when you were not using the computer, and the keyboard recessed into a drawer.

The computer itself was no slouch for 1977, but nothing you couldn’t find elsewhere. An 8080, speed unspecified, had 16 kB of RAM and 3 kB of PROM. There was also a display with a few kB of memory hanging around, too. And just in case you were worried, the bottom of the page entitled “The Ultimate in Home Computers” reads, “The NOVAL 760 COMPUTER. A fully-assembled, fully-tested personal computer … not a kit!” Of course, for us, that’s not really a selling point. If you wonder why the computer was memory limited, this is the time that Extensys bragged in an ad: 64 kB for $1495! If you ordered one, you could have it in 15 to 30 days, too!

There were options for more memory, and it wasn’t clear how many of the I/O devices in the ad were actually included in the advertised price. Some of the devices seemed very specialized, so we are guessing the basic system didn’t include some of them.

Continue reading “Retro Gadgets: The Real Desktop Computer”

PCjr WebServer Hits 2500 Hours Uptime

When [Mike] fired up his PCjr webserver back in March, he probably wasn’t expecting it to go viral. 2640 hours later, here we are! Not only has his machine run continuously for over 110 days, it also is surviving a global hug of death. All of this is thanks to some very special software.

We see lots of old machines here on Hackaday. We also see lots of minimal web servers. But we don’t see many that can run for thousands of hours, offering up to 8 simultaneous connections. Curious if jr is still up? Check brutmanlabs.org. The whole website is hosted on the 40-year-old machine. If you want to be a bit more kind, here’s a direct link to the text-only status page. While many of those hours were idle, currently lots of folks are hitting that little V20 CPU, so please give it a few seconds to respond.

The PCjr has a few upgrades — the aforementioned V20 CPU upgrade, a jrIDE sidecar, and a memory upgrade to 736 kB to name a few.  Ethernet connectivity is via a Xircom parallel port adapter – which is circa 1993.  The operating system is IBM PC DOS 5.02. One thing to note is that all these upgrades were possible back in the mid-1980’s when the PCjr was still current.  [Mike] could run the system with an MFM hard drive, an ISA ethernet card (via an adapter), and use the original CRT monitor. Older DOS versions would work too — though partition sizes would be limited. The “modern” conveniences are just to keep from wearing out vintage hardware which is quickly becoming rare.

The real glue that holds this all together is [Mike’s] own software: mTCP. mTCP is a full set of tools for running internet applications on systems running MS-DOS or a compatible OS. We’ve seen quite a few mTCP projects over the years.  [Mike] has worked tirelessly testing the software, ensuring that it is stable and reliable.

Software is never perfect though – one thing [Mike] didn’t implement is a log roller. Since he has logging turned on, the PCjr was slowly filling up its hard drive. Once the drive was full, mTCP would perform an orderly shutdown — but the uptime will be reset.  [Mike] was able to go in and switch off logging with  DOS’s DEBUG command. A live patch is not the way one would normally update software – but the fact that he was able to do it shows how deep [Mike’s] knowledge of the software goes.

[Mike] has even provided a live stream recording of the little PCjr handling requests from all over the globe.

Continue reading “PCjr WebServer Hits 2500 Hours Uptime”