diff options
author | Keith Packard <keithp@keithp.com> | 2013-09-15 14:29:09 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2013-09-15 14:29:09 -0700 |
commit | 1fa3ff9ba6d04303b3de6952675532492c85182f (patch) | |
tree | f2cad264857f609bf6bcbc88f32f06d6e707b159 /src | |
parent | 0ff5f0fbc4900ad45bb7910ffc0c5a4e4cc4b857 (diff) |
altos/telemini-v2.0: Change initialization order
Make sure busses are running before devices are initialized
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/telemini-v2.0/ao_telemini.c | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/src/telemini-v2.0/ao_telemini.c b/src/telemini-v2.0/ao_telemini.c index 294f768a..0d8dd1cb 100644 --- a/src/telemini-v2.0/ao_telemini.c +++ b/src/telemini-v2.0/ao_telemini.c @@ -24,36 +24,42 @@ __xdata uint8_t ao_force_freq; void main(void) { - /* - * Reduce the transient on the ignite pins at startup by - * pulling the pins low as soon as possible at power up - */ - ao_ignite_set_pins(); - ao_clock_init(); +#if HAS_STACK_GUARD + ao_mpu_init(); +#endif + ao_task_init(); + /* Turn on the red LED until the system is stable */ ao_led_init(LEDS_AVAILABLE); ao_led_on(AO_LED_RED); - ao_task_init(); - ao_timer_init(); + + ao_spi_init(); + ao_exti_init(); ao_adc_init(); +#if HAS_BEEP ao_beep_init(); +#endif ao_cmd_init(); - ao_spi_init(); - ao_exti_init(); +#if HAS_MS5607 ao_ms5607_init(); +#endif ao_storage_init(); + ao_flight_init(); ao_log_init(); ao_report_init(); + ao_usb_init(); ao_telemetry_init(); ao_radio_init(); ao_packet_slave_init(TRUE); + ao_igniter_init(); + ao_config_init(); ao_start_scheduler(); } |