altos: use %lu for APRS altitude in sprintf
[fw/altos] / src / telemini-v2.0 / ao_telemini.c
index b85ce8c8bf381818da224cf91713baa2174c8b12..a9ee423c9db11edcf087bc99bec187b7bb1e761e 100644 (file)
@@ -3,7 +3,8 @@
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
  *
  * This program is distributed in the hope that it will be useful, but
  * WITHOUT ANY WARRANTY; without even the implied warranty of
 
 #include "ao.h"
 #include "ao_pins.h"
-
-__xdata uint8_t ao_force_freq;
+#include <ao_exti.h>
 
 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_storage_init();
-       ao_exti_init();
-       ao_spi_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();
 }