Week 6
Week 6
Secondary storage is a memory that is stored external to the computer. It is mainly used for the
permanent and long-term storage of programs and data. Secondary memories are classified into two
types. Disk drives and tape drives. Examples include floppy disks, hard disks, SD cards, pen/flash
drives, SSD, and others; optical memories include CDs, DVDs, and others. Hard disk stores and
retrieves data using magnetic storage. Uses multiple magnetic disks coated with magnetizable
material such as iron oxide. Redundant arrays of independent disks (RAID) is another type of
memory that consists of multiple disks. This technology is used to increase the performance of data
storage through parallel I/O access. It provides reliable data storage. And this reliability is achieved
through redundancy. SSD or solid-state disks are an alternative to magnetic disks. It is a faster
memory compared to magnetic memories. Most people prefer SSD not just because it is a faster
memory but it is also a green device. SSD is a green device because SSD has no moving parts and
hence its energy consumption is much lower compared to the magnetic disk. SD card is a tiny flash
memory card. SD cards are typically used in digital cameras and other portable devices. USB flash
drive is also popularly known as pen drive. It is a plug-and-play portable storage device that uses
flash memory. Optical Devices include Compact disks such as CD, CD read-write, DVD, and so on.
6.3.3 Example of Memory Unit: 4×3-bit Memory
Figure 23: SRAM structure
Memory is capable of storing many 1s and 0s. Figure 23 shows the M by K read-write memory
whose address space is M and addressability is K. The memory is capable of being written into and
read from. Whenever the processor wants to perform reading and writing operations, it sends signals
on read and write lines, respectively. To perform a read or write operation, the processor has to send
an N-bit address on the address lines. The relationship between the number of address bits and the
address space is given by 2N = M. Data to be written into is sent on the K data input lines, and data
to be read from is sent on K data output lines.
Figure 24: 4×2 memory structure
Figure 24 shows the 4×2-bit memory. There are four memory locations; in each location, 2 bits of
information can be stored. Thus, a total of 8 bits of information can be stored in this memory. To
store these 8 bits, for each location, two flip-flops are needed. Two address lines, A1 and A0,
address four memory locations. To provide the addressability of two, there are two data input lines
and two data output lines. Data inputs are fed to the D input of the flip-flop. Data input gets latched
into the flip-flop when the clock signal is enabled. Data inputs are written to which location is decided
by the binary signal on address lines A1 and A0 and write enable WE line. The two address lines are
connected to the 2:4 decoder circuit.
Consider an example that illustrates memory write operation. Assume that the data to be written is 1
0, and the address of the memory location is 0. So, A1, A0 is set to 00, and D1 D0 is set to 10.
To write data into the memory, write enable WE signal is set to 1. This enables the first output of the
decoder, which in turn is connected to the clock inputs of the first two flip-flops, FF01 and FF00. By
enabling the clock inputs, both flip-flops store data available at D1 and D0 inputs. In this case, it is 1,
0. In the case of a memory read operation, data is obtained from the OR gate output lines. This OR
gate is driven by the AND gates. One of the inputs for these AND gates comes from the output of the
flip-flop, and the decoder output drives the other input.