summaryrefslogtreecommitdiff
path: root/avr/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'avr/main.c')
-rw-r--r--avr/main.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/avr/main.c b/avr/main.c
index fb4e35c..dc7a6ef 100644
--- a/avr/main.c
+++ b/avr/main.c
@@ -203,10 +203,12 @@ int main(void)
setup_avr();
z80_setup_bus();
+ env_init();
+
if (reset_reason_is_power_on())
- _delay_ms(CONFIG_POWRON_DELAY);
+ _delay_ms(CONFIG_PWRON_DELAY);
- serial_setup();
+ serial_setup(getenv_ulong("baudrate", 10, CONFIG_BAUDRATE));
sei();
#if DEBUG
@@ -214,8 +216,6 @@ int main(void)
print_reset_reason();
#endif
- env_init();
-
#if DEBUG
unsigned long i_speed = getenv_ulong("i2c_clock", 10, CONFIG_SYS_I2C_CLOCK);
debug("### Setting I2C clock Frequency to %lu Hz.\n", i_speed);