def __init__(self): self.samplerate = 48000 self.frequency = 440 self.amplitude = dcv.db2lin(0) self.signaltype = 'Sine' self.fft_size = 512 self.window = da.Window(self.fft_size) self.fft = da.FFT(self.fft_size) self._generate_signal() self._analyze_signal() self._create_plots() self._create_controls() plt.show()
def test_minus_inf(self): self.assertEqual(dc.db2lin(-100), 1.0e-5)
def set_signal_amplitude(self, amplitude): self.amplitude = dcv.db2lin(amplitude) self._generate_signal() self._analyze_signal() self._update_plots()
def test_zero(self): self.assertEqual(dc.db2lin(0.0), 1.0)