AVR mega16/32 starter development board Users...

18
EasyMCU Series AVR mega16/32 Starter Development Board AVR mega16/32 starter development board Users Manual Version 1.0 All boards produced by SINTECH STUDIO Rev.A, Jully 2010 Copyright 2010, SINTECH STUDIO, All rights reserved 1

Transcript of AVR mega16/32 starter development board Users...

Page 1: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

AVR mega16/32 starter development board

Users Manual

Version 1.0

All boards produced by SINTECH STUDIO

Rev.A, Jully 2010

Copyright 2010, SINTECH STUDIO, All rights reserved

1

Page 2: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

CONTENT

1. GETTING STARTED ......................................................................................................................................4

2. DEVICES SUPPORTED ................................................................................................................................4

3. TOOLS REQUIREMENT ...............................................................................................................................4

4. POWER REQUIREMENT ..............................................................................................................................4

5. SOFTWARE REQUIREMENT ......................................................................................................................4

6. BOARD FEATURES .......................................................................................................................................4

7. ELECTROSTATIC WARNING.......................................................................................................................5

8. MEGA16/32 PROCESSOR FEATURES .....................................................................................................5

9. BOARD LAYOUT,JUMPERS, PORTS AND MAIN MODULES DESCRIPTION. ..............................5

10. MODULE CIRCUITS ....................................................................................................................................6

⑴POWER MODULE ............................................................................................................................................6 ⑵POWER INPUT/OUTPUT PORT .......................................................................................................................6 ⑶MEGA16/32 SMALL SYSTEM WITH ALL PINOUTS ...........................................................................................6 ⑷4X4 KEYBOARD MODULE...............................................................................................................................6 ⑸4X1 USER BUTTONS MODULE ........................................................................................................................7 ⑹LEDS MODULE...............................................................................................................................................7 ⑺8-BITS-7-SEG DISPLAY MODULE .................................................................................................................7 ⑻INT0 AND INT1 .............................................................................................................................................8 ⑼SYSTEM RESET CIRCUIT ...............................................................................................................................8 ⑽ADC0 INPUT ..................................................................................................................................................9 ⑾BUZZER MODULE ...........................................................................................................................................9 ⑿DS1302 MODULE............................................................................................................................................9 ⒀DS18B20 MODULE .......................................................................................................................................10 ⒁LED CONTROLLED BY PWM SIGNAL ........................................................................................................11 ⒂RS232 COMMUNICATION MODULE .............................................................................................................11 ⒃AT24CX(X=1,2….16) EEPROM MODULE...................................................................................................12 ⒄LCD1602 DISPLAY PORT.............................................................................................................................13 ⒅LCD12864 DISPLAY PORT...........................................................................................................................13 ⒆ISP PROGRAMMING PORT ...........................................................................................................................13 ⒇JTAG DEBUGGING PORT.............................................................................................................................14 (21)SI-PROGRAMMER INTEGRATED ON BOARD .............................................................................................14

11. FREQUENTLY ASKED QUESTIONS .....................................................................................................16

1).I TRIES TO POWER THE BOARD, BUT THE BOARD DOES NOT POWER UP, WHAT’S WRONG?.......................16 2) HOW IS POWER SUPPLIED TO THE EXPERIMENTER’S BOARD? ...................................................................16 3) WHAT DEVICES CAN BE PROGRAMMED WITH THE EXPERIMENTER’S BOARD? .........................................16 4) THE MEGA16/32 IS NO LONGER ACCESSIBLE VIA PROGRAMMER/DEBUGGER, IS SOMETHING WRONG WITH THE DEVICE? ..........................................................................................................................................16 5) I HAVE LOADED THE MEGA16/32 SAMPLE CODE, BUT IT DOESN’T SEEM TO BE WORKING, WHAT’S WRONG? ...........................................................................................................................................................16 6) I HAVE LOADED THE MEGA16/32 SAMPLE CODE, BUT IT SEEM TO BE WORKING VERY SLOWLY, WHAT’S WRONG? ...........................................................................................................................................................16

APPENDIX A. PACKING LIST .......................................................................................................................16

APPENDIX B. BOARD PCB.............................................................................................................................17

2

Page 3: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

APPENDIX C. BOARD SCHEMATIC ............................................................................................................18

APPENDIX D. CONTACT US..........................................................................................................................18

3

Page 4: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

1. Getting Started AVR mega16/32 Starter Development Board is an easy-to-use development and testing system for the new ATmega16/32 high-performance microcontroller, and is also a starter kit for learning AVR microcontroller hardware and software design. it has ISP and JTAG port for programming and debugging, RS232 communication, 8 status Leds, 4 user Buttons,4x4 keyboard,DS1302 circuit,DS18B20 circuit, buzzer circuit, EEPROM circuit, ADC input,8bits 7-SEG display control circuit,LCD1602,LCD12864,INT0&INT1 and all of the GPIOs are taken out to make them available for further connections. 2. Devices Supported AVR mega16/32 Starter Development Board is based on the ATMEL high-performance microcontrollers. Residing on this board is the mega16/32 microcontrollers. 3. Tools Requirement There is a serial programmer integrated on this board, which allows you to use directly to program the mega16/32 microcontrollers. But it requires a com port on your computer, it will not work with USB-RS232 converters. Certainly, this board also supports other AVR programmer/debuggers as follows: ⑴AVR ONE ⑵AVR ISP ⑶AVR ISP MKII ⑷AVR JTAGICE ⑸AVR JTAGICE MKII ⑹AVR DREGON ⑺AVR STK200 ⑻AVR STK500 ⑼AVR STK600 ⑽AVR USBASP … 4. Power Requirement ⑴USB power Cables

Figure4-1

⑵External 6—12VDC

Figure4-2

You can select one of them to power your board. If your programmer/debugger can power your board, it is no need to use USB power Cables or External 6—12VDC. 5. Software Requirement ⑴. AVR Studio + WinAVR free development IDE, AVRICC or other development IDE. ⑵. Programming software for loading. 6. Board Features - CPU: mega16/32 microcontroller ■ISP 5x2 pin connector for in-circuit programming with AVR Programmers . ■ JTAG 5x2 pin connector for in-circuit programming and Simulating. ■ 7805,LM1117 and filtering capacitors.Two kinds of power supply: 6V-12V external power supply and 5.0V USB power supply. ■SI-Programmer on Board. ■Quartz crystal oscillator circuit 1-16Mhz. ■Reset circuit. ■Status LED connected to I/O PB port via removable jumper. ■RS232 DB-9 female connector. ■MAX3232 circuit. ■4 User Buttons ■2 External Interrupts: INT0 and INT1 ■8bits 7-seg display ■74HC595 8 BIT SHIFT REGISTER for 7-seg display control

4

Page 5: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

■74HC138 3-to-8 line decoder/demultiplexer for 7-seg display control ■I2C eeprom 24CX(X=1,2,4…16) ■Programmable Resolution 1-Wire Digital Thermometer--DS18B20 ■Trickle Charge Timekeeping Chip --DS1302 ■Buzzer ■ADC0 Input Potentiometer ■LCD1602 interface ■LCD12864 interface ■PCB, 1.6 mm , blue solder mask, white silkscreen component print . ■Dimensions: 114mmx160mm 7. Electrostatic Warning AVR mega16/32 Starter Development Board is shipped in protective anti-static packaging. The board must not be subject to high electrostatic potentials. General practice for working with static sensitive devices should be applied when working with this board. 8. Mega16/32 Processor Features For detailed information of mega16/mega32 microcontroller, please refer to the datasheet named “Atmega16.pdf ” or “Atmega32.pdf ” included in the Product CD Rom. 9. Board layout,jumpers, ports and main modules description.

Figure9-1

Table1. Area Description Area Description 1 Power Input/Output 13 Buzzer Module 2 On-board SI-Programmer Port 14 DS1302 Module 3 System Power Supply 15 Eeprom 24CX Module 4 RS232 Communication Port 16 PWM 5 LCD1602 & LCD12864 Ports 17 8-BITs-7-seg Display Module 6 LCD12864 Contrast Potentiometer 18 8 LEDs 7 LCD1602 Contrast Potentiometer 19 Mega16 core with All Pinouts 8 System Clock (External Clock) 20 ADC Filter 9 ADC0 Potentiometers 21 System Reset Button

5

Page 6: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

10 DS18B20 Module 22 INT0 & INT1 Input Keys 11 ISP Programming Port 23 4*4 Keys 12 JTAG Debugging Port 24 4 User BUTTONS

10. Module Circuits ⑴Power Module AVR mega16/32 Starter Development Board can be powered by the USB port or external 6-12VDC power supply. It is necessary to note that the external power supply and the USB power can not be connected simultaneously. Power LED (red) with name POWERLED, and Power switch with name POWERSW.J1 jumper provides 5V/3.3V system power supply selection.

VCC

POWERLED

R15 1K

C6104

Vin1

GN

D2

+5V 37805D2GND 2

VCC 1

POWER

+C5

470u/25v

5 5

6 6

VCC 1

DATA- 2

DATA+ 3

GND 4

USB

-PO

WE

R

1 2 3

J1VCC

C7104

VIN3

GN

D1

VOUT 2LM1117-3.3V

POWERSW

3.3V5V

C10

104

+C9

470u/25v

C8

104

VCC

Figure10-1 Power Module

Before using this board please make sure that the J1 jumper is connected properly. ⑵Power Input/Output Port It allows you to easily power your DIY functional device/ module or to power this board using external 5V/3.3V via this Power Input/Output Port.

1 2 3 4

VCC

1 2 3 4

GND

VCC

Figure10-2 Power Input/Output Port ⑶Mega16/32 small system with all pinouts

AGND 31

X113

X212

RESET9

PD2 (INT0)16

PD3 (INT1)17

PD4 (OC1B)18

PD5 (OC1A)19

PB0 (T0)1

PB1 (T1)2

PB2 (AIN0)3

PB3 (AIN1)4

PB4 (SS)5

PB5 (MOSI)6

PB6 (MISO)7

PB7 (SCK)8

(ADC0) PA0 40

(ADC1) PA1 39

(ADC2) PA2 38

(ADC3) PA3 37

(ADC4) PA4 36

(ADC5) PA5 35

(ADC6) PA6 34

(ADC7) PA7 33

PC0 22

PC1 23

PC2 24

PC3 25

PC4 26

PC5 27

(TOSC1) PC6 28

(TOSC2) PC7 29PD7 (TOSC2)21 PD6 (ICP)20

AVCC 30

AREF 32

PD1 (TXD)15 PD0 (RXD)14

GN

D11

VC

C10

mega16/32

VCC

VCC

Y1

C222p

C122p

C29 104

C30 104

RESET

INT0INT1

RXDTXD

MOSIMISOSCK

JTAG-TCKJTAG-TMSJTAG-TDOJTAG-TDI

L1

PB0PB1PB2PB3PB4

PB5PB6PB7

PD0PD1PD2PD3PD4PD5PD6PD7

PA0PA1PA2PA3PA4PA5PA6PA7

123456789

1011121314151617181920

J2

1234567891011121314151617181920

J3PB0PB1PB2PB3PB4

PB5PB6PB7

RESET

X1X2

PD0PD1PD2PD3PD4PD5PD6

PC0PC1PC2PC3PC4PC5PC6PC7

PD7

PA0PA1PA2PA3PA4PA5PA6PA7AVCC

AVCC

AREF

PC0PC1PC2PC3PC4PC5PC6PC7

AVCC

AREF

VCC

AREF ADC FILTER

X1

X2

X1

X2

System Clock

Figure10-3 Mega16/32 small system with all pinouts

⑷4x4 Keyboard Module

6

Page 7: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

In this application, a 4x4 matrix keypad requiring eight Input/Output ports for interfacing is used. Rows are connected to PB4-PB7. Columns are connected to PB0-PB3.

Key1 Key2 Key3 Key4

Key5 Key6 Key7 Key8

Key9 Key10 Key11 Key12

Key13 Key14 Key15 Key16

PB0PB1PB2PB3PB4PB5PB6PB7

Figure10-4 4x4 Keyboard Module

⑸4x1 User Buttons Module AVR mega16/32 Starter Development Board has a total of eight user Buttons connected to PB4-PB7 of the Mega16/32 directly.

BUTTON1 BUTTON2 BUTTON3 BUTTON4

PB4 PB5 PB6 PB7

Figure10-5 4x1 User Buttons Module

⑹LEDs Module AVR mega16/32 Starter Development Board has a total of eight LEDs connected to PB0-PB7 of the Mega16/32 directly. The LEDs can be completely disconnected by using J4 jumper. When the user does not need to use the LEDs, the user should close the LEDs module via disconnecting J4 jumper to reduce the overall power consumption of the board.

VCC

LED1 LED2 LED3 LED4 LED5 LED6 LED7

PB0

PB1

PB2

PB3

PB4

PB5

PB6

PB7

LED8

R11K

R21K

R31K

R41K

R51K

R61K

R71K

R81K

12

J4

Figure10-6 LEDs Module

When using LEDs please make sure that the relational pin of J4 jumper is connected corectly. ⑺8-BITs-7-SEG Display Module In this application, 74HC595 and 74HC138 are used to control the 8-BITs-7-SEG display. The 74HC138 provides BIT signals and the 74HC595 provides Code signals.

7

Page 8: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

Figure10-7 8-BITs-7-SEG Display Module

When using 8-BITs-7-SEG Display Module please make sure that all the pins of JP4 jumper are connected. Note: For detailed information of 74HC595 and 74HC138, please refer to the datasheet named “74HC595.pdf ” and “74HC138.pdf ” included in the Product CD Rom. ⑻INT0 and INT1 In this application, two external interrupt push buttons, INT0 and INT1, are connected to the PD0 to PD1 of Mega16/32 via JP1 jumper. Please make sure that the relational pins of JP4 jumper are connected correctly when using INT0 or INT1 external interrupt sources.

VCC

VCC

R10 10KINT0

R11 10KINT1

11 2 2

33 4 4

JP1INT0INT1

Figure10-8 INT0 and INT1

⑼System Reset Circuit The RESET pin on the AVR is active LOW, and setting the pin LOW externally will thus result in a reset of the AVR. The RESET has two purposes: 1. To release all lines by tri-stating all pins (except XTAL pins), initialize all I/O registers and set program counter to zero. 2. To enter programming mode (for some parts also the PEN line is used to enter programming mode). Furthermore it is possible to enter high-voltage/parallel programming mode by drawing the RESET pin “very” high, where very high means 11.5 – 12.5V.

8

Page 9: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

VCC

R9

10K

C12

104

RESET

RESE

T

D1

Figure10-9 System Reset Circuit

⑽ADC0 Input In this application,ADC0 Input Potentiometer is connected to the PA0 Mega16/32 via JP5 jumper. Please make sure that the related pins of JP5 jumper is connected correctly when using ADC0 Input.

VCCP3

11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

1111 12 12

1313 14 14

1515 16 16

1717 18 18

JP5PA0

Figure10-10 ADC0 Input

⑾Buzzer Module In this application, buzzer drive circuit is connected to PA6 via JP5. Please make sure that the related pins of JP5 jumper are connected correctly when using Buzzer.

R35

1K

VCC

11 2 2Q9

BUZZER

33 4 4

55 6 6

77 8 8

99 10 10

1111 12 12

1313 14 14

1515 16 16

1717 18 18

JP5

PA6

Figure10-11 Buzzer Module

⑿DS1302 Module The DS1302 Trickle Charge Timekeeping Chip contains a real time clock/calendar and 31 bytes of static RAM. It communicates with a microprocessor via a simple serial interface. The real time clock/calendar provides seconds, minutes, hours, day, date, month, and year information. The end of the month date is automatically adjusted for months with less than 31 days, including corrections for leap year. The clock operates in either the 24–hour or 12–hour format with an AM/PM indicator. Interfacing the DS1302 with a microprocessor is simplified by using synchronous serial communication. Only three wires are required to communicate with the clock/RAM: (1) RST (Reset), (2) I/O (Data line), and (3) SCLK (Serial clock). Data can be transferred to and from the clock/RAM 1 byte at a time or in a burst of up to 31 bytes. The DS1302 is designed to operate on very low power and retain data and clock information on less than 1 microwatt.

9

Page 10: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

The DS1302 is the successor to the DS1202. In addition to the basic timekeeping functions of the DS1202, the DS1302 has the additional features of dual power pins for primary and back–up power supplies, programmable trickle charger for VCC1, and seven additional bytes of scratchpad memory.

Figure10-12. DS1302 pin assignment

Table2.DS1302 pin description Number Name Function 1 VCC2 Power Supply Pins 2 X1, 32.768 kHz Crystal Pins 3 X2 32.768 kHz Crystal Pins 4 GND Ground 5 RST Reset 6 I/O Data Input/Output 7 SCLK Serial Clock 8 VCC1 Power Supply Pins

In this application, the signal pin SCLK,IO,RST of DS1302 are separately connected to PC0,PC1,PC6 of mega16/32 via JP5,showed in Figure10-13.

VCCVCC21

X12

X23

GND4 RST 5

I/O 6

SLCK 7

VCC1 8

DS1302

11 2 2

32.768KY2

33 4 4

55 6 6

77 8 8

99 10 10

1111 12 12

1313 14 14

1515 16 16

1717 18 18

JP5

PC6

PC0PC1

Figure10-13 DS1302 Module

Please make sure that the related pins of JP5 jumper are connected correctly when using DS1302. Note: For detailed information of DS1302’s use, please refer to the datasheet named “DS1302.pdf ” included in the Product CD Rom. ⒀DS18B20 Module The DS18B20 Digital Thermometer provides 9 to 12-bit (configurable) temperature readings which indicate the temperature of the device. Information is sent to/from the DS18B20 over a 1-Wire interface, so that only one wire (and ground) needs to be connected from a central microprocessor to a DS18B20. Power for reading, writing, and performing temperature conversions can be derived from the data line itself with no need for an external power source. Because each DS18B20 contains a unique silicon serial number, multiple DS18B20s can exist on the same 1-Wire bus. This allows for placing temperature sensors in many different places. Applications where this feature is useful include HVAC environmental controls, sensing temperatures inside buildings, equipment or machinery, and process monitoring and control.

Figure10-14. DS18B20 pin assignment

10

Page 11: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

Table3. DS18B20 pin description Number Name Function 1 GND Ground 2 DQ Data In/Out 3 VDD Power Supply Voltage

VC

C3

GN

D1

DQ

2

DS18B20

R144.7K

VCC

VCC

11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

1111 12 12

1313 14 14

1515 16 16

1717 18 18

JP5

PC7

Figure10-15 DS18B20 Module

In this application, the signal pin DQ of DS18b20 is connected to PC7 of mega16/32 via JP5, showed in Figure10-15.Please make sure that the related pin of JP5 jumper is connected correctly when using DS18b20. Note: For detailed information of DS18B20’s use, please refer to the datasheet named “DS18B20.pdf ” included in the Product CD Rom. ⒁LED Controlled by PWM Signal In this application, LED circuit is connected to PB3 of mega16/32 via JP5, showed in Figure10-16. Please make sure that the related pin of JP5 jumper is connected correctly when using LED Controlled by PWM Signal.

VCC

11 2 2

PWMR12

1K

33 4 4

55 6 6

77 8 8

99 10 10

1111 12 12

1313 14 14

1515 16 16

1717 18 18

JP5

PB3

Figure10-16

⒂RS232 Communication Module The MAX3232 transceivers has a proprietary low-dropout transmitter output stage enabling true RS-232 performance from a 3.0V to 5.5V supply with a dual charge pump. The device requires only four small 0.1µF external chargepump capacitors. The MAX3232 is guaranteed to run at data rates of 120kbps while maintaining RS-232 output levels. The MAX3232 has 2 receivers and 2 drivers. The MAX3232 is pin, package, and functionally compatible with the industry-standard MAX242 and MAX232, respectively. The device feature a shutdown mode in which all receivers can remain active while using only 1µA supply current. The MAX3232 can be connected to MCU with RS232 communication port.

11

Page 12: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

VCCC16104

VCC16

C15104C17

104

C13 104

C14 104C1+ 1C1- 3C2+ 4C2- 5

T2in 10

T1in 11

V+2 V-6

T2out7

T1out14

R1in13 R2in8

R1out 12R2out 9GND 15U1

MAX3232

162738495

TXDRXD11

UA

RT P

ort

2 2

33 4 4

JP2

Figure10-17 RS232 Communication Module

In this application, the signal pin R1OUT, T1IN of max3232 are separately connected to RXD(PD0),TXD(PD1) of mega16/32 via JP2, showed in Figure10-17. Please make sure that the JP2 jumper is connected correctly when using RS232 Communication Module. Note: For detailed information of MAX3232’s use , please refer to the datasheet named “MAX3232.pdf ” included in the Product CD Rom. ⒃AT24CX(X=1,2….16) Eeprom Module The AT24C01A/02/04/08A/16A provides 1024/2048/4096/8192/16384 bits of serial electrically erasable and programmable read-only memory (EEPROM) organized as 128/256/512/1024/2048 words of 8 bits each. The device is optimized for use in many industrial and commercial applications where low-power and low-voltage operation are essential. The AT24C01A/02/04/08A/16A is available in space-saving 8-lead PDIP, 8-lead JEDEC SOIC, 8-lead MAP, 5-lead SOT23 (AT24C01A/AT24C02/AT24C04), 8-lead TSSOP, and 8-ball dBGA2 packages and is accessed via a Two-wire serial interface. In addition, the entire family is available in 2.7V (2.7V to 5.5V) and 1.8V (1.8V to 5.5V) versions.

Figure10-18. AT24CX(X=1,2….16) pin assignment

Table3. AT24CX(X=1,2….16) pin description Number Name Function 1-3 A0-A2 Address Inputs 4 GND Ground 5 SDA Serial Data 6 SCL Serial Clock Input 7 WP Write Protect 8 VCC Power Supply

In this application, the signal pin SCL, SDA of AT24CX are separately connected to PC0, PC1 of mega16/32 via JP5, showed in Figure10-19. Please make sure that the related pin of JP5 jumper are connected correctly when using AT24CX(X=1,2….16) Module. Note: For detailed information of 24CX’s use, please refer to the datasheet named “24C04.pdf ” included in the Product CD Rom.

12

Page 13: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

A01

A12

A23

GND4 VCC8

SDA 5SCL 6

WP 724CX

VCC

R29

R28

VCC11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

1111 12 12

1313 14 14

1515 16 16

1717 18 18

JP5

PC0PC1

Figure10-19 Eeprom Module

⒄LCD1602 Display Port 1

1

22

33

44

55

66

77

88

99

1010

1111

1212

1313

1414

1515

1616

LCD1602

VCCPD

0PD

1PD

2PD

3PD

4PD

5PD

6PD

7

PA5

PA6

PA7

VCC

P2

VCC

Figure10-20 LCD1602 Display Port

Note: For detailed information of LCD1602’s use, please refer to the datasheet named “LCD1602.pdf ” which is included in the Product CD Rom. ⒅LCD12864 Display Port

11

22

33

44

55

66

77

88

99

1010

1111

1212

1313

1414

1515

1616

1717

1818

1919

2020

LCD12864

VCC

VCC VCC

VCCR1310K

C111041

23

J6

VCC

PD0

PD1

PD2

PD3

PD4

PD5

PD6

PD7

PA5

PA6

PA7

P1

Figure10-21 LCD12864 Display Port

Note: For detailed information of LCD12864’s use, please refer to the datasheet named “LCD12864.pdf ” which is included in the Product CD Rom. ⒆ISP Programming Port

13

Page 14: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

VCC11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

ISP(New Version)MOSI

MISOSCKRESET

VCC11 2 2

33 4 4

55 6 6

77 8 8

MOSI

MISOSCKRESET

99 10 10

ISP(Old Version) Figure10-22 ISP Programming Port

⒇JTAG Debugging Port

VCC

R16 10KR17 10KR18 10K

R19 10K

C18

104

11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

JTAG(Old Version)

VCC

JTAG-TCK

JTAG-TMSJTAG-TDO

JTAG-TDI

VCC

VCC

1

11 2 2

2

J5

33 4 4

55 6 6

77 8 8

99 10 10

JTAG(New Version)

VCC

JTAG-TCK

JTAG-TMSJTAG-TDO

JTAG-TDIVCC

RESET

Figure10-23 JTAG Debugging Port

(21)SI-Programmer Integrated on Board SI-Programmer is an easy-to-use programmer integrated on this development board. It works with the AVRICC included in the Product CD Rom. It also supports the great free AVR programming software made by Claudio Lanconelli - the Pony Prog.

162738495

SI-PROG

11 2 2

33 4 4

55 6 6

77 8 8

JP3

MOSIMISO

SCKRESET

Progamming Control Circuit

Figure10-24

How to install and use(works with the AVRICC software): Step1.connects to PC via RS232 port (note it will not work with USB-RS232 converters!),the JP3 jumper keeps connecting. Step2.Power on the board via USB cable or external 6-12V power supply.

14

Page 15: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

Step3.Start AVRICC software, enter“In System Programmer”.

Figure10-25

Step4.Programmer Type and Com Port Settings.

Figure10-26

Step5. Select “Manual select”

Figure10-27

Step6. Load “.hex”file.

Figure10-28

15

Page 16: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

Step7.Click “Program FLASH/EEPROM” to Download “.hex”file to mega16/32 microcontroller.

Figure10-29

11. Frequently Asked Questions 1).I tries to power the board, but the board does not power up, what’s wrong? Make sure that the POWER LED has turned on. If the LED is not on, check to see that the external power supply(DC6-12V) or the USB power is properly connected, check to see that the J1 is properly connected .It is necessary to note that the external power supply(DC6-12V) and the USB power can not be connected simultaneously. 2) How is power supplied to the experimenter’s board? Three supply options exist: USB power Cables, external 6—12VDC and programmer/debugger power supplies are supported. You are only allowed to choose one of them. 3) What devices can be programmed with the experimenter’s board? AVR mega16/32 Starter Development Board is designed to develop applications using the Mega16/32. The device can be replaced by Mega16L/32L/16A/16A/ 8535 device derivatives, respectively. 4) The Mega16/32 is no longer accessible via programmer/debugger, is something wrong with the device? - Verify that the target device is powered properly. - If the target is powered locally, verify your programmer/debugger is connected properly. - If the programmer/debugger is connected properly, the Mega16/32 is possibly "dead". Well, it's not really dead, it's just that it can't be reprogrammed until the Mega16/32 is unlocked (for detailed method of unlocking an AVR device, please search for solution on the internet). 5) I have loaded the Mega16/32 sample code, but It doesn’t seem to be working, what’s wrong? -Try to disconnect the SI-Programmer cable or JP3,in case of some IOs occupied. - Make sure the relational jumper is correctly connected. - If the relational jumper is correctly connected, pls check whether the FUSE BITS had been changed. Note: For detailed information of FUSE BITS settings, please refer to the datasheet named “mega16.pdf ” or “mega32.pdf ” which is included in the Product CD Rom. 6) I have loaded the Mega16/32 sample code, but It seem to be working very slowly, what’s wrong? Make sure the system clock had been changed .The AVR mega16/32 Starter Development Board has a default system--internal RC 8MHz system clock, and the sample codes in product CD-ROM is based on this default system clock. If the system clock had been changed to lower one like 1MHz, the board will work slowly.

Appendix A. Packing List When you receive the products, please check the box to see if all accessories are complete. This product should include the following components: AVR mega16/32 Starter Development Board, 1 pcs; USB power supply cable, 1 pcs; CD-ROM or DVD-ROM, 1 pcs;

16

Page 17: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

Appendix B. Board PCB

17

Page 18: AVR mega16/32 starter development board Users …digsys.upc.es/.../AVR-mega16-32-Starter-Development-Board.pdfAVR mega16/32 Starter Development Board is an easy-to-use development

EasyMCU Series AVR mega16/32 Starter Development Board

18

Appendix C. Board Schematic

1 2 3 4 5 6 7 8

A

B

C

D

87654321

D

C

B

A

Title

Number RevisionSize

A3

Date: 23-Oct-2011 Sheet of File: K:\AVR-51-20110829.Ddb Drawn By:

AGND 31

X113

X212

RESET9

PD2 (INT0)16

PD3 (INT1)17

PD4 (OC1B)18

PD5 (OC1A)19

PB0 (T0)1

PB1 (T1)2

PB2 (AIN0)3

PB3 (AIN1)4

PB4 (SS)5

PB5 (MOSI)6

PB6 (MISO)7

PB7 (SCK)8

(ADC0) PA0 40

(ADC1) PA1 39

(ADC2) PA2 38

(ADC3) PA3 37

(ADC4) PA4 36

(ADC5) PA5 35

(ADC6) PA6 34

(ADC7) PA7 33

PC0 22

PC1 23

PC2 24

PC3 25

PC4 26

PC5 27

(TOSC1) PC6 28

(TOSC2) PC7 29PD7 (TOSC2)21 PD6 (ICP)20

AVCC 30

AREF 32

PD1 (TXD)15 PD0 (RXD)14G

ND

11V

CC

10

mega16/32

VCC

1 1

2 2

3 3

4 4

5 5

6 6

7 7

8 8

9 9

10 10

11 11

12 12

13 13

14 14

15 15

16 16

17 17

18 18

19 19

20 20

LCD12864

1 1

2 2

3 3

4 4

5 5

6 6

7 7

8 8

9 9

10 10

11 11

12 12

13 13

14 14

15 15

16 16

LCD1602

VCC

VCC

VCCVCCVCC

VCC

VCC

VCC

VCC

VCC

VCC

VCC

VCC

VCC

LED1 LED2 LED3 LED4 LED5 LED6 LED7 LED8

POWERLED

R11K

R21K

R31K

R41K

R51K

R61K

R71K

R81K

R910K

R1010K

R1110K

R13 10KR15 1K

R16 10KR17 10KR18 10K

R19 10K

Y1

C222p

C122p

C12104

C11 104C16104

C15104C17

104

C13 104

C14 104

C18

104

C6104

C29 104

C30 104

RESET

RESET

Key1 Key2 Key3 Key4

Key5 Key6 Key7 Key8

Key9 Key10 Key11 Key12

Key13 Key14 Key15 Key16

INT0INT1

D1

RESET

11

22

33

44

JP1

INT0INT1

INT0

INT1

1 2 3 J6

C1+ 1C1- 3C2+ 4C2- 5

T2in 10

T1in 11

V+2 V-6

VCC16

T2out7

T1out14

R1in13 R2in8

R1out 12R2out 9GND 15U1

MAX3232

162738495

RXDTXD

TXDRXD

Vin1

GN

D2

+5V 37805D2GND 2

VCC 1

POWER

+C5

470u/25v

VCC 3

GND 1

DQ 2

DS1

8B20 R14

4.7K

R2710K

R2610K

R2510K

R2410K

R2310K

R2210K

R2110K

11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

ISP(New Version)

11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

JTAG(Old Version)

MOSI

MOSI

MISO

MISO

SCK

SCKRESET

VCC

VCC

VCC

VCC

VCC

JTAG-TCK

JTAG-TCK

JTAG-TMS

JTAG-TMS

JTAG-TDO

JTAG-TDO

JTAG-TDI

JTAG-TDI

P3

5 5

6 6

VCC 1

DATA- 2

DATA+ 3

GND 4

USB

-PO

WER

A1

B2

C3

G1

6

G2A

4

G2B

5

GN

D8

Y7

7Y

69

Y5

10Y

411

Y3

12Y

213

Y1

14Y

015

VC

C16

74LS138

DS0

DS1

DS2

DS3

DS4

DS5

DS6

DS7

E2

C3

B1Q8 Q7 Q6 Q5 Q4 Q3 Q2 Q1

VCC

VCCVCCVCC VCCVCCVCCVCC VCC

VCC

R2010K

ISP

Prog

ram

min

g Po

rt

JTAG Debugging/Programming Port

LCD12864 PORT

QB

1

QC

2

QD

3

QE

4

QF

5

QG

6

QH

7

GN

D8

QH

'9

SRC

LK10

SRC

LK11

RC

LK12

OE

13

SER

14

QA

15

VC

C16

74H

C59

5

DS0DS1DS2DS3DS4DS5DS6DS7

VCC

L1

1 2 3

J1VCC

A01

A12

A23

GND4 VCC8

SDA 5SCL 6

WP 724CX

VCC

R29

R28

VCC

1 2 3 4

VCC

1 2 3 4

GNDVCC

PB0PB1PB2PB3PB4

PB5PB6PB7

PB0PB1PB2PB3PB4PB5PB6PB7

PD0PD1PD2PD3PD4PD5PD6PD7

PD0PD1PD2PD3PD4PD5PD6PD7

PD0PD1PD2PD3PD4PD5PD6PD7

PA0PA1PA2PA3PA4PA5PA6PA7

PA5PA6PA7PA5

PA6PA7

ADC0

P1

UA

RT

Port

SI-Programmer Port

162738495

SI-PROG

R30 4.7k

R31 4.7k

R34 4.7k

R33

10k

R3210k

D35.1v

D45.1v

B1

C2

E3

Q10

VCC

11 2 2

33 4 4

55 6 6

77 8

JP3

8 MOSIMISO

SCKRESET

AA

AA

BB

BBCC

CCDD

DD

VCC

P2

VCC

11 2 2

33 4 4

JP2

SEG

0

SEG

1

SEG

2

SEG

3

A B C D E F G DP

SEG2

SEG

0

SEG

1

SEG

2

SEG

3

A B C D E F G DP

SEG1

123456789

1011121314151617181920

J2

1234567891011121314151617181920

J3PB0PB1PB2PB3PB4

PB5PB6PB7

RESET

X1X2

PD0PD1PD2PD3PD4PD5PD6

PC0PC1PC2PC3PC4PC5PC6PC7

PD7

PA0PA1PA2PA3PA4PA5PA6PA7AVCC

AVCC

AREF

PC0PC1PC2PC3PC4PC5PC6PC7

AVCC

AREF

VCC

VCC

VCC

VCC

AREF ADC FILTER

X1

X2

PB0

PB1

PB2

PB3

PB4

PB5

PB6

PB7

12

J4

12

J5

BUTTON1 BUTTON2 BUTTON3 BUTTON4

PB4 PB5 PB6 PB7

VCCVCC21

X12

X23

GND4 RST 5

I/O 6

SLCK 7

VCC1 8

DS1302

32.768K

PWMR12

1K

11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

1111 12 12

1313 14 14

1515 16 16

1717 18 18

JP5

PB3

PA0

PA6

PC7

PC6

PC0PC1

PC0PC1

ADC0DS18B20-DQ

DS18B20-DQ

PWM

PWMBUZZERDS1302-SCLK

DS1302-SCLK

DS1302-IO

DS1302-IO

DS1302-RST

DS1302-RST

24CX-SCL

24CX-SCL 24CX-SDA

R35

1K

VCC

Q9

BUZZER

Y2

24CX-SDA

C7104

VIN3

GN

D1

VOUT 2LM1117-3.3V

POWERSW

C10

104

+C9

470u/25v

C8

104

VCC

3.3V5V

LCD1602 PORT SYSTEM POWER

4X4 KEY BOARD

4X1 USER BUTTONS

DS1302 Real-time Clock/Calendar Module

ADC0 Input

EEPROM 24CX(X=1,2...16) Module

DS18B20 Digital Thermometer Module

LED Controlled by PWM Signal BUZZER Module

Jumper

Power Input/Output External Interrupt System Reset

LEDS

8 Bits 7-SEG control circuit

RS232 Communication Module

Mega16/32 Core with All Pinouts

BUZZER

X1

X2

System Clock

11

22

33

44

55

66

77

88

99

1010

1111

1212

1313

1414

JP4

PA1

PA2

PA3

PA4

PA5

PA6

PA7

138A

138A

138B

138B

138C

RC

LK

RC

LK

SRC

LK

SRC

LK

SER

SER

138G

1

138G

2

138C

11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

JTAG(New Version)

VCC

JTAG-TCK

JTAG-TMSJTAG-TDO

JTAG-TDIVCC

VCC11 2 2

33 4 4

55 6 6

77 8 8

99 10 10

ISP(Old Version)

MOSI

MISOSCKRESET

RESET

Appendix D. Contact Us

e-mail:[email protected] QQ: 634503119