projects
/
bertos.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add support for more i2c devices.
[bertos.git]
/
bertos
/
cpu
/
avr
/
drv
/
kdebug_avr.c
diff --git
a/bertos/cpu/avr/drv/kdebug_avr.c
b/bertos/cpu/avr/drv/kdebug_avr.c
index 4cdaf94e8bcab4da6641ef2fc3b1f5d4a7ac4fe3..81e78530b30ead1ed66f766447ef75d31959abf6 100644
(file)
--- a/
bertos/cpu/avr/drv/kdebug_avr.c
+++ b/
bertos/cpu/avr/drv/kdebug_avr.c
@@
-33,7
+33,6
@@
*
* \brief AVR debug support (implementation).
*
*
* \brief AVR debug support (implementation).
*
- * \version $Id$
* \author Bernie Innocenti <bernie@codewiz.org>
* \author Stefano Fedrigo <aleph@develer.com>
* \author Francesco Sacchi <batt@develer.com>
* \author Bernie Innocenti <bernie@codewiz.org>
* \author Stefano Fedrigo <aleph@develer.com>
* \author Francesco Sacchi <batt@develer.com>
@@
-246,16
+245,29
@@
INLINE void kdbg_hw_init(void)
#endif
#elif CPU_AVR_ATMEGA168 || CPU_AVR_ATMEGA328P
#endif
#elif CPU_AVR_ATMEGA168 || CPU_AVR_ATMEGA328P
- UBRR0H = (uint8_t)(period>>8);
- UBRR0L = (uint8_t)period;
- KDBG_UART0_BUS_INIT;
+ #if CONFIG_KDEBUG_PORT == 0
+ UBRR0H = (uint8_t)(period>>8);
+ UBRR0L = (uint8_t)period;
+ KDBG_UART0_BUS_INIT;
+ #else
+ #error Only CONFIG_KDEBUG_PORT 0 is supported for this cpu
+ #endif
+
#elif CPU_AVR_ATMEGA8 || CPU_AVR_ATMEGA32
#elif CPU_AVR_ATMEGA8 || CPU_AVR_ATMEGA32
- UBRRH = (uint8_t)(period>>8);
- UBRRL = (uint8_t)period;
- KDBG_UART0_BUS_INIT;
+ #if CONFIG_KDEBUG_PORT == 0
+ UBRRH = (uint8_t)(period>>8);
+ UBRRL = (uint8_t)period;
+ KDBG_UART0_BUS_INIT;
+ #else
+ #error Only CONFIG_KDEBUG_PORT 0 is supported for this cpu
+ #endif
#elif CPU_AVR_ATMEGA103
#elif CPU_AVR_ATMEGA103
- UBRR = (uint8_t)period;
- KDBG_UART0_BUS_INIT;
+ #if CONFIG_KDEBUG_PORT == 0
+ UBRR = (uint8_t)period;
+ KDBG_UART0_BUS_INIT;
+ #else
+ #error Only CONFIG_KDEBUG_PORT 0 is supported for this cpu
+ #endif
#else
#error Unknown CPU
#endif
#else
#error Unknown CPU
#endif