• 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. How to Model a Low Pass Filter using VerilogA ?

Stats

  • Locked Locked
  • Replies 4
  • Subscribers 64
  • Views 22011
  • 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

How to Model a Low Pass Filter using VerilogA ?

Kulmani
Kulmani over 4 years ago

I am modelling a LPF using VerilogA which is used in a PLL loop, so effectively i need to convert Current outputs from Charge pump to Filtered Voltage output, i tried modelling using standard RC circuit equation but i doubt that it is the right way as i am hard coding the input from Charge Pump. Can someone please suggest a way to model a Low Pass Filter using verilogA ? It would be a great help.  

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago

    Probably the simplest is to either model an R and a C, or to use the laplace functions to give a s-domain description of the filter. You could use the various filters in rfLib that is shipped with Virtuoso, although note that these are built on the fly as you choose the parameters (this is because of the variable order of the filter; I forget now why it was done that way - maybe it preceded generator support in the language. So you might need to use them and then follow the link to the model within the simulation netlist or spectre.out file when simulating with them to see how they are implemented.

    Regards,

    Andrew

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

    Thank you Andrew. I just modelled the R and C as mentioned by you. It seem to work fine as of now. I have no clue about how to do modelling in s-domain so did not choose that. Would love to know any references for the same, i just read about the laplace_sd and laplace_zp functions, couldn't really figure out if this would give me a time domain output for a transfer function H(s). Also i was unable to find rfLib in my Lib Manager for some reason. Does it comes pre defined in Library Manager like the analoglib or i need to include it in my CDS.lib ? 

    Thank you for your help again. Me and my colleagues Really appreciate your answers.

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

    There are some examples of using these in  The Designer's Guide to Verilog-AMS  (on pages 182, 183 - there are some earlier examples of modelling skin effect). The simplest example is using the _nd form:

    V(out) <+ laplace_nd(V(in),{0,3},{4,0,1});

    which implements:

    Vout(s) =  3s
    ------    ------
    Vin(s)      s2+4

    The coefficients are in the order s0, s1, s2, s3 etc (in increasing power of s) for both the numerator and denominator. The _zp is similar but there you are specifying the poles and zeros (as an s-domain transfer function).

    For rfLib, add this to your cds.lib:

    DEFINE rfLib $(inst_root_with:tools/dfII/bin/virtuoso)/tools/dfII/samples/artist/rfLib

    Regards,

    Andrew

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

    As always it helped Andrew ! I was able to implement a 1st and 2nd order filter using the above function. It required some coefficient tuning as per my R and C and gain but once it was fixed it worked perfectly fine.

    Thank you for making life easy again ! 

    Attaching a link for the explanation of above function for future reference :

    https://help.simetrix.co.uk/8.0/simetrix/mergedProjects/verilog_a_reference/topics/veriloga_verilog_areference_verilog_afunctions.htm#laplacezp  

    Regards,

    Kulmani

    • Cancel
    • Vote Up 0 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