I have installation where a person makes a sound in a microphone and they hear the sound manipulated back 2 seconds later. The issue is that the mic also hears the delayed sound coming from the speaker so the sound gets stuck in a 2 second feedback loop. I'm considering workarounds involving cutting the mic gain but the ideal solution in my mind would be to cancel the sound coming from the speaker to the microphone while simultaneously continuing to actively capture sounds from people.
I played with delaying the sound using Zexy's [z~] instead of [delay~] and then subtracting the delayed sound from what the mic heard. With this method I tried to tweak the delay, considering the time it takes for the sound to travel from the speaker to the mic, but couldn't get any meaningful results. I also tried playing with this patch:
https://github.com/JosephEoff/PureData_NoiseFilter
and that did a great job removing feedback when no 2 second delay was present but it doesn't seem to be the appropriate tool for my problem.
Any thoughts or suggestions would be appreciated.