• 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. save currents in a spectre netlist, run the netlist in batch...

Stats

  • Locked Locked
  • Replies 10
  • Subscribers 126
  • Views 5945
  • 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

save currents in a spectre netlist, run the netlist in batch mode and the currents is saved as instance_name:number

ckseok
ckseok over 15 years ago

To save current into port "A" of instance "IDRIVER", I add the following line in the spectre netlist.

save IDRIVER:A

Then, I run the netlist in batch mode.

After simulation is finished, the result browser shows IDRIVER:2 instead of IDRIVER:A.

How can I make the simulator save current as Instance_name:port_name instead of instance_name:number?

Thank you.

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

    Hi Paul,

    This requires changes to the spectre formatter. The ADE netlisting system has only relatively recently been altered to allow terminal currents to be specified by name - and the spectre formatter does not yet provide a built-in way of doing this - partly this is because of the issue of legacy - you need to be consisent about it everywhere otherwise you might be able to save the signals, but when you plot them it still looks for the name with a position rather than name. Similarly there  may be PDK compatibilty issues too.

    Anyway, here's some code I used to test the enhancement (tidied up a little) - I will point out that I have not thoroughly tested this, so it comes at your own risk. One issue I should point out is that this requires both useterm=names to be set and the change in the formatter. If you do only one of the two, you probably won't be able to plot any currents from ADE (e.g. Outputs->To be  plotted). Loading an ADE state will wipe out the default additionalOptions value set in the code - it's only set for new ADE sessions.

     

    /* abSpectreTermByName.ils

    Author A.D.Beckett
    Group Custom IC (UK), Cadence Design Systems Ltd.
    Language SKILL
    Date Jan 04, 2011
    Modified
    By

    Registers a new formatter to allow currents to be output
    by name from ADE, for subckt pins:

    abRegisterSpectreTermByNameFormatter()

    May need to watch out if useterms=name is used and you are
    using subckt models - in this case the CDF termMapping for the
    devices would need to be adjusted.

    The code sets useterms=name in the additional options for
    Simulation->Options->Analog - however, if you load an existing
    state, this will be overwritten.

    Uses enhancement implemented under CCR 435837 - which appeared
    in IC5141 5.10.41.500.6.137 and IC613 6.1.3.500.13

    ***************************************************

    SCCS Info: @(#) abSpectreTermByName.ils 01/04/11.13:46:23 1.1

    */


    ;------------------------------------------------------------------------
    ; Need to have these contexts loaded - in the right order - so
    ; that the spectreFormatter class can be extended
    ;------------------------------------------------------------------------
    (asiGetTool 'spectre)
    (foreach context '("spectreinl")
    (unless (isContextLoaded context)
    (loadContext
    (prependInstallPath (strcat "etc/context/" context ".cxt")))
    (callInitProc context)
    )
    )

    ;------------------------------------------------------------------------
    ; Define the class for the formatter.
    ;------------------------------------------------------------------------
    (defclass abSpectreTermByNameFormatter (spectreFormatter)
    ()
    )

    /***************************************************************
    * *
    * (abRegisterSpectreTermByNameFormatter) *
    * *
    * Register the formatter with Artist *
    * *
    ***************************************************************/


    (defun abRegisterSpectreTermByNameFormatter ()
    (let (tool)
    (setq tool (asiGetTool 'spectre))
    (asiSetNetlistFormatterClass tool 'abSpectreTermByNameFormatter)
    ;-----------------------------------------------------------------
    ; tell spectre to use terminals by name - note this is only
    ; for new ADE sessions - may have to fill this in by hand if loading
    ; existing states
    ;-----------------------------------------------------------------
    (envSetVal "spectre.opts" "additionalArgs" 'string "useterms=name")
    )
    )

    /****************************************************************
    * *
    * Overload the nlInitialize method for the revised formatter to *
    * turn off the differentFrom parameters for the netlister - *
    * having initialized the standard spectre formatter first. *
    * *
    ****************************************************************/


    (defmethod nlInitialize ((formatter abSpectreTermByNameFormatter))
    (callNextMethod)
    (let ((obj (nlGetNetlister formatter)))
    (nlSetOption obj 'preserveSubcktTermNamesInOrder t)
    )
    formatter
    )

    Best Regards,

    Andrew.

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

    Hi Paul,

    This requires changes to the spectre formatter. The ADE netlisting system has only relatively recently been altered to allow terminal currents to be specified by name - and the spectre formatter does not yet provide a built-in way of doing this - partly this is because of the issue of legacy - you need to be consisent about it everywhere otherwise you might be able to save the signals, but when you plot them it still looks for the name with a position rather than name. Similarly there  may be PDK compatibilty issues too.

    Anyway, here's some code I used to test the enhancement (tidied up a little) - I will point out that I have not thoroughly tested this, so it comes at your own risk. One issue I should point out is that this requires both useterm=names to be set and the change in the formatter. If you do only one of the two, you probably won't be able to plot any currents from ADE (e.g. Outputs->To be  plotted). Loading an ADE state will wipe out the default additionalOptions value set in the code - it's only set for new ADE sessions.

     

    /* abSpectreTermByName.ils

    Author A.D.Beckett
    Group Custom IC (UK), Cadence Design Systems Ltd.
    Language SKILL
    Date Jan 04, 2011
    Modified
    By

    Registers a new formatter to allow currents to be output
    by name from ADE, for subckt pins:

    abRegisterSpectreTermByNameFormatter()

    May need to watch out if useterms=name is used and you are
    using subckt models - in this case the CDF termMapping for the
    devices would need to be adjusted.

    The code sets useterms=name in the additional options for
    Simulation->Options->Analog - however, if you load an existing
    state, this will be overwritten.

    Uses enhancement implemented under CCR 435837 - which appeared
    in IC5141 5.10.41.500.6.137 and IC613 6.1.3.500.13

    ***************************************************

    SCCS Info: @(#) abSpectreTermByName.ils 01/04/11.13:46:23 1.1

    */


    ;------------------------------------------------------------------------
    ; Need to have these contexts loaded - in the right order - so
    ; that the spectreFormatter class can be extended
    ;------------------------------------------------------------------------
    (asiGetTool 'spectre)
    (foreach context '("spectreinl")
    (unless (isContextLoaded context)
    (loadContext
    (prependInstallPath (strcat "etc/context/" context ".cxt")))
    (callInitProc context)
    )
    )

    ;------------------------------------------------------------------------
    ; Define the class for the formatter.
    ;------------------------------------------------------------------------
    (defclass abSpectreTermByNameFormatter (spectreFormatter)
    ()
    )

    /***************************************************************
    * *
    * (abRegisterSpectreTermByNameFormatter) *
    * *
    * Register the formatter with Artist *
    * *
    ***************************************************************/


    (defun abRegisterSpectreTermByNameFormatter ()
    (let (tool)
    (setq tool (asiGetTool 'spectre))
    (asiSetNetlistFormatterClass tool 'abSpectreTermByNameFormatter)
    ;-----------------------------------------------------------------
    ; tell spectre to use terminals by name - note this is only
    ; for new ADE sessions - may have to fill this in by hand if loading
    ; existing states
    ;-----------------------------------------------------------------
    (envSetVal "spectre.opts" "additionalArgs" 'string "useterms=name")
    )
    )

    /****************************************************************
    * *
    * Overload the nlInitialize method for the revised formatter to *
    * turn off the differentFrom parameters for the netlister - *
    * having initialized the standard spectre formatter first. *
    * *
    ****************************************************************/


    (defmethod nlInitialize ((formatter abSpectreTermByNameFormatter))
    (callNextMethod)
    (let ((obj (nlGetNetlister formatter)))
    (nlSetOption obj 'preserveSubcktTermNamesInOrder t)
    )
    formatter
    )

    Best 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