• 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 PCB Editor
  3. PIN select issue

Stats

  • Replies 7
  • Subscribers 159
  • Views 14508
  • Members are here 0
More Content

PIN select issue

catalineacsu
catalineacsu over 9 years ago

Hello,


I am working on a skill that generates a report with vias in pad but I am having problems using the single select function. It selects pins that are not overlapping the via but instead are 20 mils away. When I am running running the code line by line it works fine. If anyone spots a mistake please let me know. Or a workaround better than axlSingleSelectBox, which works better but not perfect...

The logic behind it is:

1. turn on vias and pads on one side of the pcb

2. select all visible vias

3. parse the list and select the pins overlapping the center of the via

4. report the result

The code is below (please forgive minor mistakes in the code if any. I have a 99% working code implemented with axlSingleSelectBox function and the one below is recreated from memory):

    axlWindowFit()
    axlVisibleDesign(nil)
    axlVisibleLayer("PIN/TOP" t)
    axlVisibleLayer("VIA CLASS/TOP" t)
    axlUIWRedraw(nil)
    
    axlClearSelSet()
    axlSetFindFilter(?enabled '(noall VIAS) ?onButtons '(noall VIAS))
    topvias = axlGetSelSet(axlAddSelectAll())
   

    axlClearSelSet()
    axlSetFindFilter(?enabled '(noall PINS) ?onButtons '(noall PINS))
    foreach(via topvias
        axlAddSelectPoint() ; this is the line that is not working!!!
    )

    vippinlist = axlGetSelSet()
    axlClearSelSet()

  • Sign in to reply
  • Cancel
  • eDave
    eDave over 9 years ago

    Did you think about doing it with polygons?

    pinCuPoly = car(axlPolyFromDB(pin ?layer "ETCH/TOP"))

    axlGeoPointInShape(via ->xy, pinCuPoly)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • catalineacsu
    catalineacsu over 9 years ago

    Hello Dave,

    Thanks for the hint. It helped.


    It crossed my mind that a point inside a polygon could solve the problem but had absolutely no idea how to do that as I was not aware of the "GEO" functions.

    This being said, it works perfect on the boards I tested. Below the final code fragment, for reference:

    foreach(via topvias
            SelectedPin = car(axlGetSelSet(axlSingleSelectPoint(via->xy)))
            if(SelectedPin != nil then
                PinCuPoly = car(axlPolyFromDB(SelectedPin ?layer "ETCH/TOP"))
                if(axlGeoPointInShape(via ->xy, PinCuPoly) == t then
                    fprintf(Log_File "%s @ \t (%.2n %.2n )\n" via->name xCoord(via->xy) yCoord(via->xy)) ; or do anything usefull
                )
            )    
        )

    problem solved, topic closed.

    Regards,

    Catalin

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