VS1053 SS_REFERENCE_SEL creates audible pop

Designing hardware that uses VLSI Solution's devices as slave codecs such as an external MP3 decoder chip for a host microcontroller.
Post Reply
lucap87
User
Posts: 7
Joined: Tue 2018-06-26 9:09
Contact:

VS1053 SS_REFERENCE_SEL creates audible pop

Post by lucap87 » Tue 2020-05-12 15:52

Hi, I implemented a streaming application with a PID controller to sync the VS1053 playback with a remote server.
The Sample Rate Finetuning solution available in the latest software patch (2020-04-29) works like a charm for sample rates below 48 kHz.

Nonetheless, I experienced a small but annoying clipping (audio pop) when SS_REFERENCE_SEL bit of SCI_STATUS is set (SCI_STATUS bit 8 set too as indicated in the patch workaround). The pop is audible at every call of my routine VS10x3_SampleRateFinetuning() that fine-tunes the sample rate. Since the PID controller calls this routine every second the pop is quite annoying especially when the volume is low. In addition, the pop is audible even when the VOL register is written.

I suspect that the problem is the same as experienced by cinpezzo in his thread: http://www.vsdsp-forum.com/phpbb/viewto ... ERENCE_SEL or something similar to http://www.vsdsp-forum.com/phpbb/viewto ... 1e07#p1829.

After a while, I assessed that by clearing SS_REFERENCE_SEL (and SCI_STATUS bit 8 as well) the pop is not produced and the continuous sample rate adjustment works smoothly.

Do you suggest a workaround to use SS_REFERENCE_SEL and Sample Rate Fine-Tuning together? Or should I renounce to the extra swing to prevent pops?

Code: Select all

void VS10x3_SampleRateFinetuning(int32_t ppm2) {
    VS10x3_WriteRegister(VS10x3_ADD_WRAMADDR, 0x1e07);
    VS10x3_WriteRegister(VS10x3_ADD_WRAM, ppm2);
    VS10x3_WriteRegister(VS10x3_ADD_WRAM, ppm2 >> 16);

    /* oldClock4KHz = 0 forces adjustment calculation when rate checked. */
    VS10x3_WriteRegister(VS10x3_ADD_WRAMADDR, 0x5b1c);
    VS10x3_WriteRegister(VS10x3_ADD_WRAM, 0);

    /* Write to AUDATA or CLOCKF checks rate and recalculates adjustment. */
    uint16_t audata = VS10x3_ReadRegister(VS10x3_ADD_AUDATA);
    VS10x3_WriteRegister(VS10x3_ADD_AUDATA, audata);
}

User avatar
Panu
VLSI Staff
Posts: 2747
Joined: Tue 2010-06-22 13:43

Re: VS1053 SS_REFERENCE_SEL creates audible pop

Post by Panu » Wed 2020-05-13 21:14

Hi!

There was a side effect of some internal function that it sets the reference to the default (low) value. Hmm, hang on for a day or two, we'll see what to do about it in this case.

-Panu
Info: Line In and Line Out, VS1000 User interface, Overlay howto, Latest VSIDE, MCU Howto, Youtube
Panu-Kristian Poiksalo, VLSI Solution Oy

lucap87
User
Posts: 7
Joined: Tue 2018-06-26 9:09
Contact:

Re: VS1053 SS_REFERENCE_SEL creates audible pop

Post by lucap87 » Thu 2020-05-14 15:24

Thank for your reply.

If you wanna experiment with something, I can help with some tests on my hardware too.

User avatar
pasi
VLSI Staff
Posts: 1712
Joined: Thu 2010-07-15 16:04

Re: VS1053 SS_REFERENCE_SEL creates audible pop

Post by pasi » Wed 2020-05-20 11:50

Unfortunately catching the code which clears the reference select is not possible, so the patch does the next-best thing and restores the value whenever it can.

A hardware workaround would be to drive RCAP with an external 1.65V regulator.
Visit https://www.facebook.com/VLSISolution VLSI Solution on Facebook

lucap87
User
Posts: 7
Joined: Tue 2018-06-26 9:09
Contact:

Re: VS1053 SS_REFERENCE_SEL creates audible pop

Post by lucap87 » Fri 2020-05-22 17:58

Thank you for your reply and effort.

I'll probably leave SS_REFERENCE_SEL disabled.

Post Reply