• 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. Allegro X Capture CIS
  3. Problem with TCL code to change pintype on symbol within...

Stats

  • State Verified Answer
  • Replies 4
  • Subscribers 42
  • Views 5196
  • Members are here 0
More Content

Problem with TCL code to change pintype on symbol within a schematic

gvellet
gvellet over 2 years ago

I have imported a schematic from Mentor Pads into Orcad Capture. The discrete symbols created have the wrong pintype and there are a lot of them. For the all discrete  symbol, I need to change the pintype value to "passive". I want to do it using a TCL script. My TCL is able to scan through all the symbol instances, and read the pintype value using the method GetPinType. However when it attempts to change the pintype value with method "SetPinType", nothing happen. I wonder if someone could help me debug my tcl code (See attach zip file)

Thank you

pin_test.zip

  • Cancel
  • Sign in to reply
Parents
  • CadAP
    0 CadAP over 2 years ago

    HI Gvellet.

    SetPinType(pinType) : returns DboState, will not work for the part placed on the schematic. Because on schematic level part/symbol pin type cannot be changed.

    Part can be edited in symbol editor.

    You need edit the part and update current(cache) will work.

    Hope this helps!

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • gvellet
    0 gvellet over 2 years ago in reply to CadAP

    Hi CadAP,

    OK I understand that I have to work on the library then do update current cache in the schematic. Can you help on how to make a script which work on an opened symbol library, it would iteratively edit all the symbols, then iteratively change the pintype of all their pins. Then I will add some intelligence to select only a set of specific symbols.

    Thank you for your time,

    gvellet

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Reply
  • gvellet
    0 gvellet over 2 years ago in reply to CadAP

    Hi CadAP,

    OK I understand that I have to work on the library then do update current cache in the schematic. Can you help on how to make a script which work on an opened symbol library, it would iteratively edit all the symbols, then iteratively change the pintype of all their pins. Then I will add some intelligence to select only a set of specific symbols.

    Thank you for your time,

    gvellet

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Children
  • CadAP
    +1 CadAP over 2 years ago in reply to gvellet

    Hi Gvellet,

    I have added below in your script to access the library part to modify it.
    #Convert PartInst to PlacedInst
    set lPlacedInst [DboPartInstToDboPlacedInst $lInst]
    #Get DboLibPart from the Placed Inst
    set lPart [$lPlacedInst GetPart $lStatus]
    set lpinIter [$lPart NewPinsIter $lStatus]
    delete_DboSymbolPinsIter $lpinIter

    Attaching the modified script(pin_test.7z) working to change the pintType.

    https://community.cadence.com/cfs-file/__key/communityserver-discussions-components-files/109/pin_5F00_test.7z

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Reject Answer
    • Cancel
  • gvellet
    0 gvellet over 2 years ago in reply to CadAP

    You surprised me with a solution that works in the schematic without having to edit the library files.

    Thank you very much.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Cadence Guidelines

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