Hi all,

I'm try to use TVL320AIC3254 Codec with Beaglebone Black via I2S bus. At 
present, I can play music but it hear noise. Attached is script to set up 
this codec with these setting: WCLK=44.1Khz, BCLK=1.4112 Mhz, MCLK=24 Mhz. 
I have some questions:

1, Below is my hw_params. I want to set BCLK=2,8224 Mhz for 32 bit stereo. 
How can I do that?

static int tlv320aic32x4_hw_params(struct snd_pcm_substream *substream,
struct snd_pcm_hw_params *params)
{
struct snd_soc_pcm_runtime *rtd = substream->private_data;
struct snd_soc_dai *codec_dai = rtd->codec_dai;
struct snd_soc_dai *cpu_dai = rtd->cpu_dai;
struct snd_soc_card *soc_card = rtd->card;
int ret = 0;
struct platform_device *pdev = to_platform_device(soc_card->dev);
unsigned int bclk_freq = evm_get_bclk(params);
unsigned sysclk = ((struct snd_soc_card_drvdata_davinci *)
snd_soc_card_get_drvdata(soc_card))->sysclk;

printk("TLV320AIC32X4 hw params\n");
printk("sysclk=%d\n", sysclk);
printk("bclk_freq=%d\n", bclk_freq);
printk("clkdiv=%d\n", sysclk/bclk_freq);

/* set the CPU system clock */
ret = snd_soc_dai_set_sysclk(cpu_dai, 0, sysclk, SND_SOC_CLOCK_OUT);
if (ret < 0)
return ret;


/* set the codec system clock */
ret = snd_soc_dai_set_sysclk(codec_dai, 0, sysclk, SND_SOC_CLOCK_OUT);
if (ret < 0)
return ret;

return ret;
}\

2, Can I change MCLK frequences to 12 MHz while frame rate is 44,1 Khz?

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beagleboard+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/cc45b494-808d-4131-8c62-a15a08d53c6f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to