shorepine / amy

AMY - A high-performance fixed-point Music synthesizer librarY for microcontrollers
https://shorepine.github.io/amy/
MIT License
184 stars 11 forks source link

Hard limits on LPF pole location; Add dc-blocking hpf to filter output. #89

Closed dpwe closed 8 months ago

dpwe commented 8 months ago

The filter-sweep bass note in examples.c:drums() was going unstable. A hard limit prevents the LPF from going too close to the unit circle (unstable poles) or too low in frequency (below ~40 Hz). This stopped the filter exploding (#88), but there was still a click after the end of filter output because there was a residual dc output (limit cycle?). I added a pole-zero dc blocker, used after the filter only when a filter is used, to remove it.