Translations of this page are also available in the following languages: Русский.
by: Ales Hvezda, firstname.lastname@example.org
This document is released under GFDL
July 10th, 2007
This document describes all the attributes used in in gEDA/gaf (GPL'd Electronic Design Automation / Gschem And Friends). This document is broken down into several section: this overview, symbol only attributes, schematic only attributes, attributes which can appear in both symbols and schematics, and
attributes which are obsolete or deprecated.
In this document, attribute names are in bold and examples are in the
Attributes in the gEDA/gaf system are nothing more than text items which take on the form: name=value. Name can be anything just as long as it doesn't contain a equals sign. Value can also be anything just as long as it is something (vs nothing). name= (without a value part) is not a valid attribute. Also, there cannot be any spaces immediately before or after the equals sign.
Attributes can be attached to some part of the symbol. If the attribute conveys information specific to an object, then the attribute should be attached directly to the object, otherwise the attribute should be free standing or floating. Free standing attributes just exist in the symbol file as text items which take on the form name=value.
device= is the device name of the symbol
device= should be placed somewhere in the symbol and made invisible. This is a free standing or floating attribute. If the object is a graphic then device= should be set to none (device=none) and attach a graphical= attribute. Do not confuse this attribute with just having a text label which the device name. Do not put spaces into the device name; there are some programs which dislike spaces in the device specifier. Generally the device name is in all caps.
Symbols which have no electrical or circuit significance need a graphical=1 attribute. Symbols like titleboxes are purely graphical symbols. Any symbol which has graphical=1 is ignored by gnetlist.
graphical=1 should exist somewhere in the symbol and made invisible. This is a free standing or floating attribute. Don't forget to set device=none.
The description attribute provides a simple one line description of what the symbol is supposed to represent.
description=4 NAND gates with 2 inputs
The author attribute identifies the name of the author of this symbol and their e-mail address. This attribute is optional, but it is nice to know who created which symbols. It also serves the purpose of known who to contact if there are questions about the intent(s) of the symbol. This attribute is free form and it can also include people's names who modified the symbol as well as multiple e-mail addresses. It is probably also a good idea to obfuscate the e-mail address so it is not harvested for spam purposes.
author=Ales Hvezda ahvezdaATgeda.seul.org
The comment attribute can contain anything. This attribute can convey any additional information which might not fit into any other attribute. There can be multiple instances of this attribute.
comment=This is a comment inside a symbol
This attribute is used to give each pin an unique number or sequence. All pins must have a pinseq=# attribute attached to the pin object. This attribute should be hidden. This attribute is used extensively by gschem and gnetlist.
In some backends (especially the SPICE backend), gnetlist will output pins in the order of increasing pin sequence. The sequence numbers start at 1 and should increase without skipping any numbers. This attribute is not the pin number (i.e. device pin numbers, like GND is 7 on TTL). For pin numbers see the pinnumber attribute.
This attribute replaces the obsolete pin#=# attribute.
This attribute is the pin number (i.e. like GND is 7 on 74 TTL). All pins must have a pinnumber=# attribute attached to the pin object.
You can have numbers or letters for the value. This attribute should be visible with the value only visible. You also need a pinseq attribute.
This attribute replaces the obsolete pin#=# attribute.
Each pin must have a pintype=value attribute attached to it and should be make hidden. Table 1 shows valid values for this attribute.
This attribute is not used extensively in the symbol library, but it will be used for DRC and netlisting. Use “Passive” if no other type matches.
|tri||Tristate (high impedance)|
|Table 1: pintype values|
This attribute labels a pin object. This attribute is primarily used by gnetlist to support hierarchical designs.
This attribute must be attached to the pin and be left visible. Please make this attribute green (instead of the default attribute yellow).
If a component has multiple slots in a physical package (such as a 7400 (NAND) which has 4 NANDs per package) then you need a numslots=# attribute. The # is the number of slots that are in a physical device. numslots=# should exist somewhere in the symbol and be made invisible. This is a free standing or floating attribute. If the symbol does not need slotting, then put numslots=0 into the symbol file.
If a component has multiple slots in a physical package then you must attach a slotdef=slotnumber:#,#,#… for every device inside the physical package.
The slotnumber corresponds to the slot number. The colon after the slot number is required. For example, if a device has 4 slots then there would be slotdef=1:…, slotdef=2:…, slotdef=3:…, and slotdef=4:… attributes somewhere in the symbol and be made invisible. This is a free standing or floating attribute.
The #'s have a one-to-one correspondence to the pinseq attributes and specify which pinnumber=# is used during display (gschem) or netlisting (gnetlist).
It is recommended that all symbols which have slots have a slot=1 attribute attached in the same fashion as the device= attribute.
See 7400-1.sym as a concrete example.
This attribute replaces the obsolete slot#=# attribute.
footprint=package_name should exist somewhere in the symbol and be made invisible. This attribute is used by gnetlist and primarily for the PCB package.
Attach this attribute just like the device= attribute. This is a free standing or floating attribute.
package_name is the pcb footprint or package type like DIP14 or DIP40. Although this attribute in principle is pcb package dependent, gEDA/gaf conventions exist to make this attribute as portable as possible, allowing for easy collaboration and sharing between users. See the Footprint naming conventions.
If the symbol does not have a footprint, then the value of footprint= should be set to none. If the footprint must be overridden in a schematic, then the value of footprint= should be set to none. If the footprint is not known, then the value of footprint= should be set to unknown.
documentation=documentation_locator may exist somewhere in the symbol and be made invisible. This attribute is used by gschemdoc to find relevant documentation for the symbol, or rather, the device or component associated with the symbol.
Attach this attribute just like the device= attribute. This is a freestanding or floating attribute.
documentation_locator is either the base filename of the documentation, or it is the complete Internet URL (Uniform Resource Locator). If it is the filename, an attempt will be made to search for it in the local gEDA share directory named documentation.
This attribute should be attached to a net object to give it a name. Multiple net names for connected net segments is discouraged. All nets which have the same value are considered electrically connected. This attribute is not valid inside symbols (as you cannot have nets inside of symbols).
The source= attribute is used to specify that a symbol has underlying schematics. This attribute is attached directly to a component.
This attribute should only be attached to instantiated components in schematics. Attach the attribute to a component and specify the filename (not the path) of the underlying schematic (like block.sch) for the value. The specified schematic must be in a source-library path. This attribute can be attached multiple times with different values which basically means that there are multiple underlying schematics.
This attribute is used to specify the reference designator to a particular instantiated component. It must be on ALL components which have some sort of electrical significance. This attribute can also be on the inside of a symbol (it will be promoted, i.e. attached to the outside of the symbol, if it is visible) to provide a default refdes value (such as U?). Usually this attribute is composed by a prefix ('U' for example) and a number (different for each component).
Gschem will accept any string as a value for the refdes. However, some back-ends to gnetlist impose restrictions on the allowed syntax.
Specifically, gsch2pcb requires:
There is a convention of the reference designator used for each kind of component. Here are some of them (substitute a cardinal value for <n>):
|P<n>||Connector (usually plugs that mate with J<n>)|
This attribute is used to specify a slot for a slotted component. It should be attached to an instantiated component. This attribute can also be on the inside of a symbol (it will be promoted, i.e. attached to the outside of the symbol, if it is visible) to provide a default slot.
The net= attribute is used to create power/ground and arbitrary nets. Please see the net= attribute mini-HOWTO for more info. When this attribute is inside a symbol, it is used to create nets. When this attribute is attached to an instantiated component (in a schematic), then the net= can also be used to create new nets and can used to override existing nets.
Used mainly in the spice backend netlister to specify the value of the various elements. No translation is done on this, and it is placed as is into the netlist.
The symversion= attribute is used to version the contents of symbols. Because symbols are, by default, referenced from the schematic and not embedded within it, problems can occur in a schematic using a particular symbol if that symbol file is modified. For instance, if pins are moved in the symbol, the schematic net lines will no longer connect to the correct pins. The symversion= attribute allows tracking such breaking changes to symbols and notifying the user of potential problems when a schematic is loaded.
This attribute is optional, but if present it must take the following
where major and minor are integers. The major number is incremented when a change is made to a symbol that might break an existing schematic using the prior version of symbol when the new version is introduced. The minor number is only incremented when a minor change is made (a change that cannot break an existing schematic, such as cosmetic changes while retaining structure such as location of the pins).
If this attribute is inside a symbol and that symbol is placed onto a schematic, the symversion= attribute will be automatically “promoted”, causing a copy of the symversion=M.N attribute to be stored on the symbol instance in the schematic itself. When a symbol is loaded from disk, the value of the symversion= inside the symbol file (if any) and the symversion value attached to the symbol instance on the schematic are compared. If the values differ, then libgeda will output a warning message (for minor version changes) or an error message (for major version changes).
This attribute should normally be made invisible when placed inside a
symbol file. This attribute is always promoted when it is found inside
a symbol during component placement. Users should not attach this
attribute manually to instantiated symbols in a schematic.
The dist-license attribute is used to specify the redistribution license for the symbol or schematic. It should be the name of a known license. Some examples values are: GPL, GPL version 2 only, GPL version 3 only, public domain, Apache version 2, Modified BSD, X11, etc.
For a list of licenses see: FSF License List and OSI License List
The use-license attribute is used to specify the license for how the symbol or schematic can be used by other people in their own circuits or boards. Some example values are: unlimited, personal use only, not for sale, etc.
put a better list of examples here.
The uref= attribute is obsolete and cannot not be used. It was used to provide the same information as refdes.
The name= attribute should not be attached or appear in any symbol. It is considered ambiguous. name= was never used by gEDA/gaf.
The slot#=# attribute is obsolete and cannot be used. It was used to provide slotting information to components. The replacement attribute for this is slotdef.
The type= attribute is obsolete and cannot be used. It was used to provide type information on pins. The replacement attribute for this is pintype.
The information in this attribute has been merged with author.
|July 14th, 2002||Created attributes.tex from attributes.txt.|
|July 14th, 2002||Updated doc to be in sync with post-20020527.|
|August 25th, 2002||Added obsolete type= attribute.|
|September 14, 2002||Added description= attribute. Minor fixes|
|October 7, 2002||Added doc= attribute; Egil Kvaleberg.|
|February 11, 2003||Added reference to footprint conventions.|
|February 23, 2003||Added author=, email=, and comment= attributes.|
|July 6th, 2004||Added symversion= attribute.|
|July 10th, 2007||Added dist-license= and use-license= attributes.|