Hi Guys,
I am having difficulties in clipping or limiting overshoots from my FM stereo encoder.
I have a ESP32 where i have already a working stereo encoder. It works fine. It has decent FIR 15kHz filtering so both the pilot and RDS is protected from audio.
My current flow is: ADC@48ksps->IIR preemphasis->FIR 15kHz LPF with Kaiser window->Polyphase FIR upsampler->stereo generator->DAC@192kHz.
This setup adds +6dB overshoots to the MPX signal. What i have done so far to get rid of it:
1. Added soft clipping (tanh) on the output of the preemphasis. This supresses some of the overshoots but the overshoots added by the FIR filter and upsampler remains. Also clipping the output of the preemphasis is causing IM so the audio is sounding harse.
2. Added soft clipping (tanh) on the output of the upsampler. This
supresses most of the overshoots but the so the audio is sounding harse.
3. Added lookahead limiter after the upsampler. 5ms loohahead. I have tried release times between 5 and 50ms and although most over the overshoots are gone but there is a huge amount of distortion (IM?).
4. Calculating the MPX signal (without pilot) and feed it as a sidechain to the lookahead limiter that sits right after the upsampler. Most overshoots are gone but there is a huge amount of distortion (IM?).
The thing is, the ESP32 is running at a clock speed of 240MHz. So no fancy stuff can be done.
So would it possible to implement a clipper or limiter to get rid of the overshoots without it sounding to harse? I accept distortion but not if it sounds anoying. Or should i forgetabout it and stop trying?I already spend lots of time trying to make something that sounds resonable. I hate giving up to soon.

Anny help is MUCH appriciated!!
Thank guys!
my 5c:
w.r.to the signal chain, ADC@48ksps->IIR preemphasis->FIR 15kHz
with 240MHz ESP, pl see if you can add a DC removal filter at the start. then a 20Hz HPF and 7.0k LPF. adding a dynamic compressor before the preemphasis may reduce chances for BB clipping.
revisit your FIR and relax spec so that ringing can be reduced.






