I need a circuit that can hold the battery charge level at level that set by me and stop the charge at that level. Also the device is battery powered so the device also needs power.
This is my circuit Files · master · mutantCybernetics / mutantC-v4 · GitLab
I used a xor to do that, but point is when it disable the main power device runs on battery, so there will be a high speed switching on off to keep the level.
I am wondering if there is other way to do that.
It a lithium ion battery, single cell 18650. I need this feature because it's a mainly battery powered device so conserving battery is important.
Did you try Google? Battery charging is a big business. Many semiconductor companies sell devices that can be used for charging batteries. Because there are many different types, sizes, chemistry there is no universal answer. There are complete solutions in single chips for some battery types and there are components that can be used to create individual solutions.
There are plenty of documents from datasheets to application notes and research papers available.
I am sure there is, but i am trying to keep it simple and do it using hobbyiest parts, like tp4056. TP4056 have a CE pin to turn off the charging but aging it's high speed switching to keep the battery level at certain stage.
Suppose i set the battery level to 50% then when 50% is reached then the system will cut the power, and now the device will use power from the battery. now it will discharge to 49% then the system will turn on the power to charge it until 50% is reached. so it's a cycle and that's what i am calling high speed switching. But problem is here battery is charging and discharging and if that happens then this feature is no use.
I need this so the battery will last longer.
One of the issues here is you are only using 1% of the battery capacity - so your battery is 100 times bigger than it needs to be .
There is some advantage to not fully charge a Lipo , but 80% down to 0% ( not flat !) is sensible .
Other types of battery eg lead acid , Nicad have different needs. ( eg holding a lead acid at 50% will shorten its life )
Have a good read up on batteries , as said there are a number of battery management IC’s around , to give optimum performance ...worth some research .
Sorry, i thought everyone can figure it out. Anyways it's a lithium ion battery, single cell 18650. I need this feature because it's a mainly battery powered device so conserving battery is important.
Why would you use the battery if your connected to another source of power? When mains power is plugged in, disconnect the battery and use the mains power to both power the load and charge the battery. Then just cut off the battery when it's fully charged. When mains power goes away, switch over fully to battery power. Nothing good can come of rapidly switching the battery charging on and off forever.
And why do you only want to partially charge the battery? The device doesn't appear to be an energy harvester, so it doesn't make sense that you would not want full charge. So I guess this is the real question: Why do you not want full charge?
@Jiggy-Ninja I am trying to implement battery managment system from the mac. Read this from apple how they do it About battery health management in Mac laptops - Apple Support. For short it limits the charge to a certain level for better battery life-span. @srnet i am using ESP32-S2. I used that because it has many pins that i need and easy to solder in a PCB.
I had a look at your web page. Nice project. You build in a standard 18650 battery that will be cheap to replace. Apple is overcharging their customers and tries to extend the battery life for users that use the MAC mostly connected to a power line.
I think you can spend your talent on other features of your project and ignore battery life extension. For instance, I would prefer battery clips over soldering the wires.
Thanks, You are right, for a single cell it does not matter.
Yes that battery connector will be a good choice. if you wanna join the project , you are most welcome.