Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.apple2.programmer > #3404
| Newsgroups | comp.sys.apple2.programmer |
|---|---|
| Date | 2017-03-30 01:52 -0700 |
| References | <7c5cc1a1-9e51-42f0-a77b-09b7af92c817@googlegroups.com> |
| Message-ID | <f00ad411-e2e4-4e85-9ecc-d10b1325bdc5@googlegroups.com> (permalink) |
| Subject | Re: AppleWIN debugger question |
| From | Nick Westgate <nick.westgate@gmail.com> |
On Wednesday, 29 March 2017 12:53:51 UTC+13, Mark Lemmert wrote:
> I’m hoping that AppleWIN debugger can somehow alert me when $DE0C = $39.
AppleWin can't do this as is ... but with Visual Studio it can.
If you're using Windows, then just install VS 2017 Community Edition, install the C++ workflow, grab the source code and build AppleWin.
https://www.visualstudio.com/vs/community/
https://github.com/AppleWin/AppleWin
Search the source for CheckInterruptSources and put the following before it in the CPU of your choice, e.g. in cpu65C02.h around line 324:
if (mem[0xDE0C] == 0x39 && g_nAppMode != MODE_STEPPING)
{
g_nAppMode = MODE_STEPPING;
break;
}
You'll end up in the debugger just after the instruction that did it.
(With a warning since we haven't entered the debugger normally.
It would be nice to be able to do this properly - maybe Michael can expand if needed.)
Or if you just want to print something to the VS Output pane then put this in there:
char outputString[32];
sprintf_s(outputString, "PC=%0.4X", regs.pc);
OutputDebugStringA(outputString);
That's how I'd do it. Let me know if you need help.
Cheers.
Nick.
Back to comp.sys.apple2.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
AppleWIN debugger question Mark Lemmert <mark.lemmert@gmail.com> - 2017-03-28 16:53 -0700
Re: AppleWIN debugger question qkumba <peter.ferrie@gmail.com> - 2017-03-28 21:06 -0700
AppleWIN debugger question Michael Pohoreski <michael.pohoreski@gmail.com> - 2017-03-29 00:54 -0700
Re: AppleWIN debugger question 6502workshop@gmail.com - 2017-03-29 12:08 -0700
Re: AppleWIN debugger question Nick Westgate <nick.westgate@gmail.com> - 2017-03-30 01:52 -0700
Re: AppleWIN debugger question 6502workshop@gmail.com - 2017-03-30 19:20 -0700
Re: AppleWIN debugger question TomCh <tomcharlesworth26@gmail.com> - 2017-04-17 08:09 -0700
Re: AppleWIN debugger question 6502workshop@gmail.com - 2017-04-22 18:32 -0700
csiph-web