#define KDBG_WRITE_CHAR(c) _kdebug_bitbang_putchar((c))
#define KDBG_MASK_IRQ(old) do { IRQ_SAVE_DISABLE((old)); } while(0)
#define KDBG_RESTORE_IRQ(old) do { IRQ_RESTORE((old)); } while(0)
#define KDBG_WRITE_CHAR(c) _kdebug_bitbang_putchar((c))
#define KDBG_MASK_IRQ(old) do { IRQ_SAVE_DISABLE((old)); } while(0)
#define KDBG_RESTORE_IRQ(old) do { IRQ_RESTORE((old)); } while(0)
/* Compute the baud rate */
uint16_t period = DIV_ROUND(CLOCK_FREQ / 16UL, CONFIG_KDEBUG_BAUDRATE) - 1;
/* Compute the baud rate */
uint16_t period = DIV_ROUND(CLOCK_FREQ / 16UL, CONFIG_KDEBUG_BAUDRATE) - 1;
#if CONFIG_KDEBUG_PORT == 0
UBRR0H = (uint8_t)(period>>8);
UBRR0L = (uint8_t)period;
#if CONFIG_KDEBUG_PORT == 0
UBRR0H = (uint8_t)(period>>8);
UBRR0L = (uint8_t)period;