Adds a new section in the symbol.

syntaxSyntax:
DlxLibraryDevice.AddSymbolSection(symbolName, prefixMode = DlxApp.LIBSECTIONPREFIX_NONE, sectionName = "")

Parameters

Parameter Description
symbolName The name of the symbol to use for the section being defined. If the symbol is contained in an external library, also specify the library name after the "/" character. (symbolName/libraryName).
prefixMode If you choose Prefix, the pin names are prefixed with the index of the part. Set one of the following values:
DlxApp.LIBSECTIONPREFIX_NONE
DlxApp.LIBSECTIONPREFIX_PREFIX
DlxApp.LIBSECTIONPREFIX_SUFFIX
DlxApp.LIBSECTIONPREFIX_PREFIXCHAR
DlxApp.LIBSECTIONPREFIX_SUFFIXCHAR
sectionName The name of the section being defined.

Return Value

If the function ends correctly it returns true otherwise it returns false.

Example

  Copy codeCopy code
var libPrj = DlxApp.GetJob().GetProject("Example Lib");
if (!libPrj.IsValid())
  libPrj = DlxApp.GetJob().NewProject("Example Lib");
var libDoc = libPrj.GetDocument("Examples Lib", DlxApp.DOCTYPE_LIBRARY);
if (!libDoc.IsValid())
  libDoc = libPrj.NewDocument("Examples Lib", DlxApp.DOCTYPE_LIBRARY);
if (libDoc.IsValid() && libDoc.Activate())
{
  var folderGates = libDoc.AddFolder("Gates");
  var device = folderGates.AddDevice("SN74HC00");
  device.SetIcon(0);
  device.SetName("SN74HC00");
  device.SetDeviceName("SN74HC00");
  device.SetReferencePrefix("U");
  device.SetDeviceClass("Gates", "NAND gate");
  device.SetManufacturer("Texas Instruments");
  device.SetDescription("2-Input NAND gate");
  device.SetDatasheetLink("https://www.ti.com/lit/ds/symlink/sn74ahc00.pdf");
  device.SetAttribute("CARD", "SPICE", "#gates NAND [1 2 3][4 5 6][9 10 8][12 13 11][PWR 14 7] %&model", "", "", DlxApp.ATTRIBUTEFLAGS_ADVANCED);
  device.SetAttribute("MODEL", "SPICE", "SN74HC00");
  device.BeginSymbolDefinition("7400");
  device.AddSymbolSection("NAND_2INP/Logic Symbols", DlxApp.LIBSECTIONPREFIX_PREFIX);
  device.AddSymbolSectionPin("1", "1,4,9,12");
  device.AddSymbolSectionPin("2", "2,5,10,13");
  device.AddSymbolSectionPin("3", "3,6,8,11");
  device.AddSymbolSectionPin("4", "7");  
  device.AddSymbolSectionPin("5", "14");
  device.EndSymbolDefinition();
  device.AddFootprint("TI_N14");
}

See also