aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--ui/anduril/config-default.h6
-rw-r--r--ui/anduril/ramp-mode.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/ui/anduril/config-default.h b/ui/anduril/config-default.h
index 04fc956..cd25b52 100644
--- a/ui/anduril/config-default.h
+++ b/ui/anduril/config-default.h
@@ -113,6 +113,12 @@
// timer is available in regular ramp mode and candle mode
#define USE_SUNSET_TIMER
+// optionally make gradual ticks happen faster
+// Affects: thermal regulation speed, sunset mode, maybe other features
+// (default is calibrated for 8-bit PWM,
+// but 10-bit should set this value to 4 instead of 1)
+#define GRADUAL_ADJUST_SPEED 1
+
///// What to do when power is connected /////
// factory reset function erases user's runtime configuration in eeprom
diff --git a/ui/anduril/ramp-mode.c b/ui/anduril/ramp-mode.c
index 9e19025..4c535b4 100644
--- a/ui/anduril/ramp-mode.c
+++ b/ui/anduril/ramp-mode.c
@@ -287,7 +287,7 @@ uint8_t steady_state(Event event, uint16_t arg) {
static uint16_t ticks_since_adjust = 0;
ticks_since_adjust++;
if (diff) {
- uint16_t ticks_per_adjust = 256;
+ uint16_t ticks_per_adjust = 256 / GRADUAL_ADJUST_SPEED;
if (diff < 0) {
//diff = -diff;
if (actual_level > THERM_FASTER_LEVEL) {
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.