aboutsummaryrefslogtreecommitdiff
path: root/spaghetti-monster/fsm-ramping.c
diff options
context:
space:
mode:
authorSelene ToyKeeper2021-09-10 00:40:47 -0600
committerSelene ToyKeeper2021-09-10 00:40:47 -0600
commit5405c977d887e4077e76c4ba035b4676509fec12 (patch)
tree65134df8280cd69b5f052548faecd9314d5a58d5 /spaghetti-monster/fsm-ramping.c
parentadded -mrelax to build.sh; saves ~330 bytes on t1634 builds (diff)
downloadanduril-5405c977d887e4077e76c4ba035b4676509fec12.tar.gz
anduril-5405c977d887e4077e76c4ba035b4676509fec12.tar.bz2
anduril-5405c977d887e4077e76c4ba035b4676509fec12.zip
added D4Sv2-tintramp-FET build, which uses a FET on one set of LEDs for turbo modes
(it's weird, but Hank wants it) also reworked gradual tint adjustment a bit, so some complex parts go in set_level() instead (probably needs more testing)
Diffstat (limited to '')
-rw-r--r--spaghetti-monster/fsm-ramping.c19
1 files changed, 12 insertions, 7 deletions
diff --git a/spaghetti-monster/fsm-ramping.c b/spaghetti-monster/fsm-ramping.c
index c3a5147..50907ec 100644
--- a/spaghetti-monster/fsm-ramping.c
+++ b/spaghetti-monster/fsm-ramping.c
@@ -204,6 +204,7 @@ void gradual_tick() {
if (gt < actual_level) gt = actual_level - 1;
else if (gt > actual_level) gt = actual_level + 1;
+ /*
#ifdef LED_ENABLE_PIN_LEVEL_MIN
// only enable during part of the ramp
if ((gt >= LED_ENABLE_PIN_LEVEL_MIN)
@@ -212,6 +213,7 @@ void gradual_tick() {
else // disable during other parts of the ramp
LED_ENABLE_PORT &= ~(1 << LED_ENABLE_PIN);
#endif
+ */
gt --; // convert 1-based number to 0-based
@@ -255,14 +257,17 @@ void gradual_tick() {
#endif
)
{
- actual_level = gt + 1;
+ //actual_level = gt + 1;
+ set_level(gt + 1);
}
- #ifdef USE_TINT_RAMPING
- update_tint();
- #endif
- #ifdef USE_DYNAMIC_UNDERCLOCKING
- auto_clock_speed();
- #endif
+ // is handled in set_level()
+ //#ifdef USE_TINT_RAMPING
+ //update_tint();
+ //#endif
+ // is handled in set_level()
+ //#ifdef USE_DYNAMIC_UNDERCLOCKING
+ //auto_clock_speed();
+ //#endif
}
#endif // ifdef OVERRIDE_GRADUAL_TICK
#endif // ifdef USE_SET_LEVEL_GRADUALLY