• 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. Mixed-Signal Design
  3. stop & restart clock

Stats

  • Locked Locked
  • Replies 6
  • Subscribers 64
  • Views 6953
  • 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

stop & restart clock

Charanraj Mohan
Charanraj Mohan over 8 years ago

Hi,

Just a question. Can b silly. How to stop the clock and start again in a transient time ?? Say, the whole clock time has same period, pulse width, tr, tf, td. I can do it in Vpwl, but the clock I am planning has more cycles :(

Thanks in advance.

  • Cancel
Parents
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    One way would be to use a bit source (so use source from analogLib and set the type to be "bit"). You can then either define a sequence of 1 and 0 values, along with the values these correspond to, rise times, periods and so on, or you can reference a "pattern" which could be defined in an include file. See "spectre -h pattern" and "spectre -h vsource". The pattern allows nested patterns with repetitions - so you could define a fairly complex sequence simply:

    // example of using pattern to simply define a clock pulse that
    // is enabled for 50 periods, then off for 20 periods, then on for another
    // 17 periods

    parameters clkFreq=1M

    clk50 pattern data="10" rpttimes=49 // means 50 total
    off20 pattern data="00" rpttimes=19 // means 20 total
    clk17 pattern data="10" rpttimes=16 // means 17 total

    vclk (clk 0) vsource type=bit data="00,clk50,off20,clk17,0000" val0=0 \
    val1=1.8 rise=.1n fall=0.1n period=1/(clkFreq*2)

    tran tran stop=(50+20+17+3)*1/clkFreq

    Here's what it ends up looking like:

    Hope that helps!

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    One way would be to use a bit source (so use source from analogLib and set the type to be "bit"). You can then either define a sequence of 1 and 0 values, along with the values these correspond to, rise times, periods and so on, or you can reference a "pattern" which could be defined in an include file. See "spectre -h pattern" and "spectre -h vsource". The pattern allows nested patterns with repetitions - so you could define a fairly complex sequence simply:

    // example of using pattern to simply define a clock pulse that
    // is enabled for 50 periods, then off for 20 periods, then on for another
    // 17 periods

    parameters clkFreq=1M

    clk50 pattern data="10" rpttimes=49 // means 50 total
    off20 pattern data="00" rpttimes=19 // means 20 total
    clk17 pattern data="10" rpttimes=16 // means 17 total

    vclk (clk 0) vsource type=bit data="00,clk50,off20,clk17,0000" val0=0 \
    val1=1.8 rise=.1n fall=0.1n period=1/(clkFreq*2)

    tran tran stop=(50+20+17+3)*1/clkFreq

    Here's what it ends up looking like:

    Hope that helps!

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

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