Convert Stereo (2CH) Design to Multuchannel (4CH)

Sub forums for various specialist XMOS applications. e.g. USB audio, motor control and robotics.
Post Reply
AlexAdvice
XCore Addict
Posts: 138
Joined: Sun Feb 23, 2014 11:30 am

Convert Stereo (2CH) Design to Multuchannel (4CH)

Post by AlexAdvice »

Hello friends.

I'm working with 2CH Reference designt with one tile 8 cores 500MHz proc. The software uses 5 cores.
Now I'm thinking to try to make 4CH output, (I want use one of the free 1bit port line as SD2_OUT).
But, I saw that multychannel designes are made with 1000MHz 2 tile devices.
Is it still possible with 1 tile 500MHz proc, or I need to upgrade it?
Or It is enough just to set the corresponding channel numbel and additional I2S Data line?

Thanks.

P.S. The goal is to add the separate subwoofer channel with processing (LPF, room correction, etc.) by the Foobar's plugin.


User avatar
infiniteimprobability
XCore Legend
Posts: 1126
Joined: Thu May 27, 2010 10:08 am
Contact:

Post by infiniteimprobability »

No need to worry - you'll run out of one bit ports long before you run out of performance when doing multichannel on a single tile device.

So yes, 4ch out is easily done on a single tile and well within the capability of the ref design. The DJ kit does this anyhow - 4ch in/out.
Or It is enough just to set the corresponding channel numbel and additional I2S Data line?
Yep!

Look at app_usb_skc_su1 for further details if you need them..
AlexAdvice
XCore Addict
Posts: 138
Joined: Sun Feb 23, 2014 11:30 am

Post by AlexAdvice »

Thank you!
AlexAdvice
XCore Addict
Posts: 138
Joined: Sun Feb 23, 2014 11:30 am

Post by AlexAdvice »

Hi,

I'm sucsessfully implement 4CH and have tried even 8CH!

But, there are some problems:
8CH works with PCM 352/384kHz, just if I set 16bit in the Thesycon driver.
If I set 24bit - I got "Cannot create ASIO Buffer". So, 8192 samples is not enough, is it possible to increase it, or we should wait for the future driver's versions from Thesycon? ( I used 2.23 EVAL).

In Native DSD Mode - just dsd64/128 works, dsd256 - not works.
In DoP DSD Mode - just dsd64 works (it is clear - dsd128 cannot work because of a problem with pcm352).
User avatar
Ross
XCore Expert
Posts: 962
Joined: Thu Dec 10, 2009 9:20 pm
Location: Bristol, UK

Post by Ross »

There are 8 micro-frames per 1ms in high-speed USB (so 125uS per micro-frame)

384kHz / 8 / 1000 = 48 samples per channel per USB micro-frame (125uS)

Add one due to async requirement of sending one more/less sample per frame per channel = 49

24 bit (packed into 4 byte subslots) = 49 * 4 = 196bytes per channel per micro-frame

* 8 channels = 1568bytes, exceeding USB packet size of 1024bytes.

Max channels for a standard bandwidth USB Iso endpoint @ 384 /32 bit is 5. Set the slot size to 24bit/3bytes and you will be able to squeeze in 6 channels

Or wait till XMOS releases some high B/W endpoint code ;)
Last edited by Ross on Thu Apr 16, 2015 10:22 am, edited 1 time in total.
Reason: Added a bit more clarify to the math.
AlexAdvice
XCore Addict
Posts: 138
Joined: Sun Feb 23, 2014 11:30 am

Post by AlexAdvice »

Thank you for explanation, Ross.
About 8CH 384/24 it is clear.
But - with 8CH XMOS device, is it possible to send just 2CH 384/24 and 2CH Native DSD128, Native DSD256 and DoP DS128? Now these formats does not works, but works fine with 2CH XMOS device.
Or it is not depend of a XMOS firmware and is driver related?
User avatar
Ross
XCore Expert
Posts: 962
Joined: Thu Dec 10, 2009 9:20 pm
Location: Bristol, UK

Post by Ross »

I would be possible to program the device to have one interface that is 8 channels and an alternative that is 2 channels. The ADAT Rx code does this. It would require some modification to the software though and not something that would work "out of the box"
Post Reply