• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC Design
  3. HB Analysis on PLL

Stats

  • Locked Locked
  • Replies 20
  • Subscribers 125
  • Views 23061
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

HB Analysis on PLL

fortune100worse
fortune100worse over 4 years ago

Dear Cadence SpectreRF Experts:

I am running HB analysis on a PLL. PLL reference is 20MHz and its output is 240MHz. Its VCO operates at 480MHz and there is a fixed divide-by-2 at the VCO output and a feedback divider that divides by 12. The total divide ratio is therefore 24. At this stage, I am only interested to have a HB analysis of the PLL to have its periodic steady state.

I use HB analysis and the setting I am using is as attached in the picture. The convergence is achieved and the simulation is successfully finished.

However, the problem is, the PLL output and the feedback divider output are all at 0 and the VCO output is at VDD/2 (about 720mV) from HB td results. The only signal that appears to be periodic is the reference which has a correct period of 1/20MHz. I have attached a picture of the output.

Can you explain why is the outputs (VCO, PLL, and feedback divider) flat at 0?

Thanks!

Br, 

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago

    I rather doubt 50 harmonics would be enough with a divide ratio of 24 - that's only 2 harmonics to represent the VCO output frequency (and you can already see quite a bit of Gibbs effect on the reference clock). However, the first thing I would check is what is going on in the initial transient results (you've saved them). Is the VCO even oscillating? Perhaps it hasn't started properly... (that might explain why the VCO output is flat and the divider output is flat, and also might explain how it managed to converge with rather few harmonics)?

    Is there a particular reason why you want to use harmonic balance for this rather than pss with shooting?

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • fortune100worse
    fortune100worse over 4 years ago in reply to Andrew Beckett

    The VCO is oscillating and the PLL is settling, see below:

    I used PSS HB option, behaved similarly. I used PSS Shooting and it gave non-convergence over and over. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago in reply to fortune100worse

    Can you zoom into a couple of periods of the 240MHz (near the end) and show that?

    Can you also please show the analysis statements from the bottom of the input.scs (paste them here)?

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • fortune100worse
    fortune100worse over 4 years ago in reply to Andrew Beckett

    Below is the analysis statements:

    ----------------------------- 

    simulatorOptions options psfversion="1.4.0" reltol=1e-3 vabstol=1e-6 \
    iabstol=1e-12 temp=175 tnom=27 scalem=1.0 scale=1.0 gmin=1e-12 \
    rforce=1 maxnotes=5 maxwarns=5 digits=5 cols=80 pivrel=1e-3 \
    sensfile="../psf/sens.output" checklimitdest=psf
    hb hb tstab=10u saveinit=yes oversample=[10] fundfreqs=[(20M)]
    + maxharms=[50] errpreset=moderate annotate=status
    modelParameter info what=models where=rawfile
    element info what=inst where=rawfile
    outputParameter info what=output where=rawfile
    designParamVals info what=parameters where=rawfile
    primitives info what=primitives where=rawfile
    subckts info what=subckts where=rawfile

    ----------------------------- 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago in reply to fortune100worse

    OK, oversample of 10 is probably not particularly helpful here - you might need 2 or 4, but it's rare to need beyond that. I would guess you're going to want at least 200 harmonics to capture the edges with some level of fidelity. I'm not that sure why the i_clk_240MHz should be flat in the time domain output from the hb unless the oscillation has died out completely - it's really hard to tell without seeing the example.

    Can you contact customer support?

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • fortune100worse
    fortune100worse over 4 years ago in reply to Andrew Beckett

    I will contact support...

    Just one question: do we need to set an Initial Condition in the oscillator to get oscillation going for the HB? I thought if the HB tan gets going it should be sufficient for the HB?!

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago in reply to fortune100worse

    No - it's clearly oscillating in the transient phase and that is used to determine the starting point for the harmonic balance solution. It's possible however that the harmonic balance solution is not sufficient to sustain the oscillation - which is why I was suggesting increasing the number of harmonics (50 means that the maximum frequency in the circuit is 1GHz, which is clearly nonsense) might help. Having too few harmonics means that you are trying to represent the solution with just the harmonics you've asked for, and that means that circuit state in the frequency domain doesn't match reality - it may iterate towards the oscillation dying out. I'm guessing a bit here, because I don't know what was going on and haven't seen the log file.

    So try increasing the number of harmonics to 200 or 400 to see whether that helps (and reduce oversampling to 2 or 4).

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • fortune100worse
    fortune100worse over 4 years ago in reply to Andrew Beckett

    Well 1G > 2x480M (> Nyquist) so I expected to see at least one tick of output or VCO within the 1/20MHz period. FYI, I used 200 harmonics with 4 oversampling and it converged buy output and VCO were still stuck at 0. Then I tried 500 harmonics with 2 oversampling and it failed convergence. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • ShawnLogan
    ShawnLogan over 4 years ago in reply to fortune100worse

    Dear fortune100worse,

    I am jumping into your post a bit later...but have been monitoring Andrew's good suggestions...I might add a few comments based on my experiences simulating high Q resonator and ring VCO. Please consider these my comments and not necessarily consistent with Andrew's opinions and suggestions!

    fortune100worse said:
    Well 1G > 2x480M (> Nyquist) so I expected to see at least one tick of output or VCO within the 1/20MHz period. FYI, I used 200 harmonics with 4 oversampling and it converged buy output and VCO were still stuck at 0. Then I tried 500 harmonics with 2 oversampling and it failed convergence. 

    I am not sure of the type of VCO you are attempting to simulate in your PLL simulation. However, higher Q based VCO do require some "special" attention - especially with respect to their start-up and HB convergence behavior. A few comments...

    fortune100worse said:
    hb hb tstab=10u saveinit=yes oversample=[10] fundfreqs=[(20M)]
    + maxharms=[50] errpreset=moderate annotate=status

    1. I noticed you have set your errpreset to "moderate". I would suggest using a value of "conservative" for any VCO based on a relatively high Q resonator (such as an LC or quartz resonator) or one in which the accuracy of the frequency of oscillation is important. to you (i..e., even if your VCO is a ring based VCO). This will likely increase the simulation time somewhat, but it is probably more acceptable than waiting for your existing simulation times and seeing no oscillation from your VCO!

    2. From my experience, and especially since your simulation time is 10 us, the default value of the integration timestep defined by your use of an errpreset of "moderate" may not be sufficient to assume start-up. The maximum timestep of your simulation, in turn, sets the bound on the simulator numerical noise which is the mechanism you are using the excite your VCO.and may not be sufficient to assure VCO start-up and convergence in an HB simulation. I recommend forcing a value of maxstep to be 1/100 or 1/200 of the VCO period (or less). Hence, for a 20 MHz based VCO, I might suggest a maxstep of 500 ps or 250 ps or less (1/20 MHz = 50 ns and 50 ns/100 = 500 ps). Check the value your simulation is using in your spectre.out file.

    3.  A final thought...are you using  spectre +aps or spectre ++aps? I might also suggest if you are using spectre ++aps, you use +aps. I have seem some cases where, although it reduces simulation time, the difference in accuracy using ++aps in lieu of +aps can be an issue in precision VCO. If you are not using either +aps nor ++aps (and hence using just spectre), the use of +aps will reduce your simulation time signficantly without a significant loss in simulator accuracy.

    Anyway, a few thoughts that came to mind to possibly provide some help or insight into your issue...hope they do!

    Shawn

    • Cancel
    • Vote Up +1 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago in reply to ShawnLogan
    fortune100worse said:
    Well 1G > 2x480M (> Nyquist) so I expected to see at least one tick of output or VCO within the 1/20MHz period. FYI, I used 200 harmonics with 4 oversampling and it converged buy output and VCO were still stuck at 0. Then I tried 500 harmonics with 2 oversampling and it failed convergence. 

    From this, I think you have a flawed understanding of the importance of harmonics in a harmonic balance simulator. 

    With the shooting approach (Shooting Newton) available in PSS, the simulation solution is essentially a transient (with additional controls to ensure sufficient time steps to guarantee enough spectral accuracy, plus techniques to ensure that the result is periodic and also to accelerate finding the settled steady state). The number of harmonics is an output parameter, and doesn't particularly affect the accuracy of the solution - it just controls how many harmonics you observe in the frequency domain results. Put another way, the analysis will naturally follow the transitions in the output signals (just as transient does) and a high number harmonics simply ensures there are enough points simulated in the period captured in order to ensure that those higher harmonics can be captured with enough fidelity. The solution itself is the time domain simulation and that should handle pretty nonlinear designs. The fact that it doesn't converge is a little odd - but more on that in a moment.

    With the harmonic balance approach available either in pss or hb analyses (the engine is the same; it's just the interface to the engine that is different), the solution is a harmonic series in the frequency domain, represented by the number of harmonics you ask for. For a weakly nonlinear system, you can represent the solution with a small vector of complex harmonic components for each node, and so it can be quite efficient. However, it is very important to ask for sufficient harmonics, because all of the energy in the signals at every node and branch current has to completely be contained within the number of harmonics you've asked for. In other words, asking for 2 harmonics of a square wave frequency is going to massively misrepresent that signal and the energy will spread into places it's not supposed to be. That can lead to significant inaccuracy and strange results (quite often you'd see it fail to converge for any reasonable circuit). As with shooting, the harmonic balance analysis is trying to find the settled steady state performance of the circuit and this means that it can predict a solution a long way away from the initial "guess" that it's given (based on the initial transient results), which could be that that the oscillation has died out (maybe). It does do some occasional points in the time domain (it does an inverse Fourier transform from the frequency domain solution, and re-solves at a set of sample points, oversampled if needed, to take into account the nonlinear components in the circuit), but the primary solution is the frequency domain solution as described by the number of harmonics. you've asked for. For this reason, 50 is definitely too few points.

    Now, there may be other things going on here (and bear in mind I'm rather blind to your actual circuit):

    1. Are you using the oscillator mode of the hb or pss analysis? If so, you should turn it off. A PLL is a driven circuit, not autonomous (i.e. not an oscillator). The fact that it has an oscillator within the circuit is irrelevant, because all that oscillator does is produce a harmonic of the input reference clock - as such, all frequencies should be harmonics of the input frequency (or maybe of a subharmonic of the input frequency - more on that  next). Using oscillator mode on something that isn't an oscillator can lead to non-convergence.
    2. How is your divider implemented? It's a divide by 12 - but are there any lower frequencies within the divider? Remember that with both shooting and harmonic balance, every node in the circuit must be an integer multiple of the fundamental frequency - so if it (say) really divided by 16 and then reset when the divider reached a count of 12, then you'd have 15MHz in the circuit - and so your fundamental would need to be 5MHz (as the greatest common divisor of 20MHz and 15MHz). Getting this wrong would almost certainly cause shooting to fail to converge, but with too few harmonics and harmonic balance it might have ended up killing the oscillator and converging with the oscillator not running (bit of a wild guess here though - I could easily be wrong).

    Regards,

    Andrew

    • Cancel
    • Vote Up +1 Vote Down
    • Cancel
>

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information