0
\$\begingroup\$

I'm working on a circuit based on an ATTiny85 and I need accelerometer input. I was looking at using an analog accelerometer (KXTC9-2050 that runs around 240 uA) because I have the extra pin and I'm a noob so I figured it would be better if I avoided the complexity of I2C right now.

Since that's the case, it looks like I need to drive my 8 LEDs (WS2812B) with 5V (the LEDs at full brightness should consume about 50mA) and my ICs with 3.3V. I'll need to find a power cell I suppose (I'm open to suggestions).

Originally I said, "for space, I'd like to use a coin cell lithium battery so my supply voltage will be nominally 3V." This seems infeasible because the maximum discharge rate won't drive my LEDs

On a related note, these LEDs are really bright at 100%. Chances are good, they'll be PWM'd to less than 50%, they won't all be lit at the same time, and they won't all be full white all the time. Their actual power consumption will likely be considerably less than 50mA. But, I figured you plan for the peaks. If that's wrong, please let me know.

Things I've considered:

  1. The ICs have voltage ranges. Maybe I can power the ATTiny and the accelerometer directly off the battery and use a boost converter to get the 5V that I need for the LEDs. (Which I supposed doesn't really answer the question because I don't have 2 regulated power rails).

  2. I could boost the supply to 5V and use an LDO regulator for the 3.3 rail.

  3. I could boost the supply to 5V and use an LED to drop the voltage down for the 3.3 rail.

  4. I could use 2 boost converters.

\$\endgroup\$
15
  • 1
    \$\begingroup\$ How many LEDs are you planning to drive from this coin cell, and for how long? How much current does the accelerometer need? What is the capacity and maximum discharge current of the battery? Please provide links to the datasheet for the accelerometer and the battery. \$\endgroup\$ Jan 29, 2019 at 16:08
  • 2
    \$\begingroup\$ Check the current available from a coin cell, and calculate the power. Now check the power needed by the LED. Compare and contrast. Coin cells are wimpy compared to the power needs of an LED. \$\endgroup\$
    – TimWescott
    Jan 29, 2019 at 16:12
  • 1
    \$\begingroup\$ Don't power anything directly off the batteries, that's going to damage the batteries when they get overdischarged. \$\endgroup\$
    – Hearth
    Jan 29, 2019 at 16:29
  • 1
    \$\begingroup\$ I hate that terminology, on the grounds of dimensional analysis. When it's a discharge rating, "xC" really means "x/hour * C". So 2C from a 1 amp-hour cell is 2 amps, but 2C from a 100mA-hour cell is just 200mA. You can get model airplane cells rated at up to 40C, so the actual discharge rate is only an issue if you only need power out of the thing for a minute or two -- if you want it to stay lit for minutes or hours, you care about the battery capacity. \$\endgroup\$
    – TimWescott
    Jan 29, 2019 at 16:35
  • 1
    \$\begingroup\$ "Basically, if I have a 840 mAh battery, 1C is .84A per hour?" Oh, please put up a question saying "What does battery C rating mean?" If you have a 840mAh battery, 1C means you can safely draw 840mA from it. 2C means you can draw 1680mA, etc. \$\endgroup\$
    – TimWescott
    Jan 29, 2019 at 22:54

1 Answer 1

2
\$\begingroup\$

One approach (not necessarily the best) would be to use a boost converter module with some cell such as a (protected) 18650 which is appropriate to your LED loads. One common chip that the modules are based upon is the MT3608. A synchronous chip might be be a bit more effecient, especially near the end of discharge.

The rest of the circuit is relatively low current, as I understand it, so you could use a linear LDO from the +5V rail for the 3.3V.

One approach could be to re-purpose an inexpensive USB power bank that uses a single cell. That gets you the cell, protection, charging and 5V boost. Then you just add a little LDO regulator to get 3.3V. I have a couple that look like lipstick cases, hardly much bigger than the cell itself.

\$\endgroup\$
3
  • \$\begingroup\$ Thanks for your answer! I'd need to put the LDO on the 5V rail (rather than right off the battery) to get to my 3.3V because the LDO dropout voltage? I like the power bank idea. I'm space constrained, but I think I can make that work. \$\endgroup\$
    – D. Patrick
    Jan 29, 2019 at 16:46
  • 1
    \$\begingroup\$ The minimum voltage from the battery (before protection kicks in) might be closer to 3V so the regulator would drop out before the battery was fully discharged. The downside of regulating off the 5V line is that it uses more power from the battery but if the 3.3V current is much less than the 5V current, it's not going to be significant. And if you're using a USB power bank you don't need to cut into it. \$\endgroup\$ Jan 29, 2019 at 16:50
  • 1
    \$\begingroup\$ From my experience there is no problem converting 5V to 3V with a voltage regulator, even not classified as LDO if the 5V supply is regular (e.g. USB power bank), On bateries, an LDO with less than 1V drop out is necessary because the voltage will decrease faster and you may not have anything if the voltage falls under 4.7V for example. \$\endgroup\$
    – Fredled
    Jan 29, 2019 at 20:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.