summaryrefslogtreecommitdiff
path: root/src/ao.h
diff options
context:
space:
mode:
authorBdale Garbee <bdale@gag.com>2011-01-17 09:50:17 -0700
committerBdale Garbee <bdale@gag.com>2011-01-17 09:50:17 -0700
commitda42f406e88ccc821cd45d5a94d5afec65ec50e9 (patch)
tree53482327b8f5d49d052c42943510b4524b6a9d21 /src/ao.h
parentea4cdfb87e03ecfb974f98305671265b6fb95372 (diff)
parentcf550f9b96fa94d8db559e01df0e265bb1c7b572 (diff)
Merge branch 'master' of ssh://git.gag.com/scm/git/fw/altos
Diffstat (limited to 'src/ao.h')
-rw-r--r--src/ao.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/ao.h b/src/ao.h
index 5721c344..cef20e61 100644
--- a/src/ao.h
+++ b/src/ao.h
@@ -163,6 +163,11 @@ struct ao_adc {
#endif
#if HAS_ADC
+
+#ifndef HAS_ACCEL_REF
+#error Please define HAS_ACCEL_REF
+#endif
+
/*
* ao_adc.c
*/
@@ -178,6 +183,9 @@ struct ao_adc {
*/
extern volatile __xdata struct ao_adc ao_adc_ring[AO_ADC_RING];
extern volatile __data uint8_t ao_adc_head;
+#if HAS_ACCEL_REF
+extern volatile __xdata uint16_t ao_accel_ref[AO_ADC_RING];
+#endif
/* Trigger a conversion sequence (called from the timer interrupt) */
void
@@ -649,7 +657,7 @@ enum ao_flight_state {
ao_flight_invalid = 9
};
-extern __xdata struct ao_adc ao_flight_data;
+extern __data uint8_t ao_flight_adc;
extern __pdata enum ao_flight_state ao_flight_state;
extern __pdata uint16_t ao_flight_tick;
extern __pdata int16_t ao_flight_accel;