• 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. PCB Design
  3. Variant Mode in TCL scripting

Stats

  • Locked Locked
  • Replies 1
  • Subscribers 164
  • Views 14734
  • Members are here 0
More Content
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

Variant Mode in TCL scripting

Loic TCL
Loic TCL over 11 years ago
Hello there, 

For several months now, my mission is to create TCL / Tk scripts in OrCAD Capture to have new tools to automate various tasks related to the design of schematics. However, today I am facing a problem on one of my scripts. 

The goal of the script: This script has the specific objective of creating a "manufacture file" in relation to an OrCAD Capture design. This one allows to find out information on all components of a same design that will be useful in the manufacture of the card. Today, I can well retrieve all the necessary informations on all the components of my design. 

How it works: My script path all the design and retrieve various properties of all instances and occurrences. 

The problem: As we use "Variant Mode", it happens that some components become unmounted (gray on the design). In this case we wouldn't want them to appear in the "manufacture file". And here is my problem, I can't recover through TCL commands any information that would allow me to deduct my component is unmounted, allowing me to make sure it is not treated. 

I already know the documentation "OrCAD Capture TCL / Tk Extensions" which contains various commands available but I haven't found one that might interest me. 

The tracks I'm trying to explore without success: 
  •  When a component is unmounted and I look at its Orcad properties (double-click), some values ​​appear in "NC" and if the component is mounted another value appears. I can well recover the values ​​associated with all properties of the components, but I don't get the "NC" value when the component is unmounted. I get the same value that if the component was mounted. 
  • In the same way, I try to retrieve the color symbol for each component (the mounted component appears in blue and unmounted in gray). But again, if the component is mounted or not I always gets the same color code (48). 
  • Finally, I found a function "IsActiveVariant ()" in the guide "OrCAD Capture TCL / Tk Extensions". This feature seems to be interesting if I could apply it to my instance (or occurrence) and it turned me if the component is "active" or not used in the current variant mode. Unfortunately, I did not manage to make it work because it is applied to an object of type "CISVariantPartOBJ (CISBase)" and I don't know how to get. 
So, I can't differentiate a mounted an unmounted component by these methods. Can you give me your help?
I hope that I was clear enough on explaining my problem and I am at your disposal for any further information. 

Best regards.
  • Cancel
Parents
  • oldmouldy
    oldmouldy over 11 years ago

    Take a look at the sample code in <install_dir>\tools\capture\tclscripts\capCustomSamples\capCIS.tcl this provides examples of using the CIS TCL commands, note that you will need to have run the Part manager at least once in the CIS session to get the CIS TCL environment initialized.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • oldmouldy
    oldmouldy over 11 years ago

    Take a look at the sample code in <install_dir>\tools\capture\tclscripts\capCustomSamples\capCIS.tcl this provides examples of using the CIS TCL commands, note that you will need to have run the Part manager at least once in the CIS session to get the CIS TCL environment initialized.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data
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.

© 2026 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information