• 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. how to pass array of parameters through CDF down to a verilogA...

Stats

  • Locked Locked
  • Replies 11
  • Subscribers 127
  • Views 22705
  • 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 pass array of parameters through CDF down to a verilogA code?

naderi
naderi over 13 years ago

 Hello all,

 Is there any way to pass an array of parameters down to a verilogA code?

if I put following statement in a verilogA sub-circuit.

parameter real vdc[3:0] ={0,0,1,0};

Then {0, 0, 1, 0} appears in CDF parameters for vdc. However, spectre complains later during circuit read-in.The error message is :

 Error found by spectre during circuit read-in.
    ERROR (SFE-874): "input.scs" 1087: Unexpected block statement "{".

I realized if I enter the parameters within double-qoute as "{0, 0, 1, 0}" at CDF, then spectre will be happy and goes for simulation, but the results are incorrect.

 

I wonder if there is any solution?

Thanks,

Ali

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

    Ali,

    You misunderstood. The VerilogA code needs to use {0,0,1,0} syntax, but in the CDF you'll need to define the default as [0 0 1 0] (no commas, although commas are tolerated at the moment - but you get a warning about them not being supported in the future). Also, when you instantiate the block, with a different value, you'd need to specify it with square brackets. To illustrate what I mean, here's some VerilogA:

     `include "disciplines.vams"

    module blah (op,ip);

    output op;
    input ip;
    electrical op,ip;

    parameter real vdc[3:0]={0,0,1,0};

    analog begin

       V(op) <+ vdc[2]*V(ip);

    end

    endmodule

    and here's the corresponding spectre netlist:

     //

    I1 (o1 i1) blah vdc=[2 2 2 2]

    v1 (i1 0) vsource type=sine freq=1M ampl=1

    ahdl_include "blah.va"
    tran tran stop=2u

     

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

    Ali,

    You misunderstood. The VerilogA code needs to use {0,0,1,0} syntax, but in the CDF you'll need to define the default as [0 0 1 0] (no commas, although commas are tolerated at the moment - but you get a warning about them not being supported in the future). Also, when you instantiate the block, with a different value, you'd need to specify it with square brackets. To illustrate what I mean, here's some VerilogA:

     `include "disciplines.vams"

    module blah (op,ip);

    output op;
    input ip;
    electrical op,ip;

    parameter real vdc[3:0]={0,0,1,0};

    analog begin

       V(op) <+ vdc[2]*V(ip);

    end

    endmodule

    and here's the corresponding spectre netlist:

     //

    I1 (o1 i1) blah vdc=[2 2 2 2]

    v1 (i1 0) vsource type=sine freq=1M ampl=1

    ahdl_include "blah.va"
    tran tran stop=2u

     

    • 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