18 years ago I designed a power supply to charge or discharge batteries for a medical company.
It acted like a buck converter for charging and acted like a a boost for discharging.
Two FETs were all the switches needed for either conversion, as either FET could act as a switch or as a diode.
I...