- Edited
lokki will do, it could be a couple of weeks before i get to it
No hurry. This is all for fun and education
lokki 100 (50-190), 225, 330, 470, 700, 1030, 1500, 2280, 3300, 4700, 9000(6800-12700)
In the current code these can be manually assigned as my prior instructions suggested. Q = fc/BW. The main interest in frequency sweep and/or step response data is to get an estimate of filter order used.
matt but when you do that make sure the pulsewidth is set as low as possible, essentially turning the square wave into a pulse train.
@lokki Please use the step response (long pulses)
@matt Here is why I advise against using short pulses: What you say is true in theory, but the impulse response will be coming into your measurement system on the order of microvolts (signal-noise ratio becomes a very big deal). If you jack up the impulse amplitude, then you drive the system nonlinear and then the assumption of an LTI system is no longer a valid approximation. If you amplify the output then you amplify the noise with it so both your system and post-amplification needs to have noise amplitude < a few microvolts. I tried this on a Crybaby circuit and convinced myself you just can't win this way without expensive test equipment. That is why the Vector Network Analyzer was invented -- it is a practical measurement method that is largely immune to noise . It is expensive test equipment. In the absence of a VNA, the next best thing is a step response.
A step response overcomes the the signal/noise challenge by injecting energy into the system over a longer period of time rather than impractically high amplitudes (e.g. 44.1 kV). The response has enough power to give you acceptable signal-to-noise ratio in the measurement system. With a step response you still get all the information you need about the system in a relatively tidy package, that is,
M(s) = U(s)*H(s) = (1/s)*H(s)
M(s) : Measured signal input
U(s) : Unit step response
H(s) : System being characterized
Hence,
H(s) = s*(1/s)*H(s)
where convolution with "s" is the time-domain derivative
The impulse response is therefore the time-domain derivative of the step response in an LTI system. The main advantage is you get (1/Tpulse) more signal power than what the approximated impulse dumps into the system. It is not difficult for post-processing because you can apply the bilinear transform of 1/s for a band-limited stable derivative function. Executing the derivative (or band-limited difference) in the time domain side-steps additional FFT windowing considerations for the step response (the bilinear transform becomes the windowing function, which has a good match to continuous time systems up to Fs/6).
I would still recommend doing a step response because you will get significantly better signal/noise ratio in the measurement than you will get from approximating the impulse response with narrow pulse width. It is true that after the derivative is applied, you end up with the same small amplitudes you would get from the impulse response (these are mathematical equivalents). The difference is you're starting with a signal that is lower SNR, and not adding significant noise in the derivative function (quantization & truncation error of a 32-bit FPU).
matt using the zero delay feedback method which may increase the efficiency of your vocoder
I haven't dug very deep into the zero-delay feedback method, much but I'm looking forward to when you upload the code. In the mean time would you post a short snippet of the filter difference equation that gets computed every cycle?
Right now I have a clear vision for how to get the current biquad implemention down to this:
4 MUL, 3 ADD
If a ZDF implementation can knock off another MUL, then score
However, I think my main efficiency drag is the whole program structure, in how functions are called and how coefficients are accessed from memory and less due to FPU cycles.
For example, CPU usage with 8 samples per block goes from 48% (all-on) down to about 33% when I disable ONLY the envelope detectors (all 32 biquads still running) -- I clearly have some work to do on the EVD section. CPU usage split is about 1/2 biquads, and 1/2 EVD right now.