Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Message

Re: How to set interrupt mask whilst single stepping

2013-02-25 by David V

--- In AVR-Chat@yahoogroups.com, Jim Wagner <wagnejam99@...> wrote:
>
> I believe that the ONLY way to mask interrupts while single-stepping is to clear the IE flag bit in the Status Register.


S6 has an option to "hide" the interrupts from you, but it doesn't seem to work very well yet.  You can turn off specific ints in S4 while stepping, just clear the appropriate enable bits. You can also just disable all.

I will frequently use a debug equate for this.

.equ debug = true ;

.... Init code happens... then just before main where I would SEI.

.if debug
 ; leave ints off for debug!
.else
    sei
.endif

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.