\section{Introduction}
Although the differences between the memory systems in the 3 models of 
clacualtor mean that the systems will be described separately, there are 
genearl features common to all of them which will be described first.

The memory system consistrs of the ROMs (both those containing the 
standard calculator firmware and those in optional extension modules), 
the RAM, and the memroy cotnrol circuitry. The latter contains a pair of 
16 bit shift registers, the memory address (or `M') register is serially 
loaded with the current memroy address by the processor. Its parallel 
output select a particular location in the ROM or RAM. The memory data 
(or `T') register provides an interface betwee nthe 16 bit parallel 
memory data bus and the bit-serial processor. For read operations, the 
contents of the selected memory location are parallel-loded into the 
memroy data register and trasnfered serially to the processor. For write 
operations, the memroy data register is loaded serially by the processor 
and then its contents are transfered to the addressed RAM location.

The parallel outputs of the M register address a 32K word address space 
(the MSB, {\bf M(15)}, which correspods to the indireciton bit of a 
procesosr address, is used to trigger an eaxternal DMA device in the 
HP9820 and HP9830 machines, and is not regarded as part of the 
memory address). This single address space contains the ROM and RAM devices.

The CPU microocde word bits 24 and 25, known as the `S field' (with bit 24
as the MSB) are decoded by the memory control system. This field controls
the bit-serial input to the second ALU input (signal {\bf ALUSerIn}) and
has the following meanings : 
\begin{description}
\item[S=0] : Force 0 into the ALU
\item[S=1] : Read the M register into the ALU
\item[S=2] : Read the T register into the ALU
\item[S=3] : Force 1 into the ALU
\end{description} 

The ROM devices used are HP-designed 512*8 bit mask-programmed ROMs. They 
are somwahat unconventional, in that they are internally designed as a 
pair of 256*8 ROMS\footnote{The organisation of the device and the 
data it contains are determined by the final metalisation layer on the 
chip. 256*16 bit ROMs using the same underlying device are found in other HP 
products of the period.}. Each secion of the ROM is eanabled by a 
separate active-low input, these are conventionally linked to gate forms 
of address line {\bf A8} and its inverse, so that when the ROM is 
accessed one (and only one) of the sections is eanabled. Another 
unconventional feature of these early MOS ROMs is that the enable inputs 
have to be taken to +12V votlage levels, rather than the (5V) 
TTL-compatible levels on all the other inputs and outputs.

This series of machines was one of the first major commercial 
applications for the Intel 1103 1K bit RRAM. These PMOS devices run from 
-16V supplies with a +3V bias supply, and have 16V votlage swings on the 
logic inputs and outputs. In the HP9800 series, the power supply pins are 
re-labelled as +16V and +19V (this makes no electrical differenec, you 
can connect th ecommon lead of your voltmeter anywhere), but of course 
bufferes are still needed to convert between the TTL level logic signals 
used elsewhere in the machine and the 16V ones used by the RAMs.

One further comment is that the processor requires ROM starting at
locaiton 0 to provide the first instruciton to be executed at power-on,
the 'counter constant' at locaiton 1 (this is a special bit pattern,
($043060_8$) used by the floating point microcode routines. However, the
memory area from $1400_8$ to $1777_8$ must contain RAM to store the
floating point data, the ssytem stack point, etc. This is no problem on
the HP9810, which simply fils the first 512 words with a pair of ROMs and
the next 512 words with a block of RAM but it slightly complicates the
address decoder in the other calculators. 

Physicaly, the memory system of the HP9810 and HP9820 machines is 
contained in a memtal boc plugged into the main backplane, Inside the box 
are the ROM and RAM PCBs and 3 boards of memory control circuity ({\bf 
Memory Address},  {\bf Memory Data}, and {Memory Timing} PCBs. The memory 
ssytem of the HP9830 consists of PCBs directly plugged into the main 
backplane, these consist of ROM and RAM PCBs, 2 boards ({\bf Memory 
Addres} and {\bf Memory Data}) contianing the memory control circutiry, 
and the {\bf Ext ROM Seleector} PCB. 

