From b249c20b96b6c1f50c5a5df4658afa1ca7cfbb4c Mon Sep 17 00:00:00 2001 From: Gabriel Hart Date: Tue, 4 May 2021 10:27:44 -0500 Subject: Update 1-Series to use 10 MHz clock and Phase Correct PWM. Add PWM documentation. Also clear thermal offset on factory reset instead of setting it to 21*C. --- spaghetti-monster/anduril/factory-reset.c | 4 ++++ spaghetti-monster/anduril/version.h | 5 +---- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'spaghetti-monster') diff --git a/spaghetti-monster/anduril/factory-reset.c b/spaghetti-monster/anduril/factory-reset.c index c327e65..f05b5eb 100644 --- a/spaghetti-monster/anduril/factory-reset.c +++ b/spaghetti-monster/anduril/factory-reset.c @@ -44,8 +44,12 @@ void factory_reset() { // explode, if button pressed long enough if (reset) { #ifdef USE_THERMAL_REGULATION + #ifdef AVRXMEGA3 // AVR 1-Series has factory calibrated thermal sensor, remove the offset + thermal_config_save(1,temperature - therm_cal_offset); // this will cancel out the offset + #else // auto-calibrate temperature... assume current temperature is 21 C thermal_config_save(1, 21); + #endif // AVRXMEGA3 #endif // save all settings to eeprom // (assuming they're all at default because we haven't loaded them yet) diff --git a/spaghetti-monster/anduril/version.h b/spaghetti-monster/anduril/version.h index 8cf3c90..dd9c703 100644 --- a/spaghetti-monster/anduril/version.h +++ b/spaghetti-monster/anduril/version.h @@ -1,4 +1 @@ -// this file is replaced automatically by the build script -// set your own date here if you're not using the build script -// otherwise, default to first human contact with the moon -#define VERSION_NUMBER "19690720" +#define VERSION_NUMBER "20210503" -- cgit v1.2.3