forked from labtroll/KiCad-Simulations
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathLoudspeaker.lib
138 lines (136 loc) · 3.71 KB
/
Loudspeaker.lib
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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
* https://www.electro-tech-online.com/threads/ltspice-model-loudspeaker.142634/
* Source File: SpeakerBlock.asc
* Developer: ETech ([email protected])
* Created: Oct 25 2014
* Revision: NA
*
* This Loudspeaker spice model was tested with
* LTSpice IV. Temperature is not modeled. It is
* intended to be used as a test aid for audio
* crossover networks.
*
* Modified for ngspice by H. Vogt
* Jan 6th, 2022
*
* The following parameters can usually be supplied
* directly from the speaker specification sheet
* Parameters:
* Re = Measured Voice Coil Resistance
* Le = Measured Voice Coil Inductance
* Fs = Resonant Frequency
* Qms = Mech Suspension control measurement (Surround and Spider)
* Qes = Electrical Suspension control measurement (Voice coil and Magnet)
*
* Calculations:
* Res = (Qms / Qes) * Re = (Core & Suspension Losses)
* Lces = Re / (2 * pi * Fs * Qes) = (Cone Mass)
* Cmes = Qes / (2 * pi * Fs * Re) = (Cone Suspension)
*
* Template use info:
* 1. Copy template to appropriate section
* (Tweeter, Midrange, Woofer, subwoofer section)
* 2. Replace [Name] with unique name (use model number)
* 3. Replace each [value] with appropiate value
* 4. Remove comment character "*" before ".subckt",
* "XSpkr" and ".ends" statements to activate.
****************Begin Template*****************
* [Description]
*
*.subckt [Name] SPK+ SPK- PARAMS: Re=[value] Le=[value] Fs=[value] Qms=[value] Qes=[value]
*
** Do not edit line below, but remove leading "*" character
*XSpkr SPK+ SPK- speaker Re1={Re} Le1={Le} Fs1={Fs} Qms1={Qms} Qes1={Qes}
*
*.ends [Name]
****************END Template*******************
*
*
* Subckt Symbol Definitions
*
*
* TWEETER
***********************************************
* Dayton Audio DC28F-4 1-1/8" Silk Dome Tweeter
*
.subckt DC28F4 SPK+ SPK- PARAMS: Re=2.82 Le=0.51m Fs=535 Qms=2.3 Qes=0.99
*
XSpkr SPK+ SPK- speaker Re={Re} Le={Le} Fs={Fs} Qms={Qms} Qes={Qes}
*
.ends DC28F4
*
* Dayton Audio DC28F-8 1-1/8" Silk Dome Tweeter
*
.subckt DC28F8 SPK+ SPK- PARAMS: Re=5.5 Le=0.09m Fs=637.2 Qms=0.82 Qes=0.90
*
XSpkr SPK+ SPK- speaker Re={Re} Le={Le} Fs={Fs} Qms={Qms} Qes={Qes}
*
.ends DC28F8
*
* Focal Tc120td5 20mm Tioxid Dome Tweeter
*
.subckt Tc120td5 SPK+ SPK- PARAMS: Re=6 Le=1.49m Fs=812.7 Qms=2.79 Qes=1.15
*
XSpkr SPK+ SPK- speaker Re={Re} Le={Le} Fs={Fs} Qms={Qms} Qes={Qes}
*
.ends Tc120td5
* Focal Tc120tdx 20mm Tioxid Dome Tweeter
*
.subckt Tc120tdx SPK+ SPK- PARAMS: Re=5.7 Le=0.08m Fs=1181 Qms=2.16 Qes=1.42
*
XSpkr SPK+ SPK- speaker Re1={Re} Le1={Le} Fs1={Fs} Qms1={Qms} Qes1={Qes}
*
.ends Tc120tdx
*
*
* MIDRANGE
***********************************************
* Dayton Audio DC50FA-8 Classic Series 2" Dome Midrange
*
.subckt DC50FA8 SPK+ SPK-
.PARAM Re=4.50 Le=0.41m Fs=380 Qms=4.13 Qes=1.16
*
XSpkr SPK+ SPK- speaker Re={Re} Le={Le} Fs={Fs} Qms={Qms} Qes={Qes}
*
.ends DC50FA8
*
*
* WOOFER
***********************************************
* Dayton Audio RS225-8 8" Reference Woofer
*
.subckt RS2258 SPK+ SPK- PARAMS: Re=6.53 Le=0.86m Fs=28 Qms=1.46 Qes=0.51
*
XSpkr SPK+ SPK- speaker Re={Re} Le={Le} Fs={Fs} Qms={Qms} Qes={Qes}
*
.ends RS2258
*
*
* SUBWOOFER
***********************************************
* Dayton Audio IB385-8 8" Reference Woofer
*
.subckt IB3858 SPK+ SPK- PARAMS: Re=5.2 Le=3.08m Fs=21.5 Qms=8.92 Qes=0.63
*
XSpkr SPK+ SPK- speaker Re={Re} Le={Le} Fs={Fs} Qms={Qms} Qes={Qes}
*
.ends IB3858
*
*
* Main speaker model definition (do not edit)
***********************************************
.subckt speaker SP+ SP- Re={Re} Le={Le} Fs={Fs} Qms={Qms} Qes={Qes}
*
.param Re = {Re}
.param Le = {Le}
.param pi = 3.14
.param Res = {(Qms / Qes) * Re}
.param Lces = {Re / (2 * pi * Fs * Qes)}
.param Cmes = {Qes / (2 * pi * Fs * Re)}
*
L2 SP- 3 {Lces}
C1 3 SP- {Cmes}
L1 2 3 {Le}
R2 3 SP- {Res}
R1 2 SP+ {Re}
*
.ends speaker