E-switch UI Development / FSM

I just watched a video of a guy cracking nuts with a SS Zy-t11.

Was that you Tom.

Yes, Anduril supports a 3-channel board with aux/button LED. It just needs a hwdef file to specify the pin layout and a cfg file to specify the UI options. Normally the aux LED goes on pin 7 in this setup, and it uses VCC to measure voltage instead of a divider.

Also, Tom, that is some really impressive soldering skill. I don’t know how you can get such small parts to be so precise.

Thanx! That was done when I was young, well under 60...

Hello,

first sorry, I didn´t read complete Thread :innocent: .

I read at TLF, that Andúril should work on Emisar D4s.
What´s about the AUX LED configuration.

Original Firmware on Emisar D4s is Ramping IOS V3.
7 clicks to change option for AUX LEDs.

Is it in Andúril also possible to change the AUX LED brightness?

thanks.

Yes it works, I have it on two D4S’es

The same 7x click on Anduril. On the D4S the modes are: OFF - LOW - HIGH - PULSE

Hi,
thanks a lot.
Thats sounds good.

So a colleague can flash my seven D4s´ for me ;).

Is there a complete chart, showing all functions and programmable options for Andúril, available?

I´ve only found this:

Thanks.

That IS the complete function chart :smiley:
Only thing missing from there is the AUX-7x click stuff. for AUX enabled lights.

There is a compete text version here if there’s something you are unsure of :slight_smile:

The questions were already answered in other comments, but I have one note to add. The original firmware for the Emisar D4S is actually Anduril. RampingIOS V3 came later, and is a simpler version of Anduril with a few things removed or rearranged. When I make updates, they happen in Anduril first and are then sometimes copied to RampingIOS V3 afterward.

Anyway, these are the most recent builds for D4S:

Hi,
thanks for all.

@ToyKeeper:
These builds for D4s are two different ones?
I can download them and flash (maybe).
Which differences are between them?
Or need I both to flash?

Sorry I´ve never flashed a flashlight-firmware, only somy mobilephones in the past.

I´ve bought a programmer some time ago:
https://www.fasttech.com/products/1002900
Never tested, but looks like the same which I saw on pictures showing Emisar D4s head with pogo pins.

Is there a detailed review for flashing Emisar D4s.

Don´t know, which programms etc I need…
thanks

square74, I would suggest reading through the “README” file in the firmware repository, which is also in the first post or two of the firmware discussion thread. Click the Link in my signature for more information.

The main cautionary note is to avoid flashing any fuse values with avrdude. That way, even if it fails it should be possible to try again until it works.

On another note, I finally wrote a user manual for Anduril. This is only a first draft, but I hope it makes sense.

Thanks a lot, something to read for me the next sleepless nights… ;).

Programmer I´ve is ok, cables can I make by myself or solder it…

I have today flashed a ROT66 v1 with Anduril

What I find very strange is that no matter what I doo in thermal config it starts to get out of Turbo at 45°C

I pushed at least 40 times one time for 70°C buit it ignores it
set the room temperature smaller but did not help

Try building the firmware with THERM_HARD_TURBO_DROP turned off.

The default ROT66 build is a bit paranoid about overheating, and tries extra hard to avoid it.

I know its active, but why is it completely ignoring the temperature setpoint?

It’s probably not. It’s probably just rising so fast it predicts it’ll be incredibly hot soon, and the prediction is above the limit even if the current temperature is not.

Anduril - Muggle mode

Currently I have seven lights running this fantastic firmware. And especially after the latest changes that got rid of the ramp lvl 1 flicker.

To me it’s 99% perfect. I only have ONE little detail I would like to change. Muggle ramp ceiling, set to max regulated level?

I have two kids, who often borrow a light. And i put it in muggle mode to prevent them and me from going blind, or melting stuff.
But it’s still too bright at the highest level. The max regulated level seems to be the sweet spot (for me)
BUT, I still haven’t got firmware-compiler-skills :open_mouth:

Is there a friendly soul out there that can compile an anduril.2019-01-05.kid.edition.hex for the D4/D4-219/D4S/D4S-219

Hey TK. Is there a FW3A hex floating around somewhere ? Only link I seen took me to a 404 error.

All hexes are here: Index of /torches/fsm

I just checked out the bzr branch. Having used Anduril for a while but not taken a look at the source code, this is even more impressive.

Normally I work in a totally different are of software development (lots of data, machine learning etc.). I wonder whether it would be feasible to integrate a C-based test framework and write test code for Anduril which would be executable on PCs using stubs in dedicated include files.

Many standard operations (like switching on, strobe etc.) could be tested including their interaction also for different targets. Usually this makes refactoring much easier. As the turnaround time including flashing the driver and testing the lights “by hand” is quite long, this could eventually lead to a considerable speedup in development.

Unit tests (see e.g. List of unit testing frameworks - Wikipedia) could be a good start. A natural evolution is BDD (Behavior-driven development - Wikipedia) which can also be used for embedded systems (example at Using Catch to Write BDD-Style Unit Tests for C — ElectronVector - Test-First Embedded Software)

What do you think?