4 Replies Latest reply on Aug 8, 2014 8:32 PM by kendall_hiles

    tieLeg Object

    wayne

      I have been working with the tieLeg object and I am trying to return the width of the tie leg. I have three questions.

       

      How do yo get the width of a tieLeg?

      Is this in the Dimensions property?

      How do you return Dimensions data?

       

      ' set tieLeg collection

          set tls = plane.tieLegs

          ...

       

      for each tl in tls

         ...

         set tlDims = tl.Dimensions

         for each tlDim in tlDims     - ERROR HERE: "Object not a collection"

            ...

         next

      next

        • 1. Re: tieLeg Object
          wayne

          I found this but it is not returning the actual width of the tie legs on the board in all cases.

           

          For each pin in pinCol

                  pin.Selected = True

                  docObj.ActiveView.SetExtentsToSelection

           

                  pin.TieLegWidth(1, epcbUnitCurrent)

              pin.Selected = False

              next   

           

          Any ideas?

          • 2. Re: tieLeg Object
            wayne

            Got it!

             

            for each pin in pinCol

                set conObjs = pin.ConnectedObjects

                For i = 1 To conObjs.Count

                    Set tmpObj = conObjs.Item(i)

             

                    ''Looking for pins connected to some type of copper object

                    If (tmpObj.ObjectClass = epcbObjectClassConductorLayerGfx) Then

                        set obj = tmpObj

             

                        '' If object connected to pin is a plane

                        '' Select and zoom to pin

                        '' Collect tie leg data

                        if tmpObj.Type2 = epcbGfxActualPlaneShape then

                            pin.Selected = True

                            docObj.ActiveView.SetExtentsToSelection

             

                            'Set ref des and pin no

                            ref = pin.Component

                            pinNo = pin.Name

             

                            ''Find number of tie legs

                            tieType = pin.TieLegType(tlLayer)

             

                            ''Find Tie leg width

                            tieWidth = pin.TieLegWidth(tlLayer)

             

                            ' Set a "real" number of ties

                            Select Case tieType

                                Case 4

                                    tiesNo = "0"

                                Case 3

                                    tiesNo = 8

                                Case 2

                                    tiesNo = 4

                                Case 1

                                    tiesNo = 2

                                Case 0

                                    tiesNo = 0

                            End Select

             

                           msgbox ref & "-" & pinNo &  No of Ties"  & tiesNo & " Width: " & tieWidth

                           'file.write ref & "-" & pinNo & chr(9) & tlLayer & chr(9) & tiesNo & chr(9) & tieWidth & vbcrlf

             

                           pin.Selected = False

             

                   end if

              next

            next

            • 3. Re: tieLeg Object
              wayne

              I have been able to generate a report and output a csv list. However the generated list is inaccurate. For example if a pin has a thermal overide set to 4 legs and can only generate three due to the shape of the plane, Mentor automation generates a report of how many ties are set and not the actual numbers. In other words tieleg portion of automation is of no use.

               

              If anyone knows of a way around this, please post.

              • 4. Re: tieLeg Object
                kendall_hiles

                You just have to add up the ties for each pin  in this example from AATK....

                It puts the report in the output directory