• 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 Scripting - TCL
  3. How to get pin position and location?

Stats

  • State Suggested Answer
  • Replies 8
  • Answers 1
  • Subscribers 13
  • Views 1487
  • Members are here 0
More Content

How to get pin position and location?

Morgan
Morgan 3 months ago

Hi friends of the community,

After select one Symbol on Page with Capture CIS, How to get all pin position(Top, Bottom, Left, Right), and pin location (X,Y) to place wire, use TCL?

  • Sign in to reply
  • Cancel
  • CadAP
    0 CadAP 3 months ago

    Hi Morgan,

    Below api will help you to get X and Y position of hotspot where we connect wire.

    Once you have hotspot of pin use that coordinate to draw wire using first point (x,y ) of pin hotspot.

    DboPortInst_sGetHotSpotX(obj, status) : returns int
    Parameters:
    obj: DboBaseObject *
    status: DboState &
    DboPortInst_sGetHotSpotY(obj, status) : returns int
    Parameters:
    obj: DboBaseObject *
    status: DboState &

    Hope it helps.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • Morgan
    0 Morgan 3 months ago in reply to CadAP

    Thank you, CadAP, Now the question becomes:

    1. What value should be give to variable obj?

    2. How to get pin position on the Symbol, such as Top, Bottom, Left or Right?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • CadAP
    0 CadAP 3 months ago in reply to Morgan

    Hi Morgan,

    1. What value should be give to variable obj?

    Ans: Pin dbid. you can get the pin dbid and pass that as argument to the above api.

     

    2. How to get pin position on the Symbol, such as Top, Bottom, Left or Right?

    Ans: Why you need pin position any specific reason, because i don't see any direct api for it.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • Morgan
    0 Morgan 3 months ago in reply to CadAP

    Hi CadAP,

    1.When I use code: $portInst GetId $lStatus, get the pin ID, and pass it to DboPortInst_sGetHotSpotX, it error;

    2.Get pin position to place wire, if the pin is on Top, the wire will go to top from pin hotspot; if the pin is on right, the wire will go to right from pin hotspot, so must know the pin position on the Symbol.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • CadAP
    0 CadAP 3 months ago in reply to Morgan

    Hi Morgan,

    1.When I use code: $portInst GetId $lStatus, get the pin ID, and pass it to DboPortInst_sGetHotSpotX, it error;

    Ans: DboPortInst_sGetHotSpotX $portInst $lStatus -- correct command.

    2.Get pin position to place wire, if the pin is on Top, the wire will go to top from pin hotspot; if the pin is on right, the wire will go to right from pin hotspot, so must know the pin position on the Symbol.

    Ans: Need to create a script to get pin position. I'll create a sample and share it with you.

    • 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