Running equalizer together with mp3 decoding

felixcollins
Posts: 125
Joined: Fri May 24, 2019 2:02 am

Running equalizer together with mp3 decoding

Postby felixcollins » Wed Nov 02, 2022 1:36 am

I have a pipeline running that reads from an sdcard and decodes mp3 files before sending out i2s to a classd amp. I tried putting the equalizer element in the pipeline to give me the ability to reduce bass (our simple speaker hardware distorts with too much bass). I followed the equalizer example code. Unfortunately, with the default equalizer gains (which should do very little as it is flat) the output sounds terrible at any volume. It sounds slightly laggy and distorted. Every now and then I see...

Code: Select all

E (1434316) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
E (1434316) task_wdt:  - IDLE (CPU 0)
E (1434316) task_wdt: Tasks currently running:
E (1434316) task_wdt: CPU 0: mp3
E (1434316) task_wdt: CPU 1: IDLE
... in the log. So it looks as though the processor is not keeping up with the work load. Is the equaliser that thirsty on the cpu? There is no source code for it, so it is hard to tell if it has been optimised. Could there be some other reason for this problem? If I can not use the equaliser to reduce bass, what other options do I have? Is there a simple bass/treble filter element that would be lighter weight on the cpu?

Thanks in advance!

felixcollins
Posts: 125
Joined: Fri May 24, 2019 2:02 am

Re: Running equalizer together with mp3 decoding

Postby felixcollins » Thu Nov 24, 2022 3:10 am

I revisited the EQ element. I remembered that I had the frequency scaling power saving feature enabled for the processor with a max freq of 80MHz. Once I set that to 240MHz the eq ran with everything else just fine. However it did not seem to audibly affect the sound. I am trying to cut the bass with an eq of [-13,-13,-13, 0, 0, 0, 0, 0, 0, 0,] but can hear no change when this is applied.

Is it possible to set the EQ gains while it is running?

Who is online

Users browsing this forum: No registered users and 32 guests