Presentation is loading. Please wait.

Presentation is loading. Please wait.

Atmega32 processor architecture Presentation By:- Sojitra Tushar(130360111011) Sitapara Kishor(130360111009) Ramani hiren (130360111007) Malakiya vipul.

Similar presentations


Presentation on theme: "Atmega32 processor architecture Presentation By:- Sojitra Tushar(130360111011) Sitapara Kishor(130360111009) Ramani hiren (130360111007) Malakiya vipul."— Presentation transcript:

1 Atmega32 processor architecture Presentation By:- Sojitra Tushar(130360111011) Sitapara Kishor(130360111009) Ramani hiren (130360111007) Malakiya vipul (130360111005) Sub:- microcontroller Department.:- Electronics & Communication College:- Sanjaybhai Rajguru College of Engineering

2 Architecture – attributes of a system visible to a programmer – these attributes have a direct impact on the logical execution of a program Instruction set, number of bits used for data representation, I/O mechanisms, addressing techniques – Design issue: whether a computer will have a specific instruction. e.g. Is there a multiply instruction?

3 Organization – the operational units and their interconnections that realize the architectural specifications (how features are implemented) – hardware details that are transparent to the programmers – Control signals, interfaces, memory technology – Design issue: how this instruction is to be implemented. Is there a hardware multiply unit or is it done by repeated addition? Split caches or unified cache

4 Many computer manufacturers offer a family of computer models, all with the same architecture but with differences in organization. This gives code compatibility (at least backwards) – All Intel x86 family share the same basic architecture – The IBM System/370 family share the same basic architecture An architecture may survive many years, but its organization changes with the changing technology. – E.g. the IBM Systems/370 architecture, with few enhancements, has survived to this day as the architecture of IBM's mainframe product line.

5 Atmel Corporation is a manufacturer of semiconductors, founded in 1984.semiconductors Atmel introduced the first 8-bit flash microcontroller in 1993, based on the 8051 core. In 1996, a design office was started in Trondheim, Norway, to work on the AVR series of products. Its products include microcontrollers (including 8051 derivatives and AT91SAM and AT91CAP ARM-based micros), and its own Atmel AVR and AVR32 architectures.8051AT91SAMAT91CAPARMAtmel AVRAVR32

6 The AVR architecture was conceived by two students at the Norwegian Institute of Technology (NTH) Alf-Egil Bogen and Vegard Wollan. The AVR is a modified Harvard architecture 8-bit RISC single chip microcontroller which was developed by Atmel in 1996. The AVR was one of the first microcontroller families to use on-chip flash memory for program storage, as opposed to one-time programmable ROM, EPROM, or EEPROM used by other microcontrollers at the time. The AVR is a modified Harvard architecture machine where program and data is stored in separate physical memory systems that appear in different address spaces, but having the ability to read data items from program memory using special instructions. Atmel says that the name AVR is not an acronym and does not stand for anything in particular. The creators of the AVR give no definitive answer as to what the term "AVR" stands for. However, it is commonly accepted that AVR stands for Alf (Egil Bogen) and Vegard (Wollan)'s Risc processor"

7  In a Harvard architecture, there is no need to make the two memories share characteristics. In particular, the word width, timing, implementation technology, and memory address structure can differ. In some systems, instructions can be stored in read-only memory while data memory generally requires read-write memory. In some systems, there is much more instruction memory than data memory so instruction addresses are wider than data addresses.wordmemory addressread-only memoryread-write memory Howard Hathaway Aiken  The Harvard architecture is a computer architecture with physically separate storage and signal pathways for instructions and data.computer architecturestorage  The term originated from the Harvard Mark I relay-based computer, which stored instructions on punched tape (24 bits wide) and data in electro-mechanical counters.Harvard Mark Ipunched tape

8  The phrase Von Neumann architecture derives name of the mathematician and early computer scientist John von Neumann.mathematiciancomputer scientistJohn von Neumann  The meaning of the phrase has evolved to mean a stored-program computer in which an instruction fetch and a data operation cannot occur at the same time because they share a common bus. This is referred to as the Von Neumann bottleneck and often limits the performance of the system.busVon Neumann bottleneck John von Neumann  In contrast with the Harvard architecture, the Von Neumann architecture has a single storage structure to hold both instructions and data. The CPU can be either reading an instruction or reading/writing data from/to the memory because instructions and data use the same bus system.

9 A modified Harvard architecture machine is very much like a Harvard architecture machine, but it relaxes the strict separation between instruction and data while still letting the CPU concurrently access two (or more) memory buses. The most common modification includes: Separate instruction and data caches backed by acommon address space. While the CPU executes from cache, it acts as a pure Harvard machine. When accessing backing memory, it acts like a von Neumann machine (where code can be moved around like data, a powerful technique). This modification is widespread in modern processors such as the ARM architecture and X86 processors.cachesARM architectureX86 Provides a pathway between the instruction memory (such as ROM or flash) and the CPU to allow words from the instruction memory to be treated as read-only data. This technique is used in some microcontrollers, including the Atmel AVR. This allows constant data, such as text strings or function tables, to be accessed without first having to be copied into data memory, preserving scarce (and power-hungry) data memory for read/write variables. Special machine language instructions are provided to read data from the instruction memory. (This is distinct from instructions which themselves embed constant data, although for individual constants the two mechanisms can substitute for each other.)Atmel AVR

10 CISCRISC Emphasis on hardwareEmphasis on software Include multi-clock complex instructionsInclude single-clock reduce instruction only Memory-to-memory: “Load” and “Store” incorporated in instructions Register-to-register: “Load” and “Store” are independent instructions Small code sizes, high cycles per secondLow cycles per second, large code sizes Transistors used for storing complex instructions Spends more transistors on memory registers RISC vs. CISC is a topic quite popular on the Net. Every time Intel (CISC) or Apple (RISC) introduces a new CPU, the topic pops up again. Most PC's use CPU based on CISC architecture. For instance Intel and AMD CPU's are based on CISC architectures. Many claim that RICS is the architecture of the future. But even though RISC has been in the market since 1980, it hasn’t managed to kick CISC out of the picture, some argue that if it is really the architecture of the future it should have been able to do this by now.

11  Classic AVR  e.g. AT90S2313, AT90S4433  Mega  e.g. ATmega8, ATmega32, ATmega128  Tiny  e.g. ATtiny13, ATtiny25  Special Purpose AVR  e.g. AT90PWM216,AT90USB1287

12 ATmega128 ATtiny44 Atmel group Flash =128K Atmel Flash =4K AT90S4433 Atmel Classic group Flash =4K Tiny group

13 Port A Port B Port D Port C

14

15

16 Digital IO is the most fundamental mode of connecting a MCU to external world. The interface is done using what is called a PORT. A port is the point where internal data from MCU chip comes out or external data goes in. They are present is form of PINs of the IC. Most of the PINs are dedicated to this function and other pins are used for power supply, clock source etc. ATMega32 ports are named PORTA, PORTB, PORTC, and PORTD.

17

18

19

20 Defining a pin as either Input or Output – The DDRx Registers LDI R20,0xFF ;R20 = 0b01110101 (binary) OUT PORTx,R20 ;PORTA = R20 OUT DDRx,R20 ;DDRA = R20 DDRx = 0b01110101; /* Configuring I/O pins of portb */

21 Case 1 : To make a pin go high or low ( if it is an output pin)- Data Register PORTx

22 Pull-up resistors are used in electronic logic circuits to ensure that inputs to logic systems settle at expected logic levels if external devices are disconnected or high-impedanceresistorslogic circuitshigh-impedance

23 Case 2 : To activate / Deactivate pull up resistors-Data Register PORTx

24 The PINx register gets the reading from the input pins of the MCU

25

26 Native data size is 8 bits (1 byte). Uses 16-bit data addressing allowing it to address 2 16 = 65536 unique addresses. Has three separate on-chip memories 2KB SRAM 8 bits wide used to store data 1KB EEPROM 8 bits wide used for persistent data storage 32KB Flash 16 bits wide used to store program code I/O ports A-D Digital input/output Analog input Serial/Parallel Pulse accumulator

27 1.2KB SRAM – For temporary data storage – Memory is lost when power is shut off (volatile) – Fast read and write 2.1KB EEPROM – For persistent data storage – Memory contents are retained when power is off (non-volatile) – Fast read; slow write – Can write individual bytes 3.32KB Flash Program Memory – Used to store program code – Memory contents retained when power is off (non-volatile) – Fast to read; slow to write – Can only write entire “blocks” of memory at a time – organized in 16-bit words (16KWords)

28 AVR microcontrollers are Harvard architecture. This means, that in this architecture are separate memory types (program memory and data memory) connected with distinct buses. Such memory architecture allows processor to access program memory and data memory at the same time. This increases performance of MCU comparing to CISC architecture, where CPU uses same bus for accessing program memory and data memory. Each memory type has its own address space:

29 Flash Memory Layout

30 ATmega32 contains 1024 bytes of data EEPROM memory. It is organized as a separate data space, in which single bytes can be read and written. The EEPROM has an endurance of at least 100,000 write/erase cycles. Different chip have different size of EEPROM memory EEPROM

31 GPRs (general purpose registers), Special Function Registers (SFRs), and Internal data SRAM. The data memory is composed of three parts:

32 Internal data SRAM is widely used for storing data and parameters by AVR programmers and C compilers. Each location of the SRAM can be accessed directly by its address. Each location is 8 bit wide and can be used to store any data we want. Size of SRAM is vary from chip to chip, even among members of the same family.

33


Download ppt "Atmega32 processor architecture Presentation By:- Sojitra Tushar(130360111011) Sitapara Kishor(130360111009) Ramani hiren (130360111007) Malakiya vipul."

Similar presentations


Ads by Google