In this post I have explained how the internal body diodes of MOSFETs could be exploited for enabling the charging of battery through the same transformer which is being used as the inverter transformer.
In this article we will investigate a full bridge inverter concept and learn how the in-built diodes of its 4 MOSFETs could be applied for charging an attached battery.
What is a Full Bridge or H-Bridge Inverter
In few of my earlier posts we have discussed full bridge inverter circuits and regarding their working principle.

As shown in the above image, basically, in a full-bridge inverter we have a set of 4 MOSFETs connected to the output load. The diagonally connected MOSFET pairs are alternately switched through an external oscillator, causing the input DC from the battery to transform into an alternating current or AC for the load.
The load is normally in the form of a transformer, whose low voltage primary is connected with the MOSFET bridge for the intended DC to AC inversion.
Typically, the 4 N-channel MOSFET based H-bridge topology is applied in full bridge inverters, since this topology provides the most efficient working in terms of compactness to power output ratio.
Although using 4 N channel inverters depend on specialized driver ICs with bootstrapping, yet the efficiency overweighs the complexity, hence these types are popularly employed in all modern full bridge inverters.
Purpose of MOSFET Internal Body Diodes
The internal body diodes present in almost all modern day MOSFETs are primarily introduced to safeguard the device from reverse EMF spikes generated from a connected inductive load, such as a transformer, motor, solenoid etc.
When an inductive load is switched ON through the MOSFET drain, electrical energy gets stored instantaneously inside the load, and during the next moment as the MOSFET turns OFF, this stored EMF is kicked back in the reverse polarity from MOSFET source to drain, causing a permanent damage to the MOSFET.
The presence of an internal body diode across the drain/source of the device thwarts the danger by allowing this back emf spike a direct path through the diode, thus safeguarding the MOSFET from a possible breakdown.
Using MOSFET Body Diodes for Charging Inverter Battery
We know that an inverter is incomplete without a battery, and an inverter battery inevitably requires charging frequently to keep the inverter output topped-up and in the standby condition.
However, charging a battery requires a transformer, which needs to be a high wattage type to ensure optimal current for the battery.
Using a additional transformer in conjunction with the inverter transformer can be quite bulky and costly too. Therefore finding a technique in which the same inverter transformer is applied for charging the battery sounds extremely beneficial.
The presence of the internal body diodes in MOSFETs fortunately makes it possible for the transformer to be switched in the inverter mode and also in the battery charger mode, through some easy relay changeovers sequences.
Basic Working Concept
In the diagram below we can see that, each MOSFET is accompanied with an internal body diode, connected across their drain/source pins.

The anode of the diode is connected with the source pin, while the cathode pin is associated with the drain pin of the device. We can also see that since the MOSFETs are configured in a bridged network, the diodes also become configured in a basic full-bridge rectifier network format.
A couple of relays are employed which implement a few quick changeovers for enabling the grid AC to charge the battery via the MOSFET body diodes.
This bridge rectifier network formation of the MOSFET internal diodes actually makes the process of using a single transformer as an inverter transformer and charger transformer very straightforward.
Current Flow Direction through MOSFET Body Diodes
The following image shows the direction of current flow through the body diodes for rectifying the transformer AC to a DC charging voltage

With an AC supply, the transformer wires change their polarity alternately. As shown in the left image, assuming the START as the positive wire, the orange arrows indicate the flow pattern of current via D1, battery, D3 and back to the FINISH or the negative wire of the transformer.
For the next AC cycle, the polarity reverses, and the current moves as indicated by the blue arrows via body diode D4, battery, D2, and back to the FINISH or the negative end of the transformer winding. This keeps repeating alternately, transforming both the AC cycles to DC and charging the battery.
However, since MOSFETs are also involved in the system, extreme care has to be exercised to ensure that these device do not get damaged in the process, and this calls for a perfect inverter/charger changeover operations.
Practical Design
The following diagram shows a practical design set up for implementing MOSFET body diodes as a rectifier for charging an inverter battery, with relay changeover switches.

To ensure 100% safety for the MOSFETs in the charging mode and while using the body diodes with the transformer AC, the MOSFET gates must be held at the ground potential, and completely cut-off from the supply DC.
For this we implement two things, connect 1 k resistors across the gate/source pins of all the MOSFETs, and a put a cut-off relay in series with the Vcc supply line of the driver IC.
The cut-off relay is an SPDT relay contact with its N/C contacts connected in series with the driver IC supply input. In the absence of AC mains, the N/C contacts remain active allowing the battery supply to reach the driver IC for powering the MOSFETs.
When mains AC is available, this relay changes over to the N/O contacts cutting off the IC Vcc from the power source, thus ensuring a total cut off for the MOSFETs from the positive drive.
We can see another set of relay contacts connected with the transformer 220 V mains side. This winding constitutes the output 220V side of the inverter. The winding ends are connected with the poles of a DPDT relay, whose N/O an N/C contacts are configured with the mains grid input AC and the load respectively.
In the absence of mains grid AC, the system works in the inverter mode, and the power output is delivered to the load via the N/C contacts of the DPDT.
In the presence of an AC grid input, the relay activates to N/O contacts allowing the grid AC to power the 220V side of the transformer. This in turn energizes the inverter side of the transformer and the current is allowed to pass through the body diodes of the MOSFETs for charging the attached battery.
Before the DPDT relay is able to activate, the SPDT relay is supposed to cut off the Vcc of the driver IC from the supply. This slight delay in activation between the SPDT relay and the DPDT relay must be ensured in order to guarantee 100% safety for the MOSFETs and for the sound operations of the inverter/charging mode via the body diodes.
Relay Changeover Operations
As suggested above, when mains supply is available the Vcc side SPDT relay contact should activate a few milliseconds before the the DPDT relay, at the transformer side. However, when the mains input fails, both the relays must switch OFF almost simultaneously. These conditions could be implemented using the following circuit.

Here, the operational DC supply for the relay coil is acquired from a standard AC to DC adapter, plugged with the grid mains.
This means, when grid AC is available, the AC/DC adapter powers ON the relays. The SPDT relay being connected directly to the DC supply activates quickly before the DPDT relay can. The DPDT relay activates a few milliseconds later due to the presence of the 10 ohm and the 470 uF capacitor. This ensures that the MOSFET driver IC is disabled before the transformer is able to respond to the grid AC input at its 220 V side.
When mains AC fails, both the relay switch OFF almost simultaneously, since the 470uF capacitor now has no effect on the DPDT due to the series reverse biased diode.
This concludes our explanation regarding using MOSFET body diodes for charging an inverter battery through a single common transformer. Hopefully, the idea will allow the many hobbyists to build cheap, compact automatic inverters with built-in battery chargers, using a single common transformer.




Comments
hi… swagatam , I have once contributed about this mosfet body diode inverter circuit.here are the research I did about it which give clear explanation on bi-directional inverter with voltage boosting and current regulations when charging and inverting.
my request here is to ask you if you can create an article with schematics for it.
this are the research documentary should I post it here or via your email what’s your email if u decide?
Thank you David,
However I will need a schematic for updating the information. Without a schematic it will be difficult for me to create the article.
If you have done the experiment yourself then please provide the images of the prototype, if possible I will try to figure out the diagram…
okay, I can draw the circuit related to block diagram but I want you to go through the research I did which can will still make it easy and understanding with that you can create a schematics with reference to the research on chatgpt
I understand your desire to learn more on this subject, however I cannot use chatgpt information to publish on this site, because Google does not like AI based research, Google always prefers practical research based on real human analysis.
okay then, I will try to sketch out the schematics diagram for you to see it.
That would be great, let me know when it is ready with you….thanks very much for your kind efforts.
Very interesting post… My experience working with inverters (mostly modified sine) has built in chargers and they usually use a triac when the public grid is present. They switch through a CH relay (sometimes use DTDP relays to do this task and transfer), botton line is that triac is controlling a “Chargin tap” in the transforner normally 90VAC tap (fed with 120AC) on a 120AC transformer (double for 220VAC) which increase the charging voltage at Mostef Side. Microcontroller takes care of the 3 stages charging profiles. My question is that I’m building a sine wave inverter with 3 stages charger, the controller is meant to work 12,24,36 and 48vdc depending of some jumpers. I’m using the traditional Triac on charging Tap in the Hivoltage side of the transformer . But my Power board (6KW) it has the snubber circuit and polarizing circuit (resistor and diode) and a 20kohm resistor across gate/source instead the 1kohm as you stated . This 20k resistor will work for the same task of charging (full bridge config is used by this sinewave inverter). Thanks in advance
Hi, thanks for the feedback, and glad you liked the post.
The resistor values across the gate/source of the MOSFFETs is not critical, so a 20k resistor should also be fine. It is simply because MOSFET gates have extremely high impedance in many Megaohms, therefore a 20k will be sufficient enough to hold the gates to the ground level while they are switched OFF.
Perfect. Thanks for your kind reply.
You are welcome…
Chinonso you cannot increase your output current when charging because input mains is low all you have to do is to design a switching stabilizing unit using a ferosonite system for your inverter mains input
Hello, I am actually looking for solution to this problem. In a 12v inverter, a 7v-220v transformer is often used. If you apply 220v AC mains, the voltage at the mosfet side will be 6v, which is not enough to charge a 12v battery. I have also read it online that the boost Pfc method is used to boost the voltage. But I can’t find any circuit anywhere.
Pls help.
Most of low frequency inverters (uses 50/60hz transformers) use a charging tap at high voltage side of the inverter (90vac for a 120Vac inverter as reference) . A triac it is used here and controlled by a microcontoller to achive 3 stages charging system , this will boost the voltageat low voltage side of the transformer when main are present and charging is needed.
In traditional inverters there is a charging tap at high side of the transformer which isconnected by a triac and controlled by microcontroller for 3 stage battery system …
You are welcome.
Okay…
Thank you very much appreciated
Am grateful…
For 7Ah it is around 900ma on the 12v side of the transformer and around 24 amps for the 200 Ah battery, again on the 12v side of the transformer.
Okay,sorry for much questions…
For 7ah battery, how many ampere is the 1uf 400v capacitor allowing to flow to the transformer?
And 200ah?
For 7Ah battery a capacitor of 1uf 400v can be used in series with the 220v side winding of the transformer, and for 200Ah this capacitor can be rated at 25uF 400v. Both should be non polar type.
Yes but I mean if am not to use this circuit maybe I choose to use another circuit designed by me, what capacitor should I use for regulating the current used for charging 12v 7ah battery for example and 200ah battery?
And I will like the capacitor to be at the secondary terminal not the MOSFET terminal. Please help me
Referring to the diagram, it seems we can simply add the capacitor in series with one of the N/O contacts of the secondary side DPDT relay.
However why do we even need a current regulation, because the transformer is already rated correctly to provide the calculated amount of charging current to the battery.
Yes I would prefer using an additional relay changeover stage.
And if I am to use the transformer in charger mode, what will be the value of the capacitor and it’s voltage for restricting the current when charging the battery let say charging a 12v 7ah SLA battery.
I will like you to give me a bench mark for the capacitance value,so that I can be able to change the current used in charging the battery according to my needs
And I will prefer the capacitor to be at the primary terminal (220v side ) in serial line.
Pls help me…
A capacitor can be added neither at the secondary or the primary, because that would restrict the inverter from operating normally in the inverter mode.
You can try the same circuit which is explained in the above, however a current controller cannot be added or maybe it could be added through an additional relay changeover stage.
Okay,
That mean when the primary voltage changes to either high or low , it will be directly proportional to it secondary too ?
If so you once talked about using a capacitor to reduce the current but you said it will be at the secondary,why can’t we use it at the primary??
Pls what other idea is efficient, to use the same transformer for inverter and as battery charger using mosfet body diode like other professional inverters do ?
Hi Davis,
A triac dimmer can be used at the primary of the transformer to control the secondary voltage, however i am not sure how this can be implemented to control current?
Hi… Swagatam
Been awhile making some research about this circuit how about using a AC dimmer circuit? Using a TRIAC at the inverters output to control the secondary current coupled with relays. how possible will it be ? Can you modify the post on this exact topic? Plz I will be very greatfull if you do so…
Okay! , I will try and give a feedback Thank you very much appreciated
God bless you.
The transformer primary can be 0-22V.
If you use a wire link for the current limiting resistor then your inverter will not have the over current protection.
Sorry i forgot mentioning the voltage. is a 24v battery. What will the transformer primary voltage be ?
And can i use wire instead of a shunt resistor at the pin 1of the egs002?
I don’t need current sensing.
Hi David,
It will depend on the voltage connected with the drains of the high side mosfets
https://www.homemade-circuits.com/egs002-datasheet-circuit-diagram-explained/
Hi.. swag
Pls what will my transformer primary voltage be when using an Egs002 card ?
Once again, Thank you.
Am Greatfull
You are most welcome, David.
That’s correct. Adding a separate winding for charging is the best and safest way to go. Appreciate your feedback.
Yes, true
And that’s makes it complex
I think adding a different windings for charging and controlling them with high amps relay would makes things more easy. And make it to be on a safer side
Thank you very much Swag.!!
220V is for the output winding of the transformer (load side). The actual charging voltage is coming from the input side of the transformer which is supposed to be rated at 28V. So the 30 amp is relevant to this 28V side of the transformer, not the 220V side.
Actually, the capacitor cannot be used here, because that would interfere with the normal working of the circuit while in the inverter mode.
No problem David, all the best to you!
I’m a little bit confused here.
You mean 30amps current should be able to flow through the 220vac line ? Or the 28vac line?
Where would the capacitor be placed. at the mains input ? or the the transformers output ? before rectification.
Your battery is rated at 24V 220 Ah so the charging current requirement will be around 30 amps, not 4 amps.
Merry Christmas to you too, in advance. Let me know if you have any further questions.
Yes, that’s right, however the body diode battery charging concept has not been tested by me practically, so please proceed with caution.
Ohh wow…
That means for 4amps current to flow at 220v i will use an 80uf non polarized capacitor ( Code 806) (1uf 50ma) 50ma multiply by 80 = 4,000 (4amps)
Which mean at 220v ac multiply by 4amps = 880w at the transformers output when is at charging mode .
I will use a relay to control the non polar capacitor when needed to charge the battery. Is my calculations correct??
Honestly am so excited for ur kind feedback merry Christmas in advance..
Okay..then,if so i can successfully design my inverter system using Tlp250 gate driver and Sg3524 pwm signal?
A 1uF capacitor allows around 50 ma current, so you can use this benchmark to calculate the total capacitor value for allowing 30 amps. The capacitor must be non-polar.
The gate is separated by the drain and source through a capacitive region, so current cannot flow from drain or source towards the gate.
That’s correct, the inverter then would be around 800 watts.
Drawing more than this current would cause overheating of the transformer or burning.
If my transformer is rated 200amp or 220amps what capacitance can i add in series line of the 220v to bring down the output current to 22amps or 30amps when using the transformer in charging mode ?
Okay!
You mean current won’t be able to flow through 1k resistor causing the mosfet to close and shorting the body diode?
Okay its clear
a 24v 200amps = 4800w battery.
Charging current mode is 28v multiply by 30amps = 840w charger.
Does that means the inverter would be 840w ?
And if so drawing more than 840w from the transformer when loaded on inverter mode would heat up an probably burn out the coil.?
Hi David,
I am not so sure about this working concept, no I can’t suggest much on this topic.
Hi David,
For a 12v battery the charging voltage can be 14v and for 24v battery it can be 28v.
Discharging rate and charging rate are supposed to be identical (0.15C) to ensure long battery life