LTspice transformer and buck converter

I am trying to simulate an efficient circuit to take 120 V AC at 60 Hz and convert it to 5 V, 5 A. I have a transformer and rectifier circuit to get the 120 V down to about 12.6 V DC and I made a buck converter to take the 12.6 V to 5 V.

The circuits work fine when separate, but when I combine the two it doesn't work, the transformer seems to drop the output to less than 10 V.

I don't understand why, because then I can't get the math to work for either circuit.

I was using the LC3636 in these simulations but I was having the same problem were the chip would work fine connected to a 12.6 V DC source but when connected to the rectifier it would just fall apart.

Please help if you are able to. Also I should add that the buck converter with the DC power supply is 90% efficient, but when I adjust the values (guessing and checking to make the whole circuit "work") the efficiency drops to around 50%.

• It might be educational to look at your V2n and Vrectifier nodes. With 5V, 5A out, if Vin is 12V you're pulling about 2A from the "transformer" section. That means that R6 will drop about 1.5V, and your bridge rectifier will drop around 1.2V. Moreover, I think you may be assigning a too-low inductance to the transformer (but I could be wrong -- and V2n will tell you that). Nov 7, 2022 at 1:16
• Is there any reason why you would not just purchase (or design and build) a 120 VAC to 5V 5A switching supply? Nov 7, 2022 at 2:10
• Unless I am wrong, the rectifier block can't supply 12V (only 5V de facto) with 2A after 0.75 Ohm. Nov 7, 2022 at 8:10
• @TimWescott is right (the comment could be better used as an answer). I'll just add that, since you've already used a model for M1, you should also use one for D1, and D2 is not needed since the .model has a built-in antiparallel diode. That can be disabled with is=0 though, and then you can use the external diode with the vp parameter, which the VDMOS doesn't have. Also, your .tran card doesn't make sense: the total simulation time is 0.5 s and the timestep is 1 s? Try .tran 5m; increase if needed. For tight(er) timestep use .tran 0 5m 0 0.1u. No need for uic. Nov 7, 2022 at 8:32
• @Nemo11 That's true but, you can also use the source as a cosine (phase -90) and you can add an .ic i(l1)=0, which will make the output start at maximum, save the initial step response due to the derivative and the initial voltages on the capacitor(s) (which can also be set either through the .ic or with their own ic=<...> values). Example. Nov 7, 2022 at 15:15