Vous êtes sur la page 1sur 7

ATmega48/88/168 Development Board

This is versatile development board for AVR microcontrollers ATmega48/88/168. It is good for testing and debugging embedded programs. It has many built-in peripheries connected to microcontroller so you can use them without soldering. ATmega microcontrollers are produced by ATMEL and they include a lot of features: I/O, Timers, PWM generators, ADC, RS232, TWI, SPI, Analog Comparator, Oscillator, EEPROM These microcontrollers are very versatile, easy to program and easy to use. This is the reason why I like these microcontrollers and why I decided to make development board for them.
LEDs Reset Config Header Port C Pot.
Temp. Analog Temp. PWM

Screw Terminals

RS232

Port D Piezo

Crystal Port B CPU Power Supply Buttons

AREF

ISP

Top view

Bottom view

1. ATmega AVR microcontroller in DIP28 package The development board is designed to use ATmega48 with 4kB flash memory or ATmega88 (8kB), ATmega168 (16kB). New version of these microcontrollers ATmega48P/88P/168P and ATmega328P (with 32kB) are pin compatible so they can be used also. External crystal X1 is placed in socket, so it is easy to change it or remove it. If internal oscillator is used then two PB6 and PB7 pins dedicated for crystal can be connected to the Port B connector. Microcontroller can be reset by pressing reset button S1.

2. AVR Ports B, C, D headers If built in peripheries are not used another device can be connected to the PORT B, C and D. Each port is connected to the 10-pin header. You could connect LCD display, Rotary Encoder, SD Card Reader, etc. with microcontroller. See my future posts.

3. 5V Power supply Both AC and DC voltage can be plugged in, because of using rectifier bridge. Input voltage can be connected to 2.5mm power jack connector or screw terminal. Power can be switch on / off by SW1. Power supply voltage is stabilized by common IO 7805. When the power is switch on red LED6 is lighted.

4. 4x LEDs Four green LEDs can be connected to the Port D shorting jumpers JMP6-9.

5. 4x Buttons Four buttons are connected to the Port B.

6. Piezo Piezo speaker can be connected to pin PB1 through JMP5.

7. ADC accessories The microcontroller has built-in 10bits AD converter. On the board is LC filter for power supply of this ADC. You can use internal or external reference. The rotary trimming resistor R2 is connected to Aref input for playing with the external reference.

8. Potentiometer For simulation of varying ADC input voltage the rotary trimming resistor R1 can be connected to PC1 (ADC1) through JMP12.

9. Temperature sensors If you want to play with temperature sensor, you can connect temperature sensor with either analog or PWM output. Temperature sensor with analog output can be connected to the PC0 (ADC0) through JMP10. Temperature sensor with PWM output can be connected to the PB0 through JMP11.

10. RS232 line Standard serial interface is placed on the board. Level shifter MAX232 is used. MAX232 has two receiver and two transmitter lines. You can connect RXD and TXD of RS232 with RXD and TXD of microcontroller with help of config header. RTS and CTS of RS232 can be connected with PD6 and PD7 through JMP3 and JMP4. See config header part.

11. Config Header Config header allows interconnect different I/O microcontroller pins with RS232 line or with screw terminal.

12. Screw Terminals Screw terminals allow easily connect wires to microcontroller. Through this terminal you compose for example frequency counter of voltmeter, etc. Ground and 5 Volts are also presented on screw terminal.

13. ISP Development board includes serial port interface to allow direct in-system programming (ISP). Microcontroller can be programmed trough RS232 serial port by using program Pony Prog or AVDdude (ponyser). To avoid interference with RS232 signals, programmer can be disconnected using analog switches 4066. These switches can be closed manually by SW2 or automatically when the reset is active (using JMP13).

14. Mounting Holes In each corner of PCB is placed one 3.2mm mounting hole.

You can find this article on my blog site: http://diy4fun.blogspot.com/2008/04/atmega4888168-development-board.html

Following web side inspired me to build the development board. http://hubbard.engr.scu.edu/embedded/avr/boards/index.html

PROCESSOR
VCC R1 10K RESET C1 100nF GND VCC

BYPASS CAPACITOR
VCC

PUSHBUTTONS

TEMPERATURE SENSORs
VCC S2 S3 S4 S5 3 IO4 LM35CZ 2 JMP10 PC0

S1

IO1 PC6 PD0 PD1 1 2 3 4 5 6 7 8 9 PC6 (RESET) PD0 (RXD) PD1 (TXD) PD2 (INT0) PD3 (INT1/OC2B) PD4 (T0/XCK) VCC GND PB6 (TOSC1/XTAL1) PB7 (TOSC2/XTAL2) PD5 (T1/OC0B) PD6 (AIN0/OC0A) PD7 (AIN1) PB0 (ICP1/CLKO) ATmega48 GND GND PC6 PC4 PC2 PC0 IO2 2 16 VDD VCC C1+ C1C2+ C2T1IN T2IN 1 3 4 5 11 10 12 9 15 (ADC5/SCL) PC5 (ADC4/SDA) PC4 (ADC3) PC3 (ADC2) PC2 (ADC1) PC1 (ADC0) PC0 AGND AREF AVCC (SCK) PB5 (MISO) PB4 (OC2A/MOSI) PB3 (SS/OC1B) PB2 (OC1A) PB1 28 27 26 25 24 23 22 21 20 19 18 17 16 15 AREF AVCC PB5 PB4 PB3 PB2 PB1 VCC P4 1 3 5 7 9 2 4 6 8 10 PC5 PC3 PC1 PB6 PB4 PB2 PB0 PC5 PC4 PC3 PC2 PC1 PC0 GND C12 100pF PB2 PB3 PB4 PB5

+VS VOUT GND 1

A GND GND 2 IO5 +VS VOUT GND 3 SMT160-30 1 JMP11 PB0

GND

PD2 PD3 PD4

C2 22pF

I/O PORT INTERFACE


AREF AVCC VCC P3 1 3 5 7 9 2 4 6 8 10 PB7 PB5 PB3 PB1

STATUS LED
VCC R6 330 R7 330 R8 330 GND R9 330 LED4 JMP9 PD7 GND LED1 JMP6 PD4 LED2 JMP7 PD5 1 LED3 JMP8 PD6 3

GND

2 X1 20MHz PD5 GND C3 22pF JMP1 PB6 JMP2 B PB7 PD6 PD7 PB0

10 11 12 13 14

POTENCIOMETER
VCC R15A 10k 2 C18 100nF B GND

JMP12 PC1

PORTB

SERIAL RS-232 INTERFACE


C5 1uF J3 1 6 2 7 3 8 4 9 5 CANON9 GND GND GND GND

VCC C4 1uF

POWER JACK / SWITCH / REGULATOR / POWER LED


J1 GND VCC 1 3 2 DB1 Bridge1 SW1 POWER SW 1 2 3 J2 1 2 GND DC POWER GND GND GND GND GND GND GND C13 470uF C14 100nF 1 IO3 MC7805CT IN OUT GND 2 3 C15 100nF C16 10uF LED5 VCC R14 330

PORTC C7 1uF VCC C8 1uF SERIAL_TXD SERIAL_CTS SERIAL_RXD SERIAL_RTS PD6 PD4 PD2 PD0 P5 1 3 5 7 9 2 4 6 8 10 PD7 PD5 PD3 PD1

DC JACK

11 10

RS232_RXD RS232_RTS RS232_TXD RS232_CTS

RS232_RXD RS232_CTS RS232_TXD RS232_RTS

14 7 13 8 6 C6 1uF

T1OUT T2OUT

R1IN R1OUT R2IN R2OUT VEE MAX232 GND

PORTD

GND

PIEZO
C C

CONFIG HEADER
P1 PD0 SERIAL_RXD PC2 TERM3 PD2 1 3 5 7 9 2 4 6 8 10 PD1 SERIAL_TXD PC3 TERM4 PD3

ANALOG VOLTAGES

VCC R3 330 LS1

ISP (IN-SYSTEM PROGRAMMING)


IO6A 74VHC4066N R1110k Speaker J4 1 6 2 7 3 8 4 9 5 SUB D9 P6 D4 5V1 C17 220p D3 5V1 10 7 GND GND GND Title D2 5V1 R4 33K 3 7 R124k7 R134k7 9 7 T1 BC547 2 7 CNTL OUT/IN IN/OUT GND IO6B VDD 13 1 PC6 14 5 4 PB4 14 6 8 14 12 11 PB5 14 VCC GND GND RESET T2 BC557C R18 MISO R16 100 PB3 MOSI R17 10k SCK 10k VCC

JMP13 VCC R19 10k 3 2 1 GND

VCC L1 100nH AVCC PB1

JMP5

SW2 ISP SW

CONFIG HEADER JMP3 SERIAL_RTS JMP4 SERIAL_CTS PD7 GND PD6

C9 100nF

11 10

CNTL OUT/IN IN/OUT GND IO6C VDD

SCREW TERMINALS
VCC

CNTL OUT/IN IN/OUT GND IO6D VDD

VCC

C19 100nF

MOUNTING HOLES

2 1 MTH1 MNT2 MNT3 MNT4 D 1 1 1 1 R2 5k C10 100nF

AREF PC0 PC1 TERM3 TERM4

1 2 3 4 5 6 TERMINALS

CNTL OUT/IN IN/OUT GND VDD

GND GND

GND GND

Size A3 Date: File:

Number 30.3.2008 Sheet of G:\== Altium Designer ==\..\Mega48.SchDoc Drawn By: 7

Revision