ini
[aversive.git] / projects / microb2009 / tests / bootloader / uart_config.h
1 /*  \r
2  *  Copyright Droids Corporation, Microb Technology, Eirbot (2005)\r
3  * \r
4  *  This program is free software; you can redistribute it and/or modify\r
5  *  it under the terms of the GNU General Public License as published by\r
6  *  the Free Software Foundation; either version 2 of the License, or\r
7  *  (at your option) any later version.\r
8  *\r
9  *  This program is distributed in the hope that it will be useful,\r
10  *  but WITHOUT ANY WARRANTY; without even the implied warranty of\r
11  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
12  *  GNU General Public License for more details.\r
13  *\r
14  *  You should have received a copy of the GNU General Public License\r
15  *  along with this program; if not, write to the Free Software\r
16  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA\r
17  *\r
18  *  Revision : $Id: uart_config.h,v 1.2 2009-02-20 21:10:01 zer0 Exp $\r
19  *\r
20  */\r
21 \r
22 /* Droids-corp 2004 - Zer0\r
23  * config for uart module\r
24  */\r
25 \r
26 #ifndef UART_CONFIG_H\r
27 #define UART_CONFIG_H\r
28 \r
29 #if defined __AVR_ATmega128__\r
30 \r
31 /* compile uart0 fonctions, undefine it to pass compilation */\r
32 #define UART0_COMPILE  \r
33 \r
34 /* enable uart0 if == 1, disable if == 0 */\r
35 #define UART0_ENABLED  1\r
36 \r
37 /* enable uart0 interrupts if == 1, disable if == 0 */\r
38 #define UART0_INTERRUPT_ENABLED  1\r
39 \r
40 #define UART0_BAUDRATE 57600\r
41 \r
42 #define UART0_USE_DOUBLE_SPEED 0\r
43 \r
44 #define UART0_RX_FIFO_SIZE 64\r
45 #define UART0_TX_FIFO_SIZE 16\r
46 \r
47 #define UART0_NBITS 8\r
48 #define UART0_PARITY UART_PARTITY_NONE\r
49 #define UART0_STOP_BIT UART_STOP_BITS_1\r
50 \r
51 #elif defined __AVR_ATmega2560__\r
52 \r
53 /* compile uart3 fonctions, undefine it to pass compilation */\r
54 #define UART3_COMPILE  \r
55 \r
56 /* enable uart3 if == 1, disable if == 0 */\r
57 #define UART3_ENABLED  1\r
58 \r
59 /* enable uart3 interrupts if == 1, disable if == 0 */\r
60 #define UART3_INTERRUPT_ENABLED  1\r
61 \r
62 #define UART3_BAUDRATE 57600\r
63 \r
64 #define UART3_USE_DOUBLE_SPEED 0\r
65 \r
66 #define UART3_RX_FIFO_SIZE 64\r
67 #define UART3_TX_FIFO_SIZE 16\r
68 \r
69 #define UART3_NBITS 8\r
70 #define UART3_PARITY UART_PARTITY_NONE\r
71 #define UART3_STOP_BIT UART_STOP_BITS_1\r
72 \r
73 #endif /* avr type */\r
74 \r
75 #endif\r
76 \r