Advices for powering my PCB circuit

Hello,

My projects consist of measuring different sensors using the ESP32 bare chip. It takes a measurement once every 2h and goes back to deepsleep.
I need confirmation that I'm not doing anything wrong. I've tested it, except for the Mosfet that protect for reverse polarity. I'm sure you might be able to make much better than that. I just need to know if you think there's anything wrong or that could be improved.
I have:

  • a power source (a 18650 or a Lithium polymer battery)
  • a power regulator (MCP1700)
  • a voltage divider connect to a pin on the ESP32
  • a battery charger (TP4056) in case I need to use a solar panel
  • a protection for reverse polarity

So what do you think guys?

Thanks a lot for your help
Laurent

A quick look by me (its late in the evening here in UK).

  • Is the FET really needed?
  • R3 and R2 present a large discharge on the battery. The resistance could be raised significantly and/or turned on only when the battery level needs to be checked.

I agree with both points. The mosfet is always on, so there's no point to having it there. And the resistor divider could have much higher values, like 100K each, or even 220K.

Edit: Ok, you said reverse polarity. That's why the mosfet is there.

I'm a bit concered about Out- and Bat- being connected together. If your module is like mine, with the DW01 protection chip, connecting them like that defeats the protection, which works by controlling the low side. So I think Out- should be connected to ground, and Bat- should be connected to the battery's minus terminal.

Out+ and Bat+ are actually connected together on the module.

My thoughts:

I get the MosFet is for reverse polarity safety. However your P-channel must be fully on with only 3.7 volts on the gate. I'm not sure P-ch exist with such a low -VGS. Keep in mind the mosfet should have a Vgs spec of significantly < 3.7 volts for it to be fully on.

C1 need not be as large as you have. Stay with the MCP1700 app notes.

R2 and R3 could go higher and add a 0.1 cap on the "BattLvl" connection.

You need a capacitor (or 2) at the circuit side of J1

Post the ESP32 connections for more help.

1 Like

Thanks to all of you for taking time to help me.

Actually, I'm wondering if it is really needed. Especially if I will use a polymer lithium battery with a JST plug

I thought it would be fine with the DMG2301L-7. Anyway, I decided to take it out.

I'm not sure to understand. How can that be? The Bat+ and OUT+ are not the same.

For the rest, I updated all your recommandations. Please, let me know if it's better now.

That's what I wanted to do after but I first wanted to focus on the power part.
Here's the ESP32 part:

  • I have a USB to UART TTL that I will plug to the pin socket connector to load my program
  • I don't think it is necessary to show how my LoRa module is connected. I have a RFM95W-868S2 chip.
  • I have the temperature sensor DS18B20 connected to GPIO22
  • And a potentiometer connected to GPIO35 and controlled by GPIO21

Thanks again guys

C5 needs to be 0.1uF, not 100uF.

Can you post a link to your TP4056 module?

Ok thanks. Just to be sure, are we talking about polarized aluminium or unpolarized ceramic capacitors? And is it the same for C6?

I finally decided to go with the LiPo battery. So as you suggested in my previous topic, I don't need any protection. And now, I realize why you're asking me that! I guess I need to change my scheme since I will actually use this one:


So does that mean the Batt+ will go to both the voltage divider and the MCP1700?

C5 would just be a plain ceramic cap. C6 would be a polarized aluminum electrolytic, 100uF. So C5 and C2 could be the same cap.

No, that's not why. The TP4056 module with protection has separate holes for Out+ and Bat+, but if you'll look at the board, those holes are shorted together. But that's not the case on the negative side. The protection circuit disconnects Bat- from Out- if a violation occurs. So if you need the protection on the module, you shouldn't connect the negative terminals together.

But if you're going with the non-protected module, then there's no separation on the negative rail.

1 Like

Yes.

So if I go with the TP4056 with protection, I go like this:
image

If I go with the unprotected TP4056, I go like this:
image
Right?

And what about the ESP32? Is that ok for the 2 switches? And the pin holders to connect with my USB-to-UART TTL?

Yes, it looks right to me.

I don't know about that. You'll have to find an ESP32 expert for that, or a schematic for an existing ESP32 board to see how it's done.

Thanks a lot @ShermanP.
That's what I did for the ESP32. I just wanted to double check.

One last question for you @ShermanP. If I decide not to plug any solar panel to the JST connector (J4), apart from taking space on my PCB, is it bad? in terms of current consumtion or anything else...?

No I don't think so. With no power coming in, the TP4056 will shut down, and the battery will power the load. There may be a very small amount of leakage current back through the TP4056, but not enough to make any difference - maybe a couple microamps.

1 Like

Great. Thanks. If I see I really don't need it, I will take it out in future.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.