
Rev. 1.00
46 of ���
�an�a�� 1�� �01�
Standard 8051 8-Bit Flash MCU
HT85F2260/HT85F2270/HT85F2280
RAM Data Memory
19
RAM Data Memory
The Data Memory is a volatile area of 8-bit wide RAM internal memory and is the location where
temporary information is stored. Divided into several sections, the first of these is an area of RAM
where special function registers are located. These registers have fixed locations and are necessary
for correct operation of the devices. Many of these registers can be read and written to directly
under program control, however, some remain protected from user manipulation. The second area
of Data Memory is reserved for general purpose use. All locations within this area are read and
write accessible under program control. The Data Memory also includes the Bit-Addressable Space
and four Register Banks.
Structure
The Data Memory is subdivided into two blocks, Internal Data RAM (IDATA) and On-Chip
External Data RAM (XDATA), which are implemented in 8-bit wide RAM. The IDATA is
subdivided into two sections, known as the Upper section and the Lower section. The Upper section
includes two blocks, the Special Function Registers, SFR, and the 128-byte General Purpose RAM.
The Special Function Register can be accessed using direct addressing methods while the 128-byte
General Purpose RAM must be accessed using indirect addressing methods.
The upper section 128-byte RAM has an address range of 80H to FFH, and is assigned to both
the General Purpose memory and the Special Function Registers. Although the address range is
identical these two RAM sections are physically separate, they are distinguished by their different
addressing methodology. Using direct addressing instructions will point to the SFR registers while
indirect addressing instructions will point to the upper 128-byte General Purpose RAM.
The lower section 128-byte RAM is dedicated to the General Purpose RAM, and consists of an
80-byte General Purpose RAM section, four 8-byte register banks and 16-bytes of Bit-Addressable
Space. The lower section can be accessed both by Indirect and Direct addressing methods. The
16-byte Bit-Addressable Space, which can be addressed by both byte format and 128 bit location
format, is located from at the address range, 20H to 2FH. The four register banks, each of which
contains eight bytes of general purpose registers, are located at the address range 00H to 1FH.
The XDATA is assigned as General Purpose Data RAM and can only be accessed using indirect
addressing. The HT85F2270 and HT85F2280 have 2048-bytes of XDATA while the HT85F2260
has 1024-bytes of XDATA.
Note that the internal data memory is also used as a software stack. The designer must initiate the
stack pointer register, namely SP, in the application program.
The following diagram illustrates the memory structure and their various access methods.