Scimpy: open-source speaker design, impedance measurements, & book (Win/Mac/Linux)

Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.
I may be making some incorrect assumptions from this window, but…

Speaker parameters should be in a separate database. A design file should allow the saving of multiple alignments. I find it useful to take a design file and then load a different driver to make comparisons or to start a new design file.

I hope that descriptions make sense.

dave

Speaker database would be great - for now it is set up so the user can type in the specs from the data sheet or measure them using the impedance tool, then use that to design.

https://github.com/maqifrnswa/scimpy/issues/6

An eventual speaker database would be perfect, any volunteers? ;-) Maybe an open source database somewhere on the web that scimpy or other software can connect to?

Saving designs is needed, just need to eventually get to it
https://github.com/maqifrnswa/scimpy/issues/7
 
I'll also ask what is an ideal sealed box? It is different for each application. We should be able to input a volume, and a curve with relavent information shown. Or input desired Q and have box volume spit out.

dave

By "Ideal" I mean pure mathematical function.

I'll rename it as "Calculate B2 Closed Box" and drop the word "ideal" since it implies preference, when I just meant that it was a "design that matches an ideal second-order butterworth transfer function"
https://github.com/maqifrnswa/scimpy/issues/8

We should be able to input a volume, and a curve with relavent information shown. Or input desired Q and have box volume spit out.

That's how it works! Clicking "calculate" just gives you the starting point for box volume & port length/diameter that the user can accept, modify, or just ignore.
 
An eventual speaker database would be perfect, any volunteers? ;-) Maybe an open source database somewhere on the web that scimpy or other software can connect to?

I think a database of published parameters is pointless. You can find many freeware databases full of useless published information. A way to save measurements and projects to files for sharing is all that is needed.
 
frugal-phile™
Joined 2001
Paid Member
for now it is set up so the user can type in the specs from the data sheet or measure them using the impedance tool, then use that to design.

I have no problems with the user making their own database, but there needs to be a database to enter them into … MacSpeakerz came with one, i haven't used a single one of the drivers provided. I have added hundreds of drivers of my own.

dave
 
I think a database of published parameters is pointless. You can find many freeware databases full of useless published information. A way to save measurements and projects to files for sharing is all that is needed.

Thank you Ron and Planet.

It looks like a speaker edit tool is needed. You'd enter (or load or measure) your parameters there, then it will be saved in a "speaker database file" which is a json text file. In the Speaker Model tool you select the speaker you want, and then edit the box. The project can be saved in a "design database" (another json text file). The design will also hold all the speaker parameters, in case the user changes or removes a speaker from the database (and also so you can share whole design databases as well as individual designs)

TODO:
  1. Code documentation and clean up
  2. Finish QB3 alignment so there is at least one completed vented box alignment (QB3-B3-C4)
  3. Place all these widgets and figures in to a single application. Right now there are a bunch of separate tools that open individually. I think we'll have to move to a single UI with toolbars and each tool in a dock.

I think there will be a bit of refactoring going on to implement all this. Git is generally good when lots of changes are going on, but still keep a heads up with the changes. If your changes are incompatible just keep working, we can do a git merge to get them all to line up later.

EDIT:
Also, saving/loading FRD/ZMA files is a must
 
Last edited:
If it helps, here's some equations for QB3, C4, SC4 for the single damped (only leakage term) case
These are from an equation solver, so not quite ready for use

/QB3
AA1=0
AA2=0
/QB3
/C4-SC4
Y=(k^4+6*k^2+1)/8
a1=(1-(1-k^2)/(2*sqrt(2)))*a3/sqrt(Y)
a2=(1+k^2*(1+sqrt(2)))/sqrt(Y)
a3=k*sqrt(4+2*sqrt(2))/sqrt(sqrt(Y))
/C4-SC4

H=Fb/Fs
alpha=Vas/Vb
/common equations
a1=(Ql+h*Qts)/(sqrt(h)*Ql*Qts)
a2=(h+(alpha+1+h^2)*Ql*Qts)/(h*Ql*Qts)
a3=(h*Ql+Qts)/(sqrt(h)*Ql*Qts)
AA1=a1^2-2*a2
AA2=a2^2+2-2*a1*a3
AA3=a3^2-2*a2
/common equations
 
Numpy has helpers for importing data from text:
HTML:
file_data = np.genfromtxt(fname, delimiter="   ", usecols=(0,1))
The above imports frd data from SoundEasy files anyway (minus phase, since I didn't care about that, but you could add that back in).

thank you! that is better than I was going to use, and they have a "comments" argument built in to the function so we can filter out the "*"s. Also ndarray.tofile to save since they are already in numpy arrays.
 
If it helps, here's some equations for QB3, C4, SC4 for the single damped (only leakage term) case
These are from an equation solver, so not quite ready for use

/QB3
AA1=0
AA2=0
/QB3
/C4-SC4
Y=(k^4+6*k^2+1)/8
a1=(1-(1-k^2)/(2*sqrt(2)))*a3/sqrt(Y)
a2=(1+k^2*(1+sqrt(2)))/sqrt(Y)
a3=k*sqrt(4+2*sqrt(2))/sqrt(sqrt(Y))
/C4-SC4

H=Fb/Fs
alpha=Vas/Vb
/common equations
a1=(Ql+h*Qts)/(sqrt(h)*Ql*Qts)
a2=(h+(alpha+1+h^2)*Ql*Qts)/(h*Ql*Qts)
a3=(h*Ql+Qts)/(sqrt(h)*Ql*Qts)
AA1=a1^2-2*a2
AA2=a2^2+2-2*a1*a3
AA3=a3^2-2*a2
/common equations

Thank you! saves me some time!
 
Update:

Overall UI is coming together:

scimpy-docked-widgets.png


Speaker modeling and impedance testing are two docks see as tabbed widgets on the left. Data is shown in the right. You can pull the docks off and place them where ever you like or just have them floating. In the above image, the data is output from the modeling tool. On the right you can see the impedance test tool that now uses Ron E's input/output control.

What works:
  1. Speaker Modeler: enter in any arbitrary T/S and enclosure parameters and get plots of impedance magnitude & phase, SPL magnitude & group delay.
  2. Speaker calculator. Give it driver T/S values and it will find you the values for a B2 closed box volume and a QB3-B4-C4 alignment ported box volume & port length/area ratio. It can do SC4 too, but for now it uses QB3 instead of SC4 (Small wrote at one point that QB3 was better than SC4, but I don't know if that's still popular opinion)
  3. Speaker calculator: give it T/S values and volume of a closed box, it instantly computes f3. Same goes the other way around (give it an f3 and it will compute box volume)
  4. Impedance tool: If you run the tool, you will send a stereo chirped sine wave to your output device (be careful and turn down the volume if it is just going to a speaker and not to a test measurement set-up!) and it will record stereo input from the input device. It will displace the microphone waveform as well as the magnitude of the FFT.

What doesn't work:
  1. Impedance tool: Doesn't give impedance yet. All the data is there, just need to do the math (and know the test resistor value).
  2. Speaker Calculator: doesn't calculate f3 for anything except a B2 closed box. We can find that numerically, probably should just do that.

Short term to do (if anyone wants to tackle these or anything else, please let me know!)
  1. Saving/loading FRD and ZMA files, speaker parameter files/database, and design files/database.
  2. Get impedance testing to work (just needs some math on the data that already exists)
  3. Cosmetic: Reduce speaker modeler widget size, make it narrower, other layout tweaks
  4. Issues listed on github

Questions:
  1. Do people care more about SPL phase or group delay? Or neither, or it depends?

Thanks everyone
 
Last edited:
Very nice graphs!

Update:
(Small wrote at one point that QB3 was better than SC4, but I don't know if that's still popular opinion)

Do people care more about SPL phase or group delay? Or neither, or it depends?

SC4 has slightly better transient response. QB3 has better F3. Both are useful, but if you can only have one, QB3 is best, IMO.

SPL phase for a box design isn't very useful, but since it comes along with the transfer function perhaps just a check box to enable/disable would be useful. Group delay is often desired, but I think few understand it enough for it to be really useful. Not terribly hard to add, though.

Some sort of step/impulse response widget could be more useful ;)

Driver/Vent/PR displacement and velocity for a given stimulus, Max SPL (excursion and thermal limit, whichever is less) both are useful and easy to add.

Dual voice coil support.

Auxiliary filter alignments, passive radiators and 4th order bandpass (just a vented box stiffened by the sealed chamber and with no driver contribution to the sum response) are all quite easy to add.
 
Last edited:
Thanks ron, I added those to the "to do list"
I also have a Windows preview version that can be downloaded for testing.
https://github.com/maqifrnswa/scimpy/releases/tag/v0.0.0

I've been thinking about what should be the minimum requirements for v1.0.0. There are plenty of good free tools out there for cross-over design, frequency response, and other elements of speaker design - so I think it's still best to focus on impedance measurements first. Version 1.0.0 will just target working impedance measurements.

Remember, this isn't just free as in "free beer" but this is also free as in "free speech." It's released open-source with modification and redistribution rights for everyone, even for commercial use (if you follow the GPL). If someone in the community wants to modify anything, code up their own features, or merge anything from this into their own project, they can do that.

Lastly, as this progresses, I'd be interested in comments as to what would make the best UI. Or better yet, someone to fix up the code!

I like this UI, and it looks like we used the same tool kit. We have different functionality, but I think the layout makes sense.
http://www.diyaudio.com/forums/soft...lse-measuring-frequency-impulse-response.html
 
Last edited:
Another update: I'm designing some speakers now, and the results from the modeling tool exactly match Parts Express'
"Optimum Cabinet Size (determined using BassBox 6 Pro High Fidelity suggestion)"

which is good, since it works - but bad because you could just use the part's express website! What that means is that once we can actually measure our own T/S, we can accurately calculate and design for specific drivers that don't match their datasheet
 
frugal-phile™
Joined 2001
Paid Member
T/S Parameters

calculate and design for specific drivers that don't match their datasheet

Do keep in mind that T/S are not scalars but curves. Much of the time people claim that the data they measure is not the same as the manufacturers, but it is really a case of measuring at a different place on the curve. In the case of getting close, it is, to me, more an indication of how horizontal the curve is.

But it is also important to note that manufacturer data is an average across a selection of sample units. I have measured 1000s of drivers, most often in batches of 20 units. Unit-to-unit variation of units with good QC (Mark Audio) hit just under +/- 10% (i have a metric derived from many of the measured results). The Fostex (mediaum QC) can get up to 15-17%, some i have tested are so different that it is hard to imagine they are the same driver.

I measure drivers only to be able to match the drivers, and the measures for a match have to be done in the same session, as the parameters change with the weather. Mostly dominated by temperature and air pressure.

An example set of measurements of a Fostex FE127eN below, my measures (using techniques similar to what this sw does in this case), the same driver tested by Mark Fenlon using typical factory gear and the manufacturers specs. Note that the factory data is for a stock driver, the others are for my treated drivers. Treatment has only a slight effect on the scalars i measure (given the caveat that the measures made after treatment are not done in the same session as when stock).

attachment.php


We rarely build a box for drivers we don't like (we are still into 100s of actual test builds), but i always start with the factory data. Very rarely do we need to adjust the boxes, and changes are rarely because the bass is off.

It is also important to keep in mind that T/S will change with where you have the volume set and dynamically with the music (our boxes typically use bass tuning that is tolerant to changes in T/S).

It would be nice if a measure tool could measure the curve and not just pick scalars off of it.

dave
 

Attachments

  • Fenlon-FE127-measures.gif
    Fenlon-FE127-measures.gif
    7.2 KB · Views: 1,077
I'm looking for something like this Scimpy.

Where is this software available? I've been to the links listed but can't find any way to acquire it. It sounds like it might be more than I need but I like the graphics. Does it use the Thiele and Small parameters for box design and alignment? I've resurrected an old Basic program I used 35 years ago from a David Weems book. The box parameters section works fine but I can't seem to interface the graph section with the GUI on my Mac (Leopard OS). Back in the day I had it on my Apple IIC and the theoretical frequency response graphs were quite good (for the time). They were only "ball park" estimations but you could tell if you were going in the right direction. It saved a lot of trial and error work and the results were darn good. I'd sure like to try Skimpy if it will work with my Mac.
 
Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.