aboutsummaryrefslogtreecommitdiff
path: root/spaghetti-monster/fsm-adc.h
diff options
context:
space:
mode:
authorSelene ToyKeeper2019-11-14 01:56:29 -0700
committerSelene ToyKeeper2019-11-14 01:56:29 -0700
commitd4a899d99a366c09f5e38eb9ef71e538e4def2c1 (patch)
treef3bffcbb1677120f27c1d0b641d86db7fd3c0b23 /spaghetti-monster/fsm-adc.h
parentrefactored how interrupts work... (diff)
downloadanduril-d4a899d99a366c09f5e38eb9ef71e538e4def2c1.tar.gz
anduril-d4a899d99a366c09f5e38eb9ef71e538e4def2c1.tar.bz2
anduril-d4a899d99a366c09f5e38eb9ef71e538e4def2c1.zip
started refactoring ADC code to split voltage and temperature into their own functions
Diffstat (limited to 'spaghetti-monster/fsm-adc.h')
-rw-r--r--spaghetti-monster/fsm-adc.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/spaghetti-monster/fsm-adc.h b/spaghetti-monster/fsm-adc.h
index acb3da6..5f4d0c8 100644
--- a/spaghetti-monster/fsm-adc.h
+++ b/spaghetti-monster/fsm-adc.h
@@ -44,6 +44,7 @@ uint16_t adc_value; // last ADC measurement
uint8_t adcint_enable = 0; // is the current ADC result needed?
void ADC_inner(); // do the actual ADC-related calculations
+static inline void ADC_voltage_handler();
volatile uint8_t voltage = 0;
void low_voltage();
@@ -56,7 +57,7 @@ void battcheck();
#define USE_BLINK_DIGIT
#endif
#endif
-#endif
+#endif // ifdef USE_LVP
#ifdef USE_THERMAL_REGULATION
@@ -85,7 +86,8 @@ int8_t therm_cal_offset = 0;
//void low_temperature();
//void high_temperature();
volatile uint8_t reset_thermal_history = 1;
-#endif
+static inline void ADC_temperature_handler();
+#endif // ifdef USE_THERMAL_REGULATION
inline void ADC_on();