summaryrefslogtreecommitdiff
path: root/Windows/spice/examples/xspice/original-examples/analog_models4_ac.deck
blob: 70413e1ad04e86d9ff7049c449cc13afcea8a21d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
Code Model Test - DC: sine, triangle, aswitch, zener, oneshot
*
*
*** analysis type ***
.ac dec 10 10 1000
*
*
*** input sources ***
*
v1 1 0 1.0 AC 1.0 0.0
*
v2 2 0 DC 1.0
*
v3 3 0 DC 1.0
*
*
*
*
*** sine block ***
a1 1 10 sine1
.model sine1 sine (cntl_array=[-1.0 0.0 1.0 2.0] 
+                  freq_array=[1.0 1.0 100.0 100.0]
+                  out_low=-1.0 out_high=1.0)
*
*
*** triangle block ***
a2 1 20 triangle1
.model triangle1 triangle (cntl_array=[-1.0 0.0 1.0 2.0] 
+                  freq_array=[1.0 1.0 100.0 100.0]
+                  out_low=-1.0 out_high=1.0 duty_cycle=0.8)
*
*
*** aswitch block ***
a3 1 (2 30) aswitch1
.model aswitch1 aswitch (cntl_off=0.0 cntl_on=1.0 log=TRUE
+                        r_off=1.0e12 r_on=10.0)
*
*
*** zener diode ***
r4 1 40 10K
a4 (40 0) zener1
.model zener1 zener (v_breakdown=10.0 i_breakdown=2.0e-2
+                    r_breakdown=1.0 i_rev=1.0e-6 i_sat=1.0e-12
+                    n_forward=1.0 limit_switch=FALSE)
*
*
*** oneshot block ***
a5 3 1 2 50 oneshot1
.model oneshot1 oneshot (cntl_array=[-1.0 0.0 1.0 2.0]
+                        pw_array=[1.0 1.0 0.1 0.1] clk_trig=0.5
+                        pos_edge_trig=TRUE out_low=0.0 out_high=1.0
+                        rise_time=1.0e-6 rise_delay=1.0e-9 
+                        fall_delay=1.0e-9 fall_time=1.0e-6
+                        retrig=FALSE)
*
*
*
*
*** resistors to ground ***
r1 1 0 10k
r2 2 0 10k
r3 3 0 10k
*
r10 10 0 10k
r20 20 0 10k
r30 30 0 10k
r40 40 0 10k
r50 50 0 10k
r60 60 0 10k
*
*
.end