With work being so slow, both because of reduced sales and some process improvements that have greatly increased time efficiency, I’ve been in full R&D mode for most of the last two weeks. I’m sure y’all noticed a sudden quickening of the pace.
I forgot I hadn’t yet tested low-battery shutdown, but the adjustable linear regulator I was using in place of the micro’s LDO has a dropout of like 1V so definitely not suitable for continuing to power the micro at 2.5V with a battery input of 2.7V or so. I’ve now acquired the correct part and can test and program for that.
I also got in some of the analog temp sensors I want to test for LED temperature monitoring. They’ll work down to a fairly low voltage, and also operate on a max of 10uA, so I’m going to try powering them in parallel with the LED. The parasitic current should have an imperceptible difference on brightness even at low settings. This means only one additional wire to the LED’s PCB to get temperature readings.
The only problem now is the ground reference is floating. Fortunately that offset is always a known value - in fact, a value determined by the micro - so the math to compensate for it is easy. The simplest method is to simply scale the PWM value against the current-sense resistor, and account for the difference between ADC reference and Vcc (2.048V vs 2.5V, so a factor of roughly 1.25). Since all of those factors are constant the scaling factor is constant and determined at design time, therefore easy to program in as a constant in code.
I’ve got PCBs drawn up for 2A and 3A versions. Basically the only thing changing is the buck driver; the 2A version is a SOT25 package I can home-etch boards to test with but the 3A is an SC70-5 with pin pitch too fine for my Sharpie skills so, while I have some to test with, I’ve never actually lit one up. Its internal FETs have a lower on-state resistance though most other parameters are basically the same, so it should be more efficient.
What’s going to be the hangup in testing is LED PCBs. I’ll have to make do with regular 2-layer PCBs, thin and with plenty of vias for heat transfer, probably lap the soldermask off the bottom, but eventually I’ll want something proper. I’ve done a bit of looking at MCPCB threads on here but they were all a few years old. Who do y’all trust these days for small batch custom boards? I’m testing with two lights right now, one with a P60 dropin (16mm LED board) and a zoomie with a screw-in pill that takes a 17mm driver and 20mm LED, so I’m drawing up temp-sensor-integrated LED boards for both sizes.
Also because I got time, I’m working on prototype PCBs for a 1S 6V/5A buck, and the ~400mA buck/boost for a 2xAAA penlight. Got parts to play with, but no PCBs. They’ll probably be in the same order as the above test drivers. Next I’ll iron out the 6A buck, and then start hammering out the 8A boost, both of which will benefit from a FET tailswitch.