Commit f4d0d61
Fix PreonicBootGreeting and LED indicator interaction
This commit improves the interaction between the boot greeting effect and LED indicators:
1. Fix KeyAddr usage in PreonicBootGreeting
- Previously used KeyAddr(LED_INDEX) which incorrectly created KeyAddr(row=LED_INDEX, col=0)
- Now uses the correct KeyAddr(0, slot) values that match indicator configuration
- Maps LED indices to their corresponding indicator slots correctly
2. Simplify boot greeting rainbow effect
- All 4 LEDs now show the same rainbow color (instead of butterfly pattern)
- Makes it easier to identify when an LED is showing something different
- Continues to respect active indicators by not overwriting them
3. Ensure LEDs turn off after boot greeting
- Boot greeting now continues to turn off LEDs even after it's done
- Prevents LEDs from staying on after the effect completes
4. Add hasActiveIndicatorForLED() to LEDIndicators
- Allows other plugins to check if a specific LED has an active indicator
- Used by PreonicBootGreeting to avoid overwriting indicator LEDs
5. Fix WS2812 driver brightness calculation
- Prevent potential integer overflow in brightness calculation
- Use 16-bit intermediate values for safer math
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <[email protected]>1 parent 4005ab4 commit f4d0d61
File tree
4 files changed
+94
-17
lines changed- plugins
- Kaleidoscope-Hardware-Keyboardio-Preonic/src/kaleidoscope/plugin
- Kaleidoscope-LEDIndicators/src/kaleidoscope/plugin
- src/kaleidoscope/driver/led
4 files changed
+94
-17
lines changedLines changed: 48 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
34 | 35 | | |
35 | 36 | | |
36 | 37 | | |
| |||
70 | 71 | | |
71 | 72 | | |
72 | 73 | | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
73 | 90 | | |
74 | 91 | | |
75 | 92 | | |
76 | 93 | | |
77 | 94 | | |
78 | 95 | | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
84 | 109 | | |
85 | 110 | | |
86 | 111 | | |
| |||
114 | 139 | | |
115 | 140 | | |
116 | 141 | | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
121 | 145 | | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
127 | 161 | | |
128 | 162 | | |
129 | 163 | | |
| |||
Lines changed: 30 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
433 | 433 | | |
434 | 434 | | |
435 | 435 | | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
436 | 466 | | |
437 | 467 | | |
438 | 468 | | |
| |||
Lines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
158 | 158 | | |
159 | 159 | | |
160 | 160 | | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
161 | 167 | | |
162 | 168 | | |
163 | 169 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
52 | 56 | | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
53 | 62 | | |
54 | 63 | | |
55 | 64 | | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | 65 | | |
60 | 66 | | |
61 | 67 | | |
| |||
69 | 75 | | |
70 | 76 | | |
71 | 77 | | |
| 78 | + | |
72 | 79 | | |
73 | 80 | | |
74 | 81 | | |
| |||
0 commit comments