Lo5 - 3
Lo5 - 3
I. Objectives
At the end of the lesson the students should be able to:
1. Illustrate and relay the flow of information between storage devices to the microprocessor and RAM.
III. Procedure:
A. PRELIMINARY ACTIVITIES
A.1 Prayer
A.2 Greetings
A.3 Classroom management
A.4 Checking of attendance
A.5 Review of past lesson (The teacher will call student/s to recap the lesson.)
B. ACTIVITY
C. ANALYSIS
The teacher will collate the ideas of the students. Each of the student’s ideas will be connected through the following guide questions:
D. ABSTRACTION
With the use of PowerPoint presentation, the teacher will discuss about THE FLOW OF INFORMATION BETWEEN
STORAGE DEVICES TO THE MICROPROCESSOR AND RAM.
HOW COMPUTERS WORK: The CPU and Memory
The computer does its primary work in a part of the machine we cannot see, a control center that converts data input to
information output. This control center, called the central processing unit (CPU), is a
highly complex, extensive set of electronic circuitry that executes stored program instructions. All computers, large and
small, must have a central processing unit. The central processing unit consists of two parts: The control unit and the arithmetic/logic
unit. Each part has a specific function.
Before we discuss the control unit and the arithmetic/logic unit in detail, we need to consider data storage and its relationship
to the central processing unit. Computers use two types of storage: Primary storage and secondary storage. The CPU interacts closely
with primary storage, or main memory, referring to it for both instructions and data. For this reason this part of the reading will
discuss memory in the context of the central processing unit. Technically, however, memory is not part of the CPU.
The control unit of the CPU contains circuitry that uses electrical signals to direct the entire computer system to carry out, or execute,
stored program instructions. Like an orchestra leader, the control unit does not execute program instructions; rather, it directs other
parts of the system to do so. The control unit must communicate with both the arithmetic/logic unit and memory.
The arithmetic/logic unit (ALU) contains the electronic circuitry that executes all arithmetic and logical operations.
The arithmetic/logic unit can perform four kinds of arithmetic operations, or mathematical calculations: addition, subtraction,
multiplication, and division. As its name implies, the arithmetic/logic unit also performs logical operations. A logical operation is
usually a comparison. The unit can compare numbers, letters, or special characters. The computer can then take action based on the
result of the comparison. This is a very important capability. It is by comparing that a computer is able to tell, for instance, whether
there are unfilled seats on airplanes, whether charge- card customers have exceeded their credit limits, and whether one candidate for
Congress has more votes than another.
How do data and instructions get from an input device into memory? The control unit sends them. Likewise, when the time is right,
the control unit sends these items from memory to the arithmetic/logic unit, where an arithmetic operation or logical operation is
performed. After being processed, the information is sent to memory, where it is hold until it is ready to released to an output unit.
The chief characteristic of memory is that it allows very fast access to instructions and data, no matter where the items are within it.
To see how registers, memory, and second storage all work together, let us use the analogy of making a salad. In our kitchen we have:
a refrigerator where we store our vegetables for the salad;
a counter where we place all of our veggies before putting them on the cutting board for chopping;
a cutting board on the counter where we chop the vegetables;
a recipe that details what veggies to chop;
the corners of the cutting board are kept free for partially chopped piles of veggies that we intend to chop more or to mix with other
partially chopped veggies.
a bowl on the counter where we mix and store the salad;
space in the refrigerator to put the mixed salad after it is made.
The process of making the salad is then: bring the veggies from the fridge to the counter top; place some veggies on the chopping
board according to the recipe; chop the veggies, possibly storing some partially chopped veggies temporarily on the corners of the
cutting board; place all the veggies in the bowl to either put back in the fridge or put directly on the dinner table.
The refrigerator is the equivalent of secondary (disk) storage. It can store high volumes of veggies for long periods of time. The
counter top is the equivalent of the computer's motherboard - everything is done on the counter (inside the computer). The cutting
board is the ALU - the work gets done there. The recipe is the control unit - it tells you what to do on the cutting board (ALU). Space
on the counter top is the equivalent of RAM memory - all veggies must be brought from the fridge and placed on the counter top for
fast access. Note that the counter top (RAM) is faster to access than the fridge (disk), but can not hold as much, and can not hold it for
long periods of time.
The corners of the cutting board where we temporarily store partially chopped veggies are equivalent to the registers. The corners of
the cutting board are very fast to access for chopping, but can not hold much. The salad bowl is like a temporary register, it is for
storing the salad waiting to take back to the fridge (putting data back on a disk) or for taking to the dinner table (outputting the data to
an output device).
Let us examine the way the central processing unit, in association with memory, executes a computer program. We will be
looking at how just one instruction in the program is executed. In fact, most computers today can execute only one instruction at a
time, though they execute it very quickly. Many personal computers can execute instructions in less than one-millionth of a second,
whereas those speed demons known as supercomputers can execute instructions in less than one-billionth of a second.
Before an instruction can be executed, program instructions and data must be placed into memory from an input device or a
secondary storage device (the process is further complicated by the fact that, as we noted earlier, the data will probably make a
temporary stop in a register).
Once the necessary data and instruction are in memory, the central processing unit performs the following four steps for
each instruction:
The control unit eventually directs memory to release the result to an output device or a secondary storage device. The combination of
I-time and E-time is called the machine cycle.
Each central processing unit has an internal clock that produces pulses at a fixed rate to synchronize all computer operations. A single
machine-cycle instruction may be made up of a substantial number of sub-instructions, each of which must take at least one clock
cycle. Each type of central processing unit is designed to understand a specific group of instructions called the instruction set. Just as
there are many different languages that people understand, so each different type of CPU has an instruction set it understands.
Therefore, one CPU-such as the one for a Compaq personal computer-cannot understand the instruction set from another CPU-say, for
a Macintosh.
Memory Addresses Like Mailboxes The location in memory for each instruction and each piece of data is identified by an
address. That is, each location has an address number, like the mailboxes in front of an apartment house. And, like the mailboxes, the
address numbers of the locations remain the same, but the contents (instructions and data) of the locations may change. That is, new
instructions or new data may be placed in the locations when the old contents no longer need to be stored in memory. Unlike a
mailbox, however, a memory location can hold only a fixed amount of data; an address can hold only a fixed number of bytes - often
two bytes in a modern computer.
A payroll program, for example, may give instructions to put the rate of pay in location 3 and the number of hours worked in location
6. To compute the employee's salary, then, instructions tell the computer to multiply the data in location 3 by the data in location 6 and
move the result to location 8. The choice of locations is arbitrary - any locations that are not already spoken for can be used.
Programmers using programming languages, however, do not have to worry about the actual address numbers, because each data
address is referred to by a name. The name is called a symbolic address. In this example, the symbolic address names are Rate, Hours,
and Salary.
APPLICATION
IV - EVALUATION
V. ASSIGNMENT:
Prepared by: