EAGLE Help

UL_PIN


Data members

angle real (0.0...359.9°)
contact UL_CONTACT (see Note)
direction int (PIN_DIRECTION_...)
function int (PIN_FUNCTION_FLAG_...)
length int (PIN_LENGTH_...)
name string (PIN_NAME_LENGTH)
swaplevel int
visible int (PIN_VISIBLE_FLAG_...)
x, y int (connection point)

Loop members

circles() UL_CIRCLE
texts() UL_TEXT
wires() UL_WIRE

Constants

PIN_DIRECTION_NC not connected
PIN_DIRECTION_IN input
PIN_DIRECTION_OUT output (totem-pole)
PIN_DIRECTION_IO in/output (bidirectional)
PIN_DIRECTION_OC open collector
PIN_DIRECTION_PWR power input pin
PIN_DIRECTION_PAS passive
PIN_DIRECTION_HIZ high impedance output
PIN_DIRECTION_SUP supply pin

PIN_FUNCTION_FLAG_NONE no symbol
PIN_FUNCTION_FLAG_DOT inverter symbol
PIN_FUNCTION_FLAG_CLK clock symbol

PIN_LENGTH_POINT no wire
PIN_LENGTH_SHORT 0.1 inch wire
PIN_LENGTH_MIDDLE 0.2 inch wire
PIN_LENGTH_LONG 0.3 inch wire

PIN_NAME_LENGTH max. length of a pin name

PIN_VISIBLE_FLAG_OFF no name drawn
PIN_VISIBLE_FLAG_PAD pad name drawn
PIN_VISIBLE_FLAG_PIN pin name drawn

See also UL_SYMBOL, UL_PINREF, UL_CONTACTREF

Note

The contact data member returns the contact that has been assigned to the pin through a CONNECT command. It can be used as a boolean function to check whether a contact has been assigned to a pin (see example below).

The coordinates (and layer, in case of an SMD) of the contact returned by the contact data member depend on the context in which it is called:

Example
library(L) {
  L.symbols(S) {
    printf("Symbol: %s\n", S.name);
    S.pins(P) {
      printf("\tPin: %s, (%d %d)", P.name, P.x, P.y);
      if (P.direction == PIN_DIRECTION_IN)
         printf(" input");
      if ((P.function & PIN_FUNCTION_FLAG_DOT) != 0)
         printf(" inverted");
      printf("\n");
      }
    }
  L.devices(D) {
    D.gates(G) {
      G.symbol.pins(P) {
        if (!P.contact)
           printf("Unconnected pin: %s/%s/%s\n", D.name, G.name, P.name);
        }
      }
    }
  }

Index Copyright © 1999 CadSoft Computer GmbH