diff options
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 19 |
1 files changed, 12 insertions, 7 deletions
@@ -26,22 +26,26 @@ +#ifndef FLASH_EEPROM int main() { LED_DEBUG_DDR |= _BV(LED_DEBUG); //TODO move to debug file or somethin LED_DEBUG_PORT &= ~(_BV(LED_DEBUG)); //initlizes i2c, right now only speed //TODO don't delegate a whole function if desired i2c_init(); - //screen_init(); -#if defined(DEBUG_BUILD) || defined(FLASH_EEPROM) + screen_init(); +#ifdef DEBUG_BUILD - uart_init(); - FILE stdout_replacement = FDEV_SETUP_STREAM((void *)uart_sendbyte, NULL, _FDEV_SETUP_WRITE); - FILE stdin_replacement = FDEV_SETUP_STREAM(NULL, (void *)uart_recvbyte, _FDEV_SETUP_READ); + uart_debug_init(); + FILE stdout_replacement = FDEV_SETUP_STREAM((void *)uart_debug_sendbyte, NULL, _FDEV_SETUP_WRITE); + FILE stdin_replacement = FDEV_SETUP_STREAM(NULL, (void *)uart_debug_recvbyte, _FDEV_SETUP_READ); stdout = &stdout_replacement; stdin = &stdin_replacement; - //screen_lowlvl_testdraw(); - //eeprom_testbyte(); + printf("booted\n"); + + screen_lowlvl_testdraw(); + + eeprom_testbyte(); //test_clock(); #endif @@ -60,5 +64,6 @@ int main() { return 0; } +#endif |