Instagram filter used: Lo-fi
Author: scruss
-
Emulating a Mac IIx on Raspberry Pi
Yup, I have a failing for 512×384 screens … Running Mini vMac on a Raspberry Pi is hardly news. But maybe running it as a colour Mac II is. The screen size I’ve chosen is closer to a Color Classic, for no other reason that I like it.
To build a Mac II-capable version of Mini vMac, you’ll need the Alpha source code. You’ll also need a working Mini vMac setup, as it uses a 68k Mac program to set up the source. Pretty much any basic setup and bootable disk will run this okay:
Mini vMac building on an emulated Mac Classic booting from the System 7 Network Access floppy image (no, I couldn’t boot from Classic’s hidden boot ROM disk) The build options I chose are:
-t larm -ccs -m II -hres 512 -vres 384 -depth 3 -mf 2 -magnify 1 -em-cpu 2 -mem 8M
I’ve chosen to swap the Ctrl key with the Command (⌘) key, as most non-Mac keyboards work better with this.
The build program will export a file out/minivmac-3.5.0-larm.tar that you can unpack into the full source code. It’s a really simple build, and fast, too.
Now you’ll need a Mac IIx ROM image (which I’m not supposed to help you find, but it’s an easy search) and OS image disks from the Mini vMac System Software page. Have fun!
-
Fun things you learn from old computers …
The program on the left is running on the decimal interpreter, the one on the right the regular one Microsoft used to supply two versions of its BASIC for Macintosh. One used decimal mathematics for precise tallying of small amounts. The other used the more familiar floating point mathematics, rounding errors and all. I don’t know what floating point library Microsoft used for sure — perhaps Motorola’s 32-bit Fast Floating Point system — but it introduces rounding errors pretty quickly. Modern routines don’t start displaying oddly until after 15 decimal places.
Consider this simple program:
10 LET x=36/10 20 LET a$="## #.#" 30 FOR n%=1 TO 18 40 PRINT USING a$; n%; x 50 LET a$=a$+"#" 60 NEXT n% 70 END
Along with the number of decimal places, it should print 3.6, 3.60, 3.600, 3.6000, … with an increasing line of zeroes after the 3.6. Bas makes a valiant but typical attempt:
1 3.6 2 3.60 3 3.600 4 3.6000 5 3.60000 6 3.600000 7 3.6000000 8 3.60000000 9 3.600000000 10 3.6000000000 11 3.60000000000 12 3.600000000000 13 3.6000000000000 14 3.60000000000000 15 3.600000000000000 16 3.6000000000000001 17 3.60000000000000009 18 3.600000000000000089
Oddly enough, good old Locomotive BASIC on the Amstrad CPC does it more correctly somehow: