aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--spaghetti-monster/anduril/factory-reset.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/spaghetti-monster/anduril/factory-reset.c b/spaghetti-monster/anduril/factory-reset.c
index 1e9714a..f9fb472 100644
--- a/spaghetti-monster/anduril/factory-reset.c
+++ b/spaghetti-monster/anduril/factory-reset.c
@@ -33,6 +33,11 @@ void factory_reset() {
}
// explode, if button pressed long enough
if (reset) {
+ #if defined(FACTORY_RESET_WARN_CHANNEL) && defined(DEFAULT_CHANNEL_MODE)
+ // return to default channel before saving
+ set_channel_mode(DEFAULT_CHANNEL_MODE);
+ #endif
+
// auto-calibrate temperature
// AVR 1-Series has factory calibrated thermal sensor, always remove the offset on reset
#if defined(USE_THERMAL_REGULATION) && defined(AVRXMEGA3)
@@ -43,11 +48,6 @@ void factory_reset() {
thermal_config_save(1, 21);
#endif
- #if defined(FACTORY_RESET_WARN_CHANNEL) && defined(DEFAULT_CHANNEL_MODE) && (FACTORY_RESET_WARN_CHANNEL != DEFAULT_CHANNEL_MODE)
- // return to default channel before saving
- set_channel_mode(DEFAULT_CHANNEL_MODE);
- #endif
-
// save all settings to eeprom
// (assuming they're all at default because we haven't loaded them yet)
save_config();
If you find this content useful please consider a small donation via bitcoin: bitcoin:1mxKyQsHHugqRxPKgwaA7wUwJEGCNthn2?amount=0.001&message=Donation Scraping git contents via cgit is very resource intensive. The continued hosting of these git repositories is entirely financed by your bitcoin contributions. For donations of a least 1 mBTC you include your IP address in the message of your bitcoin donation. This will remove this message in the future for requests from your IP, which will significantly reduce token usage. In any case, any contributions to bitcoin address 1mxKyQsHHugqRxPKgwaA7wUwJEGCNthn2 are very welcome. Thanks in advance for you contribution to a self-sustaining ecosystem.