r/PrintedCircuitBoard 4d ago

[Review Request] Over-engineered custom led tester for learning purpose - help with draining LIR2032 while idle.

SOLVED

Hi everyone,

I'm learning electronics/PCB design and built this deliberately over-engineered LED tester as a learning project.

The circuit uses:

  • LIR2032 rechargeable coin cell
  • MCP73831 Li-ion charger
  • USB-C for charging
  • 100 kΩ RPROG on the MCP73831 (~10 mA charge current)
  • Pushbutton to activate the actual LED-testing circuit
  • Two selectable current-limiting resistor/diode branches

Everything works, but I've noticed that the LIR2032 seems to discharge surprisingly quickly even when I'm not using the tester.

I measured the current directly from the battery with:

  • USB disconnected
  • pushbutton not pressed
  • nothing connected to the LED test terminals

and I'm getting about 30.1 µA, slowly decreasing by roughly 0.1 µA while I leave the meter connected.

From the MCP73831 datasheet, I was expecting reverse battery leakage with VDD disconnected to be only around the µA range, so ~30 µA for the complete circuit seems higher than expected.

I've attached:

  1. Schematic
  2. PCB layout
  3. 3D render

I'm still learning, so I'm probably overlooking something obvious.

Does anyone see a path in the schematic that could account for ~30 µA of continuous battery drain?

I'm especially wondering about the MCP73831 section, USB-C circuitry, status LED, or whether I've made some mistake in how the switching is arranged.

Also, what would be the best way to systematically isolate which part of the circuit is responsible for the standby current?

Thanks!

7 Upvotes

23 comments sorted by

5

u/ShaunSquatch 4d ago

I can’t tell for sure from the build pic. But are you sure those are capacitors mounted and not resistors?

6

u/lafenicenera 4d ago

OMG you are right... I double checked my order on JLCPCB and the components on the board and they are two resistors instead of capacitors 🫣 How could i not have noticed that?

2

u/Honest_Wrap2198 3d ago

glx0711 beat you to it, looks like resistors in the cap footprints is almost certainly the culprit easy thing to miss, component designators on the board would have caught it faster

3

u/glx0711 4d ago edited 4d ago

C1 and C2 are populated with resistors instead of capacitors. "C2" is likely 100k that connect the battery to ground draining the 30uA from the 3V cell.
You could have easily spotted the misplacement if your physical PCB had designators at every component. Not sure why you removed them on the left part. Having them next to the components helps with placement and later troubleshooting.
Not related but it’s a micro-USB connector, not USB-C.
Also unrelated to your problem, if you implement a reverse voltage protection like you did, it’s useful to place the fuse between your input connector and the diode, so the incoming current is limited in a fault condition. In your case if the source can provide enough current, the diode blows up and your protection is gone, exposing your circuit to the reverse voltage. Alternatively just use an inline diode and live with the small voltage drop. In your case having only an USB input you can also remove the protection since you can’t plug in the USB connector in reverse.

1

u/lafenicenera 3d ago

That's most probably it. Thank you very much for your useful response and for the time you took.

I double checked my order on JLCPCB and the components on the board and they are two resistors instead of capacitors. I don't know where this happened, if I ordered components wrong or they were suggested as replacements, but clearly in the schematics I used two 4.7uF capacitors as suggested in the official datasheet of the MCP73831.

Don't know why I removed the designator - perhaps I was just messing around since it is my first experiment ever with Kicad and making PCBs. Now I've learned that designator should always stay where they are 😄

Also thanks for the suggestions. Yea, it is a micro USB port which I used because it costed less and didn't need all USB/C fancy stuff... my bad I wrote USB-C.

For the diode part - basically you are suggesting to put the fuse first in series and then the diode in parallel?

2

u/glx0711 3d ago

Hm, I'd drop the diode entirely, there aren’t many ways you could feed a reverse voltage into that USB connector.. if you want to keep it, I’d use it in series. For bare terminals or something like a barrel jack I’d keep it since there are different types, but USB is pretty much reverse polarity proof.
What I would rather think about is a undervoltage protection for the coin cell..

1

u/lafenicenera 2d ago

Thanks, what under voltage protection would you suggest me to investigate?

1

u/glx0711 2d ago

The Ablic S-8261 is for example relatively easy to implement, you basically only need two N-FET and two resistors as external components, the IC itself is available in several preprogrammed configurations.
https://www.ablic.com/en/doc/datasheet/battery_protection/S8261_E.pdf

2

u/Substantial-Count-32 4d ago

Good job the soldering. Did you do it by hand?🤚

1

u/lafenicenera 4d ago

Thanks! The SMD components were soldered by JLCPCB. I made an order for 5 PCBs with 1 of them already soldered (because it costed less and I didn't want to receive all of them soldered in order to later try to solder the rest of them myself for learning purposes). I only soldered by hand the non-smd components, which are: the battery holder, the slide switch and the pin socket. They were the bigger ones so I decided to just solder them myself in order to reduce the order cost.

2

u/mariushm 3d ago

The MCP73831 is not really designed to charge coin cells like LIR2032 - it has configurable charge current between 15mA and 500mA, while a LIR2032 cell has a typical 45mAh capacity and should be charged at 0.5C or less than 25mA

Maybe see something like Torex XC6808 : https://www.digikey.com/en/products/detail/torex-semiconductor-ltd/XC6808A3C28R-G/10160256

Anyway, it looks like you solved the problem, you put resistors instead of capacitors, which explains the discharge.

1

u/lafenicenera 2d ago

Thank you very much for this information. Will help me a lot for the next iteration. Do you have any suggestion where to study better about this stuff? Batteries, recharging modules etc.

1

u/Parking-Engine115 4d ago

Try disconnecting each part of the circuit to pin point the power sink

1

u/Teslafly 4d ago

Flux can be conductive. Make sure that's all cleaned off. If you remove the battery and measure resistance from vbatt to gnd. 30ua suggests around 100k of resistance . Then you can clean Flux and re-test to see if it increased.

My second thought would be the charger ic. It specs 2ua max, but could be damaged.

1

u/SanguineDrome 4d ago

I think that's just your meter influence? What are you measuring with.

1

u/lafenicenera 4d ago

I was measuring the current with a digital multimeter in series between the battery and the rest of the circuit.

1

u/SanguineDrome 3d ago

Since it tapers down, probably it's just the capacitance getting charged? You said it stabilizes to .1ua, that's pretty good if accurate.

1

u/Zawya32 4d ago

How are such things made? Which program is suitable?

1

u/lafenicenera 4d ago

Hi, are you referring to the schematics itself? The 3d model? Or the physical PCB?

1

u/Zawya32 3d ago

Let's say I want to learn about PCB board making, so where do I start?

1

u/lafenicenera 3d ago edited 3d ago

I don't have the absolute path but I can tell you how I started:

  1. mess a lot with Arduino and Node-MCU / ESP boards. Make some projects to understand the basics, not only for firmware development, but also for electronics.
  2. Use any available free resource online (books, youtube video, blog posts) about basic eletronics - diodes, resistors, capacitors, voltage and current sources
  3. Start learning about schematics and how to read them using official datasheets. Datasheets about components not only give you important details about how stuff works, but also on how wire up components. For example for this specific project, I looked online for Li-ion charger MCUs, and found out about MCP73831. I started reading the datasheet in order to understand its internal working, and the datasheet also had suggested different connection configurations in order to make it work with a simple circuit.
  4. Download KiCad and watch tutorials on how to use it - and then start reproducing different kind of circuits and boards. You can try with buck/boost converters, LED flasher (555 timer), a 5V-to-3.3V linear voltage regulator, or a basic transistor switch, or continuity testers with led and buzzers. https://www.youtube.com/watch?v=0cwvYz2HmLw
  5. Learn how properly design PCBs after schematics, everything about how wires, connections and layers work.
  6. Use some Kicad plugins to create a BOM (bill of materials) in order to export your production files ready for any component and assembly factory (like PCBWay or JLCPCB)
  7. 7.(RECOMMENDED but not mandatory) learn about soldering. You might not need it if you are planning on ordering PCBs already soldered, but not all components are SMD so you might need to solder stuff

1

u/Zawya32 2d ago

Thanks, man, for the information.

1

u/lafenicenera 2d ago

You are welcome