Now I can control my LED Christmas Tree from DOS! 🎄💾 I hope to share more details on the code + dev stack, but basically I used:
- Open Watcom V2
- Packet drivers
- mTCP
- 86Box + Windows 11 for development
- A Gateway 2000 ColorBook 486 for the final test 😎
Now I can control my LED Christmas Tree from DOS! 🎄💾 I hope to share more details on the code + dev stack, but basically I used:
I really hate to brag, but I wanted to share this life achievement. The Pinball Arcade Trial running on Windows 98 informed me that I got the highest score possible for the trial version.
Fun fact: You can put the latest version of OpenBSD on a PPC 32-bit processor like the G4. Fun to dual boot with Mac OS 9 if you want a modern, secure computer!
The OpenBSD docs are really good and thorough. Open Firmware needs some tweaking if you want to boot directly into OpenBSD, so this is what I did after booting into it with command+option+o+f
:
setenv auto-boot? True
setenv boot-device hd:,ofwboot
reset-all
Initially I didn’t want to mess with the internal drive of the iMac since I had both Mac OS 9 and Mac OS X installed, so I tried to install to a USB drive. Although the installation succeeded (albeit extremely slowly due to USB 1.1), the boot into the system failed due to the following error:
panic: rootfilesystem has size 0
Looking at the trace of the kernel boot process it was evident why: Even though we installed the OS to sd0
(the mounted USB device), the kernel kept trying to mount wd0
which is the internal IDE drive.
I tried what I knew:
boot-device
variable in Open Firmwarebsd.rd
) and mounting the USB to see if I could tweak fstab
Supposedly if we get to the boot
prompt we can pass a -a
flag for the root device (docs), but I couldn’t figure out how to get there.
Ultimately I decided to install OpenBSD to the main internal drive for now. If I get a hankering for Mac OS 9 I still have the trusty Power Mac G4.
The best setup will eventually be a dual or triple-boot. Trying to make the super-slow USB drive work is probably a terrible idea unless we plan to run it in a ramdisk mode the entire time.
As you can see from the glxgears
output above graphics are not accelerated. I’ve mostly played with the machine over SSH in a headless state so this hasn’t bothered me too much. I did glance at dmesg
and saw that the expected driver, nv
, was loaded and detected the card so I’m not totally sure what’s happening. I’m having flashbacks of when I used to spend hours tweaking xorg.conf
and that may be on the horizon again.
If just running the console we still want the screen to sleep and I found I needed to make a couple tweaks for that to work.
First I needed to shut down X Windows:
rcctl stop xenodm
Then I needed to disable output activity from waking the screen:
display.outact=off
After that the screen would shut off after however many milliseconds were set for display.screen_off
.
Copying over /etc/examples/wsconsctl.conf
to /etc/
is a great starter config.
If you’re running a G4 iMac 15″ that’s less than 1GHz, you have the GeForce2 MX which doesn’t have support out of the box via the nouveau
driver. This means an unaccelerated graphics environment, low framerates, and sometimes a console that has inverted colors making it really hard to use.
The GeForce4 MX integrated on the 1GHz 15″ model and most of the 17″ iMacs is supported.
glxgears
at a blazing 12FPS.(Very poorly, presumably until the graphics driver is tweaked)
Running Chocolate Doom was painful. Even the setup utility had a good second or so input lag!
I know this has been done, but I hadn’t done it, so it was my weekend nerd snipe. (no game audio)
This was a lot easier thanks to doomgeneric!
Since doomgeneric exposes the framebuffer, I throw that into an SKTexture and that gets added to a node in the SpriteKit scene, which is subclassed to override the update
method to call doomgeneric_Tick()
. Objective-C is used for interop between C and Swift, and fulfills most of the functions listed here. SwiftUI ultimately outputs the scene.
Very few tweaks needed to be made in doomgeneric itself.
They were basically:
GitHub repo: https://github.com/twstokes/AppleGenericDoom
Since restoring a couple Mac OS 9 machines and playing with them, I’ve noticed some nice touches in various places.
One is that when you have the Platinum Sounds enabled and drag a window, the sound effect will pan in stereo with the window’s horizontal location.
I probably didn’t pick it up very well by recording with my iPhone, but just imagine it gets louder on the speaker the window is closest to. Pretty cool!
I haven’t spent as much time on my Commodore 64 as my other retrocomputers (which can seem modern in comparison), but my explorations over time are trending towards older hardware. I can only assume that my final stop will be an abacus.
I have three C64s all passed down from my dad. One had been devoted to a home alarm system (of course we still have the schematics), but by the time I came around it was only used for playing half-working totally not bootlegged games.
A sampling of some favorite software from my childhood:
I hope to be able to fully restore at least one of these machines this year. The one pictured above powers on and is fully functional, but some flakiness at startup tells me that it’s overdue for a recap.
One not-so-smart thing I did when I unpacked all of this equipment was powering it up with the original C64 power supply. That’s a risky move and likely to damage the C64 with bad power, so I’ve since replaced it with a new modern one (see the parts list).
I’m not interested (nor do I have the space) to use these machines in the “pure way” with a CRT and 1541 drives, although I have both. Maybe down the road that would be fun, but for now I’m utilizing modern gadgets from the wonderful C64 aftermarket community.
The Power Mac G4 didn’t get the “windtunnel” nickname for nothing – its power supply is quite loud. Thankfully with the help of an adapter, a standard ATX (or SFX) power supply can replace it. I love putting “modern” power supplies into my retro machines to get less noise and clean power.
I went with a Corsair SF600 from my previously built Mini-ITX machine and it’s worked really well due to its small form factor. Although it’s rigged in place with two wire ties it’s not going anywhere. 😀
Resources:
I’ve acquired yet another retro machine – this one a Power Mac G4 MDD. There are a few reasons I find it appealing:
Surprisingly it started on the first boot attempt! The PRAM battery was dead, which was expected, but other than that it seemed perfect… for a while. The next day when I tried to boot it I saw only a black screen, so the troubleshooting started.
To keep things brief it all came down to two components in my case (literally) – either the power supply or the video card, which is an ATI Radeon 9000 Pro Mac Edition 64MB.
After trying some spare PC AGP cards I was able to boot consistently with a PNY GeForce 2, telling me the power supply is probably OK. I could’ve stopped here but the graphics performance was terrible with the GeForce 2 and I never got hardware acceleration to work.
I attempted to flash a new ROM to the card but kept getting rejected, so I decided to go in another direction.
There are a few sites that were extremely helpful in this quest to determine what cards could be used in the Power Mac:
If going with a PC version of a video card some will need to be re-flashed with Mac firmware and some also need pins disabled.
I decided to go with another Radeon 9000 but not a Mac Edition – one for PCs only. This would mean higher availability in the used hardware market, a lower cost, and no work to disable pins. It also meant double the VRAM – 128 MB instead of 64.
I wouldn’t be utilizing the extra ADC power port in the AGP slot nor would the card supply an ADC connector, but for me that’s OK.
When I ordered the card from eBay the description mentioned a failed fan so I needed to address that first.
The board’s connector outputs 5V DC and most of my other cards do 12V, but I found a spare fan I’d used for a Raspberry Pi that would work. It’s a bit of a rig at the moment, but a wire tie holds the fan tightly to the original heat sink.
Once I was sure the new fan setup was working I popped the card into the Mac just to see what would happen. Turns out, nothing. Just a black screen. I don’t think Mac OS 9 even booted.
I pulled the card out of the Mac and inserted it into one of my trusty Gateway Slot-1 machines with an AGP port to flash it with the Mac firmware.
The PC needed two files:
After transferring the files I booted into DOS and followed this sequence in the directory where I’d stored the files:
atiflash -i
to make sure the adapter was detected and learn the adapter ID (0
in my case).atiflash -s 0 backup.rom
to make a backup of the PC ROM.atiflash -f -p 0 [mac_rom_filename.rom]
to force-write the Mac ROM firmware.I then removed the card from the PC.
The last step to prepare the card for the Mac was to remove the protective tape at the top left and flip switch 2 (the top one pictured) from MF to SF.
With the card reinserted into the Power Mac we boot right up! Until the ATI drivers are installed there will be no hardware acceleration. The ones I’m currently using are the drivers supplied with Mac OS 9 Lives 9.2.2 and they are working great. 🚀
It may not be real, but it’s so much fun!