I've since moved on to the new Anduril repo here which is based on the latest Toykeeper's Anduril repo on github. This old fork here will probably not be updated and I will slowly move all the features I've done to the new Anduril codebase.
The short story is that the Anduril code has changed a lot, and moved to github. The new multi-channel related code has many conflicts with what I've done here. Currently only a small portion of features are moved to the new repo:
Please consider using the firmware from the new Anduril if you like what I did here. However expect things to go slowly there. Thanks.
This is a clone from ToyKeeper's Flashlight Firmware from branch anduril2, revision 653
For ToyKeeper's binary see here
Since I plan to only work with my existing Anduril2 lights (see below list), I've deleted unrelated FW for other flashlights and many more stuffs from the huge repository. Basically I copied the ToyKeeper/ stuff from the original repo and removed unrelated hwdef and configs here.
This repo contains my own changes to Anduril2 firmware for my several D4v2's, a DW4, a D4K, and some SP10 Pro's and TS10's (as of Aug 2023). For other Anduril2 lights that I don't own, I won't be able to test or support. Please file a bug report if you see any issue.
noctigon-kr4-nofet (0212
):
noctigon-kr4 (0211
):
noctigon-kr4-noaux (0217
):
noctigon-kr4-219b (0214
) (50% FET):
emisar-d4sv2-tintramp (0135
): (for D4v2 tintramp)
emisar-d1v2-linear-fet (0124
):
emisar-d1v2-no-fet (0125
):
noctigon-k1-12v (0253
):
sofirn-sp10-pro (0631
):
wurkkos-ts10 (0714
):
sofirn-lt1s-pro (0623
): (Not included yet as this is better worked on Toykeeper's new multi-channel branch which I haven't got time yet)
noctigon-dm11-nofet (0272
):
noctigon-dm11-12v (0273
):
wurkkos-ts25 (0715
):
Since I've made use of AUX light a lot in this Anduril2 fork, some functions become dependent on AUX and won't work on lights that do not have AUX. So for mule or lights that do not have AUX (for example, KR1 and D1V2), I have added the following in MODELS
that has NO_AUX
defined in the config header:
Use this build instead so the following features/changes is ineffective/reverted:
6C
when in normal mode - will skip "main emitters on, aux high, button low" mode7C
in candle mode to turn on AUX along with main emittersDisclaimer: Use at your own risk. I'm not responsible for any loss caused by these firmware changes.
Ramp up main emitters output in 1 level using 3C
.
Use 9C
to switch between smooth and discrete ramp style (not used often, and makes it harder to reach by mistake than default 3C
)
Use 8C
to enter momentary mode (not used often, and makes it harder to reach by mistake than default 5C
)
Direct copy from SammysHP's Smooth sunset v2 patches or smooth sunset which is awesome.
When in lower levels (< DEFAULT_LEVEL), optionally we can turn on AUX LED along with main emitters.
6C
: in lower levels, allow AUX colour LED to be turned on along with main emitters for possible tint mix. 6H
changes AUX colour from RED to WHITE (total 7 colours).
6C
: in lower levels, cycle through these additional states (only for AUX LEDs):
No extra state is defined and the AUX LED on is temporary (not remembered) so if there is any button event (ramp up for example), AUX LED will be off. If later user enters moonlight, only main emitters will be lit (default). You need to re-enable this through 6C
or 6H
. The current AUX LED colour is remembered until reboot(factory reset).
Note that in lights with AUX but without button LED (ex. Wurkkos TS25), there will be just 2 modes in 6C
:
When AUX isn't available but indicator LED is:
6C
: turn on indicator LED
6H
: turn off indicator LED
Note that in newer Hank lights where there is a RGB switch/button LED, if the light comes with front-facing AUX LED, the RGB switch/button LED is wired to the AUX LED so the button LED control (second and third state in 6C
) won't work. This is not a firmware or hardware issue, but rather expected due to how it is.
In a tint ramping light, use 8H
to go to middle tint. (Copied from 4h to go to middle, not in the middle of 3h )
In addition, there is a shortcut 5C
to go to tint edge. Note that 5C
is for controlling parameters in some strobe modes so this shortcut won't work in candle/lightning/fireworks/lighthouse/tint alternating/tint smooth ramp modes.
Note that when lights are off or locked out, 5C
and 8H
still works but not visible until the emitters are turned on.
Direct copy from SammysHP's stepped tint ramping. Brilliant work there.
With the additional strobes I implemented, there are now maximum ten modes when doing 3H
:
Strobe mode is entered via 3H
, and strobes can be cycled using 2C
to go forward and 3C
to go back
2C
is to cycle to the next strobe state. Add 3C
to cycle back to the previous state. The purpose of this is that the most used strobe states are candle and lightning mode. If I'm already at lightning mode but want to go to candle mode, there was no option but to go through the blinding tactical strobe or party mode. While I don't want to disable tactical strobe nor party mode, let's add an option to just go back to the previous state.
In candle mode, add the following options which are saved:
4C
: making candle amplitude smaller (candle in sort of a more stillness, calmer)5C
: making candle amplitude bigger (candle in the wind)6C
: reset to default (which is a bit calmer then the stock one)Additionally, in lights with just indicator LED (single colour AUX, such as TS10), we can use 7C
to cycle through the indicator LED state in candle mode:
Two additional wobble styles: fireplace_slow and fireplace_fast. Use 4H
to cycle through all 3 wobble styles. This is a saved configuration.
In candle wobble style (default/stock) and with AUX LEDs present, we can additional use 7C
to toggle if we want to use aux led to assist in tint mixing. Red or yellow aux LED will light up along with the wobbling light.
For lights with just indicator LED, 7C
is used to cycle through indicator off/low/high.
In lightning mode, add the following options which are saved:
4C
: turn down busy factor so the lightning is less busy (less frequent)5C
: turn up busy factor so the lightning is busier (more frequent)6C
: reset to default (which is max 16sec until the next lightning strike, originally it's about 8sec)An additional strobe mode called Fireworks, right after Lightning mode. The main emitters will light up like fireworks.
Adjust firework brightness (explosion brightness):
4C
: decrease brightness by 125C
: increase brightness by 126C
: reset brightness to default (max regulated level, which is MAX_1x7135)For dual channel lights, fireworks mode will randomly choose from the following tint modes when doing the strobes:
An additional strobe mode called Lighthouse Beacon, right after Fireworks mode. The main emitters will light up periodically like a lighthouse where the intensity rapidly accelerates to turbo (level 150) and then ramps back down to 0 (when it rotates away from the viewer). It will wait for a few seconds (configurable) before doing it again.
Adjust the delay by:
4C
: decrease delay by 1 second (Min: 0 second)5C
: increase delay by 1 second (Max: 30 seconds)6C
: reset delay to default (5 seconds)An additional strobe mode called broken fluorescent, right after Lighthouse Beacon mode. The main emitters will flicker continously that simulates a broken fluorescent light. Brightness of the flicker can be adjusted by the usual 1H
and 2H
and is remembered.
A tint alternating strobe mode (after tactical strobe) for dual channel lights. It switches between channel 1 and 2 continously with configurable brightness (the usual 1H
and 2H
) and interval (4C
for decreasing and 5C
for increasing the interval by 0.5 second). The setting (brightness and interval) is saved.
A tint ramping strobe mode (after tint alternating strobe) for dual channel lights. It ramps between both channels repeatedly with configurable brightness (the usual 1H
and 2H
) and pause at each tint step (4C
for decreasing and 5C
for increasing the interval by 2 microseconds). The setting (brightness and pause) is saved.
It's a bit too harsh when using the main emitters to blink voltage/temperature readout. Use red AUX LED instead. For lights with indicator LED only (TS10 for example), the indicator LED (high) will be used.
Idea from this post.
When doing 1-click from off to turn on the light, there are additionally 3 modes that can be selected through Misc Config Menu (9H
from off).
See this youtube video for demo.
The Misc Config menu has the following items:
USE_TINT_RAMPING
(if enabled) is the first item (for tint ramping lights)USE_JUMP_START
(if enabled) is the second item (for lights with jump start enabled)Based on different light's config this can be 1st, 2nd or 3rd item in the menu. For dual channel with jump start, it is the third. For single channel with jump start, it is the second. For SP10 pro and TS10 it's the first and only item.
Please note that when start up mode is not 0 (instant on), jump start is disabled because it doesn't make sense to have jump start.
Idea from SammysHP's commit
Add mode 4 and mode 5 for low/high blinking.
Modes:
Add an additional mode "temperature" in AUX LED mode (for standby/lockout) after "voltage". The AUX LED will change colour based on the on-chip temperature reading.
<=12C
: pink/purple (red+blue)12~16C
: blue16-20C
: cyan (green+blue)20-25C
: green25-28C
: yellow (red+green)>28C
: redThis setting is after "voltage" mode. Use 7H
from off to loop each mode.
When voltage is < 3.2V when light is off, the off/lockout AUX mode will not activate. Instead, the AUX red LED will blink. Original idea from reddit user connorkmiec93 at this post.
The blinking is in a pattern called breathing (although it's only low/high mode in AUX LED) so it's less distracting to the original blinking and one can tell the difference to the normal blinking in RED mode.
For lights with the indicator LED, the indicator LED will be used.
Note that a similar feature is now implemented in r654 that is not yet integrated into this fork as of now.
Instead of blinking the main emitter, blink the AUX green LED at high power to indicate it's powered on. Original idea from here
There is an additional UI (in addition to Simple and Advanced) that is basically the same as Simple UI but with the following differences (limitations):
12H
from off in advanced UI)RAMP_DISCRETE_FLOOR
and 30Enter by 12C
from off, exit by 12H
from off.
Switch to this mode before handling the light to the kids.
8C
instead of 5C
for momentary mode (not used often so make it harder to enter)9C
in ramp mode to switch ramp style (smooth or discrete)11C/11H to go to this mode and back to advanced mode.
In this mode:
Refer to a great guide here