One of the easiest-to-use microcontrollers out there, the Atmel AVR AT90S8515
microcontroller's only downside is its price.
- RISC Architecture, up to (true) 8 MIPS at 8MHz
- 8K ISP (in system programmable) Flash memory
- 512 Bytes of each SRAM and (ISP) EEPROM
- Operates with 4 - 6V
- up to 32 I/O Lines
- power down mode, brownout detection
- Timers, Analog comparator, UART, external interrupt lines, Pulse Width
Programming the micro
To program the microcontroller
I used its ISP interface instead of buying one of these expensive programming
kits. For instructions on how to program the micro using the atmel's SPI
bus, refer to the Atmel Datasheet available from the atmel homepage - or
download aVrite from the Dontronics homepage. To use aVrite, wire the micro
to your PC's parallel port as follows:
PC-to-uC ASCII Art
2,6,7,8,9 --->|-- VCC (5 low-loss schottkys)
3 ------- reset
4 ------- SCK
5 ------- MOSI
10 --###-- MISO (1K resistor)
Generating ASM code
The lazy person I am, I decided
not to write Assembler myself but let a compiler do this job. I chose AVRgcc,
available from the Dontronics homepage - mainly because it's free, fast
and much easier to use than comercially available compilers.
Wiring the micro
This is the fun part. Basically you just have to supply +5V to VCC, hook
GND to 0V and connect a resonator (I chose 4MHz) to XTAL1, XTAL2 and GND
(the latter to the center pin of the resonator).
You are ready to begin experimenting with your micro.
This is my wiring diagram. It was originally not
intended to be on my homepage, so resistors are shown as pink lines, red
lines are "holes".
Thumbnail of PCB Layout (zoomable)
The circuit on the top (far-)left is kind of an ultrasonic meter. The
one to the top left of the micro is the ISP interface and the reset pin.
The one to the bottom left is a LCD interface, with a contrast poti. To
the bottom of the micro is the resonator socket. Below this socket are
two transistors I used as amplifiers for sensors.