Samsung S3C84E5 user manual WFI Wate for Interrupt, Wfi, Opc 4n3F, Enable global interrupt

Models: S3C84E5

1 316
Download 316 pages 61.65 Kb
Page 213
Image 213

INSTRUCTION SET

S3C84E5/C84E9/P84E9

 

 

WFI — Wate for Interrupt

WFI

Operation: The CPU is effectively halted before an interrupt occurs, except that DMA transfers can still take place during this wait state. The WFI status can be released by an internal interrupt, including a fast interrupt.

Flags: No flags are affected.

Format:

Bytes Cycles Opcode (Hex)

opc

1 4n3F

(n = 1, 2, 3, … )

Example: The following sample program structure shows the sequence of operations that follow a "WFI" statement:

Main program

.

.

.

EI

(Enable global interrupt)

WFI

(Wait for interrupt)

(Next instruction)

 

.

 

.

 

.

 

Interrupt occurs

 

Interrupt service routine

 

.

 

.

 

.

 

Clear interrupt flag

 

IRET

 

Service routine completed

6-86

Page 213
Image 213
Samsung S3C84E5 user manual WFI Wate for Interrupt, Wfi, Opc 4n3F, Enable global interrupt, Wait for interrupt