How to make the diyinhk multichannel i2s interface receive slave lrck? Topic is solved

Technical questions regarding the xTIMEcomposer, xSOFTip Explorer and Programming with XMOS.
T-5
Member
Posts: 11
Joined: Wed Jun 26, 2019 3:59 pm

Re: How to make the diyinhk multichannel i2s interface receive slave lrck?

Postby T-5 » Thu Jul 18, 2019 9:44 pm

Nope, need to use I2S unfortunately.
View Solution
T-5
Member
Posts: 11
Joined: Wed Jun 26, 2019 3:59 pm

Postby T-5 » Fri Jul 19, 2019 7:55 pm

Meanwhile I digged around in the sources, also in the usb audio module, way more than I had liked too :)

I now have my own build configuration with 2 input channels, 10 output channels, adat & spdif disabled.
Added my own defines:
NUM_USB_CHAN_IN 2
NUM_USB_CHAN_OUT 10
I2S_CHANS_DAC=10
I2S_CHANS_ADC=2

and in the xk-audio-216-mc.xn file i reused the adat output pin (XS1_PORT_1E) and defined it to be PORT_I2S_DAC4

It compiles. Can't test it atm as I'm not home...

What is still unclear to me is how to determine if the chip can do that (resource-wise). Still the whole concept of tiles/cores/channel ends is pretty unclear to me, even after trying to read the whole manual twice :)
T-5
Member
Posts: 11
Joined: Wed Jun 26, 2019 3:59 pm

Postby T-5 » Sun Jul 21, 2019 6:21 pm

I can confirm that the board now runs 5 I2S lines at 192kHz sampling frequency. We tested all I2S output lines with an oscilloscope and it seems fine (tested sine waves and watched for differences in I2S signals, according to playback volume). For a final test we'd need to attach real DACs to the outputs but what I see so far makes me quite happy.

So the last thing we'd need to rectify is the switching of the oscillators according to the sampling rate. I'll repeat my question here: ca I do that in the function AudioHwInit()?
T-5
Member
Posts: 11
Joined: Wed Jun 26, 2019 3:59 pm

Postby T-5 » Wed Jul 31, 2019 12:52 am

It has been very silent here ;)

We managed to adjust the code to drive the two crystal oscillators in AudioHwInit(). The project is now finally done. :)))

Should I accept my own post/answer?
User avatar
akp
Respected Member
Posts: 314
Joined: Thu Nov 26, 2015 11:47 pm

Postby akp » Wed Jul 31, 2019 12:56 am

Yes. Well done figuring it all out.
T-5
Member
Posts: 11
Joined: Wed Jun 26, 2019 3:59 pm

Postby T-5 » Wed Jul 31, 2019 3:15 am

Maybe one last question: what's the licenceing situation for this stuff? Would I be allowed to distribute source code with my changes? How about flashable binary files?
User avatar
akp
Respected Member
Posts: 314
Joined: Thu Nov 26, 2015 11:47 pm

Postby akp » Fri Aug 02, 2019 3:23 pm

If you are using sw_usb_audio-[sw]_6.15.2rc1 for the source then refer to https://www.xmos.com/license-agreements#usb-audio

Who is online

Users browsing this forum: No registered users and 3 guests