Building a Tiny Classic Mac Part 3 – OS and Software

In building the project I wanted the computer to have the closest to the original feel as I could get. There were a few difficulties in the project, from the TFT screen, to the OS configuration. Yet in the end, I got a cute little replica running on top of a Raspberry Pi. I am not trying to break copyright, or profit from this. I simply do it as a fan of good hardware and past operating systems.

To start I want to mention that there are areas of this “guide” where I have been short, if you are unfamiliar with Linux, some of the parts in this config may give you problems. This project includes compiling code, adding scripts to boot, and configuring systems like VNC.

I loaded the standard Debian install onto a SD card to start (which at the time was Debian 6 or 7), then I started investigating the different original Motorola Mac emulators. The two main ones I found were Basilisk II and Mini vMac. Basilisk offers features such as Color, networking, and advanced features over Mini vMac. A very useful feature that Basilisk has is supporting a shared drive. You can tell the emulator that a folder on your Pi or any PC should show up as a hard drive in Mac OS 7. That way you can easily download games/software from archive.org or other locations, then load it onto the virtual system!

Mini vMac did offer greater compatibility for apps, while only being black and white, it seems to do a much deeper level of emulation; this makes it slower, but some apps that wont work on Basilisk will work on it. My solution in the end was to put both of the emulators on the box, pointing to the same virtual hard drive.

A script wraps the system, by default it auto boots into Basilisk, but if you “shutdown” the Mac in the emulator, you get a options screen that will allow you to switch modes the emulator is running in, the emulator itself, or some other settings. Some of the other settings including pairing Bluetooth, shutting down, or dropping to the console.

These files are available under https://github.com/daberkow/minimacparts. There is a SYSINIT script that starts the script, aka the wrapper, and gets the session started under the “pi” user, this goes in the /etc/init.d folder. Then there are folders for the different emulators in the /opt/mac folder.

Note: I used the current Raspberry Pi Debian build when I did this project, which at the time was using SYSINIT over the newer SystemD. If you want to use a newer build (which you probably should) you will have to translate my crummy SYSINIT script into a SystemD script. Feel free to pull request the repo! 🙂

One of the larger issues that had to be overcome was screen scaling. The screen I used is 480×320, but the original Macintosh resolution was 512 × 342. This had some of the emulators either cut off, or scrolling around the screen when the mouse got to a corner, which was not great. I could run the emulators at a smaller resolution, but some software was designed with that screen in mind and applications were cut off!

My solution was to use VNC, the system starts the emulator in a VNC session running at the native resolution, then the Pi screen connects to that session and enables scaling mode, shrinking it to the proper size. This way VNC worries about all the scaling, at a minor speed loss. I looked at different X configs to try to do the scaling that way, but the way this screen works, it gets upset and has problems very easily. The screen does not have a scaler of any sort, so you HAVE to send that resolution of 480×320 to it. The VNC solution works well. The different emulators have VNC config files that are copied to the running config right before its run depending on the emulators properties.

At this point we should discuss dependencies; TightVNC server was used for VNC. A quick minor note about VNC, you need to config the VNC users password, and then setup the script to auto-login with that password for the above script to work. Bluez Bluetooth stack and utils were used to be able so use Bluetooth peripherals. Basilisk and Mini vMac were compiled from source on the Pi 2 so that I could squeeze the most performance out of the little PC. Also its hard to find the latest versions ARM compiled online.

Basilisk II:

Basilisk has a good make file that you can use on the Pi as long as you have standard development environment setup, https://github.com/cebix/macemu/tree/master/BasiliskII.

Mini vMac:

The authors website offers a nice little service to have the website compile to code for you, or you can compile it yourself. Depending on your screen and how you want the app to start (a lot of those settings are hard coded in at compile time) http://www.gryphel.com/c/var/index.html.

I made one virtual hard drive, that both emulators used. Luckily they use a compatible hard drive image format. I set the first image up on my desktop just because it was easier. Then copied it over once I got the image in a good state. For years Apple gave out for free on their website Mac OS 7.5.3, then after a website update it seem to break a lot of the links. A few still worked but most over the years have stopped working. A lot of different sites have mirrors of those disks available though, if you search “System_7.5.3_01of19.smi.bin”, that should bring you to one of the mirrors. The one other thing you need is a ROM for a original Macintosh. I have some classic Macs at home, and you can dump the ROM from those. Or there are sites out there that have them hosted, I would guess that would not be to hard to find.

I put the virtual hard drive, and the ROM in a folder called “Shared” in the /opt/mac directory. You may have to tweak some of the configs/scripts to get everything working your way.

Once you get it working, there are a ton of games and pieces of software on archive.org for the old Macintosh, just make sure you get the 680*0 versions not the PowerPC versions. There are also a ton of abandonware sites, since half the companies that made this software are out of business, I doubt they will mind you taking a look, though legally its a grey area.

Those are the basics for how I got the system setup. One item that gave me a bunch of problems was the TFT screen. At the time you needed to load separate kernel modules and configure boot parameters for it. I think newer kernel images have added this, so that should be a simpler task for everyone.

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s