altos: Remove 8051 address space specifiers
[fw/altos] / src / kernel / ao_log_telem.c
index 095aca371d0227b0851a143b8e567ef4a6e6a261..8c0b88e47441e0a30cd1264f429bf51be7a84d5f 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_flight.h>
 #include <ao_sample.h>
 
-__code uint8_t ao_log_format = AO_LOG_FORMAT_TELEMETRY;
+const uint8_t ao_log_format = AO_LOG_FORMAT_TELEMETRY;
 
-static __data uint8_t                  ao_log_monitor_pos;
-__pdata enum ao_flight_state           ao_flight_state;
-__xdata int16_t                                ao_max_height;  /* max of ao_height */
-__pdata int16_t                                sense_d, sense_m;
-__pdata uint8_t                                ao_igniter_present;
+static uint8_t                 ao_log_monitor_pos;
+enum ao_flight_state           ao_flight_state;
+int16_t                                ao_max_height;  /* max of ao_height */
+int16_t                                sense_d, sense_m;
+uint8_t                                ao_igniter_present;
 
 static void
 ao_log_telem_track() {
@@ -49,7 +50,7 @@ ao_log_telem_track() {
                                ao_flight_state = ao_log_single_write_data.telemetry.sensor.state;
                                if (ao_flight_state == ao_flight_pad)
                                        ao_max_height = 0;
-                               ao_wakeup(DATA_TO_XDATA(&ao_flight_state));
+                               ao_wakeup(&ao_flight_state);
                        }
                }
        }
@@ -110,7 +111,7 @@ ao_log_single(void)
                                ao_log_telem_track();
                        }
                        /* Wait for more telemetry data to arrive */
-                       ao_sleep(DATA_TO_XDATA(&ao_monitor_head));
+                       ao_sleep(&ao_monitor_head);
                }
        }
 }