6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sun Nov 24, 2024 6:53 am

All times are UTC




Post new topic Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Mon Mar 27, 2006 9:50 pm 
Offline

Joined: Sun Feb 05, 2006 1:20 am
Posts: 21
Location: The Netherlands
Unlike IRQ, the NMI doesn't feature a corresponding flag in the status register. I'm trying to figure out the implications.
To me, it seems the 6502 cannot "remember" it is currently running an NMI handler. So the CPU remains susceptible to subsequent NMIs, allowing an indefinite number of NMI levels to nest (assuming there is plenty of time and the stack isn't full).
Does anyone know if my assumption is right, or is there some hidden flag?

_________________
I trust my somewhat flawed English is comprehensible to all.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Mar 27, 2006 10:30 pm 
Offline

Joined: Wed Oct 22, 2003 4:07 am
Posts: 51
Location: Norway
AFAIK, your assumption is right, the 6502 doesn't know that it's handling an NMI so your NMI handler can be interupted by another NMI. But the NMI is edge trigged, not level triggered, so as long as the original NMI source doesn't release the NMI line no new NMIs will be triggered (I dont know the right terminology, I hope you understand what I mean)


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Mar 27, 2006 10:50 pm 
Offline

Joined: Sun Feb 05, 2006 1:20 am
Posts: 21
Location: The Netherlands
Thowllly wrote:
But the NMI is edge trigged

Yes. But come to think of it:
I guess the NMI needs to be edge triggered to prevent unstopable nesting at the blink of an eye.

_________________
I trust my somewhat flawed English is comprehensible to all.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Mar 27, 2006 11:22 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8546
Location: Southern California
These things are addressed in the interrupts primer.  The NMI portion starts here.  Be sure to let it completely load before scrolling, so it will land on the right part of the page.

_________________
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 7 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: