It’s an interesting idea.
I’ve avoided making claims about what a “safe volume” is because I don’t actually know, and the 3000 max isn’t actually a max, it’s just a value where I’m fairly certain that it’s going to sound bad if you go higher.
The origin of the volume calculation in ProffieOS is actually in the dynamic compressor. When I wrote that code, I ended up with a multiplication in it, sort of like:
output sample = \frac{input sample * volume}{\sqrt{\sum{|input samples|}}}
The range of this volume is basically determined by this equation, which is why it ended up the way it did. Initially we started with volumes around 1000, and people have been experimenting with higher and higher volumes ever since.
If the volume is really high, what tends to happen is clipping. The output sample has a min/max of +/- 32768, and if you try to go beyond that, you just get 32768. A little clipping doesn’t matter. A lot of clipping alters the sound significantly, which can be good or bad depending on what you prefer.
Now, proffieboards have a 3 watt amplifier. However, it should be noted that those three watts are calculated on a sine wave with a 1% THD (total harmonic distortion) at 5 volts, with a 4 ohm speaker. 1% THD means that there is a very small amount of clipping going on, so the sine wave basically goes to +/- 32768.
However, things gets complicated…
- Proffieboards use 5.1 volts instead of 5 volts, which would result in ~3.25 watts of output.
- People don’t always use 4 ohm speakers. Speaker ohms vary over frequencies and are seldom well documented.
- If you output a square wave instead of a sine wave, the total amount of energy output doubles to 6.5 watts.
- The dynamic compressor (outlined above) creates a non-obvious relationship between the waveform and how many watts are being output.
Now, when there comes to speaker-killing, there are two distinct ways to kill a speaker (using an amplifier):
- heating/frying the magnet coil
- shake it apart
The first one is generally caused by putting too much wattage into the speaker. However, there is an additional detail that complicates things: The Proffieboard uses a class D amplifier. Class D amplifiers don’t actually output analog signals. Instead, they output very fast digital signals. The amplifier used on Proffieboards output a 400kHz PWM signal and relies on the coil in the speaker to act as a filter to smooth things out. It does this because of efficiency. A regular analog amplifier heats up a fair amount because of acting like a variable resistor, letting just the right voltage out to the speaker at any given time, class D amplifiers don’t have that problem, but dumps that problem on the speaker coil instead. I don’t really know how much extra stress a class D amplifier puts on a speaker, but the energy that gets filtered out by the coil has to go somewhere…
In the case of “shaking things apart”, the problem isn’t so much about how much energy there is. It’s more about how steep the curves are, and sometimes, it’s about resonance. Steep curves in your audio means that the speaker membrane has to move fast, which means higher forces on the speaker, which means more chance of ripping it apart. Obviously steep curves at high volumes are worse than steep curves at low volumes, but I don’t have any math for any of this, so I don’t know how much. In some cases, particular frequencies are easier for the speaker to play because of resonance. It can be a nice thing, because it produces more sound, at least at that frequency, but it can also mean more stress on the speaker membrane. Possibly causing it to break.
Now, probably none of the stuff written above matters.
In practice, most of us are running our speakers far beyond what they were meant to handle, and we just keep some spare speakers around if they break. IF we managed to calculate safe volumes , in spite of the complications above, I suspect that they would be much lower than what people would actually want, which would take us right back to square one again.
As an alternative to all the math above, we could just sit down and do a bunch of speaker testing to establish limits. That would be time-consuming and somewhat expensive, and it would have to be done explicitly for each kind of speaker. (And it could be rendered useless if the manufacturer changes anything in their speaker construction.) It’s possible to do, but unlikely to actually happen I think.
Maybe the best we can do is to build some sort of database where people can enter what fonts, volume and speaker and if they have had any problems with distortion or dead speakers?