Hi, please help. I flashed an a6 firmware. I removed the hidden modes and put the strobe to the highest mode like this
#define NUM_MODES1 5
// PWM levels for the big circuit (FET or Nx7135) #define MODESNx1 0,0,80,255,STROBE
// PWM levels for the small circuit (1x7135) #define MODES1x1 2,70,0,0,STROBE
Now the problem is I want the turbo timeout to work on the 4th mode (FET 255) not on STROBE mode. How do I edit the firmware so that when I am in the 4th mode it will step down to 3rd mode at turbo timeout?
I built another blf a6 driver. I disabled the med press. I want the mode direction from turbo to low and always start at turbo. How do I make it it?
Here are my modes
I started digging thru different codes in search for smooth ramping, idea is to have 1-mode flashlight that would, when switched on, started ramping from no light to max light in set period of time.
When reaching max light it would stay there.
Anything similar here?
If I am on the 4th mode and low voltage kicks in, it ramp down to 3rd mode but the 3rd mode is brighter and 2nd mode and 1st mode. How do I make it ramp up at low voltage so that when I am on the first mode when low voltage kick in it will go to 2nd mode? And when I am on the 4th mode it will just turn off.
Sounds like you will need to re-work the LVP logic to continue down this path.
Alternatively, it might be easier to put everything back to original and just tweak mode_idx to default to turbo instead of moon. Then the modes would still be in ascending order, but it would just turn on to turbo.
Or even easier yet, you can just activate memory. No mods needed.
I only offer alternatives in case re-working LVP is not worth it to you.
Not that Iâm aware of, but I doubt it would be difficult to create.
The main questions are what type of driver, and what type of switch?
There are already some smooth-ramping projects for e-switch lights, but Iâm not aware of any for clicky switches. It seems like it should be easy to create something like this though:
If the button was long-pressed, start at moon and ramp up over several seconds. Save the level to a ânoinitâ variable every time it changes.
If the button was short-pressed, start at the last-used level and stay there.
So, if you pick it up and turn it on, itâll ramp up from zero to max. If you quickly tap the button during that ramp, itâll stop and stay at the current level.
Isn't blf A6 bistro? Why reverse the ramps? Why not just set reversemodes to 1 by default instead? Or if you want, reverse the modegroups. Then you wouldn't need to modify the step down code, but whatever gets it done. I may be confused.
I got the predecessor to Narsil still working on 13A's, but not with smooth ramping, but the modes work the same as Narsil mode sets - a twist on the Werner UI. Mine should be in the repository, not changed for couple years I'm thinking.
The UI is pretty similar, but blf-a6 was heavily refactored to make bistro and it needs a bigger MCU. It didnât just add more options, it also changed a bunch of core logic. It made a lot of things easier, like reversing the mode order, but I donât think it has been ported back to the attiny13 yet⌠except for biscotti, which is generally more like guppydrv than like blf-a6.
There might be an easier solution, but I donât think an exact match exists yet.
Yeah, ok, I thought the code snippets looked pretty familiar, and yet different, then I did kind of remember that the attiny25 thread only started back in the summer or so (I think). It seems pretty hard to fit most of the mode logic into half the memory. I did try to really update/spring-clean the pre-processor configs in HD for pulling functionality in and out for various builds, but I'm not sure even with some of the new savings, if there's any way to get a build back down to that small as it stands now.