aboutsummaryrefslogtreecommitdiff
path: root/spaghetti-monster
diff options
context:
space:
mode:
authorSelene ToyKeeper2019-11-20 15:34:48 -0700
committerSelene ToyKeeper2019-11-20 15:34:48 -0700
commit02ba399f83371d3c8dba866fefb2519767d809b7 (patch)
treedeee785616d0ae57a287bc0b829a726c169541f9 /spaghetti-monster
parentmerged more updates from fsm / irq-refactor branches, finishing up previous c... (diff)
downloadanduril-02ba399f83371d3c8dba866fefb2519767d809b7.tar.gz
anduril-02ba399f83371d3c8dba866fefb2519767d809b7.tar.bz2
anduril-02ba399f83371d3c8dba866fefb2519767d809b7.zip
made the button LED turn off in momentary mode, instead of staying on forever
Diffstat (limited to 'spaghetti-monster')
-rw-r--r--spaghetti-monster/anduril/anduril.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/spaghetti-monster/anduril/anduril.c b/spaghetti-monster/anduril/anduril.c
index a86af16..5c5a6ee 100644
--- a/spaghetti-monster/anduril/anduril.c
+++ b/spaghetti-monster/anduril/anduril.c
@@ -1863,9 +1863,14 @@ uint8_t momentary_state(Event event, uint16_t arg) {
}
}
else {
- if (arg > TICKS_PER_SECOND*15) { // sleep after 15 seconds
+ if (arg > TICKS_PER_SECOND*5) { // sleep after 5 seconds
go_to_standby = 1; // sleep while light is off
- // TODO: lighted button should use lockout config?
+ // turn off lighted button
+ #ifdef USE_INDICATOR_LED
+ indicator_led(0);
+ #elif defined(USE_AUX_RGB_LEDS)
+ rgb_led_update(0, 0);
+ #endif
}
}
return MISCHIEF_MANAGED;
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.