Microprocessors Meghraj

download Microprocessors Meghraj

of 4

Transcript of Microprocessors Meghraj

  • 8/3/2019 Microprocessors Meghraj

    1/4

    Microprocessors

    A microprocessor is a multipurpose programmable clockdriven, register based

    electronic device that reads binary instruction from a storage device called

    memory, accepts binary data as input and process data according to thoseinstructions and provides results as output.

    At present various microprocessors are available from different manufacturers.

    Examples of widely used 8 bit microprocessors include Intel 8085,Zilog Z80

    Motorola 68008 etc. Here are some pictures of microprocessors...

    (figure 1)

    (figure 2)

    Figure 2 shows a simplified but formal structure of a microprocessors based

    system. It includes three components microprocessors, input and output ports,

    memory. These 3 components are organised around a common

    communication path called a system bus.

    The microprocessor based system can be discussed under mainly 3 groups

    namely hardware, software, application spectrum...

    (figure 3)

    Talking about hardware perspective

    The microprocessor can be divided into 3 segments mainly ALU, register array,

    control unit.

    ALU: this is the area of the microprocessor where various computing functions

    are performed on data. The ALU unit performs such arithmetic operations as

    addition and subtraction and such logic operations as AND, OR and exclusive

    OR.

    Register Array: This area of the microprocessor consists of various registers

    identified by letters such as B, C, D, E, H, and L. These registers are primarily

    used to store data temporarily during the execution of a program and are

    accessible to the user through instructions.

  • 8/3/2019 Microprocessors Meghraj

    2/4

    Control Unit: The control unit provides the necessary timing and control signals

    to all the operations in the microcomputer. It controls the flow of data

    between the microprocessor and peripherals.

    Memory unit

    Memory stores binary information as instruction/data and provides that

    information to microprocessor whenever necessary.

    For better understanding let us imagine memory unit to be a tall building

    consisting of 8 floors including the ground floor. Let each floor consist of only 1

    house where a maximum of only 8 members are allowed to occupy. Let the

    address of the house at the ground floor be 000 and of the one in 1st

    floor be

    001 and so on. If a man represent 0 and a woman represent 1 then any

    combination of 0s and 1s can occupy a house unless the number exceeds 8.

    Referring to the above analogy the no of floors can be considered as the size of

    the memory block i.e 8=23

    in this case that the memory block contains 8

    locations where it can store the data, each house can be considered as a

    register which can hold 8 bit data which is nothing but the no of men and

    women staying at a house, the address given to every house is the address to

    every location of the memory, since in this case the memory size is 8 3 bits are

    required to specify the address. Both the address and data are represented in

    hex code . It is very important to know the difference between address of thememory location and the data stored in that particular location.

    The memory block has 2 major sections ROM and RAM.

    ROM is used to store programs that do not need alterations. Monitor program

    of a single board microcomputer is generally stored in ROM.

    RAM also known as user memory is used to store user program and data which

    can be altered.

    SYSTEM BUS

    This consists of 3 different buses Address bus, Data bus, Control bus..

    Address bus: it is a group of 16 lines generally identified as A0 to A15.The

    address bus is unidirectional: bits flow in 1 direction from the MPU to

    peripheral devices.

  • 8/3/2019 Microprocessors Meghraj

    3/4

    Data bus: the data bus is a group of eight lines used for data flow. These lines

    are bidirectional data flow in both directions between the MPU and

    peripheral devices.

    Control bus: It is comprised of various single lines that carry synchronization

    signals. These are not groups of lines like address or data buses, but individual

    lines that provide a pulse to indicate an MPU operation. The MPU generates

    specific control signals for every operation it performs.

    Now the question that arises is how is data processed in Microprocessor..

    The MPU performs primarily 4 operations

    a. Memory readb.

    Memory write

    c. Input readd. Input write

    If we consider ourselves to be present in the MP and the memory block

    considered as a notebook, then reading is a process of acquiring information

    from the notebook , thus the data is transferred from notebook to our brain

    which is analogous to reading data from memory to MP similarly writing would

    mean giving out the information stored in our brain on to the notebook which

    is analogous to transfer of data from MP to memory.

    If the read and write operation has to be performed then the MP needs to

    perform following steps

    a. Identify the memory locationb. Transfer binary informationc. Provide timing or synchronization signals.

    MP uses the address bus to identify the memory location. The MP places 16 bit

    address on the address bus. The address on the bus is decoded by an external

    logic circuit, may be some kind of a high level decoder and the memory

    location is identified. The MPU sends a pulse called memory read or memory

    write as the control signal. The pulse activates the memory chip, and if the

    data stored has to be read , the data is placed on the data bus and brought

    inside the microprocessor where it is processed and executed. Similarly if the

  • 8/3/2019 Microprocessors Meghraj

    4/4

    data is to be stored to the memory location the data is placed on the data bus

    which carries the same from the MP to the memory and is stored.