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("CAY16-AS Series");
var device = folderGates.AddDevice("{$1} ohms");
device.SetDeviceName("CAY16-{$2}J4AS");
device.SetReferencePrefix("R");
device.SetDeviceClass("Resistors", "Resistor Networks");
device.SetManufacturer("Bourns");
device.SetDescription("Thick Film Chip Arrays");
device.SetDatasheetLink("https://www.bourns.com/docs/product-datasheets/cay16-as.pdf?sfvrsn=d1a46bf6_4");
device.SetAttribute("CARD", "SPICE", "%?#(1)<%RR %#(1 2) {$1} %=TEMP %=TC>", "", "", DlxApp.ATTRIBUTEFLAGS_ADVANCED);
device.SetAttribute("PINS", "SPICE", "1,8;2,7;3,6;4,5", "", "", DlxApp.ATTRIBUTEFLAGS_ADVANCED);
device.BeginSymbolDefinition("RPACK");
device.AddSymbolSection("RESISTOR/Simdevices");
device.AddSymbolSectionPin("1", "1,2,3,4", "R1A,R2A,R3A,R4A");
device.AddSymbolSectionPin("2", "8,7,6,5", "R1B,R2B,R3B,R4B");
device.AddRepeatString("100|101");
device.AddRepeatString("220|221");
device.AddRepeatString("470|471");
device.EndSymbolDefinition();
}
|