[WIP] 17mm DD+single-7135 driver / single sided / Dual-PWM

Ok, so I think I need to change the CAP_SHORT value, and I can use offtime-cap.c to calibrate it, am I right?

And to get the right resistor values, I use the battcheck firmware?

The offtime-cap firmware can give you values for CAP_SHORT; just half-press the button for the amount of time you want to set as the threshold between short and long presses, take a few readings, get an average.

As for resistor values, I can’t really help. Battcheck doesn’t provide resistor values; it only provides ADC values to use after you’ve already gotten the resistors worked out. You need to divide the voltage in hardware to get it completely in the range of 0.1 to 1.1V though. Battcheck can at least tell you if you’re getting usable values though; try it with a full battery vs a low battery, and if the values are too close to each other (or if any readings are 255), then the resistors are wrong.

Am I understanding correctly that all the components for this board are the same as the single sided FETDD board with the exception of the 7135 chip? I just piggy pack the zener on the 10uf cap, and flash with the dual PWM firmware?

Yes, and for the Zener see this post [WIP] 17mm DD+single-7135 driver / single sided / Dual-PWM

[quote=finges]
Yes, and for the Zener see this post https://budgetlightforum.com/t/-/31102?page=2#comment-716463
[/quote
]

Do you have a post#? Those links don't work for me, and depends on your posts/page setting. I'm interested in that too, and couldn't find it.

For zener info Look at posts 78-83. For 6v lvp you’ll need to swap out R1 for a higher value as well. Anything between 30k-40k seems to work fine.

Yes, thanx for the LVP tip too!!

I’m sure Tom knows, but I’ll add this for anyone else reading: the firmware lvp values will still need to be tweaked, even with the correct R1.

I may forget more than I remember Smile. Haven't done a zener mod in a long time, though I know it's a combo of the resistor and firmware values read in. Would the 30-40K work for 3 cells as well, and just tweak the values in firmware also?

Hmm I’m not sure, I haven’t done a 3S zener. Just guessing you’ll probably need to go closer to 50k

Depending on your required voltage cutoff, 36K will still work with 3S cells.

Recall the simple voltage divider formula (for these newer drivers without the diode voltage drop):

(Desired Voltage * R2 * 255) / ((R1 + R2)*1.1) = ADC Value

Where the 255 is the highest possible value (which is true, since we are using 8-bits worth of resolution) and 1.1 is the reference voltage.

So in your case, you'd get the following for a 9V LVP ADC value:

9*4700*255 = 10,786,500

(36000+4700)*1.1 = 44,770

10,786,500/44,770= 240.93--round to 241.

OK, now we know the math and understand what's going on. For those who don't like to slog through the math every time (like myself ) I created a Google sheet that you can just punch the values into.

P.S. As many here have noted, the voltage divider resistors can, and will, affect the off-time timing. You'll find that with the zener-mod setups the divider's effect is minimal (the circuit is different).

Ohhh - thanx again Richard! I know you posted this stuff before, but this time I'll really tag it/copy it some where I won't forget Frown. Frustrating - just can't get to all the mods I want to... Limited time, and my mod sessions are much shorter now because of several things goin on - neck, back, access to my modding office, etc.

That spreadsheet works nice for seeing many options at once. I plugged in my 4S buck setup (100K and 5.1K) and got the right answer.

The voltagedivider consumes “standby” current so for electronic switch lights it might be recommended to use higher values like 100k and 22k as a standard…

Has anyone compared the so8 fets? Is the 0R9 one worth the dollar more?
What resistor Sizes are optimal for this driver 0805 or 0603?

For a single-cell light with a clicky button, a 19.1k resistor is the way to go. 22k also works, but it messes with the offtime capacitor.

Specifically, 22k pushes the offtime values to the far end of the measurable range, and makes the “off” timings very temperature-sensitive.

Any one have the Eagle files for this driver?

It would be nice to make similar boards available in other sizes.

Unfortunately not, but there are already some other sizes available. They use the same principle (FET+1)

[WIP] 10mm DD+single-7135 driver: double sided 10440 torture for Dual-PWM
[WIP] 12mm DD+single-7135 driver: double sided 10440 fun for Dual-PWM
[WIP] 15mm DD+single-7135 driver - single sided Dual-PWM compatible using 3.3x3.3mm FET
[WIP] 22mm DD+single-7135 driver / single sided / Dual-PWM / Zener

I’m not sure what kinds of files Eagle uses, but the OSHpark page linked in the first post has a link to download a zip containing a bunch of design files. gtp, gts, txt, dri, gbl, gbo, gbp, gbs, gko, gpi, gtl, and gto. Not sure what each one is, but maybe something in there will be sufficient?

The .dri file says it was generated by “EAGLE CAM Processor 7.1.0”.

Those design files are gerber files for the PCB manufacturing. The .dri file is the drill holes data of the PCB.

Thank you finges. I'll check those out.

Unfortunately TK, the Gerber files can not be used to create Eagle files (At least as far as I know).

I was hoping wight might have shared the Eagle files with someone before he left. It would take someone like me a boat load of time to recreate them due to my limited experience with Eagle. It would be cool if we shared the Eagle files. That way others could tweak them for their purposes and report back. It would accelerate board development. I know there is a thread were some component libraries are shared.

If anyone has the Eagle files for this or any other BLF driver that is Attiny 13a, and DD or 7135 based, it would be cool if you made them publicly available.

EDIT: Corrected spelling of finges name. My apologies. May take me a bit to not include an "r".