diff options
| author | Selene ToyKeeper | 2023-08-29 12:55:27 -0600 |
|---|---|---|
| committer | Selene ToyKeeper | 2023-08-29 12:55:27 -0600 |
| commit | 158ad8bc28a578874e0906c0f2416ef8e5fa8446 (patch) | |
| tree | 08ef6d3d7803e61ebf3b2ac700956d2d3939314c | |
| parent | made smooth steps look more natural (especially when turning off) (diff) | |
| download | anduril-158ad8bc28a578874e0906c0f2416ef8e5fa8446.tar.gz anduril-158ad8bc28a578874e0906c0f2416ef8e5fa8446.tar.bz2 anduril-158ad8bc28a578874e0906c0f2416ef8e5fa8446.zip | |
renamed wurkkos-ts10-rgb to wurkkos-ts10-rgbaux
(for consistency, and in case they ever make a full RGB version)
(also, raised the post-off voltage brightness threshold, because
these aux LEDs are pretty bright)
(and updated the TS10 hwdef to the current API)
| -rw-r--r-- | hwdef-wurkkos-ts10.c | 16 | ||||
| -rw-r--r-- | spaghetti-monster/anduril/MODELS | 3 | ||||
| -rw-r--r-- | spaghetti-monster/anduril/cfg-wurkkos-ts10-rgbaux.h (renamed from spaghetti-monster/anduril/cfg-wurkkos-ts10-rgb.h) | 4 |
3 files changed, 14 insertions, 9 deletions
diff --git a/hwdef-wurkkos-ts10.c b/hwdef-wurkkos-ts10.c index 44602c0..06f5bac 100644 --- a/hwdef-wurkkos-ts10.c +++ b/hwdef-wurkkos-ts10.c @@ -6,6 +6,8 @@ #include "chan-aux.c" +void set_level_zero(); + void set_level_main(uint8_t level); bool gradual_tick_main(uint8_t gt); @@ -22,16 +24,14 @@ Channel channels[] = { }; +void set_level_zero() { + CH1_PWM = 0; + CH2_PWM = 0; + PWM_CNT = 0; // reset phase +} + // single set of LEDs with 2 stacked power channels, DDFET+1 or DDFET+linear void set_level_main(uint8_t level) { - if (level == 0) { - CH1_PWM = 0; - CH2_PWM = 0; - PWM_CNT = 0; // reset phase - return; - } - - level --; // PWM array index = level - 1 PWM_DATATYPE ch1_pwm = PWM_GET(pwm1_levels, level); PWM_DATATYPE ch2_pwm = PWM_GET(pwm2_levels, level); // pulse frequency modulation, a.k.a. dynamic PWM diff --git a/spaghetti-monster/anduril/MODELS b/spaghetti-monster/anduril/MODELS index f46d2a3..97af879 100644 --- a/spaghetti-monster/anduril/MODELS +++ b/spaghetti-monster/anduril/MODELS @@ -21,6 +21,7 @@ Model Name MCU 0141 emisar-d18 attiny85 0142 emisar-d18-219 attiny85 0143 noctigon-m44 attiny1634 +0151 emisar-d4k-3ch attiny1634 0211 noctigon-kr4 attiny1634 0212 noctigon-kr4-nofet attiny1634 0213 noctigon-kr4-219 attiny1634 @@ -67,7 +68,7 @@ Model Name MCU 0623 sofirn-lt1s-pro attiny1616 0631 sofirn-sp10-pro attiny1616 0632 sofirn-sc21-pro attiny1616 -0713 wurkkos-ts10-rgb attiny1616 +0713 wurkkos-ts10-rgbaux attiny1616 0714 wurkkos-ts10 attiny1616 0715 wurkkos-ts25 attiny1616 0716 wurkkos-fc13 attiny1616 diff --git a/spaghetti-monster/anduril/cfg-wurkkos-ts10-rgb.h b/spaghetti-monster/anduril/cfg-wurkkos-ts10-rgbaux.h index b307491..4350828 100644 --- a/spaghetti-monster/anduril/cfg-wurkkos-ts10-rgb.h +++ b/spaghetti-monster/anduril/cfg-wurkkos-ts10-rgbaux.h @@ -68,6 +68,10 @@ #undef DEFAULT_BLINK_CHANNEL #define DEFAULT_BLINK_CHANNEL CM_AUXWHT +// the aux LEDs are pretty bright; set the high-mode threshold a bit higher +// (default is 15) +#define POST_OFF_VOLTAGE_BRIGHTNESS 25 + // the default of 26 looks a bit rough, so increase it to make it smoother #define CANDLE_AMPLITUDE 33 |
