*BLF LT1 Lantern Project* (codes going out for more LT1s, second batch shipping!)

10048 posts / 0 new
Last post
ToyKeeper
ToyKeeper's picture
Offline
Last seen: 1 hour 18 min ago
Joined: 01/12/2013 - 14:40
Posts: 10107
Location: (469219) 2016 HO3
Madtoffel wrote:
If we need the 7135 chips for the button LED and the FET struggles with low currents why don’t we just use a combined FET+1 design?

It doesn’t work that way. It wouldn’t really help anything.

The linear FET’s extra pin is needed because of how that type of circuit works.

With a 7135 chip design, a pulsed (PWM) signal goes from the attiny chip to a set of 7135 chips, turning them on and off at about 16 kHz. This can be detected by measuring equipment but is invisible to the eye. It looks like a steady brightness level, and it mostly “just works” without issues. The 7135 chips don’t care about the pulse voltage, they only care about whether it’s on or off.

With a linear FET design, a PWM signal goes from the attiny to a circuit which averages it into a smooth analog voltage. At 4.2V and 50% PWM duty cycle, the output signal is a steady 2.1V. This tells the FET how much power to allow through. But the same 50% duty cycle on a low battery at 3.0V only averages out to 1.5V. So the brightness changes with voltage.

To avoid the problem of brightness changing with voltage, the attiny needs to receive a constant input voltage. Let’s say that’s always 5.0V exactly, using some magic on the VCC input pin. Then a 50% duty cycle always averages out to 2.5V, and the brightness stays the same regardless of whether the batteries are full or almost empty.

However, this means the attiny has no idea whether the battery is full or empty. So we have to add a second connection to the battery, to allow the attiny chip to measure battery status. This uses up an extra pin.

Agro
Agro's picture
Offline
Last seen: 32 min 1 sec ago
Joined: 05/14/2017 - 11:16
Posts: 5039
Location: Ślōnsk
Stereodude wrote:
A good boost circuit should be able to achieve >90% efficiency. A linear driver achieves way less than that. If we’re using four Sanyo 3500mA GA cells the battery will have an average voltage of about 4V over the first 1/3rd of it’s capacity. With Vf of 3.01V at 1A you’re just at ~75% efficiency with the FET driver. If you want to run it at 1/2 power (.5A) Vf drops to 2.87V and pushing your efficiency down to 71.75% efficiency. At 1/4 power Vf is below 2.82V and your efficiency is barely scraping 70%.


I see over 4V for about 600 mAh which is 18% of capacity, not 1/3.
Voltage decreases pretty much linearly to 90% capacity, from 4.15 to 3.4V. Then it falls off the cliff.
Over that 90% capacity, with Vf of 2.82 linear driver is about 75% efficient. Over the last 10% it’s about 91% efficient.
Overall efficiency is more like 78%.
A 95% efficient driver would increase runtime by about 22% in the lowest modes, less in the higher ones.

ToyKeeper
ToyKeeper's picture
Offline
Last seen: 1 hour 18 min ago
Joined: 01/12/2013 - 14:40
Posts: 10107
Location: (469219) 2016 HO3
Lexel wrote:
pinout
PB0 enable of Boost USB and the opamps
PB1 3000k
PB2 voltage divider 220/47k for LVP
PB3 switch over 1k
PB4 5000K

Is there any chance of using PB0 and PB1 for 3000K and 5000K, and PB4 for USB/opamps? The chip likes having the two PWM channels on PB0 and PB1. I’m hoping for something like this:

                 ----
         Reset -|1  8|- VCC
 (PB3) eswitch -|2  7|- voltage divider (PB2)
   (PB4) opamp -|3  6|- 5000K (PB1)
           GND -|4  5|- 3000K (PB0)
                 ----

Otherwise, the second PWM counter gets involved, and it runs at a different speed, and things get a little weird.

Also, how slow can the PWM signal can be without causing problems? I usually underclock the MCU at low levels to make the bottom of the ramp more efficient, but I’m not sure that’ll work with a linear FET.

If I understand correctly, the 7135 version might be something like this?

                 ----
         Reset -|1  8|- VCC
 (PB3) eswitch -|2  7|- USB enable (PB2)
 (PB4) aux LED -|3  6|- 5000K (PB1)
           GND -|4  5|- 3000K (PB0)
                 ----
Captain_Joe
Offline
Last seen: 19 hours 49 min ago
Joined: 09/10/2017 - 03:05
Posts: 23
Location: Deutschland

I´m in for one!

Madtoffel
Offline
Last seen: 6 hours 16 min ago
Joined: 05/07/2018 - 09:46
Posts: 87
Location: Germany (TLF member)

Thanks for the clarification ToyKeeper Thumbs Up
I actually thougt that we need one of the 7135s to drive the button led Facepalm , I really shouldn’t read this while doing something else…

Stereodude
Offline
Last seen: 2 weeks 4 days ago
Joined: 03/16/2013 - 21:14
Posts: 521
Location: US of A

Agro wrote:

I see over 4V for about 600 mAh which is 18% of capacity, not 1/3.
Voltage decreases pretty much linearly to 90% capacity, from 4.15 to 3.4V. Then it falls off the cliff.
Over that 90% capacity, with Vf of 2.82 linear driver is about 75% efficient. Over the last 10% it’s about 91% efficient.
Overall efficiency is more like 78%.
A 95% efficient driver would increase runtime by about 22% in the lowest modes, less in the higher ones.
I didn’t say over. I said average. The midpoint of the voltage of the first ~1200mAh at a low discharge current (which it will be because there are 4 in parallel) is ~4.0V. My numbers were right for the scenario I outlined.
Stereodude
Offline
Last seen: 2 weeks 4 days ago
Joined: 03/16/2013 - 21:14
Posts: 521
Location: US of A

ToyKeeper wrote:
Well actually… Silly

* GD&R *

Tint changes with current, and is usually best (whitest) when the current is in the medium-high range of an emitter’s power capacity. Tint is generally worst at very low power levels, or when the emitter is heavily overdriven, but fine anywhere in-between.

Here’s a video of a single emitter changing color due to different power levels being used. The light on the right is alternating between 350mA constant current and 350mA via a pulsed FET. The light on the left is only there for reference. http://toykeeper.net/torches/blf-a6/tintshift.avi (sorry for the bad video, I should re-do this demo sometime)

For the lantern, the risk is using too little power, causing unnecessary tint shift because the emitters aren’t running hot enough to get to their ideal range. If it’s only 1.4A total, split across 4 to 8 emitters, that’s 175 to 350 mA per emitter at the highest brightness. This is low enough to get some tint shift, but not a lot. However, a constant current driver will get worse tint shift as the total power goes down, while a PWM driver keeps a constant tint.

But between a linear FET or a buck/boost driver, tint shouldn’t be any different. They both shift the same way at low levels. The only style which doesn’t is PWM.

At least the effect doesn’t seem particularly bad on the LH351D. I notice it a lot more with XP-G2.

A constant current boost driver can be PWM’d. Some of them can also change the LED drive current without using PWM. As I stated, the use of a boost driver doesn’t cause any tint shift issues that weren’t there before.
Agro
Agro's picture
Offline
Last seen: 32 min 1 sec ago
Joined: 05/14/2017 - 11:16
Posts: 5039
Location: Ślōnsk

Stereodude wrote:
Agro wrote:

I see over 4V for about 600 mAh which is 18% of capacity, not 1/3.
Voltage decreases pretty much linearly to 90% capacity, from 4.15 to 3.4V. Then it falls off the cliff.
Over that 90% capacity, with Vf of 2.82 linear driver is about 75% efficient. Over the last 10% it’s about 91% efficient.
Overall efficiency is more like 78%.
A 95% efficient driver would increase runtime by about 22% in the lowest modes, less in the higher ones.
I didn’t say over. I said average. The midpoint of the voltage of the first ~1200mAh at a low discharge current (which it will be because there are 4 in parallel) is ~4.0V.

I stand corrected
Stereodude wrote:
My numbers were right for the scenario I outlined.

I thought you meant to say that with GA and Vf of 2.82, average efficiency of linear driver would barely scrap 70% over entire discharge.
Now I think you meant over the first 1/3 of discharge.
Is that correct? If no, could you clarify how did you come up with the number? It’s quite different from mine.
ToyKeeper
ToyKeeper's picture
Offline
Last seen: 1 hour 18 min ago
Joined: 01/12/2013 - 14:40
Posts: 10107
Location: (469219) 2016 HO3
Stereodude wrote:
A constant current boost driver can be PWM’d. Some of them can also change the LED drive current without using PWM. As I stated, the use of a boost driver doesn’t cause any tint shift issues that weren’t there before.

Fair enough. The BLF GT uses both methods — current control for 10% to 100% power, and PWM below 10%. But it needs two pins to control one power channel… one for current and one for on/off. That’s what the lantern was going to do while using DEL’s design, before the tint ramping was added.

I’m guessing that a boost design for the lantern would keep the cells in a 4P configuration, but the emitters would be two channels each configured as 2S2P? That should keep the voltages far enough apart for a boost to work. And then instead of burning off excess voltage, the driver’s heat would instead come from voltage conversion.

sbslider
sbslider's picture
Offline
Last seen: 1 hour 50 min ago
Joined: 01/22/2017 - 13:41
Posts: 1440
Location: United States

great discussion over the past few pages, I learned a bunch.

PocketSammich wrote: I don’t need this, but I want it. Please sign me up.

fixed it
Offline
Last seen: 2 days 6 hours ago
Joined: 12/08/2015 - 14:27
Posts: 396
Location: Canada

ToyKeeper wrote:
With a linear FET design, a PWM signal goes from the attiny to a circuit which averages it into a smooth analog voltage. At 4.2V and 50% PWM duty cycle, the output signal is a steady 2.1V. This tells the FET how much power to allow through. But the same 50% duty cycle on a low battery at 3.0V only averages out to 1.5V. So the brightness changes with voltage.

To avoid the problem of brightness changing with voltage, the attiny needs to receive a constant input voltage. Let’s say that’s always 5.0V exactly, using some magic on the VCC input pin. Then a 50% duty cycle always averages out to 2.5V, and the brightness stays the same regardless of whether the batteries are full or almost empty.

You should try compensating in software instead. You could recover a pin and the drain of the voltage divider. And you no longer need the magic circuitry for VCC either.
Lexel
Lexel's picture
Online
Last seen: 1 min 30 sec ago
Joined: 11/01/2016 - 08:00
Posts: 5533
Location: Germany

wrong a boost driver needs also Vcc 2.8V and voltage divider for the MCU

reason is it needs an analog control voltage to set the output current

to use all solutions with CC+PWM on both channels would simply need an MCU with 7 or more free pins

twodollarbill
Offline
Last seen: 2 days 9 hours ago
Joined: 01/30/2017 - 11:57
Posts: 43

ToyKeeper wrote:

Some thoughts on this…

Advantages to PWM / AMC7135 chips:

  • Better tint. LEDs get less white at low power, and these are expected to run at fairly low current. PWM runs at a consistent power level and produces a consistent tint regardless of how many lumens are coming out, but a constant current driver has more visible tint shift when not running at full power.
  • Can keep the button LED. PWM doesn’t require as many MCU pins, so we could still have a lighted button with multiple modes. The linear FET option may also have higher parasitic drain in standby mode, due to needing a voltage divider to measure battery status. This effect could be very small though, if done right.
  • Manages heat better. The 7135 chips spread heat across a wider area and have thermal regulation built in, so they don’t overheat. However, a linear FET concentrates heat into a smaller space on the driver, which means the driver itself may need heat sinking.
  • Better low modes, usually. The “raptor claw” 7135 chips have good performance in low modes, so the bottom of the ramp should be pretty low and pretty stable. However, a linear FET tends to have difficulty in really low modes, so the bottom of the ramp might not be very low or very stable.
  • Simpler driver design, easy and pretty much risk-free.

Advantages of a linear FET:

  • Higher efficiency in most modes. More lumens or more runtime. At the lantern’s power level though, this effect may be small, like only a 5% or 10% difference.
  • The parts might cost less.
  • Can potentially be modded for higher current by changing a sense resistor, but this also increases the risk of driver damage due to heat.

I’ll get things working on whichever one is used, but personally I lean a bit toward the simpler option even if it’s a bit less efficient.

I trust ToyKeeper’s opinion on stuff like this and based on her list alone, it looks like the AMC driver has more pros than the FET driver.
However, it seems like the majority of votes so far have been for the FET driver. I’m not knowledgeable enough to understand why.

Can anyone explain their reasoning for wanting the FET over the AMC?
sbslider
sbslider's picture
Offline
Last seen: 1 hour 50 min ago
Joined: 01/22/2017 - 13:41
Posts: 1440
Location: United States

I voted before seeing all the details. I still wonder how/if we can be assured of getting the “raptor claw” AMC chips. I am only think I know what I have read on here, and my impression is that one can not guarantee getting these parts in general. But that may be if one is buying in small quantity from Chinese stores. Lexel thought the FET was a better choice, and he has lots of experience designing drivers, so there is something to be said for that as well.

Two established, experienced people, two different points of view. Question

PocketSammich wrote: I don’t need this, but I want it. Please sign me up.

DBSAR
DBSAR's picture
Offline
Last seen: 3 hours 3 min ago
Joined: 02/11/2013 - 23:28
Posts: 6123
Location: Ontario, Canada
ToyKeeper wrote:
sbslider wrote:
DBSAR wrote:
if we can get the tint ramping feature integrated.
There is no doubt in my mind that Toykeeper is fully capable of this. The hardware is easy (and done), the firmware is not much different than what already exists in Anduril.

I already have most of the code written. I just haven’t been able to actually try it since the hardware doesn’t exist yet.

The light operates the same as any other Anduril light, but with one key difference: While the light is on, in almost any mode, the user can “click, click, hold” to make it change tint. This happens smoothly without significantly affecting total lumen output. If the color changes in the wrong direction, let go of the button and do it again.

Good work Toykeeper. Lexel mentioned he can make a prototype or two at a cost, or it may be possible Barry can get one or two built to send to you for testing.

That Canadian flashlight guy & Lantern Guru -Den / DBSARlight

LichtAn
Offline
Last seen: 2 months 6 days ago
Joined: 03/08/2018 - 02:37
Posts: 322
Location: Germany

The boost driver is just out of question because of higher costs? What costs are we talking here? 5$? 50$?

DBSAR
DBSAR's picture
Offline
Last seen: 3 hours 3 min ago
Joined: 02/11/2013 - 23:28
Posts: 6123
Location: Ontario, Canada

Lexel wrote:

lets go with the FET, most people dont care about 10% average efficiency gain for a more compley and costly boost driver

pinout
PB0 enable of Boost USB and the opamps
PB1 3000k
PB2 voltage divider 220/47k for LVP
PB3 switch over 1k
PB4 5000K

Agree on that to go with the the standard FET (or AMC) over a Boost driver for this application, as with four high capacity cells and the lower amp loads the efficiency wont be that big of a concern.

That Canadian flashlight guy & Lantern Guru -Den / DBSARlight

Pezo
Offline
Last seen: 2 weeks 2 days ago
Joined: 04/03/2018 - 15:55
Posts: 55
Location: Austria

Lexel wrote:
lets go with the FET, most people dont care about 10% average efficiency gain for a more compley and costly boost driver

pinout
PB0 enable of Boost USB and the opamps
PB1 3000k
PB2 voltage divider 220/47k for LVP
PB3 switch over 1k
PB4 5000K

You don’t actually need an extra pin for measuring VCC, have a look at AN2447
This way we could still have the button lighted from the MCU.

Regarding the app note, you don’t even need to use division (which is a lot of code) if all you care about are a couple of thresholds and not the actual VCC value.

fixed it
Offline
Last seen: 2 days 6 hours ago
Joined: 12/08/2015 - 14:27
Posts: 396
Location: Canada

Pezo wrote:

You don’t actually need an extra pin for measuring VCC, have a look at AN2447
This way we could still have the button lighted from the MCU.
TK knows about that trick. It can’t be used if Vcc is regulated.
Pezo
Offline
Last seen: 2 weeks 2 days ago
Joined: 04/03/2018 - 15:55
Posts: 55
Location: Austria

fixed it wrote:
TK knows about that trick. It can’t be used if Vcc is regulated.

Ah yes I hadn’t considered that. However, you don’t need to regulate VCC, you only need to regulate the high voltage of the PWM outputs used for the DAC… I’ll have to think about that.
ToyKeeper
ToyKeeper's picture
Offline
Last seen: 1 hour 18 min ago
Joined: 01/12/2013 - 14:40
Posts: 10107
Location: (469219) 2016 HO3
fixed it wrote:
Pezo wrote:
You don’t actually need an extra pin for measuring VCC, have a look at AN2447 This way we could still have the button lighted from the MCU.

TK knows about that trick. It can’t be used if Vcc is regulated.

That’s how the code currently works by default. The pin7 voltage divider trick is supported too, but it requires a different config when compiling.

ToyKeeper
ToyKeeper's picture
Offline
Last seen: 1 hour 18 min ago
Joined: 01/12/2013 - 14:40
Posts: 10107
Location: (469219) 2016 HO3
fixed it wrote:
You should try compensating in software instead. You could recover a pin and the drain of the voltage divider. And you no longer need the magic circuitry for VCC either.

No. I’ve tried. It doesn’t work well at all.

CV-based circuits need a good solid voltage source, and an attiny is not a good voltage regulator.

Lexel
Lexel's picture
Online
Last seen: 1 min 30 sec ago
Joined: 11/01/2016 - 08:00
Posts: 5533
Location: Germany

toykeeper I changed the pinout

5 3000k
6 5000k

ToyKeeper
ToyKeeper's picture
Offline
Last seen: 1 hour 18 min ago
Joined: 01/12/2013 - 14:40
Posts: 10107
Location: (469219) 2016 HO3
LichtAn wrote:
The boost driver is just out of question because of higher costs? What costs are we talking here? 5$? 50$?

As Lexel noted, making it work properly would require more pins than we have. It also would require redesigning the MCPCB. Maybe some other things too.

More pins means changing the type of MCU, which means rewriting pretty much all the low-level code. That will probably have to happen eventually, but I’m not sure now is the right time. At minimum, it would be a significant delay for this project.

ToyKeeper
ToyKeeper's picture
Offline
Last seen: 1 hour 18 min ago
Joined: 01/12/2013 - 14:40
Posts: 10107
Location: (469219) 2016 HO3

Lexel wrote:
toykeeper I changed the pinout

5 3000k
6 5000k

Thanks! That makes things easier. Smile

I have a different question about the layout though. There are several ground vias directly under the BAT+ ring. They’re masked, but I wonder if there might still be any risk of shorting ground to BAT+ through those vias. I’m not sure how much the mask protects against that. Is that likely to be a problem?

Stereodude
Offline
Last seen: 2 weeks 4 days ago
Joined: 03/16/2013 - 21:14
Posts: 521
Location: US of A

Agro wrote:
I thought you meant to say that with GA and Vf of 2.82, average efficiency of linear driver would barely scrap 70% over entire discharge.
Now I think you meant over the first 1/3 of discharge.
Is that correct? If no, could you clarify how did you come up with the number? It’s quite different from mine.
I was talking about the first 3rd of the battery. In the case of barely getting to 70% that was a case where the lantern was running at like 1/4rd power also.

ToyKeeper wrote:
I’m guessing that a boost design for the lantern would keep the cells in a 4P configuration, but the emitters would be two channels each configured as 2S2P? That should keep the voltages far enough apart for a boost to work. And then instead of burning off excess voltage, the driver’s heat would instead come from voltage conversion.
I would suggest two strings of 4 LEDs. One for each color temp. That way the current is the same in each LED and binning variances can’t lead to one pulling more current than the others. A 2S2P battery configuration would be better than 1S4P, but that complicates the battery situation by using unprotected batteries in series which is ill advised.

DBSAR wrote:
Agree on that to go with the the standard FET (or AMC) over a Boost driver for this application, as with four high capacity cells and the lower amp loads the efficiency wont be that big of a concern.
Why does everyone want to toss an additional 20-30% of the battery life at lower brightness levels (not that much on high)? The reasons you cite for efficiency not being a big concern actually are reasons why the efficiency is even worse in this lantern than lights pulling more current with fewer batteries. The low LED current means lower forward voltages. This means more power is burned off in the driver. The four batteries in parallel mean the per cell current draw is quite low meaning the cell voltage sags less and stays at a high voltage longer meaning more power is burned up in the driver.

Boost drivers aren’t hard. I don’t understand why everyone is scared of them or doesn’t want to use them.

DavidEF
DavidEF's picture
Offline
Last seen: 2 weeks 2 hours ago
Joined: 06/05/2014 - 06:00
Posts: 7698
Location: Salisbury, North Carolina, USA

Stereodude wrote:
Boost drivers aren’t hard. I don’t understand why everyone is scared of them or doesn’t want to use them.

Simple solution: You (Stereodude) design a boost driver board which includes a USB charging interface and fits into the Q8 size host. Also, it must use ATtiny85 or else you must port TK’s firmware to whichever MCU you decide to use. The driver design must not be too complicated nor the parts list too expensive for our Chinese manufacturer to make it reliably and at a reasonable price. Because time is of the essence, we will continue using Lexel’s design until you present yours to the team. Then we will discuss whether yours is good enough to merit making it the new standard. DEAL? Innocent

The Cycle of Goodness: “No one prospers without rendering benefit to others”
- The YKK Philosophy

lexvegas
Offline
Last seen: 3 days 5 hours ago
Joined: 07/24/2018 - 14:20
Posts: 91
Location: USA
DavidEF wrote:
Stereodude wrote:
Boost drivers aren’t hard. I don’t understand why everyone is scared of them or doesn’t want to use them.
Simple solution: You (Stereodude) design a boost driver board which includes a USB charging interface and fits into the Q8 size host. Also, it must use ATtiny85 or else you must port TK’s firmware to whichever MCU you decide to use. The driver design must not be too complicated nor the parts list too expensive for our Chinese manufacturer to make it reliably and at a reasonable price. Because time is of the essence, we will continue using Lexel’s design until you present yours to the team. Then we will discuss whether yours is good enough to merit making it the new standard. DEAL? Innocent

I want a boost driver, but I’d rather get a lantern this year than 2020, so I’m happy with the PWM driver or the FET driver. I’m ordering 3, so if I can design a boost driver that fits, I will at most break one. Smile I’m sure that if a boost driver does get made, it will be open source, and anyone will be free to make one. Also, what you can afford in qty 5 is not what is affordable to a Chinese mfg. at qty 1000+ when they start counting pennies. I can afford 5 $5 FETs to use on my board for a 10% gain, they can’t.

Phlogiston
Phlogiston's picture
Offline
Last seen: 3 days 10 hours ago
Joined: 10/27/2016 - 16:57
Posts: 890
Location: Scotland

I’ve spoken out in favour of the linear FET driver because it doesn’t have PWM and gets a few more lumens per watt, but I’m fine with the 7135 version if that has more plus points overall. I still don’t feel the need for a boost driver.

I do have a question about the FET driver tint shift, though. Would the tint ramping capability let people manually correct for the tint shift at a given brightness? Or would the shift be in a different direction to the ramp within the colour space?

The_Driver
The_Driver's picture
Offline
Last seen: 17 hours 19 min ago
Joined: 10/20/2016 - 05:51
Posts: 1428
Location: Germany
Phlogiston wrote:
I do have a question about the FET driver tint shift, though. Would the tint ramping capability let people manually correct for the tint shift at a given brightness? Or would the shift be in a different direction to the ramp within the colour space?

Tint is not CCT (color temperature). Tint is a deviation form perfect white light (which can be warm, cool or in between, always on the line of the black body radiator). Tint is when the light has a green tinge or is red-tinted for example.

The lantern will be able to change its CCT, not the tint.

Pages