With the latest release of MPLAB C32 compiler v.1.04, Microchip has added a complete set of DSP functions for the PIC32 to complement the standard math libraries. Among them you will find a number of vector processing functions and as expected several different types of FFT functions. You will remember that in Chapter 7, in order to give the PIC32 some work to do while we were playing wit the cache and pre-fetch mechanism to find the optimal performance tuning, we used a FFT function. That was a simple “schoolbook” implementation of the basic algorithm in C.

If you try the new DSP library, don’t be too surprised if you discover that the speed of execution is increased by orders of magnitude. In fact the libraries are written for fractional numbers (16 and 32-bit fixed point** **numbers) as most DSP algorithms do, and were hand optimized (large portions were written in assembly) by MIPS experts to obtain the maximum performance from the PIC32 instruction set.

Ciao Lucio,

The DSP library is a great tool, however, so far it is not much supported by Microchip. I have been trying to find a code example with mips_fft32 function on

Microchip web site, but nothing was found except for incomplete one in Libs. Manual (DS51685B).

It is not clear how to handle int32c data, especially how to fill up an input string from A/D converter data.

If such code examples do exist, I would appreciate if you help me to get access to it.

Hope Microchip will provide better support in this area.

Regards,

Evgeny

Hi Evgeny,

you are right the support of the DSP libraries with version 1.04 is a bit sketchy! Version 1.05 has just been released and has improved already the documentation. I am considering talking more about fixed point math in one of the next postings, that should help…