This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Using DSPLIB 3.1 in CCS5

Other Parts Discussed in Thread: MATHLIB

Hello, everyone.

I'm developing a FIR filter and after doing my best to reach a high frequency performance (I got 50 MHz of signal input for a 52 coefficients filter), I decided to test the DSPLIB since I see I could reach frequencies above 140 MHz.

In order to create the project I tried different methods:

1) Whit RTSC

  • I created a simple "Hello word" CCS5 project and after I added a .cfg file to convert the project to a RTSC.
  • In Properties>General>RTSC I checked the DSPLIB and the MATHLIB options.
  • In my source file I added the ".../inc/dsplib.h" and "../inc/mathlib.h" headers.

2) Trying to manually linking the libraries.

  • I created a simple "Hello word" CCS5 project.
  • In Properties>c6000 Compiler>Include options I added the paths to the DSPLIB installation folder and the DSPLIB packages folder.
  • Link the DSPLIB library with one of those two methods:
  • In Properties>c6000 Linker>File Search Path I added the library file dsplib.a66.
  • In my .cmd I added at the beggining the line -l "C:/ti/dsplib_c66x_3_0_0_8/lib/dsplib.a66"
  • In my source file I added the ".../inc/dsplib.h" and "../inc/mathlib.h" headers.

In both cases, when I build the program an error saying "unresolved symbol xx" for any function xx of the library I use. Besides, when I'm writing the code the autocompletion doesn't show any help about the fuctions of the library but it does for example, for the mathlib.

I add an example of the console log of my error.

**** Build of configuration Debug for project testdsplibka ****

C:\ti\ccsv5\utils\bin\gmake -k all
'Building target: testdsplibka.out'
'Invoking: C6000 Linker'
"C:/ti/ccsv5/tools/compiler/c6000/bin/cl6x" -mv6600 -g --display_error_number --diag_warning=225 --abi=eabi -z -m"testdsplibka.map" --warn_sections -i"C:/ti/ccsv5/tools/compiler/c6000/lib" -i"C:/ti/ccsv5/tools/compiler/c6000/include" --reread_libs --rom_model -o "testdsplibka.out"  "./main.obj" -l"libc.a" -l"C:\ti\dsplib_c66x_3_1_0_0\lib\dsplib.a66" "../lnk.cmd"
<Linking>
warning #10349-D: creating output section ".init_array" without a SECTIONS
   specification.  For additional information on this section, please see the
   'C6000 EABI Migration' guide at
   http://processors.wiki.ti.com/index.php/C6000_EABI:C6000_EABI_Migration#C6x_
   EABI_Sections

 undefined  first referenced
  symbol        in file     
 ---------  ----------------
 DSP_fir_r8 ./main.obj      

error #10234-D: unresolved symbols remain
error #10010: errors encountered during linking; "testdsplibka.out" not built

>> Compilation failure
gmake: *** [testdsplibka.out] Error 1
gmake: Target `all' not remade because of errors.

**** Build Finished ****

How can I correctly linking the DSPLIB into my project? Is there any step missing?

Thank you.

  • Hello Adrian,

    Did you resolve this issue?  I am having the same problem.  I see there has been no responses.

     

    Thanks,
    Brandy

    EDIT:  Never mind, I found your other post.  This solved my problem :)

    http://e2e.ti.com/support/dsp/c6000_multi-core_dsps/f/639/t/183458.aspx

     

  • Hello, Brandy. I asked this so long ago that I had forgotten it at all.

    I didn't remember well how did I get the answer, but until now the only way I've found to use the DSPLib and Mathlib is by manually linking them. Those are the steps I alwasy do, but I guess some of them could be ommited.

    Everythin is done in the Project Properties window.

    1) In "Build", in the tab "Build variables" I manually add a symbol with the library main install directory. Lets say, I put DSP_INSTALL_DIR with the route C:/ti/dsplib_c66x_3_1_0_0.

    2) In "Build>C6000 Compiler>Include Options" I add a search path with the packages directory. I.e, "${DSPLIB_INSTALL_DIR}/packages".

    3) In "Build>C6000 Linker>File Search Path" I add the library in the first  textbox, like "${DSPLIB_INSTALL_DIR}/lib/dsplib.ae66".

    3) Still in "Build>C6000 Linker>File Search Path", in the second  textbox, I add the inc and lib directories. This is "${DSPLIB_INSTALL_DIR}/inc" and "${DSPLIB_INSTALL_DIR}/lib".

    Those steps should be enough. I've noticed that doing this automatically activates the DSPLib checkmarck in the "RSTC" tab from "General" the inverse relation doesn't work. Besides I sadly discoverd that not all the DSPLib or Mathlib functions can be called this way, because they are in subfolder inside the library organization. In fact, many of those "missing" functions that actually exist are not listed in the library documentation.

    Your actual problem could be the same as mine at the beginning. When you are using ELF output format you must use the dsplib.ae66, not the dsplib.a66 wich is for COFF. Obviously using the wrong library causes a linkage error.

    I hope this information to help you. If you find out a more "elegant" or complete solution, let me know it too. Good luck.

    -- Adrian