Status Register (SREG) and Boolean Formula

I T H S V N Z C
1
I

1

The I Flag is set.

Example:

 ... 
extint: push r0 ; Save r0 on the Stack
 ... 
 pop r0 ; Restore r0
 reti ; Return and enable interrupts
Words
1 (2 bytes)
Cycles

4 devices with 16-bit PC

5 devices with 22-bit PC

Note: RETI behaves differently in megaAVR and AVR XMEGA devices. In the megaAVR series of devices, the global interrupt flag is cleared by hardware once an interrupt occurs and this bit is set when RETI is executed. In the AVR XMEGA devices, RETI will not modify the global interrupt flag in SREG since it is not cleared by hardware while entering ISR. This bit should be modified using SEI and CLI instructions when needed.