Fix trying to use serial before it's intiialized

This commit is contained in:
VintagePC 2022-07-01 08:37:32 -04:00 committed by D.R.racer
parent ace5130d9f
commit 8eb054e789
1 changed files with 6 additions and 4 deletions

View File

@ -1044,10 +1044,6 @@ void setup()
{
timer2_init(); // enables functional millis
if (eeprom_read_byte((uint8_t *)EEPROM_MMU_ENABLED))
{
MMU2::mmu2.Start();
}
ultralcd_init();
@ -1063,6 +1059,12 @@ void setup()
fdev_setup_stream(uartout, uart_putchar, NULL, _FDEV_SETUP_WRITE); //setup uart out stream
stdout = uartout;
if (eeprom_read_byte((uint8_t *)EEPROM_MMU_ENABLED))
{
MMU2::mmu2.Start();
}
#ifdef XFLASH
bool xflash_success = xflash_init();
uint8_t optiboot_status = 1;