Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Simulating a hysteretic buck converter?

Status
Not open for further replies.

Flyback

Well-Known Member
Hello,
The below is the schematic of my attempt at doing a simulation of a hysteretic buck converter.(LED driver)
The idea is that one comparator will turn off the FET when the inductor current reaches the peak, and the other comparator will turn the FET ON when the inductor current reaches the trough.
However, unfortunately, it doesn't work, as a little "glue" logic is needed, and I haven't quite got this right yet.
Do you know how I can make this work?
schematic and LTspice simulation attached
 

Attachments

  • Hysteretic buck.pdf
    22.3 KB · Views: 386
  • Hysteretic buck.txt
    8.1 KB · Views: 266
  • Hysteretic buck.asc
    7.8 KB · Views: 323
That circuit seems rather complicated. Why not just use one of the ICs designed for hysteretic converters?
 
I am trying to get the simulation going so I can show it on a course.

Here is a fairly working version, but it is noisy, with sometimes uneven switching.
Do you know how to get rid of the noise in this new circuit below? (otherwise it works quite well)
The comparators have "L" inputs which latch their output.

Simulation and schematic attached
 

Attachments

  • Hysteretic buck1.pdf
    21 KB · Views: 365
  • Hysteretic buck1.txt
    7 KB · Views: 298
  • Hysteretic buck1.asc
    6.7 KB · Views: 298
One thing I noticed is that D5 has a short across it. I assume that's an error?
 
Hi,
Thanks, Yes, though it seems to work anyway....here is the corrected schem and sim (ltspice)
 

Attachments

  • Hysteretic buck2.pdf
    21.2 KB · Views: 342
  • Hysteretic buck2.asc
    7 KB · Views: 298
Now D6 is redundant since it is in parallel with D5.

Your problem with uneven switching appears to be a simulation anomaly. If you add a value of 5us or so to the Maximum Timestep option in the Simulation Command window, the switching becomes even (looking at the inductor current).
 
thanks, but I just made the "maximum timestep " equal 5u (it was blank before), and it made no difference
 
I like hysteretic converters. Most of the time I must have fixed frequency which hysteretic is not.
**broken link removed**
**broken link removed**
 

Attachments

  • slyt391.pdf
    600.1 KB · Views: 549
Thanks, RonSimpson, I think the powerint.com LNK switches beat those kind of low power bucks that the app note in your thread shows.

still trying to get the two comparator hysteretic buck simulation working non noisily.
I have a one comparator hysteretic buck simulation working fine, but with just the one comparator, its not quite as accurate over line and vout changes
 
Last edited:
A constant off time controller and a hysteretic are closely related.

My first controllers were "voltage" mode. The controller only watched the output voltage. If the input voltage jumped 2X the error amp did nothing until the output voltage was wrong. Then the error amp started to slowly walk over to a new duty cycle.

Years later when the UC3842 came out, it watched the current on every stroke. A 2x jump in input voltage caused a instant change in duty cycle with out the error amp needing to respond. (very nice) It also had good short circuit protection. The on-time is set by (InVoltage * Time).

With hysteretic we have (InVoltage * Time) and (OutVoltage * Time). Because Vout is constant, a constant off time controller is (approximately) the same thing.

Years ago, a controller that varied duty cycle by errors in output voltage was all we had. (better than linear)
A controller that directly responded to 'input power' (with out the error amp) was a major jump.
I have built controllers that watch output current and respond. (without the error amp)
Now there is more than duty cycle. (on time, off tine, frequency, phase, etc)
 
Here's a screen shot of my simulation with a 5us Maximum Timestep. The inductor current seems quite uniform. Do you not see that in your simulation?

Hysteretic Buck2.gif
 
No, my inductor current, with 5us max timestep , is as follows..
2uj6tc5.jpg




.tran 0 100m 0 5u startup

...this is the command I have used in LTspice....I cant see if it is the same as yours
 

Attachments

  • induc hyst.jpg
    induc hyst.jpg
    103.6 KB · Views: 311
Yes, that command is identical to mine.

I did notice that your ripple frequency is much higher than my simulation. Have you changed the circuit from the one I downloaded?

Try reducing to Maximum Timestep to 1us and see if that helps.
 
yes I changed it from 1mh inductor to 100uh.......I originally changed to 1mh to see if it stopped the noisiness, but it didn't.
I tried 1us max timestep and it is certainly better, though not as nice as the single comparator case, which I attach here in LTspice
 

Attachments

  • Hysteretic buck _1 c'tor.asc
    4.9 KB · Views: 313
Okay. Try 0.1us. That seems to work well with 100uH in my simulation.
 
Works well! Thanks! You're a genius, How you knew that waveform anomaly was a feature of the simulator , and not of the circuit etc, I do not know.
 
...............How you knew that waveform anomaly was a feature of the simulator , and not of the circuit etc, I do not know.
No magic. I've done a lot of simulations and I've seen similar types of anomalies before where a waveform is unstable or has distortion that don't seem normal for the circuit. So then I tried, somewhat randomly, changing some of the simulation parameters until I found one that gave a proper display. In cases such as this, normally the timestep is determined automatically by the program to minimize simulation time, which usually is fine, but for some reason with certain types of circuits it picks timesteps that are too long, causing unstable or distorted waveforms. So you then reduce the maximum timestep manually until the waveform looks normal. But if you reduce the maximum too much, the simulation time starts to increase, so that's why you don't always want to put a short value in for the timestep.
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top