Skip to main content
Home Forums Booting Mac Plus right from ROM + some games! Booting Mac Plus right from ROM + some games!
Thread

Booting Mac Plus right from ROM + some games!

Booting Mac Plus right from ROM + some games! Troubleshooting 78 posts Nov 8, 2014 — Feb 6, 2015
68000-cpu-dip.png.2978e493d3fba6e50e2552f3960baac6.png


Could you also strap on 4M of RAM to max out sub-Plus Macs?

I see there is 23 address lines, just trying to figure out how rob knew to grab lines 18 and 19, because they were not supplied to the stock rom sockets.

lol do i take 16 million and divide it by 23? and that is your space per line?   Ah never mind i'll leave it to the pro's.

The one thing that bothers me with hot flashing, you would have to shadow the ROM, no? because if I am not mistaken, there are constant calls in and out of ROM. you would almost need to disable ALL interrupts and calls during the flash, which means video would go bye bye. 

I would imagine if you write or re-arrange code while that block is running might cause a freeze/hang and poof done. 
I don't think you'd have to shadow the ROM, but you would need to make sure not to access it, which would mean disabling all interrupts while updating the first 128K of Flash ROM where all the Mac toolbox code lives. I don't think that means you'd lose video, though. If I recall, video is a separate circuit that somehow timeshares with the 68000, and it's not interrupt driven. So the update tool would allocate a bunch of RAM, read the new image data from disk into the RAM buffer, disable interrupts, copy the data from the RAM buffer to Flash ROM, then re-enable interrupts.

I see there is 23 address lines, just trying to figure out how rob knew to grab lines 18 and 19, because they were not supplied to the stock rom sockets.

lol do i take 16 million and divide it by 23? and that is your space per line?   Ah never mind i'll leave it to the pro's.
There's a thread about it at mac68k.info with some more of the details. Rob knew to grab A18 and A19 because they are the next two higher address lines from the ones that are already wired to the stock ROM sockets.

All the address lines taken together create a binary number, which is the memory address of whatever the CPU is accessing. The 68000 has 24 address lines*, which means there are 2 to the 24th power different possible binary numbers, or 16777216. That's the total number of bytes of memory the 68000 can possibly access. This address space is divided between RAM, ROM, chips like the IWM, SCC, and VIA, as well as some unused sections. There are other chips on the motherboard whose job is to figure out which chip should be activated, depending on what address the CPU has on the address lines. The beauty of Rob's ROM adapter idea is that these chips are already set up to activate the ROM for any memory access to addresses in the range 400000 to 4FFFFF (hex), even though the stock ROM only goes from 400000 to 41FFFF. So you can just drop in bigger ROM chips with a physical 32-to-28 pin adapter, and then it all just works. You couldn't necessarily do the same by trying to drop more memory into other unused regions in the address space.

400000 hex is 010000000000000000000000 binary. 4FFFFF is 010011111111111111111111 binary. The first 4 bits (A23-A20, the 0100 part) go to the address decoder - those chips on the motherboard I mentioned that figure out what to activate. That leaves the 20 lower bits that are actually connected to the new 1MB ROM socket: these are A19 through A0.

* actually the 68000 has 23 address lines numbered A23 to A1. There's no A0, but there are two other signals for "upper and lower data strobe", and the effect is basically the same.

Sorry for the long boring digression, please return to your normally scheduled Mac activities now. :)

I'm looking at the photos and it really doesn't look like you need the board at all. Simply bending four pins up and soldering wires from point to point will do the exact same purpose so the 512K mod is still possible. You just need to be good with an iron.

Now mind you I can't look at the actual layout files and confirm this because he's using formats that Eagle can't make any sense of. Fffs.

Yeah, it should be possible without any adapter board, but with a lot of wires. On the new Flash ROM chips, you'd have to bend up the A16, A17, A18, /WE, /OE, and Vcc pins on both chips, solder the matching pins on each chip together, then solder them to the CPU as well. The little adapter board certainly makes it easier. 


                             +------------+
                         A18 |1         32| Vcc
    +------------+       A16 |2         31| /WE
A15 |1         28| Vcc   A15 |3         30| A17
A12 |2         27| A14   A12 |4         29| A14

 A7 |3         26| A13    A7 |5         28| A13
 A6 |4         25| A8     A6 |6         27| A8
 A5 |5         24| A9     A5 |7         26| A9
 A4 |6         23| A11    A4 |8         25| A11
 A3 |7         22| A16    A3 |9         24| /OE
 A2 |8         21| A10    A2 |10        23| A10
 A1 |9         20| /E     A1 |11        22| /CE
 A0 |10        19| Q7     A0 |12        21| Q7
 Q0 |11        18| Q6     Q0 |13        20| Q6
 Q1 |12        17| Q5     Q1 |14        19| Q5
 Q2 |13        16| Q4     Q2 |15        18| Q4
GND |14        15| Q3    GND |16        17| Q3

    +------------+           +------------+
        27C512                   29F040B

ASCII art FTW
Wow, that was actually legible in the preview window. Oh well. :)

Legible to me.

Oh. I was under the assumption the new EEPROM chips were pin compatible to the 27C512, not the old ROM chips. Suddenly my idea of "burn to EPROMs and hack it in" doesn't work and I'd have to buy cruddy new EEPROMs.

I looked at this a bit further, and there's a small difference between the Mac 128K/512K ROM socket and the Plus ROM socket (beyond the difference in space between chips on the motherboard). So even if you could cut the adapter board in half, it still wouldn't work in the 128K/512K. Fixing it should be pretty simple, but it means there can never be a universal adapter board that works in all those machines. There will need to be a version A for 128K/512K, and a version B for Plus.

So a small adapter board to sandwich in between would not work?

I looked at this a bit further, and there's a small difference between the Mac 128K/512K ROM socket and the Plus ROM socket (beyond the difference in space between chips on the motherboard). So even if you could cut the adapter board in half, it still wouldn't work in the 128K/512K. Fixing it should be pretty simple, but it means there can never be a universal adapter board that works in all those machines. There will need to be a version A for 128K/512K, and a version B for Plus.
How do you put (actual) Plus ROMs in a 512K to make it a 512Ke then?

I was going to ask too, but I thought maybe I was reading it wrong.

stock plus rom's to pop right into a 128 / 512k.

Bmow is talking about Robs's rom's, pretty sure.

How do you put (actual) Plus ROMs in a 512K to make it a 512Ke then?
The spacing between the two ROM sockets is different for the Plus and the 128K/512K/512Ke. That's the main reason a single adapter board for all those machines would be problematic.

The sources of the ROM sockets' chip enable and output enable signals are also different between the two types of Mac. The difference doesn't matter when you're doing a normal 128K ROM swap to turn a 512K into a 512Ke, but it does matter when trying to build a sneaky adapter to give you 1 MB of ROM. 

I'm looking at the photos and it really doesn't look like you need the board at all. Simply bending four pins up and soldering wires from point to point will do the exact same purpose so the 512K mod is still possible. You just need to be good with an iron.

Now mind you I can't look at the actual layout files and confirm this because he's using formats that Eagle can't make any sense of. Fffs.
He's using OsmondPCB for the layout.  He gives a link to the software which is a free download so you can view the files.  Osmond is the only Mac PCB layout software of which I am aware, and there are PPC and Classic versions available.

His hack using the .print driver was interesting, but I wonder if he is aware of the ROM hook that Charlie told us about some years ago.  Older fellow who dropped in for a few months or years a while back.  He did some cool work on animating gif presentations on early Macs, I think.  I can't remember his exact handle.  Maybe it was Charles with a 3 instead of an e?

His hack using the .print driver was interesting, but I wonder if he is aware of the ROM hook that Charlie told us about some years ago.  Older fellow who dropped in for a few months or years a while back.
Henry, not Charlie.  His handle is/was H3NRY.   Here's a tidbit:

"Hi trag, yes you remember right, but why anybody'd want to add ROM code to a 25-year old Mac is beyond me. In the day, we needed to add code to init our SCSI port and support the Micah hard disk in the 64K ROM environment. The need for that went away with the Mac Plus ROMs which had SCSI and HD support built in, as well as support for more than 512K of RAM."

https://68kmla.org/forums/index.php?/topic/10261-video-playback-on-plusclassic/?p=109856

I think he discussed that hook in another posting somewhere.  It may be worth searching his posts.  There probably were not that many of them.

Wonder if there is any way to pop some (Fancy Rom's) into a 128k or 512k and using some kind of modern technology, flash or something, that can somehow patch a way to get around the lack of ram, like flash virtual ram.  AH, i guess its just much easier to use a Mac with more ram.

Ah, and here he discusses, very briefly, the memory address in question adn the boot behaviour:

https://68kmla.org/forums/index.php?/topic/10261-video-playback-on-plusclassic/?p=109960

Turns out H3NRY was very active while he was here, until 2012, it appears.   I think his wife had health problems that may have caused him to no longer have time for these boards.

There's some very interesting hack-worthy info in some of his postings.  It appears he was the VP of engineering at Nuvo Tech, IIRC.

Cool. The same hook for "test software" appears several places in the Plus ROM (128K ROM) too. It's literally the very first thing the ROM does when booting. If the long value at $F80000 is $55AAAA55, then it jumps to the address pointed to by whatever's at $F80004. There are three or four other similar checks during the boot sequences, at other addresses in the $F800xx range. I wonder what you'd do with that. I wonder how you could even add extra ROM that would get activated by memory accesses to that address range.

I think this would be most useful for some kind of temporary clip-on testing device containing extra software to do validation testing at the factory. If you want to permanently change the Mac's ROM-based behaviors, you're probably better off just replacing the ROMs.

Cool. The same hook for "test software" appears several places in the Plus ROM (128K ROM) too. It's literally the very first thing the ROM does when booting. If the long value at $F80000 is $55AAAA55, then it jumps to the address pointed to by whatever's at $F80004. There are three or four other similar checks during the boot sequences, at other addresses in the $F800xx range. I wonder what you'd do with that. I wonder how you could even add extra ROM that would get activated by memory accesses to that address range.

I think this would be most useful for some kind of temporary clip-on testing device containing extra software to do validation testing at the factory. If you want to permanently change the Mac's ROM-based behaviors, you're probably better off just replacing the ROMs.
I think you would do this with some additional hardware and/or replacement ROMs.   It's gives a built-in method to add functionality.  I agree that it probably makes the most sense that Apple had it in there for some kind of clip on test hardware or similar.    But as long as it's there, we can bend it's true purpose to our ends, yes?

In this particular instance, I was wondering if Rob could have used this hook for loading his code, instead of replacing the .print driver as he did. 

I finally had a chance to build a Plus ROM adapter today and try it out. Unfortunately it was a lot tougher than I expected, and I couldn't get it to work. I didn't anticipate the trickiness of soldering four rows of headers on the bottom of the board and two DIP sockets on the top, while keeping everything perfectly aligned so it would fit in the motherboard's ROM sockets. Mine was a little off, and I couldn't get it to fit right. I also had trouble running clips to the address lines on the CPU. My RAM SIMMs are slightly taller than what I think is standard, and the last SIMM blocks enough of the CPU that it was impossible for me to get the clips to stay on when the SIMM was installed. Then to add insult to injury, I couldn't even fit the motherboard with ROM adapter back inside the chassis, because it collided with the cross-piece at the rear just above the motherboard slot. Arghh! I did finally bend and wiggle it in there, but when I hooked everything back up the machine wouldn't boot. :(  It's still an awesome idea, just not quite as "plug and play" as I'd hoped. I'll chill out and try again with another board later.

lol

its just like anything easier said then done :)

I didn't anticipate the trickiness of soldering four rows of headers on the bottom of the board and two DIP sockets on the top, while keeping everything perfectly aligned so it would fit in the motherboard's ROM sockets. Mine was a little off, and I couldn't get it to fit right.
Tossing some spare sockets on the free ends of the headers to hold them straight during soldering should help.
Yup, I did use spare sockets to make sure the headers for each ROM chip were aligned, but I don't think there's any way to stabilize the gap *between* the rows of headers for the lo and hi ROM sockets, since it appears to be a non-standard spacing. So while my headers for each ROM socket were exactly 0.6 inches apart, I think the gap between them may have been slightly off. I guess I could try soldering everything together while it's actually plugged into the logic board sockets, that would guarantee it should fit. :)

 Then to add insult to injury, I couldn't even fit the motherboard with ROM adapter back inside the chassis, because it collided with the cross-piece at the rear just above the motherboard slot. Arghh!
Back in the day....

The upgrade companies that sold piggy-back upgrades for these machines recommended that you do this:

Turn the machine upside down.   Take the logic board and slide the left or the right side into the frame/chassis slot for that side.  Gently take a flat-head screwdriver and pry the other side of the frame/chassis outwards just enough so that you can slip the other edge of the logic board into its slot.   Voila; logic board installed while avoiding rear cross-bar.

Rewritable ROM disk for Mac Plus: achievement unlocked. http://www.bigmessowires.com/2014/12/20/rewritable-rom-disk-for-mac-plus/

Bbraun put together a new version of the Plus ROM adapater board, with one extra chip on it for generating the correct output enable signal for the flash ROM. Then I dusted off my Metrowerks Codewarrior skills, and wrote a little Macintosh program to do the in-system flash update. It helps that I recently did almost exactly the same thing for my 68 Katy breadboard computer, which coincidentally used the exact same flash ROM chip, and a 68000-family CPU, so I knew it could be done.

The Mac program reads 128K of data at a time from the image file you select, then disables all interrupts, does the magic incantations to unlock the flash ROM, and writes the new data to flash. It takes about 60 seconds to update the entire 1 MB contents of flash memory.

View attachment 4997

now THAT... is cool.... 

What can it be used for? Bootable ROM disk?

We have a bunch of Pluses we can install these things in. I think it would improve their value considerably [:)] ]'>

Anyone figured out something similar for the Mac SE/Classic/Classic II yet?

Save for any architectural differences, accomplishing this on the SE shouldn't be too difficult (given that the ROM chips are socketed in a similar fashion as the Plus).

c

Off Topic: Do you have an easy solution for getting screenshots from the 68k's to the modern web? I was using photoshop 1.0 to convert them to gif, then FTP'ing them over. 

lol can’t you tap into the 3 megs between SCSI and SCC ?  
icon_razz.gif.ab2a9acf5e917eecd69af3a8ca73ee4f.gif


sorry you give me and inch and i am trying to take a mile 
icon_smile.gif.92f398d39b501833af42db4c36790c51.gif
 Flashing on on the fly… ( in machine ) is super awesome… Wonder if your software could be used with Dougg3′s 2mb and 8mb simms ? lol then people will not need to buy his programmer.

not that dougg3's programmer isn't awesome...   

mp.ls