I'm working on a project with 2 batteries: main and aux. The device they're connected two can be both load or charger (depending on whether it's plugged into the wall).
So the PCB must implement both priority charge and discharge. (main battery should be discharged first and charged last)
Since I haven't found any ICs that do this stuff, I've decided to split the charge and discharge lines into two separate ones. Discharge priority is gonna be controlled by TPS2121RUXR. But I'm having trouble designing the charge part. The best I came up with is to place a not gate on the negative terminal of aux, thus when it is finished charging the not_gate will open the diode to charge the main battery.
Can you suggest me better ways to implement this whole PCB? Some folks suggested using a single MCU and a bunch of diodes to control the operation, but as a noobie, I have a feeling that MCU is overkill here
For context: both batteries have their own BMS and consist of 2 high-drain 3.7V cells, so the output might be up to 30W. And another thing to consider is that it's a portable device with uptime of up to 12H, so power efficiency is crucial.