• 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 generate spectre netlist for all the schematics in...

Stats

  • Locked Locked
  • Replies 11
  • Subscribers 125
  • Views 17900
  • 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 generate spectre netlist for all the schematics in 1 lib ?

Nhumai
Nhumai over 7 years ago

Hi ,

I would like to generate spectre netlists for all of the schematic cell in my lib. What can I do ? 

I search in the forum but didn't the answer yet 

thanks 

Nhumai 

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 7 years ago

    Hi Nhumai,

    Something like the following (untested) code:

    simulator('spectre)
    lib=ddGetObj("libName")
    foreach(cell lib~>cells
      when(ddGetObj(lib~>name cell~>name "schematic")
        design(lib~>name cell~>name "schematic" "r")
        createNetlist(?display nil)
      )
    )

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Nhumai
    Nhumai over 7 years ago in reply to Andrew Beckett

    Hi Andrew,

    I am new to skill script please help to let me know how to use it ? 

    thanks 

    Nhumai 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 7 years ago in reply to Nhumai

    Hi Nhumai,

    Either take the code above (with the correct library name where it has "libName") and paste it in the Command Interpreter Window (CIW), or probably better to put in a file, save the file, and then in the CIW type:

    load("theScript.il")

    (where "theScript.il" is whatever you've called the file).

    Regards,

    Andrew. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Nhumai
    Nhumai over 7 years ago in reply to Andrew Beckett

    Thanks a lot Andrew it works well :-) . I just ran it 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Nhumai
    Nhumai over 7 years ago in reply to Andrew Beckett

    Hi Andrew,

    If I want to create a master schematic which contain all of the cells in 1 lib what can I do ? 

    of course I can create it by hand but it will cost a lot of time. I have a lib of couple hundred cells. 

    I just realize that it would be better if I can have all the leaf cells netlists in 1 file. 

    thanks a lot 

    Nhumai 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 7 years ago in reply to Nhumai

    You'd need to create the schematic using dbOpenCellViewByType, and then open the master for each symbol using dbOpenCellViewByType, create an instance for each with dbCreateInst (probably taking care that they don't overlap) and then (assuming you don't need to wire them up) call schCheck() and dbSave() to make it netlistable.

    I'm not going to write the code for you - it's a good exercise for you to learn how to do this (I don't have time anyway - I'm travelling this week and have meetings today).

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Nhumai
    Nhumai over 7 years ago in reply to Andrew Beckett

    Hi Andrew,

    thanks a lot for your hint. Do you know where I can download the basic tutorial for skill ? 

    thanks 

    Nhumai 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Nhumai
    Nhumai over 7 years ago in reply to Nhumai

    Hi Andrew,

    I searching around the forum and with your suggestion I came up with a code below but it doesn't work 

    Can you help to see what is wrong ?

    thanks 

    Nhumai 

    lib=ddGetObj("tps65rf_std_mvt_9t_nl")

    foreach(cell lib~>cells

      master_cell= "all_stdcell_mvt_9t"

      cv=dbOpenCellViewByType(lib master_cell "schematic" "schematic" "w")

      when(ddGetObj(lib~>name cell~>name "schematic")

        mstr=dbOpenCellViewByType("tps65rf_std_mvt_9t_nl" cell  "symbol" "schematicSymbol" "r")

        dbCreateInst(geGetEditCellView() mstr "I0" 0:0 "R0" 1)

        schCheck(master_cell)

        dbSave(master_cell)

      )

    )

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 7 years ago in reply to Nhumai

    That won't work because:

    1. You are reopening the same cell (master_cell) for each cell, in write mode. This means you would overwrite it each time
    2. Inside the loop you're creating the instance in the result of geGetEditCellView() - this is the currently open schematic (or layout) view in the environment, not the cv that you'd opened earlier. Probably you didn't mean to use geGetEditCellView() but to use cv instead? If you had though, it would have been lost on each iteration.
    3. Had you used cv, all instances would have been given the same name, so the dbCreateInst would have failed for anything other than the first one. If you use "" it will create the instance name automatically.
    4. Also, if cv had been used, all the instances would have been on top of each other - 0:0 is the same origin for everything.

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • SrBraj
    SrBraj over 6 years ago in reply to Andrew Beckett

    I am using a similar code to perform the simulation of all the devices. Currently, the netlist directory is being saved at the default directory <location from where the virtuoso was invoked>/Sim/<cellName>/spectre/schematic/
    I want to save this netlist file to some other location. Could you please tell me the skill api which can save the netlist file to another location?

    • 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