
Instruction Set Overview
2-7
2.4.6
Operation It Performs
This section uses a combination of C-language and assembler syntax to describe the
operation of the instruction in detail. In some cases, pseudo-code functions are used to
simplify the code. These functions and the actions they perform are as follows:
2.4.7
Flag S ettings After Instruc tion
This section identifies the flags that are set, cleared, modified according to the result,
unchanged, or left undefined by the instruction. Each instruction has the graphic below,
and shows values for the flag bits after the instruction is performed. A "" in the bit field
indicates the value is undefined; a "–" indicates the bit value is unchanged. See "Processor
Status Flags Register" on page 1-2 for more information on the flags.
2.4.8
E xamples
This section contains one or more examples that illustrate possible uses for the instruction.
The beginning of each example is marked with a printout icon; a summary of the example’s
function appears next to it. The example code follows the summary. Note that some of the
examples use assembler directives: CONST (define constant data), DB (define byte), DD
(define double), DW (define word), EQU (equate), LENGTH (length of array), PROC (begin
procedure), SEGMENT (define segment), SIZE (return integer size) and TYPE (return
integer type).
Pseudo-Code Function
cat(componenta,componentb)
execute(instruction)
interrupt(type)
interruptRequest()
Action
Component A is concatenated with component B.
Execute the instruction.
Issue an interrupt request to the microcontroller.
Return True if the microcontroller receives a maskable
interrupt request.
Return the least significant bit of the component.
Return the most significant bit of the component.
Return the next most significant bit of the component.
Return True if the microcontroller receives a nonmaskable
interrupt request.
Return the number of operands present in the instruction.
Read a word from the top of the stack, increment SP, and
return the value.
Raise component to the nth power.
Decrement SP and copy the component to the top of the
stack.
Return True if a device resets the microcontroller by asserting
the RES signal.
Service any pending interrupts.
Return the size of the component in bits.
Suspend execution of current instruction sequence.
leastSignificantBit(component)
mostSignificantBit(component)
nextMostSignificantBit(component)
nmiRequest()
operands()
pop()
pow(ncomponent)
push(component)
resetRequest()
serviceInterrupts()
size(component)
stopExecuting()
= unknown; – = unchanged
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
Processor Status
Flags Register
reserved
OF DF
IF TF SF ZF
AF
PF
CF
= undefined; – = unchanged
res
res
res