from collections import defaultdict
from skidl import Pin, Part, Alias, SchLib, SKIDL, TEMPLATE

from skidl.pin import pin_types

SKIDL_lib_version = '0.0.1'

Isolator_Analog = SchLib(tool=SKIDL).add_parts(*[
        Part(**{ 'name':'ACPL-C790', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'ACPL-C790'}), 'ref_prefix':'U', 'fplist':['Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm'], 'footprint':'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'keywords':'Isolation Amplifer', 'description':'', 'datasheet':'http://docs.avagotech.com/docs/AV02-2460EN', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nACPL-C790\n\nIsolation Amplifer', 'pins':[
            Pin(num='1',name='VDD1',func=pin_types.PWRIN,unit=1),
            Pin(num='2',name='IN+',func=pin_types.INPUT,unit=1),
            Pin(num='3',name='IN-',func=pin_types.INPUT,unit=1),
            Pin(num='4',name='GND1',func=pin_types.PWRIN,unit=1),
            Pin(num='5',name='GND2',func=pin_types.PWRIN,unit=1),
            Pin(num='6',name='OUT-',func=pin_types.OUTPUT,unit=1),
            Pin(num='7',name='OUT+',func=pin_types.OUTPUT,unit=1),
            Pin(num='8',name='VDD2',func=pin_types.PWRIN,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'ACPL-C870', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'ACPL-C870'}), 'ref_prefix':'U', 'fplist':['Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm'], 'footprint':'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'keywords':'Optycally Isolated Voltage Sensor', 'description':'', 'datasheet':'www.avagotech.com/docs/AV02-3563EN', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nACPL-C870\n\nOptycally Isolated Voltage Sensor', 'pins':[
            Pin(num='1',name='VDD1',func=pin_types.PWRIN,unit=1),
            Pin(num='2',name='IN',func=pin_types.INPUT,unit=1),
            Pin(num='3',name='IN-',func=pin_types.INPUT,unit=1),
            Pin(num='4',name='GND1',func=pin_types.PWRIN,unit=1),
            Pin(num='5',name='GND2',func=pin_types.PWRIN,unit=1),
            Pin(num='6',name='OUT-',func=pin_types.OUTPUT,unit=1),
            Pin(num='7',name='OUT+',func=pin_types.OUTPUT,unit=1),
            Pin(num='8',name='VDD2',func=pin_types.PWRIN,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'AMC3330', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'AMC3330'}), 'ref_prefix':'U', 'fplist':['Package_SO:SOIC-16W_7.5x10.3mm_P1.27mm'], 'footprint':'Package_SO:SOIC-16W_7.5x10.3mm_P1.27mm', 'keywords':'isolated analog amplifier integrated power supply', 'description':'', 'datasheet':'https://www.ti.com/lit/ds/symlink/amc3330.pdf', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nAMC3330\n\nisolated analog amplifier integrated power supply', 'pins':[
            Pin(num='1',name='DCDC_OUT',func=pin_types.PWROUT,unit=1),
            Pin(num='10',name='OUTN',func=pin_types.OUTPUT,unit=1),
            Pin(num='11',name='OUTP',func=pin_types.OUTPUT,unit=1),
            Pin(num='12',name='VDD',func=pin_types.PWRIN,unit=1),
            Pin(num='13',name='LDO_OUT',func=pin_types.PWROUT,unit=1),
            Pin(num='14',name='DIAG',func=pin_types.OUTPUT,unit=1),
            Pin(num='15',name='DCDC_GND',func=pin_types.PWRIN,unit=1),
            Pin(num='16',name='DCDC_IN',func=pin_types.PWRIN,unit=1),
            Pin(num='2',name='DCDC_HGND',func=pin_types.PWROUT,unit=1),
            Pin(num='3',name='HLDO_IN',func=pin_types.PWRIN,unit=1),
            Pin(num='4',name='NC',func=pin_types.NOCONNECT,unit=1),
            Pin(num='5',name='HLDO_OUT',func=pin_types.PWROUT,unit=1),
            Pin(num='6',name='INP',func=pin_types.INPUT,unit=1),
            Pin(num='7',name='INN',func=pin_types.INPUT,unit=1),
            Pin(num='8',name='HGND',func=pin_types.PWRIN,unit=1),
            Pin(num='9',name='GND',func=pin_types.PWRIN,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'IL300', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'IL300'}), 'ref_prefix':'U', 'fplist':[''], 'footprint':'', 'keywords':'Vishay', 'description':'', 'datasheet':'http://www.vishay.com/docs/83622/il300.pdf', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nIL300\n\nVishay', 'pins':[
            Pin(num='1',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='2',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='3',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='4',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='5',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='6',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='7',name='NC',func=pin_types.NOCONNECT,unit=1),
            Pin(num='8',name='NC',func=pin_types.NOCONNECT,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'ACPL-C79A', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'ACPL-C79A'}), 'ref_prefix':'U', 'fplist':['Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm'], 'footprint':'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'keywords':'Isolation Amplifer', 'description':'', 'datasheet':'http://docs.avagotech.com/docs/AV02-2460EN', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nACPL-C79A\n\nIsolation Amplifer', 'pins':[
            Pin(num='1',name='VDD1',func=pin_types.PWRIN,unit=1),
            Pin(num='2',name='IN+',func=pin_types.INPUT,unit=1),
            Pin(num='3',name='IN-',func=pin_types.INPUT,unit=1),
            Pin(num='4',name='GND1',func=pin_types.PWRIN,unit=1),
            Pin(num='5',name='GND2',func=pin_types.PWRIN,unit=1),
            Pin(num='6',name='OUT-',func=pin_types.OUTPUT,unit=1),
            Pin(num='7',name='OUT+',func=pin_types.OUTPUT,unit=1),
            Pin(num='8',name='VDD2',func=pin_types.PWRIN,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'ACPL-C79B', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'ACPL-C79B'}), 'ref_prefix':'U', 'fplist':['Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm'], 'footprint':'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'keywords':'Isolation Amplifer', 'description':'', 'datasheet':'http://docs.avagotech.com/docs/AV02-2460EN', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nACPL-C79B\n\nIsolation Amplifer', 'pins':[
            Pin(num='1',name='VDD1',func=pin_types.PWRIN,unit=1),
            Pin(num='2',name='IN+',func=pin_types.INPUT,unit=1),
            Pin(num='3',name='IN-',func=pin_types.INPUT,unit=1),
            Pin(num='4',name='GND1',func=pin_types.PWRIN,unit=1),
            Pin(num='5',name='GND2',func=pin_types.PWRIN,unit=1),
            Pin(num='6',name='OUT-',func=pin_types.OUTPUT,unit=1),
            Pin(num='7',name='OUT+',func=pin_types.OUTPUT,unit=1),
            Pin(num='8',name='VDD2',func=pin_types.PWRIN,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'ACPL-C87A', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'ACPL-C87A'}), 'ref_prefix':'U', 'fplist':['Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm'], 'footprint':'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'keywords':'Optycally Isolated Voltage Sensor', 'description':'', 'datasheet':'www.avagotech.com/docs/AV02-3563EN', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nACPL-C87A\n\nOptycally Isolated Voltage Sensor', 'pins':[
            Pin(num='1',name='VDD1',func=pin_types.PWRIN,unit=1),
            Pin(num='2',name='IN',func=pin_types.INPUT,unit=1),
            Pin(num='3',name='IN-',func=pin_types.INPUT,unit=1),
            Pin(num='4',name='GND1',func=pin_types.PWRIN,unit=1),
            Pin(num='5',name='GND2',func=pin_types.PWRIN,unit=1),
            Pin(num='6',name='OUT-',func=pin_types.OUTPUT,unit=1),
            Pin(num='7',name='OUT+',func=pin_types.OUTPUT,unit=1),
            Pin(num='8',name='VDD2',func=pin_types.PWRIN,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'ACPL-C87B', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'ACPL-C87B'}), 'ref_prefix':'U', 'fplist':['Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm'], 'footprint':'Package_SO:SSO-8_6.8x5.9mm_P1.27mm_Clearance8mm', 'keywords':'Optycally Isolated Voltage Sensor', 'description':'', 'datasheet':'www.avagotech.com/docs/AV02-3563EN', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nACPL-C87B\n\nOptycally Isolated Voltage Sensor', 'pins':[
            Pin(num='1',name='VDD1',func=pin_types.PWRIN,unit=1),
            Pin(num='2',name='IN',func=pin_types.INPUT,unit=1),
            Pin(num='3',name='IN-',func=pin_types.INPUT,unit=1),
            Pin(num='4',name='GND1',func=pin_types.PWRIN,unit=1),
            Pin(num='5',name='GND2',func=pin_types.PWRIN,unit=1),
            Pin(num='6',name='OUT-',func=pin_types.OUTPUT,unit=1),
            Pin(num='7',name='OUT+',func=pin_types.OUTPUT,unit=1),
            Pin(num='8',name='VDD2',func=pin_types.PWRIN,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'LOC112', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'LOC112'}), 'ref_prefix':'U', 'fplist':['', 'Package_DIP:DIP-8_W7.62mm'], 'footprint':'', 'keywords':'ixys littlefuse', 'description':'', 'datasheet':'https://www.littelfuse.com/media?resourcetype=datasheets&itemid=996c6e8f-cc1b-44f6-811e-251c6e004c56&filename=littelfuse-integrated-circuits-loc112-datasheet', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nLOC112\n\nixys littlefuse', 'pins':[
            Pin(num='1',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='2',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='3',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='4',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='5',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='6',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='7',name='NC',func=pin_types.NOCONNECT,unit=1),
            Pin(num='8',name='NC',func=pin_types.NOCONNECT,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'LOC112P', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'LOC112P'}), 'ref_prefix':'U', 'fplist':['', 'Package_DIP:DIP-8_W7.62mm', 'Package_DIP:IXYS_Flatpak-8_6.3x9.7mm_P2.54mm'], 'footprint':'', 'keywords':'ixys littlefuse', 'description':'', 'datasheet':'https://www.littelfuse.com/media?resourcetype=datasheets&itemid=996c6e8f-cc1b-44f6-811e-251c6e004c56&filename=littelfuse-integrated-circuits-loc112-datasheet', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nLOC112P\n\nixys littlefuse', 'pins':[
            Pin(num='1',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='2',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='3',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='4',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='5',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='6',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='7',name='NC',func=pin_types.NOCONNECT,unit=1),
            Pin(num='8',name='NC',func=pin_types.NOCONNECT,unit=1)], 'unit_defs':[] }),
        Part(**{ 'name':'LOC112S', 'dest':TEMPLATE, 'tool':SKIDL, 'aliases':Alias({'LOC112S'}), 'ref_prefix':'U', 'fplist':['', 'Package_DIP:DIP-8_W7.62mm', 'Package_DIP:IXYS_Flatpak-8_6.3x9.7mm_P2.54mm', 'Package_DIP:IXYS_SMD-8_6.3x9.7mm_P2.54mm'], 'footprint':'', 'keywords':'ixys littlefuse', 'description':'', 'datasheet':'https://www.littelfuse.com/media?resourcetype=datasheets&itemid=996c6e8f-cc1b-44f6-811e-251c6e004c56&filename=littelfuse-integrated-circuits-loc112-datasheet', 'search_text':'/usr/share/kicad/symbols/Isolator_Analog.kicad_sym\nLOC112S\n\nixys littlefuse', 'pins':[
            Pin(num='1',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='2',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='3',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='4',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='5',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='6',name='~',func=pin_types.PASSIVE,unit=1),
            Pin(num='7',name='NC',func=pin_types.NOCONNECT,unit=1),
            Pin(num='8',name='NC',func=pin_types.NOCONNECT,unit=1)], 'unit_defs':[] })])