Dynamic channel connecting

Technical questions regarding the xTIMEcomposer, xSOFTip Explorer and Programming with XMOS.
MarcAntigny
Member++
Posts: 18
Joined: Tue Feb 13, 2018 2:50 pm

Dynamic channel connecting

Postby MarcAntigny » Fri May 18, 2018 9:45 am

Hi all,

Working on a tile of xCORE-200, I am making a chain of threads to process samples, dynamically creating/suppressing threads. But I couldn't find how to dynamically change the channels connected to a thread.
The initial chain of threads is :
Image
What I want to do is :
Image
Creating a new thread (Thread 2') and a new chan (Channel 3) is ok but I can't pass the new channel to thread 2 to connect thread 2' and 2. I tried using global chan array but the xC rules doesn't allow it (even for reading only the channel in the array).
If someone did it or know if there is a tricky way to do it, let me know.
Thanks for your hints,

Marc
User avatar
mon2
XCore Legend
Posts: 1158
Joined: Thu Jun 10, 2010 11:43 am
Contact:

Postby mon2 » Fri May 18, 2018 12:06 pm

Hi. No direct experience with your requirement but have a look at section 1.2 of this document.

https://www.xmos.com/support/libraries/lib_xcore_c


Image

Hope it helps.
MarcAntigny
Member++
Posts: 18
Joined: Tue Feb 13, 2018 2:50 pm

Postby MarcAntigny » Fri May 18, 2018 2:48 pm

Hi mon,
Yes it could be useful, thanks. However I use select and inuint_byref in the thread (1, 2' and 2), do you think it will work with C library ?
I'll give it a try, and I'll let you know.

Thanks again,
Marc

Who is online

Users browsing this forum: No registered users and 27 guests