我有一需求,只需要 1 slave I2S,BCLK, Frame sync都是 external
不過若照SDK 2.7.0 的設置
SAI_GetClassicI2SConfig(&config, kSAI_WordWidth32bits, kSAI_Stereo, kSAI_Channel0Mask);
config.masterSlave = kSAI_Slave;
SAI_TransferRxSetConfigEDMA(SAI_RX, &saiRxHandle, &config);
是無法正常動作的
進一步查看SDK內 fsl_i2s的設置,發現當為Slave時,並沒有針對BCP做設定,這也將造成接收到的音樂資料是錯誤的
這是合理的嗎?
Can you help us to put your question in English?
Thanks
Dear Sabina,
RD used old SDK SAI_RxInit() to solve this question. RD suggest to have SAI_RX and SAI_TX driver sample code for reference.
When in slave mode, sample code have not set BCP bit. This will cause the received music data is wrong.
How to set the I2S can do Slave mode?
I just need one I2S run in Slave mode, and BCLK, Frame Sync all from external.
However, if reference as SDK 2.7.0, is not normally operated.
SAI_GetClassicI2SConfig(&config, kSAI_WordWidth32bits, kSAI_Stereo, kSAI_Channel0Mask);
config.masterSlave = kSAI_Slave;
SAI_TransferRxSetConfigEDMA(SAI_RX, &saiRxHandle, &config);
Trace method of fsl_i2s. (ref. above FIG.)
When in Slave mode, and do not set for BCP. This will cause the received music data is wrong.
It is reasonable?