RAM

The term Random Access Memory (RAM) is typically applied to memory that is easily read from and written to by the microprocessor.
In actuality, this is a misuse of this term. For a memory to be random
access means that any address can be accessed at any time. This is to
differentiate it from storage devices such as tapes or hard drives where
the data is accessed sequentially.
In general, RAM is the main memory of a computer. Its purpose is
to store data and applications that are currently in use. The operating
system controls the use of this memory dictating when items are to be
loaded into RAM, where they are to be located in RAM, and when they
need to be removed from RAM. RAM is meant to be very fast both for
reading and writing data. RAM also tends to be volatile in that as soon
as power is removed, all of the data is lost.
Static RAM (SRAM)
SRAM is made from an array of latches such as the D-latch. Each latch can maintain a single bit of data within a single memory address or location.
Latches are not small devices as logic circuits go, but they are very
fast. Therefore, in the pursuit of the performance goals of speed and
size.
SRAMs are better adapted to speed. In general, SRAMs:
• store data in transistor circuits similar to D-latches;
• are used for very fast applications such as RAM caches;
• tend to be used in smaller memories which allows for very fast
access due to the simpler decoding logic; and
• are volatile meaning that the data remains stored only as long as
power is available.
Dynamic RAM (DRAM)
A bit is stored in a DRAM using a device called a capacitor. Presence of charge is considered a logic '1'. The absence of a charge is considered a logic '0'. Since a capacitor can be made very small, DRAM technology is better adapted to high density memories, i.e., cramming a great deal of bits into a small space.
Capacitors do have a problem though. Every once in a while, one of the electrons will escape from the negatively charged plate and land on the positively charged plate. If this happens enough, the stored '1' will disappear. This movement of electrons from one plate to the other is referred to as leakage current.
The electrons stored on the plates of the capacitors are also lost
when the processor reads the data. Therefore, each read removes some of the electrons. In order to avoid having leakage current or processor reads corrupt the data stored on the DRAMs, an additional logic called refresh circuitry is used that periodically reads the data in the DRAM then restores the ones with a full charge of electrons. The refresh process involves disabling memory circuitry, then reading each word of data and writing it back.
In general, DRAMs:
• have a much higher capacity due to the smaller size of the capacitor
(The RAM sticks of your computer's main memory are DRAMs.);
• will "leak" charge due to the nature of capacitors eventually causing
the data to disappear unless it is refreshed periodically;
• are much cheaper than SRAM; and
• are volatile meaning that the data is fixed and remains stored only
as long as power is available.

Synchronous Memory Interfacing
When the memory follows a precise timing requirement governed by a clock that is added to the bus to keep everything attached in lock-step, the interface is
referred to as synchronous and the memory that uses this type of
interface is referred to as synchronous DRAM or SDRAM.
One improvement to SDRAM allows two words of data to be
written or read during a single clock cycle. This means that every time
the processor accesses the memory it transfers two words, one on the
rising edge of the clock and one on the falling edge. This type of
memory is referred to as Double Data Rate SDRAM or DDR SDRAM. DDR2 and DDR3 double and quadruple the DDR rate by allowing four and eight data words respectively to be transferred during a single clock pulse.