Sim QA: Add legacy_opamp test to check legacy subckt fields

In particular, Spice_Node_Sequence needed some additional coverage.
This commit is contained in:
Mikolaj Wielgus 2022-08-11 21:23:05 +02:00
parent c669d55eb8
commit b6f6d1ef81
6 changed files with 1143 additions and 72 deletions

View File

@ -0,0 +1,2 @@
(kicad_pcb (version 20220621) (generator pcbnew)
)

View File

@ -0,0 +1,332 @@
{
"board": {
"3dviewports": [],
"design_settings": {
"defaults": {
"board_outline_line_width": 0.1,
"copper_line_width": 0.2,
"copper_text_size_h": 1.5,
"copper_text_size_v": 1.5,
"copper_text_thickness": 0.3,
"other_line_width": 0.15,
"silk_line_width": 0.15,
"silk_text_size_h": 1.0,
"silk_text_size_v": 1.0,
"silk_text_thickness": 0.15
},
"diff_pair_dimensions": [],
"drc_exclusions": [],
"rules": {
"min_copper_edge_clearance": 0.0,
"solder_mask_clearance": 0.0,
"solder_mask_min_width": 0.0
},
"track_widths": [],
"via_dimensions": []
},
"layer_presets": [],
"viewports": []
},
"boards": [],
"cvpcb": {
"equivalence_files": []
},
"erc": {
"erc_exclusions": [],
"meta": {
"version": 0
},
"pin_map": [
[
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
2
],
[
0,
2,
0,
1,
0,
0,
1,
0,
2,
2,
2,
2
],
[
0,
0,
0,
0,
0,
0,
1,
0,
1,
0,
1,
2
],
[
0,
1,
0,
0,
0,
0,
1,
1,
2,
1,
1,
2
],
[
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
2
],
[
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
2
],
[
1,
1,
1,
1,
1,
0,
1,
1,
1,
1,
1,
2
],
[
0,
0,
0,
1,
0,
0,
1,
0,
0,
0,
0,
2
],
[
0,
2,
1,
2,
0,
0,
1,
0,
2,
2,
2,
2
],
[
0,
2,
0,
1,
0,
0,
1,
0,
2,
0,
0,
2
],
[
0,
2,
1,
1,
0,
0,
1,
0,
2,
0,
0,
2
],
[
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2
]
],
"rule_severities": {
"bus_definition_conflict": "error",
"bus_entry_needed": "error",
"bus_label_syntax": "error",
"bus_to_bus_conflict": "error",
"bus_to_net_conflict": "error",
"different_unit_footprint": "error",
"different_unit_net": "error",
"duplicate_reference": "error",
"duplicate_sheet_names": "error",
"extra_units": "error",
"global_label_dangling": "warning",
"hier_label_mismatch": "error",
"label_dangling": "error",
"lib_symbol_issues": "warning",
"multiple_net_names": "warning",
"net_not_bus_member": "warning",
"no_connect_connected": "warning",
"no_connect_dangling": "warning",
"pin_not_connected": "error",
"pin_not_driven": "error",
"pin_to_pin": "warning",
"power_pin_not_driven": "error",
"similar_labels": "warning",
"unannotated": "error",
"unit_value_mismatch": "error",
"unresolved_variable": "error",
"wire_dangling": "error"
}
},
"libraries": {
"pinned_footprint_libs": [],
"pinned_symbol_libs": []
},
"meta": {
"filename": "legacy_opamp.kicad_pro",
"version": 1
},
"net_settings": {
"classes": [
{
"bus_width": 12.0,
"clearance": 0.2,
"diff_pair_gap": 0.25,
"diff_pair_via_gap": 0.25,
"diff_pair_width": 0.2,
"line_style": 0,
"microvia_diameter": 0.3,
"microvia_drill": 0.1,
"name": "Default",
"pcb_color": "rgba(0, 0, 0, 0.000)",
"schematic_color": "rgba(0, 0, 0, 0.000)",
"track_width": 0.25,
"via_diameter": 0.8,
"via_drill": 0.4,
"wire_width": 6.0
}
],
"meta": {
"version": 2
},
"net_colors": null
},
"pcbnew": {
"last_paths": {
"gencad": "",
"idf": "",
"netlist": "",
"specctra_dsn": "",
"step": "",
"vrml": ""
},
"page_layout_descr_file": ""
},
"schematic": {
"annotate_start_num": 0,
"drawing": {
"dashed_lines_dash_length_ratio": 12.0,
"dashed_lines_gap_length_ratio": 3.0,
"default_line_thickness": 6.0,
"default_text_size": 50.0,
"field_names": [],
"intersheets_ref_own_page": false,
"intersheets_ref_prefix": "",
"intersheets_ref_short": false,
"intersheets_ref_show": false,
"intersheets_ref_suffix": "",
"junction_size_choice": 3,
"label_size_ratio": 0.375,
"pin_symbol_size": 25.0,
"text_offset_ratio": 0.15
},
"legacy_lib_dir": "",
"legacy_lib_list": [],
"meta": {
"version": 1
},
"net_format_name": "",
"ngspice": {
"fix_include_paths": true,
"fix_passive_vals": false,
"meta": {
"version": 0
},
"model_mode": 0,
"workbook_filename": ""
},
"page_layout_descr_file": "",
"plot_directory": "",
"spice_adjust_passive_values": false,
"spice_external_command": "spice \"%I\"",
"spice_save_all_currents": false,
"spice_save_all_voltages": false,
"subpart_first_id": 65,
"subpart_id_separator": 0
},
"sheets": [
[
"986bd0ba-4f89-4046-b50f-9d5b4a950ed1",
""
]
],
"text_variables": {}
}

View File

@ -0,0 +1,606 @@
(kicad_sch (version 20220622) (generator eeschema)
(uuid 986bd0ba-4f89-4046-b50f-9d5b4a950ed1)
(paper "A4")
(lib_symbols
(symbol "Device:R" (pin_numbers hide) (pin_names (offset 0)) (in_bom yes) (on_board yes)
(property "Reference" "R" (id 0) (at 2.032 0 90)
(effects (font (size 1.27 1.27)))
)
(property "Value" "R" (id 1) (at 0 0 90)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at -1.778 0 90)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_keywords" "R res resistor" (id 4) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_description" "Resistor" (id 5) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_fp_filters" "R_*" (id 6) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(symbol "R_0_1"
(rectangle (start -1.016 -2.54) (end 1.016 2.54)
(stroke (width 0.254) (type default))
(fill (type none))
)
)
(symbol "R_1_1"
(pin passive line (at 0 3.81 270) (length 1.27)
(name "~" (effects (font (size 1.27 1.27))))
(number "1" (effects (font (size 1.27 1.27))))
)
(pin passive line (at 0 -3.81 90) (length 1.27)
(name "~" (effects (font (size 1.27 1.27))))
(number "2" (effects (font (size 1.27 1.27))))
)
)
)
(symbol "Simulation_SPICE:OPAMP" (pin_names (offset 0.254)) (in_bom yes) (on_board yes)
(property "Reference" "U" (id 0) (at 3.81 3.175 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Value" "OPAMP" (id 1) (at 3.81 -3.175 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Footprint" "" (id 2) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Netlist_Enabled" "Y" (id 4) (at 0 0 0)
(effects (font (size 1.27 1.27)) (justify left) hide)
)
(property "Spice_Primitive" "X" (id 5) (at 0 0 0)
(effects (font (size 1.27 1.27)) (justify left) hide)
)
(property "ki_keywords" "simulation" (id 6) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_description" "Operational amplifier, single, node sequence=1:+ 2:- 3:OUT 4:V+ 5:V-" (id 7) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(symbol "OPAMP_0_1"
(polyline
(pts
(xy 5.08 0)
(xy -5.08 5.08)
(xy -5.08 -5.08)
(xy 5.08 0)
)
(stroke (width 0.254) (type default))
(fill (type background))
)
)
(symbol "OPAMP_1_1"
(pin input line (at -7.62 2.54 0) (length 2.54)
(name "+" (effects (font (size 1.27 1.27))))
(number "1" (effects (font (size 1.27 1.27))))
)
(pin input line (at -7.62 -2.54 0) (length 2.54)
(name "-" (effects (font (size 1.27 1.27))))
(number "2" (effects (font (size 1.27 1.27))))
)
(pin output line (at 7.62 0 180) (length 2.54)
(name "~" (effects (font (size 1.27 1.27))))
(number "3" (effects (font (size 1.27 1.27))))
)
(pin power_in line (at -2.54 7.62 270) (length 3.81)
(name "V+" (effects (font (size 1.27 1.27))))
(number "4" (effects (font (size 1.27 1.27))))
)
(pin power_in line (at -2.54 -7.62 90) (length 3.81)
(name "V-" (effects (font (size 1.27 1.27))))
(number "5" (effects (font (size 1.27 1.27))))
)
)
)
(symbol "Simulation_SPICE:VDC" (pin_numbers hide) (pin_names (offset 0.0254)) (in_bom yes) (on_board yes)
(property "Reference" "V" (id 0) (at 2.54 2.54 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Value" "VDC" (id 1) (at 2.54 0 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Footprint" "" (id 2) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Netlist_Enabled" "Y" (id 4) (at 0 0 0)
(effects (font (size 1.27 1.27)) (justify left) hide)
)
(property "Spice_Primitive" "V" (id 5) (at 0 0 0)
(effects (font (size 1.27 1.27)) (justify left) hide)
)
(property "Spice_Model" "dc(1)" (id 6) (at 2.54 -2.54 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "ki_keywords" "simulation" (id 7) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_description" "Voltage source, DC" (id 8) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(symbol "VDC_0_0"
(polyline
(pts
(xy -1.27 0.254)
(xy 1.27 0.254)
)
(stroke (width 0) (type default))
(fill (type none))
)
(polyline
(pts
(xy -0.762 -0.254)
(xy -1.27 -0.254)
)
(stroke (width 0) (type default))
(fill (type none))
)
(polyline
(pts
(xy 0.254 -0.254)
(xy -0.254 -0.254)
)
(stroke (width 0) (type default))
(fill (type none))
)
(polyline
(pts
(xy 1.27 -0.254)
(xy 0.762 -0.254)
)
(stroke (width 0) (type default))
(fill (type none))
)
(text "+" (at 0 1.905 0)
(effects (font (size 1.27 1.27)))
)
)
(symbol "VDC_0_1"
(circle (center 0 0) (radius 2.54)
(stroke (width 0.254) (type default))
(fill (type background))
)
)
(symbol "VDC_1_1"
(pin passive line (at 0 5.08 270) (length 2.54)
(name "~" (effects (font (size 1.27 1.27))))
(number "1" (effects (font (size 1.27 1.27))))
)
(pin passive line (at 0 -5.08 90) (length 2.54)
(name "~" (effects (font (size 1.27 1.27))))
(number "2" (effects (font (size 1.27 1.27))))
)
)
)
(symbol "Simulation_SPICE:VSIN" (pin_numbers hide) (pin_names (offset 0.0254)) (in_bom yes) (on_board yes)
(property "Reference" "V" (id 0) (at 2.54 2.54 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Value" "VSIN" (id 1) (at 2.54 0 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Footprint" "" (id 2) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Netlist_Enabled" "Y" (id 4) (at 0 0 0)
(effects (font (size 1.27 1.27)) (justify left) hide)
)
(property "Spice_Primitive" "V" (id 5) (at 0 0 0)
(effects (font (size 1.27 1.27)) (justify left) hide)
)
(property "Spice_Model" "sin(0 1 1k)" (id 6) (at 2.54 -2.54 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "ki_keywords" "simulation" (id 7) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_description" "Voltage source, sinusoidal" (id 8) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(symbol "VSIN_0_0"
(arc (start 0 0) (mid -0.635 0.635) (end -1.27 0)
(stroke (width 0) (type default))
(fill (type none))
)
(arc (start 0 0) (mid 0.635 -0.635) (end 1.27 0)
(stroke (width 0) (type default))
(fill (type none))
)
(text "+" (at 0 1.905 0)
(effects (font (size 1.27 1.27)))
)
)
(symbol "VSIN_0_1"
(circle (center 0 0) (radius 2.54)
(stroke (width 0.254) (type default))
(fill (type background))
)
)
(symbol "VSIN_1_1"
(pin passive line (at 0 5.08 270) (length 2.54)
(name "~" (effects (font (size 1.27 1.27))))
(number "1" (effects (font (size 1.27 1.27))))
)
(pin passive line (at 0 -5.08 90) (length 2.54)
(name "~" (effects (font (size 1.27 1.27))))
(number "2" (effects (font (size 1.27 1.27))))
)
)
)
(symbol "power:GND" (power) (pin_names (offset 0)) (in_bom yes) (on_board yes)
(property "Reference" "#PWR" (id 0) (at 0 -6.35 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "GND" (id 1) (at 0 -3.81 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_keywords" "power-flag" (id 4) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "ki_description" "Power symbol creates a global label with name \"GND\" , ground" (id 5) (at 0 0 0)
(effects (font (size 1.27 1.27)) hide)
)
(symbol "GND_0_1"
(polyline
(pts
(xy 0 0)
(xy 0 -1.27)
(xy 1.27 -1.27)
(xy 0 -2.54)
(xy -1.27 -1.27)
(xy 0 -1.27)
)
(stroke (width 0) (type default))
(fill (type none))
)
)
(symbol "GND_1_1"
(pin power_in line (at 0 0 270) (length 0) hide
(name "GND" (effects (font (size 1.27 1.27))))
(number "1" (effects (font (size 1.27 1.27))))
)
)
)
)
(junction (at 148.59 111.125) (diameter 0) (color 0 0 0 0)
(uuid d9949e12-7d59-4fa0-9376-be215b981d3b)
)
(wire (pts (xy 163.83 88.9) (xy 165.1 88.9))
(stroke (width 0) (type default))
(uuid 3ab15cd7-3ee4-44df-ad6c-cbcac288143f)
)
(wire (pts (xy 138.43 88.9) (xy 138.43 86.36))
(stroke (width 0) (type default))
(uuid 77fe2f10-ece9-44bb-9f6e-26fb59b7a3cb)
)
(wire (pts (xy 165.1 111.125) (xy 156.21 111.125))
(stroke (width 0) (type default))
(uuid a7275cbb-f17b-4fce-8d4b-ea3c7e571b76)
)
(wire (pts (xy 165.1 88.9) (xy 165.1 111.125))
(stroke (width 0) (type default))
(uuid be74a08e-5427-48d9-a414-e0111932d2ac)
)
(wire (pts (xy 138.43 86.36) (xy 148.59 86.36))
(stroke (width 0) (type default))
(uuid c30eb012-c067-4c94-ba4f-2f991b576739)
)
(wire (pts (xy 148.59 91.44) (xy 148.59 111.125))
(stroke (width 0) (type default))
(uuid de05189f-3d44-41f2-a9fd-69079fb21ccb)
)
(text ".tran 10u 10m" (at 139.7 127 0)
(effects (font (size 1.27 1.27)) (justify left bottom))
(uuid aa794284-c0cd-42ab-a681-5ddda4b38baa)
)
(label "in" (at 138.43 86.36 0) (fields_autoplaced)
(effects (font (size 1.27 1.27)) (justify left bottom))
(uuid dac5b10f-1edf-40bd-a218-aedb682eada0)
)
(label "out" (at 165.1 88.9 0) (fields_autoplaced)
(effects (font (size 1.27 1.27)) (justify left bottom))
(uuid eaa21c01-758b-487b-a59e-e5b4fd6b2bd5)
)
(symbol (lib_id "power:GND") (at 138.43 99.06 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid 1817d463-8d5f-4259-9fae-c9cf8f0de4d7)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 138.43 105.41 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 138.43 102.87 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 138.43 99.06 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 138.43 99.06 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 155fb21a-3ce1-48c4-8cd7-c59174264a56))
)
(symbol (lib_id "Simulation_SPICE:VDC") (at 153.67 101.6 180) (unit 1)
(in_bom yes) (on_board yes)
(uuid 69ce811e-d216-4700-b5e3-329c6d227d5d)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 157.48 99.695 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Value" "" (id 1) (at 157.48 102.235 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Footprint" "" (id 2) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Device" "V" (id 4) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Type" "DC" (id 5) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Pins" "1 2" (id 6) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Params" "dc=5" (id 7) (at 160.02 104.14 0)
(effects (font (size 1.27 1.27)))
)
(pin "1" (uuid 57bc86dd-2187-44f8-993f-d5ba4cfd5b25))
(pin "2" (uuid 6a64d59d-00ea-470e-ae17-010805197609))
)
(symbol (lib_id "Device:R") (at 152.4 111.125 90) (unit 1)
(in_bom yes) (on_board yes)
(uuid 6fd7ad5e-35c3-4ed7-8c83-260de65f107b)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 152.4 113.665 90)
(effects (font (size 1.27 1.27)))
)
(property "Value" "" (id 1) (at 152.4 116.205 90)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 152.4 112.903 90)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 152.4 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 8570589f-3239-4688-b9b7-f28babea55a9))
(pin "2" (uuid b28e6f6a-0a3d-4193-a4fd-094e7eb2bb42))
)
(symbol (lib_id "power:GND") (at 153.67 106.68 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid 8d4f9666-542f-4516-a40b-7249d2f7c19f)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 153.67 113.03 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 157.48 108.585 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 153.67 106.68 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 153.67 106.68 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 1dcdffb5-13db-4746-8996-b72bc72f456d))
)
(symbol (lib_id "Simulation_SPICE:VSIN") (at 138.43 93.98 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid 8fe10d6d-5ad3-4bcf-9fbd-bc9f56307af6)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 118.11 92.71 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Value" "" (id 1) (at 118.11 95.25 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Footprint" "" (id 2) (at 138.43 93.98 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 138.43 93.98 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid e14fe139-e230-4c18-ba7e-26a3436f2277))
(pin "2" (uuid 167be7c4-3f85-4d13-a262-f53f4c67d8c0))
)
(symbol (lib_id "Simulation_SPICE:VDC") (at 153.67 76.2 180) (unit 1)
(in_bom yes) (on_board yes)
(uuid 90069e2b-54a1-463f-b33c-024aaf6ce8c2)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 157.48 74.295 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Value" "" (id 1) (at 157.48 76.835 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Footprint" "" (id 2) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Device" "V" (id 4) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Type" "DC" (id 5) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Pins" "1 2" (id 6) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Params" "dc=5" (id 7) (at 160.02 78.74 0)
(effects (font (size 1.27 1.27)))
)
(pin "1" (uuid 776936fb-a72c-4688-a6a7-994f72ac29e5))
(pin "2" (uuid f1ce0139-e8d7-4f74-bb2a-8e680ca55fda))
)
(symbol (lib_id "Device:R") (at 144.78 111.125 90) (unit 1)
(in_bom yes) (on_board yes)
(uuid 9fefc6e2-71d2-44c1-9223-44afa37bea22)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 144.78 113.665 90)
(effects (font (size 1.27 1.27)))
)
(property "Value" "" (id 1) (at 144.78 116.205 90)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 144.78 112.903 90)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 144.78 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 18222c52-d810-454a-9f36-37f7e5183634))
(pin "2" (uuid f052a642-d7fc-4802-b25f-fd6d95004b7b))
)
(symbol (lib_id "power:GND") (at 153.67 71.12 180) (unit 1)
(in_bom yes) (on_board yes)
(uuid c7a6f233-67b3-4be1-8aa2-56993aa46ebc)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 153.67 64.77 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 157.48 69.85 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 153.67 71.12 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 153.67 71.12 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid ad7ba891-8ff2-4bf4-a870-e5ad25f0a69b))
)
(symbol (lib_id "Simulation_SPICE:OPAMP") (at 156.21 88.9 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid cc59f4a2-42c2-43d4-8c02-165b80567b4f)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 161.29 91.44 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "" (id 1) (at 161.29 93.98 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Primitive" "X" (id 4) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Model" "uopamp_lvl2" (id 5) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Netlist_Enabled" "Y" (id 6) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Lib_File" "opamp.lib.spice" (id 7) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Spice_Node_Sequence" "1 2 4 5 3" (id 8) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid cbbb0b8c-1dbe-4c21-af6e-6e3cf910864c))
(pin "2" (uuid bce0106b-ad36-47f9-9d83-9d977ec7738c))
(pin "3" (uuid a9a4f3a6-caaa-4546-b353-19691ed00cb5))
(pin "4" (uuid e6134a62-7970-44d5-b60f-74c34a29defd))
(pin "5" (uuid 870b6082-c2ac-4465-9283-4dda39395c4c))
)
(symbol (lib_id "power:GND") (at 140.97 111.125 270) (unit 1)
(in_bom yes) (on_board yes) (fields_autoplaced)
(uuid cff6b3be-ce12-4cf3-a4df-6cf831f3551f)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 134.62 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 137.16 111.76 90)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Footprint" "" (id 2) (at 140.97 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 140.97 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 1f17aa02-93a3-4a14-bb64-3ef4902aa181))
)
(sheet_instances
(path "/" (page "1"))
)
(symbol_instances
(path "/1817d463-8d5f-4259-9fae-c9cf8f0de4d7"
(reference "#PWR01") (unit 1) (value "GND") (footprint "")
)
(path "/cff6b3be-ce12-4cf3-a4df-6cf831f3551f"
(reference "#PWR02") (unit 1) (value "GND") (footprint "")
)
(path "/c7a6f233-67b3-4be1-8aa2-56993aa46ebc"
(reference "#PWR03") (unit 1) (value "GND") (footprint "")
)
(path "/8d4f9666-542f-4516-a40b-7249d2f7c19f"
(reference "#PWR04") (unit 1) (value "GND") (footprint "")
)
(path "/9fefc6e2-71d2-44c1-9223-44afa37bea22"
(reference "R1") (unit 1) (value "10k") (footprint "")
)
(path "/6fd7ad5e-35c3-4ed7-8c83-260de65f107b"
(reference "R2") (unit 1) (value "10k") (footprint "")
)
(path "/cc59f4a2-42c2-43d4-8c02-165b80567b4f"
(reference "U1") (unit 1) (value "OPAMP") (footprint "")
)
(path "/90069e2b-54a1-463f-b33c-024aaf6ce8c2"
(reference "V2") (unit 1) (value "VDC") (footprint "")
)
(path "/69ce811e-d216-4700-b5e3-329c6d227d5d"
(reference "V3") (unit 1) (value "VDC") (footprint "")
)
(path "/8fe10d6d-5ad3-4bcf-9fbd-bc9f56307af6"
(reference "VSIN1") (unit 1) (value "ampl=500m f=1k") (footprint "")
)
)
)

View File

@ -0,0 +1,120 @@
* Universal Opamp SPICE Macromodels
* Version: v1.1
* Date: 2019-11-23
*
* Written in 2019 by Ste Kulov, HD Retrovision LLC.
* To the extent possible under law, the author(s) have dedicated all copyright
* and related and neighboring rights to this software to the public domain worldwide.
* This software is distributed without any warranty.
* You should have received a copy of the CC0 Public Domain Dedication along with this software.
* If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
*
*****************************************
*************
* CHANGELOG *
*************
* ---------------------------------------
* v1.0
* 2019-11-08
* ---------------------------------------
* 1.) Initial Release
* ---------------------------------------
*
*
* ---------------------------------------
* v1.1
* 2019-11-23
* ---------------------------------------
* 1.) lvl2: Removed SW model and replaced all instances with semiconductor diodes.
* 2.) lvl2: Added offsets to the voltage sources to compensate for the new semiconductor junctions.
* ---------------------------------------
*****************************************
*****************************************
.subckt uopamp_lvl1 +IN -IN OUT
* Universal Opamp Level 1
* Single pole opamp without voltage rails and referenced to GND
*
* PINOUT ORDER 1 2 3
* PINOUT ORDER +IN -IN OUT
*
* Parameters:
* Avol => open-loop voltage gain (V/V), default=100k
* GBW => gain-bandwidth product (Hz), default=100meg
* Rin => differential input resistance (ohm), default=100g
* Rout => open-loop output resistance (ohm), default=1
*
R1 +IN -IN {Rin}
G1 0 OUT +IN -IN {Avol/Rout}
R2 OUT 0 100g
C3 OUT 0 {Avol/(2*pi*GBW*Rout)}
.param Avol=100k
.param GBW=100meg
.param Rin=100g
.param Rout=1
.param pi=3.1415926535898
.ends
*****************************************
*****************************************
.subckt uopamp_lvl2 +IN -IN VCC VEE OUT
* Universal Opamp Level 2
* Single pole opamp with rail saturation, current consumption, current limiting, and input offset voltage
*
* PINOUT ORDER 1 2 3 4 5
* PINOUT ORDER +IN -IN VCC VEE OUT
*
* Parameters:
* Avol => open-loop voltage gain (V/V), default=100k
* GBW => gain-bandwidth product (Hz), default=100meg
* Rin => differential input resistance (ohm), default=100g
* Rout => open-loop output resistance (ohm), default=1
* Iq => quiescent supply current (A), default=1m
* Ilimit => maximum output current (A), default=1
* Vrail => voltage between output saturation and each rail (V), default=0
* Vos => input offset voltage (V), default=0
* Vmax => total maximum supply voltage between rails (V), default=50
*
G1 VCC N001 N002 -IN 1u
G2 VEE N001 N002 -IN 1u
R1 VCC N001 {Avol/1u}
R2 N001 VEE {Avol/1u}
G3 OUT VCC VCC N001 {1/(2*Rout)}
G4 VEE OUT N001 VEE {1/(2*Rout)}
R4 VCC OUT {2*Rout}
R5 OUT VEE {2*Rout}
C1 VCC N001 {1u/(2*pi*GBW)}
C2 N001 VEE {1u/(2*pi*GBW)}
G6 N005 VEE N001 OUT {1/(2*Rout)}
G5 N006 VEE OUT N001 {1/(2*Rout)}
R8 -IN +IN {Rin}
V6 VCC N003 {Vrail+545m}
V7 N008 VEE {Vrail+545m}
V8 N002 +IN {Vos}
V9 OUT N007 {Ilimit-545m}
V10 N004 OUT {Ilimit-545m}
D1 N001 N003 diode
D2 N008 N001 diode
D3 VCC N005 diode
D4 VCC N006 diode
D5 VEE N005 zener
D6 VEE N006 zener
D7 N001 N004 diode
D8 N007 N001 diode
I1 VCC VEE {Iq}
.param Avol = 100k
.param GBW = 100meg
.param Rin = 100g
.param Rout = 1
.param Iq = 1m
.param Ilimit = 1
.param Vrail = 0
.param Vos = 0
.param Vmax = 50
.model diode D(Is=1e-14)
.model zener D(Is=1e-14 BV={Vmax})
.param pi=3.1415926535898
.ends
*****************************************

View File

@ -286,166 +286,166 @@
)
)
(junction (at 152.4 113.665) (diameter 0) (color 0 0 0 0)
(junction (at 148.59 111.125) (diameter 0) (color 0 0 0 0)
(uuid 7d5f9c7f-c76d-40e1-8801-1df86d468cda)
)
(wire (pts (xy 142.24 88.9) (xy 152.4 88.9))
(wire (pts (xy 138.43 86.36) (xy 148.59 86.36))
(stroke (width 0) (type default))
(uuid 21fe00e7-ba60-4b15-8ef1-025eba89442f)
)
(wire (pts (xy 168.91 91.44) (xy 168.91 113.665))
(wire (pts (xy 165.1 88.9) (xy 165.1 111.125))
(stroke (width 0) (type default))
(uuid 2738cace-8583-4dd0-a73a-e0a00514d71c)
)
(wire (pts (xy 152.4 93.98) (xy 152.4 113.665))
(wire (pts (xy 148.59 91.44) (xy 148.59 111.125))
(stroke (width 0) (type default))
(uuid 384ae57c-e54d-47a4-ba2d-a5f118361f7b)
)
(wire (pts (xy 168.91 113.665) (xy 160.02 113.665))
(wire (pts (xy 165.1 111.125) (xy 156.21 111.125))
(stroke (width 0) (type default))
(uuid 464d44f8-2560-4ecf-89c9-500fb5853871)
)
(wire (pts (xy 142.24 91.44) (xy 142.24 88.9))
(wire (pts (xy 138.43 88.9) (xy 138.43 86.36))
(stroke (width 0) (type default))
(uuid 494e3baa-08d1-4e6f-b155-e344680652a8)
)
(wire (pts (xy 167.64 91.44) (xy 168.91 91.44))
(wire (pts (xy 163.83 88.9) (xy 165.1 88.9))
(stroke (width 0) (type default))
(uuid 55368b74-95a7-4cf2-8f86-415db816907d)
)
(text ".tran 10u 10m" (at 146.05 123.19 0)
(text ".tran 10u 10m" (at 139.7 127 0)
(effects (font (size 1.27 1.27)) (justify left bottom))
(uuid be48cb8e-7c9f-4216-838e-ee151aaeb3f9)
)
(label "out" (at 168.91 91.44 0) (fields_autoplaced)
(label "out" (at 165.1 88.9 0) (fields_autoplaced)
(effects (font (size 1.27 1.27)) (justify left bottom))
(uuid c6d665cf-2828-4128-ae59-06a65deb6b7e)
)
(label "in" (at 142.24 88.9 0) (fields_autoplaced)
(label "in" (at 138.43 86.36 0) (fields_autoplaced)
(effects (font (size 1.27 1.27)) (justify left bottom))
(uuid e8a13b17-85b1-4981-ba25-adfdae039d30)
)
(symbol (lib_id "power:GND") (at 157.48 109.22 0) (unit 1)
(symbol (lib_id "power:GND") (at 153.67 106.68 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid 032a39b4-2686-4cc0-a834-fb52cf55377c)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 157.48 115.57 0)
(property "Reference" "U" (id 0) (at 153.67 113.03 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 161.29 111.125 0)
(property "Value" "" (id 1) (at 157.48 108.585 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 157.48 109.22 0)
(property "Footprint" "" (id 2) (at 153.67 106.68 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 157.48 109.22 0)
(property "Datasheet" "" (id 3) (at 153.67 106.68 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 233df94f-5b6f-4745-8784-1c2d9119d27f))
)
(symbol (lib_id "Simulation_SPICE:VSIN") (at 142.24 96.52 0) (unit 1)
(symbol (lib_id "Simulation_SPICE:VSIN") (at 138.43 93.98 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid 10f44001-5f65-44eb-a535-b7b3c67d5b83)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 121.92 95.25 0)
(property "Reference" "U" (id 0) (at 118.11 92.71 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Value" "" (id 1) (at 121.92 97.79 0)
(property "Value" "" (id 1) (at 118.11 95.25 0)
(effects (font (size 1.27 1.27)) (justify left))
)
(property "Footprint" "" (id 2) (at 142.24 96.52 0)
(property "Footprint" "" (id 2) (at 138.43 93.98 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 142.24 96.52 0)
(property "Datasheet" "~" (id 3) (at 138.43 93.98 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 27dbfa5d-bb20-468f-9a81-7737a5e908fc))
(pin "2" (uuid 63677ebb-93e3-49bb-8bf1-14fce6c8137d))
)
(symbol (lib_id "Device:R") (at 156.21 113.665 90) (unit 1)
(symbol (lib_id "Device:R") (at 152.4 111.125 90) (unit 1)
(in_bom yes) (on_board yes)
(uuid 2a5b0448-42a8-4fa4-9a14-267dc34f9ff7)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 156.21 116.205 90)
(property "Reference" "U" (id 0) (at 152.4 113.665 90)
(effects (font (size 1.27 1.27)))
)
(property "Value" "" (id 1) (at 156.21 118.745 90)
(property "Value" "" (id 1) (at 152.4 116.205 90)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 156.21 115.443 90)
(property "Footprint" "" (id 2) (at 152.4 112.903 90)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 156.21 113.665 0)
(property "Datasheet" "~" (id 3) (at 152.4 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 7cf6d433-268b-4901-b74d-8803afdfc194))
(pin "2" (uuid 63068397-add3-45ea-b295-240f56e8c4f9))
)
(symbol (lib_id "Simulation_SPICE:VDC") (at 157.48 78.74 180) (unit 1)
(symbol (lib_id "Simulation_SPICE:VDC") (at 153.67 76.2 180) (unit 1)
(in_bom yes) (on_board yes)
(uuid 383ea298-1cb3-473e-8fce-19d3c7ac3912)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 161.29 76.835 0)
(property "Reference" "U" (id 0) (at 157.48 74.295 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Value" "" (id 1) (at 161.29 79.375 0)
(property "Value" "" (id 1) (at 157.48 76.835 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Footprint" "" (id 2) (at 157.48 78.74 0)
(property "Footprint" "" (id 2) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 157.48 78.74 0)
(property "Datasheet" "~" (id 3) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Device" "V" (id 4) (at 157.48 78.74 0)
(property "Sim_Device" "V" (id 4) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Type" "DC" (id 5) (at 157.48 78.74 0)
(property "Sim_Type" "DC" (id 5) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Pins" "1 2" (id 6) (at 157.48 78.74 0)
(property "Sim_Pins" "1 2" (id 6) (at 153.67 76.2 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Params" "dc=5" (id 7) (at 163.83 81.28 0)
(property "Sim_Params" "dc=5" (id 7) (at 160.02 78.74 0)
(effects (font (size 1.27 1.27)))
)
(pin "1" (uuid 885c89aa-c780-4741-b398-9d4b8e38f094))
(pin "2" (uuid 8a2dca0c-b99f-4109-a426-af5e80ea91fe))
)
(symbol (lib_id "Simulation_SPICE:OPAMP") (at 160.02 91.44 0) (unit 1)
(symbol (lib_id "Simulation_SPICE:OPAMP") (at 156.21 88.9 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid 3dd58d42-1028-4fbc-adf4-32d03de981a6)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 165.1 93.98 0)
(property "Reference" "U" (id 0) (at 161.29 91.44 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "" (id 1) (at 165.1 96.52 0)
(property "Value" "" (id 1) (at 161.29 93.98 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 160.02 91.44 0)
(property "Footprint" "" (id 2) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 160.02 91.44 0)
(property "Datasheet" "~" (id 3) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Name" "uopamp_lvl2" (id 6) (at 160.02 91.44 0)
(property "Sim_Name" "uopamp_lvl2" (id 6) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Library" "opamp.lib.spice" (id 7) (at 160.02 91.44 0)
(property "Sim_Library" "opamp.lib.spice" (id 7) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Device" "SUBCKT" (id 8) (at 160.02 91.44 0)
(property "Sim_Device" "SUBCKT" (id 8) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Pins" "1 2 4 5 3" (id 9) (at 160.02 91.44 0)
(property "Sim_Pins" "1 2 4 5 3" (id 9) (at 156.21 88.9 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid bd8261ed-4ec3-466d-a593-de8cc22438a4))
@ -455,109 +455,109 @@
(pin "5" (uuid d981b8b1-dd8d-4890-a039-a934391d8000))
)
(symbol (lib_id "power:GND") (at 144.78 113.665 270) (unit 1)
(symbol (lib_id "power:GND") (at 140.97 111.125 270) (unit 1)
(in_bom yes) (on_board yes) (fields_autoplaced)
(uuid 71c5abbf-da89-4208-ab90-ab47cb47a86d)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 138.43 113.665 0)
(property "Reference" "U" (id 0) (at 134.62 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 140.97 114.3 90)
(property "Value" "" (id 1) (at 137.16 111.76 90)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Footprint" "" (id 2) (at 144.78 113.665 0)
(property "Footprint" "" (id 2) (at 140.97 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 144.78 113.665 0)
(property "Datasheet" "" (id 3) (at 140.97 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 70c0dc3a-c9e8-4d2a-a705-c6c89d9bebea))
)
(symbol (lib_id "power:GND") (at 157.48 73.66 180) (unit 1)
(symbol (lib_id "power:GND") (at 153.67 71.12 180) (unit 1)
(in_bom yes) (on_board yes)
(uuid bf78fcdf-1d24-40dc-a76b-1c91df364f4e)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 157.48 67.31 0)
(property "Reference" "U" (id 0) (at 153.67 64.77 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 161.29 72.39 0)
(property "Value" "" (id 1) (at 157.48 69.85 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 157.48 73.66 0)
(property "Footprint" "" (id 2) (at 153.67 71.12 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 157.48 73.66 0)
(property "Datasheet" "" (id 3) (at 153.67 71.12 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid d51f887c-ce71-4e7a-9f6c-4362d9b8286a))
)
(symbol (lib_id "power:GND") (at 142.24 101.6 0) (unit 1)
(symbol (lib_id "power:GND") (at 138.43 99.06 0) (unit 1)
(in_bom yes) (on_board yes)
(uuid c4334e6a-69e5-475f-b5f5-911b3308f64a)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 142.24 107.95 0)
(property "Reference" "U" (id 0) (at 138.43 105.41 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Value" "" (id 1) (at 142.24 105.41 0)
(property "Value" "" (id 1) (at 138.43 102.87 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 142.24 101.6 0)
(property "Footprint" "" (id 2) (at 138.43 99.06 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (id 3) (at 142.24 101.6 0)
(property "Datasheet" "" (id 3) (at 138.43 99.06 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 1af0463f-605e-40b1-8e1c-d6b819b8b4f8))
)
(symbol (lib_id "Simulation_SPICE:VDC") (at 157.48 104.14 180) (unit 1)
(symbol (lib_id "Simulation_SPICE:VDC") (at 153.67 101.6 180) (unit 1)
(in_bom yes) (on_board yes)
(uuid d2018f30-5def-453e-85fe-dac327cfbe9b)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 161.29 102.235 0)
(property "Reference" "U" (id 0) (at 157.48 99.695 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Value" "" (id 1) (at 161.29 104.775 0)
(property "Value" "" (id 1) (at 157.48 102.235 0)
(effects (font (size 1.27 1.27)) (justify right))
)
(property "Footprint" "" (id 2) (at 157.48 104.14 0)
(property "Footprint" "" (id 2) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 157.48 104.14 0)
(property "Datasheet" "~" (id 3) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Device" "V" (id 4) (at 157.48 104.14 0)
(property "Sim_Device" "V" (id 4) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Type" "DC" (id 5) (at 157.48 104.14 0)
(property "Sim_Type" "DC" (id 5) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Pins" "1 2" (id 6) (at 157.48 104.14 0)
(property "Sim_Pins" "1 2" (id 6) (at 153.67 101.6 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Sim_Params" "dc=5" (id 7) (at 163.83 106.68 0)
(property "Sim_Params" "dc=5" (id 7) (at 160.02 104.14 0)
(effects (font (size 1.27 1.27)))
)
(pin "1" (uuid 62bdf880-7061-4b86-be3a-09bf959fae21))
(pin "2" (uuid 9bd26aa2-337b-4c5a-a9de-bdab770672a9))
)
(symbol (lib_id "Device:R") (at 148.59 113.665 90) (unit 1)
(symbol (lib_id "Device:R") (at 144.78 111.125 90) (unit 1)
(in_bom yes) (on_board yes)
(uuid fbe00ebb-3cab-46ea-988c-9e8169e9708f)
(default_instance (reference "U") (unit 1) (value "") (footprint ""))
(property "Reference" "U" (id 0) (at 148.59 116.205 90)
(property "Reference" "U" (id 0) (at 144.78 113.665 90)
(effects (font (size 1.27 1.27)))
)
(property "Value" "" (id 1) (at 148.59 118.745 90)
(property "Value" "" (id 1) (at 144.78 116.205 90)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (id 2) (at 148.59 115.443 90)
(property "Footprint" "" (id 2) (at 144.78 112.903 90)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (id 3) (at 148.59 113.665 0)
(property "Datasheet" "~" (id 3) (at 144.78 111.125 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid fe3f00f2-cee0-4154-8f20-4097e41e635f))

View File

@ -394,6 +394,17 @@ BOOST_AUTO_TEST_CASE( LegacySallenKey )
}*/
BOOST_AUTO_TEST_CASE( LegacyOpamp )
{
TestNetlist( "legacy_opamp" );
TestTranPoint( 0, { { "V(/in)", 0 }, { "V(/out)", 0 } } );
TestTranPoint( 250e-6, { { "V(/in)", 500e-3 }, { "V(/out)", 1 } } );
TestTranPoint( 500e-6, { { "V(/in)", 0 }, { "V(/out)", 0 } } );
TestTranPoint( 750e-6, { { "V(/in)", -500e-3 }, { "V(/out)", -1 } } );
TestTranPoint( 1e-3, { { "V(/in)", 0 }, { "V(/out)", 0 } } );
}
BOOST_AUTO_TEST_SUITE_END()
#endif // KICAD_SPICE