I am trying to configure a 21489 ez-kit board to receive I2S from an external DAC.
I would like to use the I2S input as the clocking reference for the 1931 codec so I can send the received audio back off the board as an analog signal.
I think this should be possible because it seems very similar to the "SPDIF to analog talkthrough" example program. The main difference is that the I2S data comes from the on-chip SPDIF receiver versus the external header pins.
The connections I have between the external DAC and the ez-kit board are:
(all connections are made on the P2 expansion header)
DAC_FS -> DAI_P15
DAC_BCLK -> DAI_P16
DAC_DATA -> DAI_P17
Here is my code for setting up the SRU:
I'm using SPORT1 as the receiver, as in the SPDIF to analog example code.
// Route the BCLK and FS to the 1931 for slave mode
SRU(SPORT1_CLK_O, DAI_PB07_I); // CLK -> 1931 ABCLK
SRU(SPORT1_CLK_O, SPORT1_CLK_I); // required for master receive mode
SRU(SPORT1_FS_O, DAI_PB08_I); // FS -> 1931 ALRCLK
// Route the received data to the 1931
SRU(SPORT0_DA_O, DAI_PB12_I); // DAIP12 (DSDATA1) to SPORT0 DA (TX)
SRU(SPORT0_DB_O, DAI_PB11_I); // DAIP11 (DSDATA2) to SPORT0 DB (TX)
SRU(SPORT2_DA_O, DAI_PB10_I); // DAIP10 (DSDATA3) to SPORT2 DA (TX)
SRU(SPORT2_DB_O, DAI_PB09_I); // DAIP09 (DSDATA4) to SPORT2 DB (TX)
I have configured the SPORT as follows:
*pDIV1 = 0x001F001E; //Receiver (SPORT1) at 12.288 MHz SCLK and 48 kHz sample rate
*pSPCTL1 = (OPMODE | MSTR | SLEN24 | SPEN_A | SCHEN_A | SDEN_A | SPEN_B | SCHEN_B | SDEN_B );
*pSPCTL0 = (SPTRAN | OPMODE | SLEN24 | SPEN_A | SCHEN_A | SDEN_A | SPEN_B | SCHEN_B | SDEN_B);
*pSPCTL2 = (SPTRAN | OPMODE | SLEN24 | SPEN_A | SCHEN_A | SDEN_A | SPEN_B | SCHEN_B | SDEN_B);
I have configured the 1931 to sync it's PLL to the ALRCLK, using the routing and SPORT setup above, the 1931 reports that it is able to lock. I have also verified that the ABCLK and ALRCLK are present at the input to the 1931 chip.
With this setup, I am unable to hear any audio output from the 1939. I have verified that the I2S lines comming into the ez-board look active and appear to have "normal" I2S traffic.
Any ideas? Please let me know if there is other data that would help debug this issue?
Thanks in advance,