15
15 – 83
PROGRAM FLOW
IDLE
Syntax:
IDLE ;
IDLE (n);
Slow Idle
Description:
IDLE causes the processor to wait indefinitely in a low-power
state, waiting for interrupts. When an interrupt occurs it is serviced and
execution continues with the instruction following IDLE. Typically this next
instruction will be a JUMP back to IDLE, implementing a low-power standby
loop. (Note the restrictions on JUMP or IDLE as the last instruction in a DO
UNTIL loop, detailed in Chapter 3.)
IDLE (n) is a special version of IDLE that slows the processor’s internal clock
signal to further reduce power consumption. The reduced clock frequency, a
programmable fraction of the normal clock rate, is specified by a selectable
divisor n given in the instruction: n = 16, 32, 64, or 128. The instruction leaves
the processor fully functional, but operating at the slower rate during
execution of the IDLE (n) instruction. While it is in this state, the processor’s
other internal clock signals (such as SCLK, CLKOUT, and the timer clock) are
reduced by the same ratio.
When the IDLE (n) instruction is used, it slows the processor’s internal clock
and thus its response time to incoming interrupts—the 1-cycle response time
of the standard IDLE state is increased by n, the clock divisor. When an
enabled interrupt is received, the ADSP-21xx will remain in the IDLE state for
up to a maximum of n CLKIN cycles (where n =16, 32, 64, or 128) before
resuming normal operation.
When the IDLE (n) instruction is used in systems that have an externally
generated serial clock, the serial clock rate may be faster than the processor’s
reduced internal clock rate. Under these conditions, interrupts must not be
generated at a faster rate than can be serviced, due to the additional time the
processor takes to come out of the IDLE state (a maximum of n CLKIN cycles).
Serial port autobuffering continues during IDLE without affecting the idle
state.
Status Generated:
None affected.
Instruction Field:
Idle, Instruction Type 31:
23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Slow Idle, Instruction Type 31:
23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 DV