3-1
CHAPTER 3
PROGRAMMING CONSIDERATIONS
This section provides an overview of the instruction set of the MCS
®
96 microcontrollers and of-
fers guidelines for program development. For detailed information about specific instructions,
see Appendix A.
3.1 OVERVIEW OF THE
INSTRUCTION SET
The instruction set supports a variety of operand types likely to be useful in control applications
(see Table 3-1).
NOTE
The operand-type variables are shown in all capitals to avoid confusion. For
example, a BYTE is an unsigned 8-bit variable in an instruction, while a byte is
any 8-bit unit of data (either signed or unsigned).
Table 3-1. Operand Type Definitions
Operand Type
No. of
Bits
Signed Possible Values
Addressing
Restrictions
BIT 1 No True (1) or False (0) As components of bytes
BYTE 8 No 0 through 2
8
–1 (0 through 255) None
SHORT-INTEGER 8 Yes –2
7
through +2
7
–1
(–128 through +127)
None
WORD 16 No 0 through 2
16
–1
(0 through 65,535)
Even byte address
INTEGER 16 Yes –2
15
through +2
15
–1
(–32,768 through +32,767)
Even byte address
DOUBLE-WORD
(Note 1)
32 No 0 through 2
32
–1
(0 through 4,294,967,295)
An address in the lower
register file that is evenly
divisible by four (Note 2)
LONG-INTEGER
(Note 1)
32 Yes –2
31
through +2
31
–1
(–2,147,483,648 through
+2,147,483,647)
An address in the lower
register file that is evenly
divisible by four (Note 2)
NOTES:
1. The 32-bit variables are supported only as the operand in shift operations, as the dividend in 32-by-
16 divide operations, and as the product of 16-by-16 multiply operations.
2. For consistency with third-party software, you should adopt the C programming conventions for
addressing 32-bit operands. For more information, refer to page 3-9.