• Hello MLAers! We've re-enabled auto-approval for accounts. If you are still waiting on account approval, please check this thread for more information.

Force interrupt in Basilisk emulator

Does anyone know how to force a NMI inside Classic Mac (say 7.1) running inside Basilisk? Basically I want to break into MacsBug to disassemble some ROM code, and using Basilisk I can do this against a number of different ROMs.

I am running Basilisk in Windows if it makes any difference. I just have not been able to figure out how to kick off a NMI.

Thanks
 
Since you just want to disassemble some ROM code and not debug an app, you don't need NMI. You just need to create an app the calls Debugger() or DebugStr("\phello")

Does MacsBug work in Basilisk? I think you may need to use a different emulator.
 
That's a good point, I'm not even sure if MacsBug will work in Basilisk. But I'll spin up an app that calls Debugger(). That's a good start.
 
Also bear in mind that Basilisk injects loads of extra stuff, so depending on what it is you're trying to poke, you might find it work rather differently in B II than in a more hardware-accurate emulator.
 
Yeah; I'd personally avoid trying to force NMI in BII; better to use QEMU or MAME where the ROM isn't already patched so heavily.

On the other hand, BII has its own debugger already (as do QEMU and MAME), so if you don't mind learning yet another debug environment, you could just use that? command-option-d used to trigger it from a macOS host; not sure what the current Windows combo is, but it should be in the source.
 
Yeah; I'd personally avoid trying to force NMI in BII; better to use QEMU or MAME where the ROM isn't already patched so heavily.
@adespoton 10-4 on that. I tried just about every combination of interrupt and calls to Debugger() in BII. The only thing I can get in response is a frozen screen. So time to move on to a different emulator.
 
Maybe Mini vMac? (I haven't tried it)
Mini vMac mostly works; you can enter microbug (or MACSBUG or Jasik's if you've got those installed) but there can be a few surprises, as Mini vMac does still patch various I/O routines. I actually haven't tried dropping to the debugger since Paul implemented Basilisk II's graphics hack, so it's possible that will have some serious consequences -- but it shouldn't as @cheesestraws and I were discussing elsewhere on how the UI is managed from ROM to display the debugger (and welcome and shutdown screens), and not the general purpose display handlers/Quickdraw.

I'd be interested to see someone try to use NMI from modern Mini vMac; it might be worth doing so with gdb or similar attached, though.
 
It definitely works in MAME with command+power (power key is F12 by default I think) on several machines as of late last year. I worked with Arbee to hook it up in most machines that use a Cuda: the LC III, 475, 520, 550, Color Classic, Mac TV, and Quadra 630, and maybe some other variants. I think the Color Classic was broken last I checked because the fix for the Mac TV's Cuda broke it.

It doesn't work on the Egret machines yet, but I have a plan to fix that. BTW, the Egret machines don't enable command+power by default, but the Cuda ones do. MacsBug will enable it on Egret machines though.
 
Back
Top