From 8b67b3a6e21342aefb1fffef72469588ecab2614 Mon Sep 17 00:00:00 2001 From: Gabriel Hart Date: Sun, 20 Dec 2020 12:27:05 -0600 Subject: Fix 1-Series standby tick speed, use 2C Turbo --- spaghetti-monster/anduril/cfg-gchart-fet1-t16.h | 5 ++++- spaghetti-monster/anduril/version.h | 2 +- spaghetti-monster/fsm-wdt.c | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) (limited to 'spaghetti-monster') diff --git a/spaghetti-monster/anduril/cfg-gchart-fet1-t16.h b/spaghetti-monster/anduril/cfg-gchart-fet1-t16.h index 42333a4..c8727ae 100644 --- a/spaghetti-monster/anduril/cfg-gchart-fet1-t16.h +++ b/spaghetti-monster/anduril/cfg-gchart-fet1-t16.h @@ -36,4 +36,7 @@ #define RAMP_DISCRETE_STEPS 7 // stop panicking at ~30% power -#define THERM_FASTER_LEVEL 105 \ No newline at end of file +#define THERM_FASTER_LEVEL 105 + +// enable 2 click turbo +#define USE_2C_MAX_TURBO diff --git a/spaghetti-monster/anduril/version.h b/spaghetti-monster/anduril/version.h index 5ecfc65..8cc1e77 100644 --- a/spaghetti-monster/anduril/version.h +++ b/spaghetti-monster/anduril/version.h @@ -1 +1 @@ -#define VERSION_NUMBER "20201218" +#define VERSION_NUMBER "20201219" diff --git a/spaghetti-monster/fsm-wdt.c b/spaghetti-monster/fsm-wdt.c index 7bb8acc..ea2efac 100644 --- a/spaghetti-monster/fsm-wdt.c +++ b/spaghetti-monster/fsm-wdt.c @@ -64,7 +64,7 @@ inline void WDT_slow() #elif defined(AVRXMEGA3) // ATTINY816, 817, etc RTC.PITINTCTRL = RTC_PI_bm; // enable the Periodic Interrupt while (RTC.PITSTATUS > 0) {} // make sure the register is ready to be updated - RTC.PITCTRLA = RTC_PERIOD_CYC16384_gc | RTC_PITEN_bm; // Period = 0.5s, enable the PI Timer + RTC.PITCTRLA = (1<<6) | (STANDBY_TICK_SPEED<<3) | RTC_PITEN_bm; // Set period, enable the PI Timer #else #error Unrecognized MCU type #endif -- cgit v1.2.3