• 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 - Skill
  3. how can I find all net segments from type "path" with same...

Stats

  • State Not Answered
  • Replies 1
  • Subscribers 19
  • Views 682
  • Members are here 0
More Content

how can I find all net segments from type "path" with same net and select them in some loop?

Stefan IFX
Stefan IFX over 1 year ago

Hello,

I'm looking for a way to find all net segments (cline) with same net as the selection.

This is my starting condition:

seg = axlGetSelSet()
if(seg == nil then
printf("\n")
print("Please select exactly one CONNECT LINE")
else
if(length(seg) > 1 then
print("Please select exactly one CONNECT LINE")
else
seg = car(seg)
if(seg->objType != "path" then
print("Please select exactly one CONNECT LINE")
else
# how can I find all net segments from type "path" with same net and select them in some loop?
)
)
)

  • Cancel
  • Sign in to reply
  • Hoangkhoipcb
    0 Hoangkhoipcb over 1 year ago

    Hi Stefan IFX!

    Fullscreen code.txt Download
    axlCmdRegister("findSegSameNet" `findSegSameNet)
    (defun findSegSameNet ()
    	axlClearSelSet()
    	axlSetFindFilter(?enabled '(noall CLINES NAMEFORM) ?onButtons '(noall ALL))
    	mypopup = axlUIPopupDefine(nil (list (list "Done" 'axlFinishEnterFun) (list "Cancel" 'axlCancelEnterFun)))
    	axlUIPopupSet( mypopup)
    	while(axlSelect(?prompt "Please select an element...") 
    		seg = axlGetSelSet()
    		axlClearSelSet()
    		if(seg == nil then
    			printf("\n")
    			print("Please select exactly one CONNECT LINE")
    		else
    			if(length(seg) > 1 then
    				print("Please select exactly one CONNECT LINE")
    			else
    				seg = car(seg)
    				if(seg->objType != "path" then
    					print("Please select exactly one CONNECT LINE")
    				else
    					;# how can I find all net segments from type "path" with same net and select them in some loop?
    					save_visible = axlVisibleGet()
    					axlVisibleDesign(nil)
    					axlVisibleLayer("ETCH" t)
    					axlAddSelectAll()
    					select_list = setof(e axlGetSelSet() e != seg && e->net == seg->net)
    					axlClearSelSet()
    					axlVisibleSet(save_visible)
    					axlShowObject(select_list)
    					println(select_list)
    				)
    			)
    		)
    		
    	)
    )
    

    You can refer this code.

    Best Regards.

    HoangKhoi.

    • 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