How Can I use port array in one particular Function?

New to XMOS and XCore? Get started here.
Post Reply
TonyXiao
Active Member
Posts: 44
Joined: Fri Mar 29, 2019 3:58 am

How Can I use port array in one particular Function?

Post by TonyXiao »

Hi all

here i want using port array parameter for one function.
such as : void fun(port_arry[index])
i defined : port port_array[4] = on tile[2]: {XS1_PORT_1G,XS1_PORT_1H,XS1_PORT_1I,XS1_PORT_1J};
by changing the port array index, different port are function.
but the error report: error: only local variables of type chan or interface are allowed in a multi-tile main.

how can i solve it?


dongore
Junior Member
Posts: 4
Joined: Mon Aug 12, 2019 1:40 pm

Post by dongore »

I'm having a very similar problem. Did you solve yours?
Post Reply