XMOS simple FFT example

Technical questions regarding the XTC tools and programming with XMOS.
User avatar
Lefty4000
Active Member
Posts: 32
Joined: Mon Nov 11, 2013 6:17 pm

XMOS simple FFT example

Post by Lefty4000 »

Hello,

First time posting on XMOS forums so bear with me

I have two questions:

1) I am working with the simple FFT library and I noticed that the included functions do not return anything. I entirely understand that you send the functions the real and imaginary parts as well as the number of points to the functions.

I'm assuming that the functions change the already defined variable arrays and can be used as such:

int re[1024], im[1024]; //pretend these are both filled with 1024 points
N = 1024;
fftTwiddle(re, im, N);
//now the values in re and im are the output of said fftTwiddle function

is this right?

2) in the same FFT example, what is the :> operator? It doesn't seem to be a C operator and I cannot find it in the XC documentation.

Thanks for any help!
You do not have the required permissions to view the files attached to this post.


User avatar
Ross
XCore Expert
Posts: 968
Joined: Thu Dec 10, 2009 9:20 pm
Location: Bristol, UK

Post by Ross »

I've not looked at the code you have attached, but arrays are passed by reference so they could be modified by the fftTwiddle() function.

The :> operator is an input operation from a port, channel etc. It's use is fundamental to XC.

Take a look here for more info: https://www.xmos.com/download/public/XMOS-Multicore-Extensions-to-C(C).pdf