Presentation is loading. Please wait.

Presentation is loading. Please wait.

ATMEL AVR 8 bit RISC MICROCONTROLLERS a general comparison.

Similar presentations


Presentation on theme: "ATMEL AVR 8 bit RISC MICROCONTROLLERS a general comparison."— Presentation transcript:

1 ATMEL AVR 8 bit RISC MICROCONTROLLERS a general comparison

2 What does AVR RISC mean? The acronym AVR has been reported to stand for: Advanced Virtual RISC and also for the chip's designers: A lf-Egil Bogen and Vegard Wollan who designed the basic architecture at the Norwegian Institute of Technology. RISC stands for reduced instruction set computer. CPU designCPU design with a reduced instruction set as well as a simpler set of instructions (like for example PIC and AVR)instructions

3 A little history The PIC (Programmable Interrupt Controller) appeared around 1980. →8 bit bus → executes 1 instruction in 4 clk cycles → Harvard architecture → advantage ADC of 10 bits at 200 ks/s AVR (1996) → 16 bit bus → one instruction per cycle → ADC of 10 bits at 15 ks/s

4 AVR 8-Bit RISC High Performance True single cycle execution →single-clock-cycle-per-instruction execution →PIC microcontrollers take 4 clock cycles per instruction One MIPS (mega instructions per second) per MHz →up to 20 MHz clock 32 general purpose registers →provide flexibility and performance when using high level languages Harvard architecture

5 AVR 8-Bit RISC Low Power Consumption 1.8 to 5.5V operation →will use all the energy stored in your batteries A variety of sleep modes → AVR Flash microcontrollers have up to six different sleep modes → fast wake-up from sleep modes Software controlled frequency

6 AVR 8-Bit RISC Compatibility AVR® Flash microcontrollers share a single core architecture →use the same code for all families →1 Kbytes to 256 Kbytes of code →8 to 100 pins → all devices have internal oscillators

7 AVR 8-Bit RISC - picoPower Technology “PicoPower enables AVR to achieve the industry’s lowest power consumption with 650 nA with a RTC running and 100nA in Power Down sleep” (from ATMEL website) - True 1.8V Supply Voltage - Minimized Leakage Current - Ultra Low Power 32 kHz Crystal Oscillator - Digital Input Disable Registers - Power Reduction Register

8

9 So what chip should I use? the application chooses the chip each family has a large number of variants the number of pins, the package, the cost of the chip, the peripherals, the operating voltage, the current consumption, and so forth PIC is more application oriented AVR mostly pin #s and flash memory differ

10 Many choices TI(MSP430), Zilog (Z8), Freescale (SC8), Atmel(AVR), Microchip (PIC), ST, Renesas / Hitachi (Mx or H8), Philips (8051) as just few of the many possible selections MICROCHIP ATMEL and MSP430 → FREE SAMPLES

11 AVR has best documentation Wide use AVRFreaks.net Free software

12 Most Importantly!!! Best C compiler to start programming in C →and it is FREE → http://www.hpinfotech.ro/ Code Vision AVR AVR Studio 4 also free from: http://www.atmel.com/dyn/products/tools_card.asp?tool_id=2725

13 Code Vision AVR setup After opening Code Vision AVR click on: → tools → codewizardAVR select you chip version and oscillator frequency

14 Set/clear the pins you want

15 LCD setup (LCD from microprocessors lab) Control LCD with port A:

16 Setting up the Analog to Digital conversion 8 bit A/D on channel 3 (PORTA.3)

17 Simple code for writing to LCD and reading A/D channel 3 while (1) { // Place your code here lcd_clear(); i = read_adc(3); delay_ms(10); lcd_putsf(“Atmel lecture "); lcd_PrintInt(i); delay_ms(50); }; → The lcd_PrintInt function is displayed on next page. It prints an integer on the lcd. This is my function so you can write a better one.

18 How to print a varaible to the LCD void lcd_PrintInt(int number) { char character[1]; itoa(number, character); lcd_puts(character); } For example: lcd_PrintInt(i) would print the value of i to the LCD.


Download ppt "ATMEL AVR 8 bit RISC MICROCONTROLLERS a general comparison."

Similar presentations


Ads by Google