ATMEL MICROCONTROLLERS 8 bit RISC

Download Report

Transcript ATMEL MICROCONTROLLERS 8 bit RISC

ATMEL
AVR 8 bit RISC
MICROCONTROLLERS
a general comparison
What does AVR RISC mean?
• The acronym AVR has been reported to stand
for: Advanced Virtual RISC and also for the
chip's designers: Alf-Egil Bogen and Vegard Wollan
who designed the basic architecture at the Norwegian
Institute of Technology.
• RISC stands for reduced instruction set
computer.
CPU design with a reduced instruction set as
well as a simpler set of instructions (like for
example PIC and AVR)
A little history
• The PIC (Programmable Interrupt Controller) appeared
around 1980.
→ 8 bit bus
→ executes 1 instruction in 4 clk cycles
→ Harvard architecture
• AVR (1994)
→ 8 bit bus
→ one instruction per cycle
→ Harvard architecture
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
→
prevents access to RAM
• Harvard architecture
→
separate bus for program and data memory
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
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
AVR 8-Bit RISC - picoPower
Technology
• “PicoPower enables AVR to achieve the
industry’s lowest power consumption with 650
nA with a RTC (real time clock) 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
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
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
AVR has very good documentation
• Wide use
• AVRFreaks .net
• Free software
Most Importantly!!!
• Best C compiler to start programming in C
→ and it is FREE
Code Vision AVR
→ http://www.hpinfotech.ro/
• AVR Studio 4 also free from:
http://www.atmel.com/dyn/products/tools_card.asp?tool_id=2725
Code Vision AVR setup
• After opening Code Vision AVR
click on:
→ tools
→ codewizardAVR
select you chip version and
oscillator frequency
Set/clear the pins you want
LCD setup (LCD from
microprocessors lab)
• Control LCD with port A:
Setting up the Analog to Digital
conversion
• 8 bit A/D on channel 3
(PORTA.3)