Forums

Sega Master System / Mark III / Game Gear
SG-1000 / SC-3000 / SF-7000 / OMV
Home - Forums - Games - Scans - Maps - Cheats - Credits
Music - Videos - Development - Hacks - Translations - Homebrew

View topic - NMIs

Reply to topic
Author Message
Dave
  • Guest
Reply with quote
NMIs
Post Posted: Sun Jul 29, 2001 3:08 pm
In Dega I'm finding with some SMS games (Chessmaster, Xenon 2), they halt but by pressing the pause button (i.e. cause a one-off NMI) they can be 'jolted' onto the next frame.

Is there a NMI or something similar (e.g. jump to 0x66 or thereabouts) which happens regularly?
Or is it only ever caused by the pause button?

thx
 
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 8652
  • Location: Paris, France
Reply with quote
Post Posted: Sun Jul 29, 2001 3:12 pm
Quote
> In Dega I'm finding with some SMS games (Chessmaster, Xenon 2), they halt but by pressing the pause button (i.e. cause a one-off NMI) they can be 'jolted' onto the next frame.

> Is there a NMI or something similar (e.g. jump to 0x66
> or thereabouts) which happens regularly?
> Or is it only ever caused by the pause button?

On SMS, only the pause button can generate NMI.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 8652
  • Location: Paris, France
Reply with quote
It's hardwired on the system board *nt*
Post Posted: Sun Jul 29, 2001 3:13 pm
Quote
> > In Dega I'm finding with some SMS games (Chessmaster, Xenon 2), they halt but by pressing the pause button (i.e. cause a one-off NMI) they can be 'jolted' onto the next frame.

> > Is there a NMI or something similar (e.g. jump to 0x66
> > or thereabouts) which happens regularly?
> > Or is it only ever caused by the pause button?

> On SMS, only the pause button can generate NMI.
  View user's profile Send private message Visit poster's website
Dave
  • Guest
Reply with quote
Re: It's hardwired on the system board *nt*
Post Posted: Sun Jul 29, 2001 3:16 pm
Quote
> > > In Dega I'm finding with some SMS games (Chessmaster, Xenon 2), they halt but by pressing the pause button (i.e. cause a one-off NMI) they can be 'jolted' onto the next frame.

> > > Is there a NMI or something similar (e.g. jump to 0x66
> > > or thereabouts) which happens regularly?
> > > Or is it only ever caused by the pause button?

> > On SMS, only the pause button can generate NMI.

Thought so. I'll try forcing the normal interrupt then: Maybe 0x66 and 0x38 just happen to call the same code in these two games.
It's possible I have the wrong logic for activating an IRQ
 
Dave
  • Guest
Reply with quote
Slight 'doh!'
Post Posted: Sun Jul 29, 2001 3:29 pm
Quote
> > > On SMS, only the pause button can generate NMI.

> Thought so. I'll try forcing the normal interrupt then: Maybe 0x66 and 0x38 just happen to call the same code in these two games.
> It's possible I have the wrong logic for activating an IRQ


Slight doh - I have my 'cause NMI' and 'cause IRQ' in the same place in the code, so if an NMI happens, the IRQ doesn't.
(I'm guessing this isn't a good idea since the NMI would happen at a random time in relation to the TV signal, right?)

So what is jolting these games is the IRQ *not* happening, because I pressed the pause button. Too many IRQs. Still haven't found why yet though.
 
  • Joined: 18 Sep 1999
  • Posts: 498
  • Location: Portland, Oregon USA
Reply with quote
Re: Slight 'doh!'
Post Posted: Mon Jul 30, 2001 9:45 pm
Quote
>
> Slight doh - I have my 'cause NMI' and 'cause IRQ' in the same
> place in the code, so if an NMI happens, the IRQ doesn't.
> (I'm guessing this isn't a good idea since the NMI would
> happen at a random time in relation to the TV signal, right?)

> So what is jolting these games is the IRQ *not* happening,
> because I pressed the pause button. Too many IRQs. Still
> haven't found why yet though.

I've looked through your DOZE code (at least, I think it's yours) and I have a question:

In the case of an INT/NMI on HALT, how does a real Z80 behave? Does it push the PC for the next instruction after the HALT (which I believe is what DOZE does)? Or does it push the PC for the HALT, forcing the processor back into HALT mode on return from the handler?

--
Eric Quinn
  View user's profile Send private message Visit poster's website
Dave
  • Guest
Reply with quote
Re: Slight 'doh!'
Post Posted: Mon Jul 30, 2001 10:02 pm

Quote
> I've looked through your DOZE code (at least, I think it's yours) and I have a question:

> In the case of an INT/NMI on HALT, how does a real Z80 behave? Does it push the PC for the next instruction after the HALT (which I believe is what DOZE does)? Or does it push the PC for the HALT, forcing the processor back into HALT mode on return from the handler?

Wouldn't the latter mean it would never leave the HALT state?
 
  • Joined: 18 Sep 1999
  • Posts: 498
  • Location: Portland, Oregon USA
Reply with quote
Re: Slight 'doh!'
Post Posted: Mon Jul 30, 2001 10:30 pm
Quote
> Wouldn't the latter mean it would never leave the HALT state?

Yes, until RESET. In my mind, HALT implies a drastic event (fatal to system), and shouldn't be recovered from easily.

I take it from your response, though, that this is not the case, and execution resumes with the instruction after the HALT.

Thanks.

--
Eric Quinn
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 8652
  • Location: Paris, France
Reply with quote
Re: Slight 'doh!'
Post Posted: Tue Jul 31, 2001 7:39 am
Quote
>> Wouldn't the latter mean it would never leave the HALT state?
> Yes, until RESET. In my mind, HALT implies a drastic event (fatal to system), and shouldn't be recovered from easily.
> I take it from your response, though, that this is not the case, and execution resumes with the instruction after the HALT.

Yes, it is the case. HALT is basically used to wait for an interrupt.
  View user's profile Send private message Visit poster's website
Reply to topic



Back to the top of this page

Back to SMS Power!