Home
  • Products
  • Solutions
  • Support
  • Company

This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  • Products
  • Solutions
  • Support
  • Company
Community Custom IC SKILL Hilite all schematic nets that do NOT have a user added...

Stats

  • Locked Locked
  • Replies 5
  • Subscribers 136
  • Views 3741
  • Members are here 0
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

Hilite all schematic nets that do NOT have a user added property...

vtboy51
vtboy51 over 1 year ago

For a variety of reasons we have added a property to certain schematic nets, and now I want to hilite the nets that do NOT have this property. This property could exist in our top level schematic or down the signal chain in a lower level cell, it just depends on where the Designer chose to tag the net. Because of this I need to scan each net, throughout the hierarchy looking for this property, and if no property exists (at any level) then hilite it at the top level schematic. 

I found the schTraceNet function but don't fully understand the syntax to make it work. Below is what I have so far, but it doesn't work, and maybe the wrong direction. My thoughts are to set a userFlag to nil, scan through each net and if said property is found at any level of hierarchy change the userFlag=t and then hilite the net at the top level. Any tips are appreciated.

foreach(net cv~>signals
  userFlag=nil
  schTraceNet(?topCellView cv ?net net~>name ?traceCB 'rfLookForNetPropCB)
   when(userFlag
    geAddNetProbe(getCurrentWindow() list("y0" "drawing") net~>name)
   );when
);end foreach

procedure(rfLookForNetPropCB(netStruct)
 let(()
  when(car(car(netStruct->net~>allInstTerms~>net~>prop~>name)) == "netInfo"     ;netInfo is the user applied property I'm searching for
   printf("Found netInfo tag %L \n" car(car(netStruct->net~>allInstTerms~>net~>prop~>name)))
   userFlag=t
   printf("Setting user flag to true \n")
  );when
 );end let
);end proc

  • Cancel
Parents
  • AurelBuche
    AurelBuche over 1 year ago

    Hi,

    You can try the following snippet, it just add a get_hier_nets function to simplify the use of schTraceNet
    (at the expense of performances, but this should be insignificant):

    (inScheme
      (defun get_hier_nets (cv net)
        "Return all nets connected to NET in CV hierarchy"
        (let (hier_nets)
          (schTraceNet ?topCellView cv ?net net ?traceCB (lambda (hier_net) (push hier_net hier_nets)))
          hier_nets~>net))
      )
    
    let( ( win cv )
      win = getCurrentWindow()
      cv  = geGetEditCellView(win)
      foreach( net cv->signals
        unless(
          exists( net get_hier_nets(cv net) dbFindProp(net "netInfo"))
          geAddNetProbe( '("y0" "drawing") net->name)
          )))

    The inScheme call is important otherwise the function get_hier_nets will not work

    It might not work if the property is not set at net level but on pins

    Cheers,
    Aurélien

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • vtboy51
    vtboy51 over 1 year ago in reply to AurelBuche

    Thanks for this. I have got it to run, but the hilited nets are not quite correct. It is hiliting nets that do the "netInfo" tag at some place in the hiearchy. I'm still investigating, but it seems that the code is only looking at the bottom most schematic for the "netInfo" tag, if the net is tagged at the top level or somewhere in the middle of the hierarchy it's not recognized.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • vtboy51
    vtboy51 over 1 year ago in reply to AurelBuche

    Thanks for this. I have got it to run, but the hilited nets are not quite correct. It is hiliting nets that do the "netInfo" tag at some place in the hiearchy. I'm still investigating, but it seems that the code is only looking at the bottom most schematic for the "netInfo" tag, if the net is tagged at the top level or somewhere in the middle of the hierarchy it's not recognized.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
  • vtboy51
    vtboy51 over 1 year ago in reply to vtboy51

    After some more work I have a piece of code that is almost complete for my original question, but the results have triggered a new question regarding the schTraceNet function. Below is the code I have working, but my confusion presents when a net is connected to an iterated instance at a lower level (i.e nand<0:3>).

    Below are some screenshots showing the results when run with both an iterated instance and one with only a single instance. The drawn red arrow is showing where I would expect a line to exist showing the level of hierarchy which contains the iterated instance. The screenshot further below was run after I modified the schematic to only use a single instance, and then you'll see the "missing" line is reported correctly.

    Question is, is this expected behavior? Any feedback would be appreciated.

     defun( findNetInfoCB (netStruct)
       let((inst (inst makeTable("visited" nil)))
      foreach(instTerm netStruct->net~>allInstTerms
       if(car(instTerm~>net~>prop~>name) == "netInfo" then
        printf("A User prop %L found on net %L in hier path %L \n" car(instTerm~>net~>prop~>name) instTerm~>net~>name netStruct->pathToNet)
        userFlag=nil
        printf("Setting user flag to nil for net %L\n" instTerm~>net~>name)
         else
          printf("NO User prop found on net %L in hier path %L \n" instTerm~>net~>name netStruct->pathToNet)
        );if
       );foreach
      );let
    );defun

    foreach(net cv~>signals
      printf("\n---------------Net name is %L -----------\n" net~>name)
      userFlag=t
      schTraceNet(?topCellView cv ?net net~>name ?traceCB 'findNetInfoCB)
       if(userFlag then
        geAddNetProbe(getCurrentWindow() list("y0" "drawing") net~>name)
        printf("\n\nAdding hilite on net %s \n\n" net~>name)
         else
          printf("\n\nNOT hiliting net %s because it already has a user property\n\n" net~>name)
        );if
      );end foreach

    ;;results with iterated instance

    ;;results with NO iterated instance

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 1 year ago in reply to vtboy51

    I did some quick tests and it worked for me - I can imagine it might be something to do with the property being on a bussed net rather than the scalar net, but I'm not sure without an example replicating your setup. Can you contact customer support so that you can work with an application to show your example data? Otherwise I'm having to guess what you've got in your design and where the properties are.

    Regards,

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

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