| Commit message (Collapse) | Author | Files | Lines |
|
This replaces "USE_CONFIGURABLE_RGB_VOLTAGE_LEVELS"
with "USE_AUX_THRESHOLD_CONFIG", which controls the brightness of
button LEDs while the main LEDs are on,
and during post-off voltage display.
Same basic concept, but works on single-color LEDs too,
and lets the user finally configure POVD thresholds.
The code for this is a bit messy, but the aux LED code as a whole
is pretty messy since it wasn't designed for the things it does now.
The entire thing needs a refactor or rewrite someday. But not today.
For now, this is just enough to make the pull request
cover more use cases before merging into trunk.
I've tested it on a variety of lights, but am not yet entirely
comfortable with it. However, it worked on at least these:
- 1-color button LED, no RGB
- front RGB, 1-color button LED
- front RGB, hardwired also to RGB button
- RGB button, no other aux
These may need extra changes,
and may have extra config options which do nothing...
- front RGB, no button LED
- 1-color front aux, no button LED
- no aux at all
- attiny85 lights (some could theoretically support the new options,
but none even try)
|
|
Adds two entries to the battery voltage settings menu, the first
isathreshold for switching aux to high, and the second sets a minimum
level for it to be displayed, also effectively allowing the feature to
be entirely disabled if not wanted.
|
|
and updated other scripts and files accordingly
|
|
|
|
(still need to update file contents afterward,
but doing it in a separate commit so git can detect renames easier)
|
|
(also modified the build scripts to work with the new file structure)
|
|
(just moved files, didn't change the contents yet,
and nothing will work without updating #includes and build scripts and stuff)
|
|
(this gives better, smoother low modes and reduced flicker)
|
|
which gives much better resolution, especially for the 8-bit channel.
Also...
- set_channel_mode() aborts when going from/to the same channel,
to avoid unnecessary flicker
- hsv2rgb() uses 16-bit R/G/B and V now
- changed default channel to All
- reduced default channel modes to just A, B, C, and All
- smooth ramp floor defaults to 1/150
- raised level when aux LEDs turn on high during use
(for better compatibility with red main LEDs)
|
|
emisar-d4k-3ch: removed redundant #define
|
|
and made it longer on emisar-d4k-3ch
because some channels don't flash fast enough
|
|
made USE_AUX_RGB_LEDS_WHILE_ON work more like the old indicator LEDs,
where it gets set automatically with set_level()
Using set_level_zero() reduces space used by channel modes, and simplifies
code for each mode's set_level_*() functions. I measured about 220 bytes
less in the emisar-d4k-3ch build this way, while also reducing the chance
of bugs.
|
|
|