summaryrefslogtreecommitdiff
path: root/library/SubcircuitLibrary/scr
diff options
context:
space:
mode:
authorrahulp132020-02-21 12:36:46 +0530
committerrahulp132020-02-21 12:36:46 +0530
commit47d4daff2ab483c4cdfb82117ef0d25d53832214 (patch)
tree55aefefe974f151de76c6a2dbe8df3b4c3393bbe /library/SubcircuitLibrary/scr
parent453c2dab78f81046fcbd42034a86c4e759a0ff68 (diff)
downloadeSim-47d4daff2ab483c4cdfb82117ef0d25d53832214.tar.gz
eSim-47d4daff2ab483c4cdfb82117ef0d25d53832214.tar.bz2
eSim-47d4daff2ab483c4cdfb82117ef0d25d53832214.zip
restructured eSim libraries
Diffstat (limited to 'library/SubcircuitLibrary/scr')
-rw-r--r--library/SubcircuitLibrary/scr/D.lib20
-rw-r--r--library/SubcircuitLibrary/scr/PowerDiode.lib20
-rw-r--r--library/SubcircuitLibrary/scr/analysis1
-rw-r--r--library/SubcircuitLibrary/scr/scr-cache.lib150
-rw-r--r--library/SubcircuitLibrary/scr/scr-rescue.lib39
-rw-r--r--library/SubcircuitLibrary/scr/scr.cir20
-rw-r--r--library/SubcircuitLibrary/scr/scr.cir.out29
-rw-r--r--library/SubcircuitLibrary/scr/scr.pro45
-rw-r--r--library/SubcircuitLibrary/scr/scr.sch242
-rw-r--r--library/SubcircuitLibrary/scr/scr.sub23
-rw-r--r--library/SubcircuitLibrary/scr/scr_Previous_Values.xml1
11 files changed, 590 insertions, 0 deletions
diff --git a/library/SubcircuitLibrary/scr/D.lib b/library/SubcircuitLibrary/scr/D.lib
new file mode 100644
index 00000000..ef18bb50
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/D.lib
@@ -0,0 +1,20 @@
+.MODEL D1N750 D(
++ Vj=.75
++ Nbvl=14.976
++ Cjo=175p
++ Rs=.25
++ Isr=1.859n
++ Eg=1.11
++ M=.5516
++ Nbv=1.6989
++ N=1
++ Tbv1=-21.277u
++ Bv=8.1
++ Fc=.5
++ Ikf=0
++ Nr=2
++ Ibv=20.245m
++ Is=880.5E-18
++ Xti=3
++ Ibvl=1.9556m
+) \ No newline at end of file
diff --git a/library/SubcircuitLibrary/scr/PowerDiode.lib b/library/SubcircuitLibrary/scr/PowerDiode.lib
new file mode 100644
index 00000000..a2f61dce
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/PowerDiode.lib
@@ -0,0 +1,20 @@
+.MODEL PowerDiode D(
++ Vj=.75
++ Nbvl=14.976
++ Cjo=175p
++ Rs=.25
++ Isr=1.859n
++ Eg=1.11
++ M=.5516
++ Nbv=1.6989
++ N=1
++ Tbv1=-21.277u
++ bv=1800
++ Fc=.5
++ Ikf=0
++ Nr=2
++ Ibv=20.245m
++ Is=2.2E-15
++ Xti=3
++ Ibvl=1.9556m
+) \ No newline at end of file
diff --git a/library/SubcircuitLibrary/scr/analysis b/library/SubcircuitLibrary/scr/analysis
new file mode 100644
index 00000000..687c71ec
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/analysis
@@ -0,0 +1 @@
+.tran 0e-12 0e-00 0e-00 \ No newline at end of file
diff --git a/library/SubcircuitLibrary/scr/scr-cache.lib b/library/SubcircuitLibrary/scr/scr-cache.lib
new file mode 100644
index 00000000..0a685b80
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr-cache.lib
@@ -0,0 +1,150 @@
+EESchema-LIBRARY Version 2.3
+#encoding utf-8
+#
+# C
+#
+DEF C C 0 10 N Y 1 F N
+F0 "C" 25 100 50 H V L CNN
+F1 "C" 25 -100 50 H V L CNN
+F2 "" 38 -150 50 H I C CNN
+F3 "" 0 0 50 H I C CNN
+$FPLIST
+ C_*
+$ENDFPLIST
+DRAW
+P 2 0 1 20 -80 -30 80 -30 N
+P 2 0 1 20 -80 30 80 30 N
+X ~ 1 0 150 110 D 50 50 1 1 P
+X ~ 2 0 -150 110 U 50 50 1 1 P
+ENDDRAW
+ENDDEF
+#
+# CCCS
+#
+DEF CCCS F 0 40 Y Y 1 F N
+F0 "F" 0 150 50 H V C CNN
+F1 "CCCS" -200 -50 50 H V C CNN
+F2 "" 0 0 60 H V C CNN
+F3 "" 0 0 60 H V C CNN
+$FPLIST
+ 1_pin
+$ENDFPLIST
+DRAW
+S -100 100 100 -100 0 1 0 N
+X + 1 -300 50 200 R 35 35 1 1 P
+X - 2 300 50 200 L 35 35 1 1 P
+X +c 3 -50 -200 100 U 35 35 1 1 P
+X -c 4 50 -200 100 U 35 35 1 1 P
+ENDDRAW
+ENDDEF
+#
+# DIODE
+#
+DEF DIODE D 0 40 N N 1 F N
+F0 "D" 0 100 40 H V C CNN
+F1 "DIODE" 0 -100 40 H V C CNN
+F2 "" 0 0 60 H V C CNN
+F3 "" 0 0 60 H V C CNN
+$FPLIST
+ D?
+ S*
+$ENDFPLIST
+DRAW
+P 2 0 1 6 50 50 50 -50 N
+P 3 0 1 0 -50 50 50 0 -50 -50 F
+X A 1 -200 0 150 R 40 40 1 1 P
+X K 2 200 0 150 L 40 40 1 1 P
+ENDDRAW
+ENDDEF
+#
+# PORT
+#
+DEF PORT U 0 40 Y Y 26 F N
+F0 "U" 50 100 30 H V C CNN
+F1 "PORT" 0 0 30 H V C CNN
+F2 "" 0 0 60 H V C CNN
+F3 "" 0 0 60 H V C CNN
+DRAW
+A 325 225 285 -1421 -1278 0 1 0 N 100 50 150 0
+A 376 -275 356 1294 1408 0 1 0 N 150 0 100 -50
+S -100 50 100 -50 0 1 0 N
+X ~ 1 250 0 100 L 30 30 1 1 B
+X ~ 2 250 0 100 L 30 30 2 1 B
+X ~ 3 250 0 100 L 30 30 3 1 B
+X ~ 4 250 0 100 L 30 30 4 1 B
+X ~ 5 250 0 100 L 30 30 5 1 B
+X ~ 6 250 0 100 L 30 30 6 1 B
+X ~ 7 250 0 100 L 30 30 7 1 B
+X ~ 8 250 0 100 L 30 30 8 1 B
+X ~ 9 250 0 100 L 30 30 9 1 B
+X ~ 10 250 0 100 L 30 30 10 1 B
+X ~ 11 250 0 100 L 30 30 11 1 B
+X ~ 12 250 0 100 L 30 30 12 1 B
+X ~ 13 250 0 100 L 30 30 13 1 B
+X ~ 14 250 0 100 L 30 30 14 1 B
+X ~ 15 250 0 100 L 30 30 15 1 B
+X ~ 16 250 0 100 L 30 30 16 1 B
+X ~ 17 250 0 100 L 30 30 17 1 B
+X ~ 18 250 0 100 L 30 30 18 1 B
+X ~ 19 250 0 100 L 30 30 19 1 B
+X ~ 20 250 0 100 L 30 30 20 1 B
+X ~ 21 250 0 100 L 30 30 21 1 B
+X ~ 22 250 0 100 L 30 30 22 1 B
+X ~ 23 250 0 100 L 30 30 23 1 B
+X ~ 24 250 0 100 L 30 30 24 1 B
+X ~ 25 250 0 100 L 30 30 25 1 B
+X ~ 26 250 0 100 L 30 30 26 1 B
+ENDDRAW
+ENDDEF
+#
+# R-RESCUE-scr
+#
+DEF R-RESCUE-scr R 0 0 N Y 1 F N
+F0 "R" 50 130 50 H V C CNN
+F1 "R-RESCUE-scr" 50 50 50 H V C CNN
+F2 "" 50 -20 30 H V C CNN
+F3 "" 50 50 30 V V C CNN
+$FPLIST
+ R_*
+ Resistor_*
+$ENDFPLIST
+DRAW
+S 150 10 -50 90 0 1 10 N
+X ~ 1 -100 50 50 R 60 60 1 1 P
+X ~ 2 200 50 50 L 60 60 1 1 P
+ENDDRAW
+ENDDEF
+#
+# aswitch
+#
+DEF aswitch U 0 40 Y Y 1 F N
+F0 "U" 450 300 60 H V C CNN
+F1 "aswitch" 450 200 60 H V C CNN
+F2 "" 450 100 60 H V C CNN
+F3 "" 450 100 60 H V C CNN
+DRAW
+S 200 250 650 100 0 1 0 N
+X ~ 2 0 150 200 R 50 50 1 1 O
+X ~ 3 850 150 200 L 50 50 1 1 O
+X ~ 1_IN 450 -100 200 U 50 20 1 1 I
+ENDDRAW
+ENDDEF
+#
+# dc-RESCUE-scr
+#
+DEF dc-RESCUE-scr v 0 40 Y Y 1 F N
+F0 "v" -200 100 60 H V C CNN
+F1 "dc-RESCUE-scr" -200 -50 60 H V C CNN
+F2 "R1" -300 0 60 H V C CNN
+F3 "" 0 0 60 H V C CNN
+$FPLIST
+ 1_pin
+$ENDFPLIST
+DRAW
+C 0 0 150 0 1 0 N
+X + 1 0 450 300 D 50 50 1 1 P
+X - 2 0 -450 300 U 50 50 1 1 P
+ENDDRAW
+ENDDEF
+#
+#End Library
diff --git a/library/SubcircuitLibrary/scr/scr-rescue.lib b/library/SubcircuitLibrary/scr/scr-rescue.lib
new file mode 100644
index 00000000..64237b7d
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr-rescue.lib
@@ -0,0 +1,39 @@
+EESchema-LIBRARY Version 2.3
+#encoding utf-8
+#
+# R-RESCUE-scr
+#
+DEF R-RESCUE-scr R 0 0 N Y 1 F N
+F0 "R" 50 130 50 H V C CNN
+F1 "R-RESCUE-scr" 50 50 50 H V C CNN
+F2 "" 50 -20 30 H V C CNN
+F3 "" 50 50 30 V V C CNN
+$FPLIST
+ R_*
+ Resistor_*
+$ENDFPLIST
+DRAW
+S 150 10 -50 90 0 1 10 N
+X ~ 1 -100 50 50 R 60 60 1 1 P
+X ~ 2 200 50 50 L 60 60 1 1 P
+ENDDRAW
+ENDDEF
+#
+# dc-RESCUE-scr
+#
+DEF dc-RESCUE-scr v 0 40 Y Y 1 F N
+F0 "v" -200 100 60 H V C CNN
+F1 "dc-RESCUE-scr" -200 -50 60 H V C CNN
+F2 "R1" -300 0 60 H V C CNN
+F3 "" 0 0 60 H V C CNN
+$FPLIST
+ 1_pin
+$ENDFPLIST
+DRAW
+C 0 0 150 0 1 0 N
+X + 1 0 450 300 D 50 50 1 1 P
+X - 2 0 -450 300 U 50 50 1 1 P
+ENDDRAW
+ENDDEF
+#
+#End Library
diff --git a/library/SubcircuitLibrary/scr/scr.cir b/library/SubcircuitLibrary/scr/scr.cir
new file mode 100644
index 00000000..4b279764
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr.cir
@@ -0,0 +1,20 @@
+* /opt/eSim/src/SubcircuitLibrary/scr/scr.cir
+
+* EESchema Netlist Version 1.1 (Spice format) creation date: Tue Dec 8 15:47:20 2015
+
+* To exclude a component from the Spice Netlist add [Spice_Netlist_Enabled] user FIELD set to: N
+* To reorder the component spice node sequence add [Spice_Node_Sequence] user FIELD and define sequence: 2,1,0
+
+* Sheet Name: /
+U2 3 7 1 PORT
+F2 3 9 2 3 100
+D1 5 2 D
+C1 3 9 10u
+F1 3 9 4 3 10
+v1 8 4 dc
+v2 6 5 dc
+U1 9 1 6 aswitch
+R1 7 8 50
+R2 3 9 1
+
+.end
diff --git a/library/SubcircuitLibrary/scr/scr.cir.out b/library/SubcircuitLibrary/scr/scr.cir.out
new file mode 100644
index 00000000..d600f25d
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr.cir.out
@@ -0,0 +1,29 @@
+* /opt/esim/src/subcircuitlibrary/scr/scr.cir
+
+.include PowerDiode.lib
+* u2 3 7 1 port
+* f2
+d1 5 2 PowerDiode
+c1 3 9 10u
+* f1
+v1 8 4 dc 0
+v2 6 5 dc 0
+* u1 9 1 6 aswitch
+r1 7 8 50
+r2 3 9 1
+Vf2 2 3 0
+f2 3 9 Vf2 100
+Vf1 4 3 0
+f1 3 9 Vf1 10
+a1 9 (1 6) u1
+* Schematic Name: aswitch, NgSpice Name: aswitch
+.model u1 aswitch(log=TRUE cntl_off=0.0 cntl_on=1.0 r_on=1.0 r_off=1.0e12 )
+.tran 0e-12 0e-00 0e-00
+
+* Control Statements
+.control
+run
+print allv > plot_data_v.txt
+print alli > plot_data_i.txt
+.endc
+.end
diff --git a/library/SubcircuitLibrary/scr/scr.pro b/library/SubcircuitLibrary/scr/scr.pro
new file mode 100644
index 00000000..ca0df803
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr.pro
@@ -0,0 +1,45 @@
+update=Wed Jul 31 19:51:09 2019
+last_client=kicad
+[eeschema]
+version=1
+LibDir=
+[eeschema/libraries]
+LibName1=scr-rescue
+LibName2=eSim_Analog
+LibName3=eSim_Devices
+LibName4=eSim_Digital
+LibName5=eSim_Hybrid
+LibName6=eSim_Miscellaneous
+LibName7=eSim_Sources
+LibName8=eSim_Subckt
+LibName9=eSim_User
+LibName10=power
+LibName11=device
+LibName12=transistors
+LibName13=conn
+LibName14=linear
+LibName15=regul
+LibName16=74xx
+LibName17=cmos4000
+LibName18=adc-dac
+LibName19=memory
+LibName20=xilinx
+LibName21=special
+LibName22=microcontrollers
+LibName23=dsp
+LibName24=microchip
+LibName25=analog_switches
+LibName26=motorola
+LibName27=texas
+LibName28=intel
+LibName29=audio
+LibName30=interface
+LibName31=digital-audio
+LibName32=philips
+LibName33=display
+LibName34=cypress
+LibName35=siliconi
+LibName36=opto
+LibName37=atmel
+LibName38=contrib
+LibName39=valves
diff --git a/library/SubcircuitLibrary/scr/scr.sch b/library/SubcircuitLibrary/scr/scr.sch
new file mode 100644
index 00000000..69244f56
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr.sch
@@ -0,0 +1,242 @@
+EESchema Schematic File Version 2
+LIBS:scr-rescue
+LIBS:eSim_Analog
+LIBS:eSim_Devices
+LIBS:eSim_Digital
+LIBS:eSim_Hybrid
+LIBS:eSim_Miscellaneous
+LIBS:eSim_Sources
+LIBS:eSim_Subckt
+LIBS:eSim_User
+LIBS:power
+LIBS:device
+LIBS:transistors
+LIBS:conn
+LIBS:linear
+LIBS:regul
+LIBS:74xx
+LIBS:cmos4000
+LIBS:adc-dac
+LIBS:memory
+LIBS:xilinx
+LIBS:microcontrollers
+LIBS:dsp
+LIBS:microchip
+LIBS:analog_switches
+LIBS:motorola
+LIBS:texas
+LIBS:intel
+LIBS:audio
+LIBS:interface
+LIBS:digital-audio
+LIBS:philips
+LIBS:display
+LIBS:cypress
+LIBS:siliconi
+LIBS:opto
+LIBS:atmel
+LIBS:contrib
+LIBS:valves
+LIBS:scr-cache
+EELAYER 25 0
+EELAYER END
+$Descr A4 11693 8268
+encoding utf-8
+Sheet 1 1
+Title ""
+Date "21 aug 2014"
+Rev ""
+Comp ""
+Comment1 ""
+Comment2 ""
+Comment3 ""
+Comment4 ""
+$EndDescr
+Wire Wire Line
+ 3600 3250 3600 3150
+Connection ~ 5550 4950
+Wire Wire Line
+ 5800 3900 5800 3850
+Wire Wire Line
+ 5800 3850 6150 3850
+Wire Wire Line
+ 6150 3850 6150 4950
+Wire Wire Line
+ 6150 4950 3600 4950
+Connection ~ 4300 4950
+Wire Wire Line
+ 4300 4950 4300 4050
+Wire Wire Line
+ 4300 4050 3850 4050
+Wire Wire Line
+ 4700 5400 4700 5950
+Wire Wire Line
+ 4250 5950 4250 5500
+Connection ~ 4250 4950
+Wire Wire Line
+ 4250 4950 4250 5200
+Wire Wire Line
+ 5550 3600 5550 3450
+Wire Wire Line
+ 5550 4950 5550 4250
+Wire Wire Line
+ 3600 4950 3600 4400
+Wire Wire Line
+ 3600 2300 3600 2850
+Wire Wire Line
+ 3600 2300 3150 2300
+Wire Wire Line
+ 3600 4150 3600 4300
+Wire Wire Line
+ 5550 4150 5550 4000
+Wire Wire Line
+ 5550 2550 5550 2250
+Wire Wire Line
+ 4700 4950 4700 5100
+Connection ~ 4700 4950
+Wire Wire Line
+ 6650 2000 6650 5950
+Connection ~ 4700 5950
+Wire Wire Line
+ 3850 4650 3850 5950
+Wire Wire Line
+ 3850 5950 6650 5950
+Connection ~ 4250 5950
+Wire Wire Line
+ 5800 4500 5800 5950
+Connection ~ 5800 5950
+$Comp
+L PORT U2
+U 3 1 53F4C93D
+P 6650 2250
+F 0 "U2" H 6650 2200 30 0000 C CNN
+F 1 "PORT" H 6650 2250 30 0000 C CNN
+F 2 "" H 6650 2250 60 0001 C CNN
+F 3 "" H 6650 2250 60 0001 C CNN
+ 3 6650 2250
+ -1 0 0 1
+$EndComp
+$Comp
+L PORT U2
+U 2 1 53F4C934
+P 2900 2300
+F 0 "U2" H 2900 2250 30 0000 C CNN
+F 1 "PORT" H 2900 2300 30 0000 C CNN
+F 2 "" H 2900 2300 60 0001 C CNN
+F 3 "" H 2900 2300 60 0001 C CNN
+ 2 2900 2300
+ 1 0 0 -1
+$EndComp
+$Comp
+L PORT U2
+U 1 1 53F4C92A
+P 6400 4950
+F 0 "U2" H 6400 4900 30 0000 C CNN
+F 1 "PORT" H 6400 4950 30 0000 C CNN
+F 2 "" H 6400 4950 60 0001 C CNN
+F 3 "" H 6400 4950 60 0001 C CNN
+ 1 6400 4950
+ -1 0 0 1
+$EndComp
+$Comp
+L CCCS F2
+U 1 1 53F4C735
+P 5750 4200
+F 0 "F2" H 5550 4300 50 0000 C CNN
+F 1 "100" H 5550 4150 50 0000 C CNN
+F 2 "" H 5750 4200 60 0001 C CNN
+F 3 "" H 5750 4200 60 0001 C CNN
+ 1 5750 4200
+ 0 1 1 0
+$EndComp
+$Comp
+L DIODE D1
+U 1 1 53F4C6D9
+P 5550 3800
+F 0 "D1" H 5550 3900 40 0000 C CNN
+F 1 "D" H 5550 3700 40 0000 C CNN
+F 2 "" H 5550 3800 60 0001 C CNN
+F 3 "" H 5550 3800 60 0001 C CNN
+ 1 5550 3800
+ 0 1 1 0
+$EndComp
+$Comp
+L C C1
+U 1 1 53F4C6C2
+P 4700 5250
+F 0 "C1" H 4750 5350 50 0000 L CNN
+F 1 "10u" H 4750 5150 50 0000 L CNN
+F 2 "" H 4700 5250 60 0001 C CNN
+F 3 "" H 4700 5250 60 0001 C CNN
+ 1 4700 5250
+ 1 0 0 -1
+$EndComp
+$Comp
+L CCCS F1
+U 1 1 53F4C67F
+P 3800 4350
+F 0 "F1" H 3600 4450 50 0000 C CNN
+F 1 "10" H 3600 4300 50 0000 C CNN
+F 2 "" H 3800 4350 60 0001 C CNN
+F 3 "" H 3800 4350 60 0001 C CNN
+ 1 3800 4350
+ 0 1 1 0
+$EndComp
+$Comp
+L dc-RESCUE-scr v1
+U 1 1 565DBF58
+P 3600 3700
+F 0 "v1" H 3400 3800 60 0000 C CNN
+F 1 "dc" H 3400 3650 60 0000 C CNN
+F 2 "R1" H 3300 3700 60 0000 C CNN
+F 3 "" H 3600 3700 60 0000 C CNN
+ 1 3600 3700
+ 1 0 0 -1
+$EndComp
+$Comp
+L dc-RESCUE-scr v2
+U 1 1 565DC066
+P 5550 3000
+F 0 "v2" H 5350 3100 60 0000 C CNN
+F 1 "dc" H 5350 2950 60 0000 C CNN
+F 2 "R1" H 5250 3000 60 0000 C CNN
+F 3 "" H 5550 3000 60 0000 C CNN
+ 1 5550 3000
+ 1 0 0 -1
+$EndComp
+$Comp
+L aswitch U1
+U 1 1 565DC87E
+P 6400 2100
+F 0 "U1" H 6850 2400 60 0000 C CNN
+F 1 "aswitch" H 6850 2300 60 0000 C CNN
+F 2 "" H 6850 2200 60 0000 C CNN
+F 3 "" H 6850 2200 60 0000 C CNN
+ 1 6400 2100
+ -1 0 0 1
+$EndComp
+Wire Wire Line
+ 5950 2000 6650 2000
+$Comp
+L R-RESCUE-scr R1
+U 1 1 5666B019
+P 3550 2950
+F 0 "R1" H 3600 3080 50 0000 C CNN
+F 1 "50" H 3600 3000 50 0000 C CNN
+F 2 "" H 3600 2930 30 0000 C CNN
+F 3 "" V 3600 3000 30 0000 C CNN
+ 1 3550 2950
+ 0 1 1 0
+$EndComp
+$Comp
+L R-RESCUE-scr R2
+U 1 1 5666B17A
+P 4200 5300
+F 0 "R2" H 4250 5430 50 0000 C CNN
+F 1 "1" H 4250 5350 50 0000 C CNN
+F 2 "" H 4250 5280 30 0000 C CNN
+F 3 "" V 4250 5350 30 0000 C CNN
+ 1 4200 5300
+ 0 1 1 0
+$EndComp
+$EndSCHEMATC
diff --git a/library/SubcircuitLibrary/scr/scr.sub b/library/SubcircuitLibrary/scr/scr.sub
new file mode 100644
index 00000000..398c8921
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr.sub
@@ -0,0 +1,23 @@
+* Subcircuit scr
+.subckt scr 3 7 1
+* /opt/esim/src/subcircuitlibrary/scr/scr.cir
+.include PowerDiode.lib
+* f2
+d1 5 2 PowerDiode
+c1 3 9 10u
+* f1
+v1 8 4 dc 0
+v2 6 5 dc 0
+* u1 9 1 6 aswitch
+r1 7 8 50
+r2 3 9 1
+Vf2 2 3 0
+f2 3 9 Vf2 100
+Vf1 4 3 0
+f1 3 9 Vf1 10
+a1 9 (1 6) u1
+* Schematic Name: aswitch, NgSpice Name: aswitch
+.model u1 aswitch(log=TRUE cntl_off=0.0 cntl_on=1.0 r_on=1.0 r_off=1.0e12 )
+* Control Statements
+
+.ends scr
diff --git a/library/SubcircuitLibrary/scr/scr_Previous_Values.xml b/library/SubcircuitLibrary/scr/scr_Previous_Values.xml
new file mode 100644
index 00000000..8ff6e8d3
--- /dev/null
+++ b/library/SubcircuitLibrary/scr/scr_Previous_Values.xml
@@ -0,0 +1 @@
+<KicadtoNgspice><source><v1 name="Source type">dc<field1 name="Value">0</field1></v1><v2 name="Source type">dc<field1 name="Value">0</field1></v2></source><model><u1 name="type">aswitch<field1 name="Enter Log (default=TRUE)" /><field2 name="Enter Control OFF value (default=0.0)" /><field3 name="Enter OFF Resistance (default=1.0e12)" /><field4 name="Enter ON Resistance (default=1.0)" /><field5 name="Enter Control ON value(default=1.0)" /></u1></model><devicemodel><d1><field>/opt/eSim/src/deviceModelLibrary/Diode/PowerDiode.lib</field></d1></devicemodel><subcircuit /><analysis><ac><field1 name="Lin">true</field1><field2 name="Dec">false</field2><field3 name="Oct">false</field3><field4 name="Start Frequency" /><field5 name="Stop Frequency" /><field6 name="No. of points" /><field7 name="Start Fre Combo">Hz</field7><field8 name="Stop Fre Combo">Hz</field8></ac><dc><field1 name="Source Name" /><field2 name="Start" /><field3 name="Increment" /><field4 name="Stop" /><field5 name="Operating Point">0</field5><field6 name="Start Combo">Volts or Amperes</field6><field7 name="Increment Combo">Volts or Amperes</field7><field8 name="Stop Combo">Volts or Amperes</field8></dc><tran><field1 name="Start Time" /><field2 name="Step Time" /><field3 name="Stop Time" /><field4 name="Start Combo">Sec</field4><field5 name="Step Combo">ps</field5><field6 name="Stop Combo">Sec</field6></tran></analysis></KicadtoNgspice> \ No newline at end of file