aboutsummaryrefslogtreecommitdiff
path: root/spaghetti-monster
diff options
context:
space:
mode:
authorSelene ToyKeeper2018-10-07 19:19:37 -0600
committerSelene ToyKeeper2018-10-07 19:19:37 -0600
commit477082fc0c8671988b7bcac2a6d816b80a9fe675 (patch)
tree832982ad8a7d3a30d963e850c3de8e23391db328 /spaghetti-monster
parentFirst working PL47 build. Does aux LEDs on pin 7 but not pin 3. (diff)
downloadanduril-477082fc0c8671988b7bcac2a6d816b80a9fe675.tar.gz
anduril-477082fc0c8671988b7bcac2a6d816b80a9fe675.tar.bz2
anduril-477082fc0c8671988b7bcac2a6d816b80a9fe675.zip
Added option to skip "low" mode for aux LEDs.
Not actually used though.
Diffstat (limited to 'spaghetti-monster')
-rw-r--r--spaghetti-monster/anduril/anduril.c6
-rw-r--r--spaghetti-monster/anduril/cfg-ff-pl47.h4
2 files changed, 10 insertions, 0 deletions
diff --git a/spaghetti-monster/anduril/anduril.c b/spaghetti-monster/anduril/anduril.c
index 4aaea74..d15e9a0 100644
--- a/spaghetti-monster/anduril/anduril.c
+++ b/spaghetti-monster/anduril/anduril.c
@@ -1189,6 +1189,9 @@ uint8_t lockout_state(EventPtr event, uint16_t arg) {
#else
mode = (mode + 1) % 3;
#endif
+ #ifdef INDICATOR_LED_SKIP_LOW
+ if (mode == 1) { mode ++; }
+ #endif
indicator_led_mode = (mode << 2) + (indicator_led_mode & 0x03);
indicator_led(mode);
save_config();
@@ -1205,6 +1208,9 @@ uint8_t lockout_state(EventPtr event, uint16_t arg) {
#else
uint8_t mode = (arg >> 5) % 3;
#endif
+ #ifdef INDICATOR_LED_SKIP_LOW
+ if (mode == 1) { mode ++; }
+ #endif
indicator_led_mode = (indicator_led_mode & 0b11111100) | mode;
#ifdef TICK_DURING_STANDBY
if (mode == 3)
diff --git a/spaghetti-monster/anduril/cfg-ff-pl47.h b/spaghetti-monster/anduril/cfg-ff-pl47.h
index 5a623fc..d916e06 100644
--- a/spaghetti-monster/anduril/cfg-ff-pl47.h
+++ b/spaghetti-monster/anduril/cfg-ff-pl47.h
@@ -15,6 +15,10 @@
// lockout: blinking (3)
#define INDICATOR_LED_DEFAULT_MODE ((3<<2) + 2)
+// the "low" mode doesn't work on this light's aux LEDs
+// (but it does work on the switch LEDs)
+//#define INDICATOR_LED_SKIP_LOW
+
// ... or if TICK_DURING_STANDBY is turned off:
// off mode: high (2)
// lockout: off (0)
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.