Post Go back to editing

How to enable SPORT as Clock Master in SC-594 ALSA driver

Category: Software
Product Number: ADSP-SC594

Hi,

the current ALSA driver for SPORT/I2S4 just support slave mode, so clock and frame sync are generated externally by the audio codec.

How do I enable CBS_CFS mode so the SPORT becomes clock and framesync master ?

Regards,

Sebastian

Parents
  • I have solved it by adding

        case SND_SOC_DAIFMT_CBS_CFS:
            param.spctl |= (SPORT_CTL_ICLK | SPORT_CTL_IFS);
            param.div =  ((8*sport->wdsize)-1)<<16;
            param.div |= (16-1); //TODO: ADapt to sample rate and sys clkj
            printk("SPORT CLK DIV: %08X\r\n",param.div);

    to

    sc5xx_dai_set_dai_fmt

Reply
  • I have solved it by adding

        case SND_SOC_DAIFMT_CBS_CFS:
            param.spctl |= (SPORT_CTL_ICLK | SPORT_CTL_IFS);
            param.div =  ((8*sport->wdsize)-1)<<16;
            param.div |= (16-1); //TODO: ADapt to sample rate and sys clkj
            printk("SPORT CLK DIV: %08X\r\n",param.div);

    to

    sc5xx_dai_set_dai_fmt

Children
No Data