How to measure rin/rout using spectre?

Discussion in 'Cadence' started by Erik Wanta, Sep 8, 2003.

  1. Erik Wanta

    Erik Wanta Guest

    I have a simple bjt diff pair. I know that I can run spectre with the
    SP analysis and get Z11 for the input impedance, but I was wondering
    if there is a way that I can get the input impedance with the XF
    analysis as I can with .TF in hspice. Any ideas?
    ---
    Erik

    From: Andrew Beckett ()
    Subject: Re: How to measure rin/rout using spectre?
    View: Complete Thread (2 articles)
    Original Format
    Newsgroups: comp.cad.cadence
    Date: 2002-03-20 09:14:57 PST

    Hi Vincent,

    I'm not entirely certain what it is you're trying to do, but spectre's
    "sp" analysis (S parameter) analysis is probably the analysis for the
    job. Read up on this in cdsdoc/openbook.

    Regards,

    Andrew.
     
    Erik Wanta, Sep 8, 2003
    #1
  2. You can certainly get the input/output impedance and gain using xf analysis:


    //

    r1 ( 1 2 ) resistor r=1K
    r2 ( 2 0 ) resistor r=500

    #ifndef INPUT
    v1 ( 1 0 ) vsource dc=1
    #endif

    #ifdef INPUT
    analysisTF2 (1 0) xf stimuli=nodes_and_terminals save=lvl nestlvl=1
    #else
    analysisTF1 (2 0) xf stimuli=nodes_and_terminals save=lvl nestlvl=1
    #endif

    With this example, if you do:

    spectre -E testtf.scs

    you'll get xf results for node 2 which gives 333.3 V/A (i.e. ohms), and v1:p
    which is 0.333 (i.e. the gain).

    spectre -E -DINPUT testtf.scs

    You'll get xf results for node 1 which gives 1500 V/A. You need to
    do an analysis with the xf back to the input, but with the input source removed
    (because otherwise this shorts out the input being a zero-impedance source).

    Now this is only true in a simple case as shown as above. If there's no direct
    coupling between the input and output, and you don't want to find the gain, you
    can do two XF analyses, and not have a source at the input.

    Or of course you could do an sp analysis.

    Andrew.
     
    Andrew Beckett, Sep 10, 2003
    #2
  3. Erik Wanta

    Erik Wanta Guest

    Andrew:
    You mentioned the use of compiler directives. I have PCR 574128 open
    to allow me to specify compiler directives in artist. I am able to
    specify spectre command line options from Setup->Environment
    userCmdLineOption in IC 50 33. I probably would have called the label
    User Command Line Option instead of userCmdLineOption, but that is
    minor.

    I really want to give veriloga compiler directives. How do I give
    veriloga compiler directives (not spectre compiler directives (I
    thought they were the same))? I put -DTEST in the userCmdLineOption
    field, but the following code doesn't pick it up. That is, it doesn't
    set xx=1.

    `include "constants.h"
    `include "disciplines.h"

    module deftest;

    integer xx;

    `ifdef TEST
    xx=1;
    `endif

    analog begin

    $strobe(xx);

    if(xx==1)
    $strobe("%d",xx);
    end
    endmodule
     
    Erik Wanta, Sep 13, 2003
    #3
  4. Erik,

    PCR 646399 was filed recently by R&D to get the prompt changed to something
    a little more readable.

    As for the verilog-a problem, it doesn't use the C preprocessor - it's
    effectively a verilog preprocessor (since it uses ticks instead of hashes), and
    I don't believe there is a way of controlling the definitions from the command
    line (as there is with verilog/ncvlog etc). That would be a good enhancement
    though - either it could just take the cpp -D arguments and use those, or
    have another argument. Anyway, I suggest you go through your normal
    customer support route and request this.

    Regards,

    Andrew.
     
    Andrew Beckett, Sep 15, 2003
    #4
  5. Erik Wanta

    Erik Wanta Guest

    Andrew:
    FYI
    SR32574184 PCR647059
    ---
    Erik

     
    Erik Wanta, Sep 17, 2003
    #5
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.