Other Parts Discussed in Thread: PCM1792
Hello,
Here is my PCM1792 implementation:
PCM1792 is feeded via an Xmos CPU, with this implementation:
This design works, but there is issue when the frequency 'AUDIO_MCLK' change from 22.5792Mhz to 24.576 or vice versa: the dac produce some 'crack' or 'pop' noise when frequency AUDIO_MCLK change.
Also there is also pop/noise when AUDIO_CLK frequency don't change but when LRCK/BCK change, for exemple when audio stream change from 44.1khz to 88.2khz or 48khz to 96khz, so the problem is maybe relative to LRCK/BCK change.
The frequency change only when Xmos detect a change in audio stream (from usb), for exemple when stream move from 44.1khz to 48khz for exemple. Then the audio clock produced by a PLL (PLL611 from microchip).
When a freweuncy change is detected from usb stream, I try following I2C command sequence to avoid crack/pop noise from dac:
1-frequency change request
2- put dac in disable dac operation mode writing 0x10 in 0x13 register (bit OPE)
3-put some delay here from hundred us to few ms
4-change frequency on PLL611 component
5-put some delay here from hundred to us to ms
6-loop to detect new audio frequency (below 50khz, or below 100khz or below 200khz) and then feed OSx bytes from register 0x14 with correct Fs (00 for below 100khz, 01 for below 200khz and 10 for below 50khz operation), here is the code:
if (samFreq < 50000) // 44.1, 48kHz.
{
DAC_REGWRITE(0x14, 0x02);//128fs 44/48k
}
else if (samFreq < 100000) // 88.2, 96kHz.
{
DAC_REGWRITE(0x14, 0x00);//64fs 88/96k
}
else if (samFreq < 200000) // 176.4, 192kHz.
{
DAC_REGWRITE(0x14, 0x01);//32fs 188/192k
}
7-put some delay here
8-put dac in enable dac operation writing 0x0 in 0x13 register
still pop/crack noise whith this config, then I try mute mode (bit MUTE in register 0x12 instead of bit OPE of register 0x13), still pop/crack, then try some kind of manual mute feeding 0x10 & 0x11 register with 0 to have a 'force mute' then no change still pop/crack despite playing with ATLD bit... I play with delay between clock change and mute/en operation without sucess...
Can somebody help me to define a correct i2c control command sequence to avoid pop/crack on dac output when changing audio frequency ?
Note: there is only pop/crack when frequency change, one time frequency is changed dac works correctly without any pop/crack noise.