Tuesday, 20 December 2011

REVOLUTION!!!!!!!!!!!!!


During early period, people tried to express the natural occurrences in terms of the electrical parameters V and I. This was a very tedious process which motivated people to abstraction .The result of this abstraction are the laws of physics. OHMS law and MAXWELL’s laws are the most basic laws of physics. When these laws were abstracted we got the devices and components which led to the design of basic electronic circuits like the amplifier circuits. Basic electronics has two domains – ANALOG and DIGITAL. 555 IC, OP-amps etc belong to analog circuits. In digital electronics the devices have only two states of operation logic 0/logic1, on/off, true/false. Digital circuits are composed of logic gates like AND, OR, NOT, NAND, NOR, XOR, XNOR.

AND gate
AND GATE
NOR gate
OR GATE
                            
NOT gate
NOT GATE
http://www.kpsec.freeuk.com                                                              


In the higher versions of the digital circuits we attempted to control the speed of operation by using trigger or clock pulses. These are called clocked combinational logic. Moving bit more forward, digital circuits were designed to operate based on the instructions provided by a master and they are called instruction based clocked combinational logic. This is the basic idea behind a micro processor. The history of design of the first microprocessor is interesting. INTEL was the monopoly in the field of digital electronics then. BUSICOMM asked Intel to develop a programmable calculator. But the calculator developed by Intel had 12 units to perform the various tasks and was very large in size.  It was then a scientist TEDHOFF who put forth the idea to integrate all this circuits into a single unit. Thus the first microprocessor of its kind was developed and it was named as 4004 processor. Its function was to act as a programmable calculator. The second processor was 8008 and then many more followed.
.http://www.computerhistory.org/

                     A micro processor is a programmable clock driven register based electronic device which can receive binary digits as input, process binary data according to the instruction given by the master and gives an output in binary form. It is general purpose.

                    Registers are high speed memory cells which are located very close to the processor and hence the access time of such memory cells is very small. But registers are very costly and hence their availability in a system is very limited. There are two types of memory – Dynamic and Static. Usually devices like a capacitor when used they store charge but will discharge after a period of time. Hence these memory cells require constant refreshing and they are called dynamic memory cells. In static there is no need of refreshment. Registers are static memory cells.

                 An 8 bit micro processor kit was exhibited. Bit is the abbreviated form of binary digit. There was a micro processor and other peripheral chips, RAM, input unit, a display etc in the kit. When all this micro processor and other peripheral chips are integrated in a single chip we get a micro controller. Thus a micro controller is a device that is designed to perform a specific task.

PROGRAMMING MODEL OF 8085 PROCESSOR
The programming model of an 8085 processor is given below. Here the ALU unit is acting as the processor. It performs all the arithmetic and logical operations on the data. It is an 8 bit processor which shows that at a time the processor can perform the operations on 8 bit data. The registers available are program counter, instruction register, temporary register, B, C, D, E, H, and L. When more bit operation is to be performed then registers have to be paired. The pairing is done between BC, DE, and HL.  A PC holds the address of the next instruction to be executed and the IR holds the instruction that is currently getting executed. Group of wires are called BUS. There are three buses called address bus, data bus, and control bus. The bus can be bidirectional or unidirectional. Address bus is unidirectional as even if a read or write operation is to be performed by the processor the address will always be specified by the processor. Data bus is bidirectional and the control bus is unidirectional.       The width of the address bus in an 8085 processor is 16 bits and there can be 2^16 addressable locations. According to the definition available in Wikipedia interrupt is"In computing, an interrupt is an asynchronous signal indicating the need for attention or a synchronous event in software indicating the need for a change in execution ". There are two types of interrupts- vectored and nonvectored. In vectored interrupts the address to which the control to be transferred is pre defined and in the non vectored only processor is aware of the fact that it has to change the control but the location has to be provided by the user.
                        The flow of control in a 8085 processor is like as given below. After reset the address of the first instruction is to be placed in the program counter. This address is placed on the address bus and the processor fetches the instruction from the memory and it will be placed in the IR which will be decoded by the next stage instruction decoder and machine encoding cycle. To activate the required circuit inside the ALU proper trigger signal is to be generated which is done by the oscillator in the timing and control unit. There is a small micro processor and micro memory inside the timing and control unit which will activate the oscillator based on the input from the instruction decoder part. This trigger will activate the appropriate circuit in the processor.

                Addressing mode specify the way in which the data is accessed by the processor. Data can be accessed from the register or memory.
                  Next session we were taken to the micro processor lab. We wrote a code to perform the addition of two numbers, three numbers, n numbers and the output were verified using the 8 bit micro processor kit.
The code to perform addition of two numbers using assembly language code is given below.
LDA 5000
MOV B,A
LDA 5001
ADD B
STA 5000
HLT
Here LDA means to copy the contents in 5000 to the accumulator. Using mov command the value in accumulator is moved to a register B.  Then a second operand is accepted into the accumulator. ADD B command causes the contents in A and B to be added and result will be stored in A. STA command causes the result to be moved to an external memory. HLT command is used to end the operation.
The disadvantage of an assembly level language is that it is not user friendly and one has to be aware of the hardware to develop a high efficiency program.

No comments:

Post a Comment