I'm trying to simulate a buck-boost converter where Vin and Vout are constantly changing. As a result, the time it takes to charge/discharge the inductor varies as well, and a voltage source that controls the MOSFETs with a constant frequency won't cut it.
I've been simulating 1 or 2 cycles at a time by disconnecting the voltage source from the circuit after X seconds, but it's not efficient at all. Is there a way to vary the Ton of the voltage source with an equation? Or perhaps a way I can type a list of Ton values in a text box and have the voltage source pick one every cycle?
Thanks!

.param, normally, but with LTspice XVII, RClick on it brings up the new GUI, which I dislike. To circumvent it you need to Ctrl+RClick (as you know), which is a "complication" I also dislike. But it seems that.parmais an accepted mistake (like,instead of.for dot commands), and which has the happy side-effect of bypassing the new GUI. Or use only the first 3 letters,.par,.fun,.opt. Not sure if you know, but apparently these shortcuts exist since the old days of SPICE. But.parlooks crippled, while.parmaresembles the original, so I use.parma. – a concerned citizen Nov 02 '20 at 00:18.subcktwith.finis? Eh, never mind, there's a paper to read... – a concerned citizen Nov 02 '20 at 08:04