• 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. Request for Support with CDF Update Issue after importing...

Stats

  • Replies 5
  • Subscribers 130
  • Views 110
  • Members are here 0

Request for Support with CDF Update Issue after importing .spi file in virtuoso

yogeshjaiswalCAD
yogeshjaiswalCAD 4 hours ago


Greetings Andrew & Aurel,

I hope you’re having a wonderful start to the new year! I’m reaching out for your assistance with a CDF update issue.

Thanks for always being there for help..

Problem Statement:

I imported several library .spi files as schematics using the "Import .spi file" option in Cadence Virtuoso. After the import, I noticed that a specific parameter (CDF) of a transistor was not updated.

I have checked the original libaray & imorted libarary , there is a clear mismatch of  Wfg parameter. 

For example

Clean library :

CDF parameter of mos

Wfg = 140  nm

w    =   140 nm

Imported .spi  library :

CDF parameter of mos

Wfg = 100  nm

w    =   140 nm

my skill code for CDF update 

let((libName cdfId oldParam)
libName = "STD_CELL_SPI"
foreach(cell ddGetObj(libName)~>cells
cdfId = cdfGetBaseCellCDF(cell)
when(cdfId
;; Use cdfFindParamByName to locate "Wgf"
oldParam = cdfFindParamByName(cdfId "Wfg")
when(oldParam
;; Create "w" and transfer ALL necessary attributes
cdfCreateParam(cdfId
?name "w"
?prompt oldParam~>prompt
?defValue oldParam~>defValue
?type oldParam~>paramType
?display oldParam~>display
?callback oldParam~>callback
?units oldParam~>units
?choices oldParam~>choices ; Added: essential for cyclic/radio
?parseAsNumber oldParam~>parseAsNumber
?parseAsCEL oldParam~>parseAsCEL
)

;; Correct way to delete: cdfDeleteParam is valid if defined,
;; otherwise parameters are typically managed via cdfId~>parameters
cdfDeleteParam(oldParam)

;; Save the base CDF changes to disk
cdfSaveCDF(cdfId)
printf("Updated %s: Wfg changed to w\n" cell~>name)
)
)
)
)

Could you please share the Skill code or method to update the Wfg parameter to 'w'? This will ensure that the total width of the transistor is set to the width of the finger, as this discrepancy is causing an LVS issue in the imported cell from the .spi file.

I will be grateful for your help. Please help in !

Thank you for your help!

With Warm Regards & Cheers,

Yogesh Jaiswal

  • Cancel
  • Sign in to reply
Parents
  • RobMan
    RobMan 4 hours ago

    Hi Yogesh,

    Please ensure enable trigger callback in the 'Input' tab...

    Rob.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • yogeshjaiswalCAD
    yogeshjaiswalCAD 4 hours ago in reply to RobMan

    Thank you, RobMan.

    I did that in the first place while importing the .spi file, but the problem persists.

    If you can suggest some skill code modifications or share your skill code, that would be a great help!

    Thanks again,

    Cheers!

    Yogesh

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • RobMan
    RobMan 4 hours ago in reply to yogeshjaiswalCAD

    Andrew has written some code to trigger the callbacks...

    How to call CDF callbacks procedurally from SKILL to update CDF parameters?

    In this instance though it's unclear on what the dependency might be. If you tweak the 'w' (e.g. 150) on the schematic does the 'Wfg' update?

    Rob.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • yogeshjaiswalCAD
    yogeshjaiswalCAD 4 hours ago in reply to RobMan

    Rob,Thank you for your help.

    However, I'm still facing the same problem. I would appreciate it if Andrew and Aurel could also provide their insights on the cause and potential solutions.

    If you could help fix the skill code I've written, that would be a big favour.

    For example

    Clean library :

    CDF parameter of mos

    Wfg = 140  nm

    w    =   140 nm

    Imported .spi  library :

    CDF parameter of mos

    Wfg = 100  nm

    w    =   140 nm

    My skill code for CDF update 

    let((libName cdfId oldParam)
    libName = "STD_CELL_SPI"
    foreach(cell ddGetObj(libName)~>cells
    cdfId = cdfGetBaseCellCDF(cell)
    when(cdfId
    ;; Use cdfFindParamByName to locate "Wgf"
    oldParam = cdfFindParamByName(cdfId "Wfg")
    when(oldParam
    ;; Create "w" and transfer ALL necessary attributes
    cdfCreateParam(cdfId
    ?name "w"
    ?prompt oldParam~>prompt
    ?defValue oldParam~>defValue
    ?type oldParam~>paramType
    ?display oldParam~>display
    ?callback oldParam~>callback
    ?units oldParam~>units
    ?choices oldParam~>choices ; Added: essential for cyclic/radio
    ?parseAsNumber oldParam~>parseAsNumber
    ?parseAsCEL oldParam~>parseAsCEL
    )

    ;; Correct way to delete: cdfDeleteParam is valid if defined,
    ;; otherwise parameters are typically managed via cdfId~>parameters
    cdfDeleteParam(oldParam)

    ;; Save the base CDF changes to disk
    cdfSaveCDF(cdfId)
    printf("Updated %s: Wfg changed to w\n" cell~>name)
    )
    )
    )
    )

    I will be grateful for your help. Please help in !

    Thanks!

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Reply
  • yogeshjaiswalCAD
    yogeshjaiswalCAD 4 hours ago in reply to RobMan

    Rob,Thank you for your help.

    However, I'm still facing the same problem. I would appreciate it if Andrew and Aurel could also provide their insights on the cause and potential solutions.

    If you could help fix the skill code I've written, that would be a big favour.

    For example

    Clean library :

    CDF parameter of mos

    Wfg = 140  nm

    w    =   140 nm

    Imported .spi  library :

    CDF parameter of mos

    Wfg = 100  nm

    w    =   140 nm

    My skill code for CDF update 

    let((libName cdfId oldParam)
    libName = "STD_CELL_SPI"
    foreach(cell ddGetObj(libName)~>cells
    cdfId = cdfGetBaseCellCDF(cell)
    when(cdfId
    ;; Use cdfFindParamByName to locate "Wgf"
    oldParam = cdfFindParamByName(cdfId "Wfg")
    when(oldParam
    ;; Create "w" and transfer ALL necessary attributes
    cdfCreateParam(cdfId
    ?name "w"
    ?prompt oldParam~>prompt
    ?defValue oldParam~>defValue
    ?type oldParam~>paramType
    ?display oldParam~>display
    ?callback oldParam~>callback
    ?units oldParam~>units
    ?choices oldParam~>choices ; Added: essential for cyclic/radio
    ?parseAsNumber oldParam~>parseAsNumber
    ?parseAsCEL oldParam~>parseAsCEL
    )

    ;; Correct way to delete: cdfDeleteParam is valid if defined,
    ;; otherwise parameters are typically managed via cdfId~>parameters
    cdfDeleteParam(oldParam)

    ;; Save the base CDF changes to disk
    cdfSaveCDF(cdfId)
    printf("Updated %s: Wfg changed to w\n" cell~>name)
    )
    )
    )
    )

    I will be grateful for your help. Please help in !

    Thanks!

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Children
  • Andrew Beckett
    Andrew Beckett 3 hours ago in reply to yogeshjaiswalCAD

    First of all, this is a community forum, so asking for a response (in your initial post) from specific forum members is a bit presumptuous (I'm on vacation too). Secondly, I would have given exactly the same answers as Rob did.

    Your code will not do what you want, as it is creating a new CDF parameter in the Base CDF itself. That's not your issue, and so your code is completely inappropriate. It's not a matter of fixing it but throwing it away altogether.

    The right answer is one of the approaches that Rob suggested. You didn't give any specific information about what the SPICE file looked like, what mapping you used, or which PDK you're using. However, I wonder whether there is an order dependency in the CDF callbacks. If so, try choosing the "For all parameters specified on the instance line" checkbox on SPICE IN (shown in Rob's screenshot above), or using the ?order argument to CCSinvokeCdfCallbacks to limit the callbacks to call (say) just "w" it might be calling the callback for Wfg first which then sets w from Wfg). You gave no information about what happened when you tried either approach earlier or exactly what you tried.

    OK, back to vacation time...

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • 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