16 www.ubicom.com IP2022 Data Sheet 3.2 Data Memory Figure  3-6  is  a  map  of  the  data  memory.  The  special-
purpose registers and the first 128 data memory locations
(between addresses 0x080 and 0x0FF) can be accessed
with  a  direct  addressing  mode  in  which  the  absolute
address of the operand is encoded within the instruction.
The  remaining  3840  bytes  of  data  memory  (between
addresses  0x100  and  0xFFF)  must  be  accessed  using
indirect or indirect-with-offset addressing modes. There is
one  16-bit  register  for  the  indirect  address  pointer,  and
two    16-bit    registers    for    indirect-with-offset    address
pointers.  The  offset  is  a  7-bit  value  encoded  within  the
instruction.  For  more  information  about  the  addressing
modes, see Section 4.1.
Figure 3-6  Data Memory Map 3.3 Program Memory Figure 3-7 is a map of the program memory. A program
memory address in the INTVECH/INVECL, IPCH/IPCL, or
PCH/PCL registers  or  on  the  hardware stack  is  a word
address.  However, the GNU software tools require byte
addresses   when   referring   to   locations   in   program
memory.
An address loaded in the ADDRX/ADDRH/ADDL register is a byte address. Figure 3-7  Program Memory Map The  program  memory  is  organized  as  8K-word  pages
(16K bytes). Single-instruction jumps and subroutine calls
are restricted to be within the same page. Longer jumps
and  calls  require  using  a  page  instruction  to  load  the
upper  address  bits  into  the  PA2:0  bits  of  the  STATUS
register. The page instruction must immediately precede
the jump or call instruction. The PA2:0 bits should not be
modified   by   writing   directly   to   the   STATUS   register,
because this may cause a mismatch between the PA2:0
bits  in  the  STATUS  register  and  the  current  program
counter (see Section 3.3.2). For more information about
the flash program memory, see Section 4.7.
External memory is not shown in Figure 3-7 because the
CPU cannot execute instructions directly out of external
memory.  For  more  information  about  external  memory,
see Section 5.11.
515-028a.eps               127
Special-Purpose
Registers   3840 Bytes
Data Memory
0x001 7 0 0x080 0xFFF               128
Global Registers
0x100 0x07F 0x0FF 515-006a.eps Program RAM Reserved 0x000000 15 0 0x004000 Flash Program Memory 0x014000 Flash Program Memory 0x018000 Flash Program Memory 0x01C000 Flash Program Memory 0x01FFFE 0x010000 0x0000 0x2000 0xA000 0xC000 0xE000 0xFFFF 0x8000     Byte
Address
   Word
Address
0x003FFE 0x013FFE 0x017FFE 0x01BFFE 0x00FFFE 0x1FFF 0x9FFF 0xBFFF 0xDFFF 0x7FFF