DSPRelated.com
Forums

linker errors using DSPLIB c67x

Started by "Simon E. Mushi" October 1, 2008
Simon,

I just downloaded SPRU121, then extracted the files with winzip
then ran the self extracting file and had it install everything into:
C:\CCStudio\c6700\dsplib\include\

amongst the resulting files are:
DSPF_sp_mat_mul.h
DSPF_sp_mat_mul.h67

C:\CCStudio\c6700\dsplib\lib contains the library file:
dsp67x.lib
So, either your file search was incorrectly stated or you have some other very
serious problem with your computer.

These files are very visible when I extracted SPRU121.zip

R. Williams
---------- Original Message -----------
From: "Simon E. Mushi"
To: c...
Sent: Thu, 2 Oct 2008 17:51:37 -0400
Subject: Re: Re: [c6x] linker errors using DSPLIB c67x

> Hi Richard,
>
> when I add #include I get the same error btw I did a file search
> for DspLib.h and found it in these 3 locations
>
> 1) C:\CCStudio_v3.3\C5400\dsplib\include
> 2) C:\CCStudio_v3.3\C5500\dsplib\include
> 3) C:\Innovative\M6713\Libraries\DspLib
>
> I checked each one out and none of them contain the DSPF_sp_mat_mul
> function. When I ran the C67xDSPLIB_v200.exe (from sprc121) installer
> I told it to put everything in \CCStudio_v3.3\C6700\dsplib\.
>
> Any more ideas,
> Simon
>
> On Thu, Oct 2, 2008 at 5:28 PM, Richard Williams wrote:
>
> >
> > Simon,
> >
> > Perhaps I was not clear, when I mentioned how to fix the problem.
> >
> > add the following to your source file.
> >
> > #include "DspLib.h"
> >
> > R. Williams
> >
> >
> > ---------- Original Message -----------
> > From: "Simon E. Mushi"
> > To: c...
> > Sent: Thu, 2 Oct 2008 17:25:10 -0400
> > Subject: Re: [c6x] linker errors using DSPLIB c67x
> >
> > > Hi all,
> > >
> > > Christophe: Sorry but I am just getting a bit confused...on my machine
> > > DspLib.h is a library provided by Innovative Integration for their own
> > > bells and whistles, and it is already linked into my project. I was
> > > following the instructions in section 2.3.2 of spru657/spru657b to get
> > > the matrix math header file into my project.
> > >
> > > According to my .cmd file dsp67x.lib is already being linked in, and
> > > if I understand this is where DSPF_sp_mat_mul should be defined in.
> > >
> > > Mike: Yes. I am using c++, and my function call reads like the following:
> > >
> > > DSPF_sp_mat_mul(K.ptrC, 4, 30, K.ptrXc, 1, K.ptrY);
> > > where K.ptrC and K.ptryXc and K.ptrY are all (float *)...this
> > matches
> > > DSPF_sp_mat_mul(float *, int, int, float *, int, float *)
> > >
> > > Richard: Yes, indeed the linker command file I was posted was weird the
> > > first time I looked at it too, I tried taking out the dsp62x.lib
> > reference
> > > but I get a whole slew of more linker errors I think some of the
> > Innovative
> > > Integ. libraries use functions in there?? When I leave it in it
> > > doesn't hurt me.
> > >
> > > Any more of your thoughts are most welcome,
> > >
> > > Best,
> > > Simon
> > >
> > > On Thu, Oct 2, 2008 at 4:04 PM, christophe blouet <
> > > c...@hotmail.com> wrote:
> > >
> > > >
> > > > good, it took everybody 5 mails to come to the conclusion I posted
> > first.
> > > >
> > > >
> > > >
> > > > > To: m...@virginia.edu; c...
> > > > > From: r...@lewiscounty.com
> > > > > Date: Thu, 2 Oct 2008 10:58:51 -0700
> > > > > Subject: Re: [c6x] linker errors using DSPLIB c67x
> > > >
> > > > >
> > > > > Simon,
> > > > >
> > > > > Sorry, I gave you the wrong lib name.
> > > > > It is not DSPF_sp_mat_mul.lib
> > > > > rather, it is DSPLIB.lib
> > > > >
> > > > > Also, in looking at this:
> > > > > > -i"..\..\Lib\Target"
> > > > > >
> > > > > > -l csl6713.lib
> > > > > > -l HdwLib.lib
> > > > > > -l ModuleLib.lib
> > > > > > -l DspLib.lib
> > > > > > -l dsp67x.lib
> > > > > > -l dsp62x.lib
> > > > > > -l UtilLib.lib
> > > > > > -l NumLib.lib
> > > > > > -l TemplateBuilder.out
> > > > > >
> > > > > I see a few problems.
> > > > > 1) the dsp62x.lib should not be included, as it is compiled for a
> > > > different
> > > > > processor.
> > > > > 2) unless the libraries are all in the same directory as your project
> > > > (which *I*
> > > > > would not expect them to be), it is unlikely that the linker will
> > find
> > > > any of them.
> > > > > 3) the CCS project build options should have the path for each
> > library
> > > > file
> > > > > location.
> > > > > 4) the CCS project list of files should already contain these
> > libraries
> > > > in the
> > > > > 'libraries' section, so they are not needed in the .cmd file.
> > > > > 5) the CCS project/build options should already have the stack size,
> > so
> > > > it is
> > > > > not needed in the .cmd file.
> > > > >
> > > > > And now, the main answer to your problem....
> > > > > 6) the DspLib.lib contains the function DSPF_sp_mat_mul.
> > > > > 7) the DspLib.h file has to be included in the source, not
> > > > DSPF_sp_mat_mul.h.
> > > > >
> > > > > BTW:
> > > > > I found everything I needed to answer your question(s) by searching
> > at:
> > > > > http://www.ti.com
> > > > >
> > > > > R. Williams
> > > > >
> > > > > ---------- Original Message -----------
> > > > > From: "Simon E. Mushi"
> > > > > To: c...
> > > > > Sent: Thu, 2 Oct 2008 11:42:41 -0400
> > > > > Subject: Re: Re: [c6x] linker errors using DSPLIB c67x
> > > > >
> > > > > > Hi Richard,
> > > > > > Thanks for those suggestions...I made the changes below but still
> > get
> > > > > > the same error message.
> > > > > >
> > > > > > On Wed, Oct 1, 2008 at 11:23 PM, Richard Williams <
> > > > r...@lewiscounty.com>wrote:
> > > > > >
> > > > > > >
> > > > > > > Simon,
> > > > > > >
> > > > > > > In the ccs project/build options/...
> > > > > > >
> > > > > > > contains a line to list all the library directories, separated by
> > > > > > > semicolons.
> > > > > > >
> > > > > >
> > > > > > I added this line to Build Options -> Linker ->Libraries
> > > > > > -i"C:\CCStudio_v3.3\c6700\dsplib\include"
> > > > > >
> > > > > > >
> > > > > > > Has that line been updated to include the directory that contains
> > the
> > > > > > > DSPF_sp_mat_mul.lib library?
> > > > > > >
> > > > > >
> > > > > > I tried using this line #include
> > > > > > "\CCStudio_v3.3\c6700\dsplib\include\DSPF_sp_mat_mul.h" instead of
> > > > #include
> > > > > > and there was no change in my error message
> > > > > >
> > > > > > I also have the following lines in a .cmd file for my project:
> > > > > > -stack 0x1000
> > > > > > -q
> > > > > > -i"..\..\Lib\Target"
> > > > > >
> > > > > > -l csl6713.lib
> > > > > > -l HdwLib.lib
> > > > > > -l ModuleLib.lib
> > > > > > -l DspLib.lib
> > > > > > -l dsp67x.lib
> > > > > > -l dsp62x.lib
> > > > > > -l UtilLib.lib
> > > > > > -l NumLib.lib
> > > > > > -l TemplateBuilder.out
> > > > > >
> > > > > > Let me know what you think?
> > > > > >
> > > > > > Best regards,
> > > > > > Simon
> > > > > >
> > > > > > > Is the ';' missing from the end of the line that is calling
> > > > > > > DSPF_sp_mat_mul?
> > > > > > >
> > > > > > >
> > > > > > > R. Williams
> > > > > > >
> > > > > > >
> > > > > > > ---------- Original Message -----------
> > > > > > > From: "Simon E. Mushi"
> > > > > > > To: c...
> > > > > > > Sent: Wed, 1 Oct 2008 21:43:01 -0400
> > > > > > > Subject: [c6x] linker errors using DSPLIB c67x
> > > > > > >
> > > > > > > > Hi,
> > > > > > > > I have a board based on C6713 and am using some matrix
> > functions in
> > > > > > > DSPLIB.
> > > > > > > > I get an error during the link process
> > > > > > > >
> > > > > > > > **************************************
> > > > > > > > [Linking...] "C:\Program Files\C6000 Code Generation Tools
> > > > > > > 6.0.15\bin\cl6x"
> > > > > > > > -@"Debug.lkf"
> > > > > > > >
> > > > > > > >
> > > > > > > > undefined first referenced
> > > > > > > > symbol in file
> > > > > > > > --------- ----------------
> > > > > > > > DSPF_sp_mat_mul(float *, int, int, float *, int, float *)
> > > > > > > >
> > > > > > > > C:\\Innovative\\M6713\\Examples\\AMBControl\\RingBuffer.obj
> > > > > > > > >> error: symbol referencing errors - 'ServoTarget.out' not
> > built
> > > > > > > >
> > > > > > > > >> Compilation failure
> > > > > > > >
> > > > > > > > Build Complete,
> > > > > > > > 2 Errors, 0 Warnings, 0 Remarks.
> > > > > > > > **************************************
> > > > > > > >
> > > > > > > > These are the steps I have followed:
> > > > > > > >
> > > > > > > > 1. Dsplib installed to C:\CCStudio_v3.3\c6700\
> > > > > > > >
> > > > > > > > 2. Set the environment variable
> > > > > > > C_DIR=C:\CCStudio_v3.3\c6700\dsplib\include
> > > > > > > >
> > > > > > > > 3. Add #include to my code
> > > > > > > >
> > > > > > > > 4. Add rts6700.lib and dspc67x to my CCS project
> > > > > > > >
> > > > > > > > Not sure what else to try, so I would appreciate any help from
> > the
> > > > group.
> > > > > > > >
> > > > > > > > Thanks,
> > > > > > > >
> > > > > > > > Simon
> > > > > > > ------- End of Original Message -------
> > ------- End of Original Message -------
> >
> >
------- End of Original Message -------
Simon,

Here are the details, straight from the TI document SPRU657b.pdf,
Which is included as part of the SPRU121.zip file.

----------
2.2.2 Calling a DSPLIB Function From C
In addition to correctly installing the DSPLIB software, you must follow these
steps to include a DSPLIB function in your code:
Include the function header file corresponding to the DSPLIB function
Link your code with dsp67x.lib
Use a correct linker command file for the platform you use.
Remember most functions in dsp67x.lib are written assuming little-endian mode of
operation.
For example, if you want to call the single precision Autocorrelation DSPLIB
function, you would add:
#include
in your C file and compile and link using
cl6x main.c z o autocor_drv.out lrts6700.lib −ldsp67x.lib

Code Composer Studio Users
Assuming your C_DIR environment is correctly set up (as mentioned in
section 2.1), you would have to add DSPLIB under the Code Composer Studio
environment by choosing dsp67x.lib from the menu Project → Add Files to
Project. Also, you should make sure that you link with the run-time support library,
rts6700.lib.
----------------

*I* would properly update the CCS project/build options directory list rather
than messing with the C_DIR environment variable.

R. Williams

---------- Original Message -----------
From: "Richard Williams"
To: m...@virginia.edu, c...
Sent: Thu, 2 Oct 2008 16:44:30 -0700
Subject: Re: [c6x] linker errors using DSPLIB c67x

> Simon,
>
> I just downloaded SPRU121, then extracted the files with winzip
> then ran the self extracting file and had it install everything into:
> C:\CCStudio\c6700\dsplib\include\
>
> amongst the resulting files are:
> DSPF_sp_mat_mul.h
> DSPF_sp_mat_mul.h67
>
> C:\CCStudio\c6700\dsplib\lib contains the library file:
> dsp67x.lib
>
> So, either your file search was incorrectly stated or you have some
> other very serious problem with your computer.
>
> These files are very visible when I extracted SPRU121.zip
>
> R. Williams
>
> ---------- Original Message -----------
> From: "Simon E. Mushi"
> To: c...
> Sent: Thu, 2 Oct 2008 17:51:37 -0400
> Subject: Re: Re: [c6x] linker errors using DSPLIB c67x
>
> > Hi Richard,
> >
> > when I add #include I get the same error btw I did a file search
> > for DspLib.h and found it in these 3 locations
> >
> > 1) C:\CCStudio_v3.3\C5400\dsplib\include
> > 2) C:\CCStudio_v3.3\C5500\dsplib\include
> > 3) C:\Innovative\M6713\Libraries\DspLib
> >
> > I checked each one out and none of them contain the DSPF_sp_mat_mul
> > function. When I ran the C67xDSPLIB_v200.exe (from sprc121) installer
> > I told it to put everything in \CCStudio_v3.3\C6700\dsplib\.
> >
> > Any more ideas,
> > Simon
> >
> > On Thu, Oct 2, 2008 at 5:28 PM, Richard Williams wrote:
> >
> > >
> > > Simon,
> > >
> > > Perhaps I was not clear, when I mentioned how to fix the problem.
> > >
> > > add the following to your source file.
> > >
> > > #include "DspLib.h"
> > >
> > > R. Williams
> > >
> > >
> > > ---------- Original Message -----------
> > > From: "Simon E. Mushi"
> > > To: c...
> > > Sent: Thu, 2 Oct 2008 17:25:10 -0400
> > > Subject: Re: [c6x] linker errors using DSPLIB c67x
> > >
> > > > Hi all,
> > > >
> > > > Christophe: Sorry but I am just getting a bit confused...on my machine
> > > > DspLib.h is a library provided by Innovative Integration for their own
> > > > bells and whistles, and it is already linked into my project. I was
> > > > following the instructions in section 2.3.2 of spru657/spru657b to get
> > > > the matrix math header file into my project.
> > > >
> > > > According to my .cmd file dsp67x.lib is already being linked in, and
> > > > if I understand this is where DSPF_sp_mat_mul should be defined in.
> > > >
> > > > Mike: Yes. I am using c++, and my function call reads like the following:
> > > >
> > > > DSPF_sp_mat_mul(K.ptrC, 4, 30, K.ptrXc, 1, K.ptrY);
> > > > where K.ptrC and K.ptryXc and K.ptrY are all (float *)...this
> > > matches
> > > > DSPF_sp_mat_mul(float *, int, int, float *, int, float *)
> > > >
> > > > Richard: Yes, indeed the linker command file I was posted was weird the
> > > > first time I looked at it too, I tried taking out the dsp62x.lib
> > > reference
> > > > but I get a whole slew of more linker errors I think some of the
> > > Innovative
> > > > Integ. libraries use functions in there?? When I leave it in it
> > > > doesn't hurt me.
> > > >
> > > > Any more of your thoughts are most welcome,
> > > >
> > > > Best,
> > > > Simon
> > > >
> > > > On Thu, Oct 2, 2008 at 4:04 PM, christophe blouet <
> > > > c...@hotmail.com> wrote:
> > > >
> > > > >
> > > > > good, it took everybody 5 mails to come to the conclusion I posted
> > > first.
> > > > >
> > > > >
> > > > >
> > > > > > To: m...@virginia.edu; c...
> > > > > > From: r...@lewiscounty.com
> > > > > > Date: Thu, 2 Oct 2008 10:58:51 -0700
> > > > > > Subject: Re: [c6x] linker errors using DSPLIB c67x
> > > > >
> > > > > >
> > > > > > Simon,
> > > > > >
> > > > > > Sorry, I gave you the wrong lib name.
> > > > > > It is not DSPF_sp_mat_mul.lib
> > > > > > rather, it is DSPLIB.lib
> > > > > >
> > > > > > Also, in looking at this:
> > > > > > > -i"..\..\Lib\Target"
> > > > > > >
> > > > > > > -l csl6713.lib
> > > > > > > -l HdwLib.lib
> > > > > > > -l ModuleLib.lib
> > > > > > > -l DspLib.lib
> > > > > > > -l dsp67x.lib
> > > > > > > -l dsp62x.lib
> > > > > > > -l UtilLib.lib
> > > > > > > -l NumLib.lib
> > > > > > > -l TemplateBuilder.out
> > > > > > >
> > > > > > I see a few problems.
> > > > > > 1) the dsp62x.lib should not be included, as it is compiled for a
> > > > > different
> > > > > > processor.
> > > > > > 2) unless the libraries are all in the same directory as your project
> > > > > (which *I*
> > > > > > would not expect them to be), it is unlikely that the linker will
> > > find
> > > > > any of them.
> > > > > > 3) the CCS project build options should have the path for each
> > > library
> > > > > file
> > > > > > location.
> > > > > > 4) the CCS project list of files should already contain these
> > > libraries
> > > > > in the
> > > > > > 'libraries' section, so they are not needed in the .cmd file.
> > > > > > 5) the CCS project/build options should already have the stack size,
> > > so
> > > > > it is
> > > > > > not needed in the .cmd file.
> > > > > >
> > > > > > And now, the main answer to your problem....
> > > > > > 6) the DspLib.lib contains the function DSPF_sp_mat_mul.
> > > > > > 7) the DspLib.h file has to be included in the source, not
> > > > > DSPF_sp_mat_mul.h.
> > > > > >
> > > > > > BTW:
> > > > > > I found everything I needed to answer your question(s) by searching
> > > at:
> > > > > > http://www.ti.com
> > > > > >
> > > > > > R. Williams
> > > > > >
> > > > > > ---------- Original Message -----------
> > > > > > From: "Simon E. Mushi"
> > > > > > To: c...
> > > > > > Sent: Thu, 2 Oct 2008 11:42:41 -0400
> > > > > > Subject: Re: Re: [c6x] linker errors using DSPLIB c67x
> > > > > >
> > > > > > > Hi Richard,
> > > > > > > Thanks for those suggestions...I made the changes below but still
> > > get
> > > > > > > the same error message.
> > > > > > >
> > > > > > > On Wed, Oct 1, 2008 at 11:23 PM, Richard Williams <
> > > > > r...@lewiscounty.com>wrote:
> > > > > > >
> > > > > > > >
> > > > > > > > Simon,
> > > > > > > >
> > > > > > > > In the ccs project/build options/...
> > > > > > > >
> > > > > > > > contains a line to list all the library directories, separated by
> > > > > > > > semicolons.
> > > > > > > >
> > > > > > >
> > > > > > > I added this line to Build Options -> Linker ->Libraries
> > > > > > > -i"C:\CCStudio_v3.3\c6700\dsplib\include"
> > > > > > >
> > > > > > > >
> > > > > > > > Has that line been updated to include the directory that contains
> > > the
> > > > > > > > DSPF_sp_mat_mul.lib library?
> > > > > > > >
> > > > > > >
> > > > > > > I tried using this line #include
> > > > > > > "\CCStudio_v3.3\c6700\dsplib\include\DSPF_sp_mat_mul.h" instead of
> > > > > #include
> > > > > > > and there was no change in my error message
> > > > > > >
> > > > > > > I also have the following lines in a .cmd file for my project:
> > > > > > > -stack 0x1000
> > > > > > > -q
> > > > > > > -i"..\..\Lib\Target"
> > > > > > >
> > > > > > > -l csl6713.lib
> > > > > > > -l HdwLib.lib
> > > > > > > -l ModuleLib.lib
> > > > > > > -l DspLib.lib
> > > > > > > -l dsp67x.lib
> > > > > > > -l dsp62x.lib
> > > > > > > -l UtilLib.lib
> > > > > > > -l NumLib.lib
> > > > > > > -l TemplateBuilder.out
> > > > > > >
> > > > > > > Let me know what you think?
> > > > > > >
> > > > > > > Best regards,
> > > > > > > Simon
> > > > > > >
> > > > > > > > Is the ';' missing from the end of the line that is calling
> > > > > > > > DSPF_sp_mat_mul?
> > > > > > > >
> > > > > > > >
> > > > > > > > R. Williams
> > > > > > > >
> > > > > > > >
> > > > > > > > ---------- Original Message -----------
> > > > > > > > From: "Simon E. Mushi"
> > > > > > > > To: c...
> > > > > > > > Sent: Wed, 1 Oct 2008 21:43:01 -0400
> > > > > > > > Subject: [c6x] linker errors using DSPLIB c67x
> > > > > > > >
> > > > > > > > > Hi,
> > > > > > > > > I have a board based on C6713 and am using some matrix
> > > functions in
> > > > > > > > DSPLIB.
> > > > > > > > > I get an error during the link process
> > > > > > > > >
> > > > > > > > > **************************************
> > > > > > > > > [Linking...] "C:\Program Files\C6000 Code Generation Tools
> > > > > > > > 6.0.15\bin\cl6x"
> > > > > > > > > -@"Debug.lkf"
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > undefined first referenced
> > > > > > > > > symbol in file
> > > > > > > > > --------- ----------------
> > > > > > > > > DSPF_sp_mat_mul(float *, int, int, float *, int, float *)
> > > > > > > > >
> > > > > > > > > C:\\Innovative\\M6713\\Examples\\AMBControl\\RingBuffer.obj
> > > > > > > > > >> error: symbol referencing errors - 'ServoTarget.out' not
> > > built
> > > > > > > > >
> > > > > > > > > >> Compilation failure
> > > > > > > > >
> > > > > > > > > Build Complete,
> > > > > > > > > 2 Errors, 0 Warnings, 0 Remarks.
> > > > > > > > > **************************************
> > > > > > > > >
> > > > > > > > > These are the steps I have followed:
> > > > > > > > >
> > > > > > > > > 1. Dsplib installed to C:\CCStudio_v3.3\c6700\
> > > > > > > > >
> > > > > > > > > 2. Set the environment variable
> > > > > > > > C_DIR=C:\CCStudio_v3.3\c6700\dsplib\include
> > > > > > > > >
> > > > > > > > > 3. Add #include to my code
> > > > > > > > >
> > > > > > > > > 4. Add rts6700.lib and dspc67x to my CCS project
> > > > > > > > >
> > > > > > > > > Not sure what else to try, so I would appreciate any help from
> > > the
> > > > > group.
> > > > > > > > >
> > > > > > > > > Thanks,
> > > > > > > > >
> > > > > > > > > Simon
> > > > > > > > ------- End of Original Message -------
> > > ------- End of Original Message -------
> > >
> > >
> ------- End of Original Message -------
------- End of Original Message -------
Simon,

I found DSPF_sp_mat_mul in dsplib.rts, rts file is a source library file, in this file the function in asm is defined, in the same directory, you should find the .h with the prototype, and also the lib file already compiled.
I suggest you do not add too many libraries without knowing what they contain, and keep the strict minimum.
If this still not work, try to extract the source code from the rts file and compile it with another funcion name, so you can see if this is due to your C++ interface or library problem.

Regards

To: c...
From: m...@virginia.edu
Date: Thu, 2 Oct 2008 17:51:37 -0400
Subject: Re: Re: [c6x] linker errors using DSPLIB c67x

Hi Richard,

when I add #include I get the same error btw I did a file search for DspLib.h and found it in these 3 locations

1) C:\CCStudio_v3.3\C5400\dsplib\include
2) C:\CCStudio_v3.3\C5500\dsplib\include

3) C:\Innovative\M6713\Libraries\DspLib

I checked each one out and none of them contain the DSPF_sp_mat_mul function. When I ran the C67xDSPLIB_v200.exe (from sprc121) installer I told it to put everything in \CCStudio_v3.3\C6700\dsplib\.
Any more ideas,
Simon
On Thu, Oct 2, 2008 at 5:28 PM, Richard Williams wrote:

Simon,

Perhaps I was not clear, when I mentioned how to fix the problem.

add the following to your source file.

#include "DspLib.h"

R. Williams

---------- Original Message -----------

From: "Simon E. Mushi"

To: c...

Sent: Thu, 2 Oct 2008 17:25:10 -0400

Subject: Re: [c6x] linker errors using DSPLIB c67x

> Hi all,

>

> Christophe: Sorry but I am just getting a bit confused...on my machine

> DspLib.h is a library provided by Innovative Integration for their own

> bells and whistles, and it is already linked into my project. I was

> following the instructions in section 2.3.2 of spru657/spru657b to get

> the matrix math header file into my project.

>

> According to my .cmd file dsp67x.lib is already being linked in, and

> if I understand this is where DSPF_sp_mat_mul should be defined in.

>

> Mike: Yes. I am using c++, and my function call reads like the following:

>

> DSPF_sp_mat_mul(K.ptrC, 4, 30, K.ptrXc, 1, K.ptrY);

> where K.ptrC and K.ptryXc and K.ptrY are all (float *)...this matches

> DSPF_sp_mat_mul(float *, int, int, float *, int, float *)

>

> Richard: Yes, indeed the linker command file I was posted was weird the

> first time I looked at it too, I tried taking out the dsp62x.lib reference

> but I get a whole slew of more linker errors I think some of the Innovative

> Integ. libraries use functions in there?? When I leave it in it

> doesn't hurt me.

>

> Any more of your thoughts are most welcome,

>

> Best,

> Simon

>

> On Thu, Oct 2, 2008 at 4:04 PM, christophe blouet <

> c...@hotmail.com> wrote:

>

> >

> > good, it took everybody 5 mails to come to the conclusion I posted first.

> >

> >

> >

> > > To: m...@virginia.edu; c...

> > > From: r...@lewiscounty.com

> > > Date: Thu, 2 Oct 2008 10:58:51 -0700

> > > Subject: Re: [c6x] linker errors using DSPLIB c67x

> >

> > >

> > > Simon,

> > >

> > > Sorry, I gave you the wrong lib name.

> > > It is not DSPF_sp_mat_mul.lib

> > > rather, it is DSPLIB.lib

> > >

> > > Also, in looking at this:

> > > > -i"..\..\Lib\Target"

> > > >

> > > > -l csl6713.lib

> > > > -l HdwLib.lib

> > > > -l ModuleLib.lib

> > > > -l DspLib.lib

> > > > -l dsp67x.lib

> > > > -l dsp62x.lib

> > > > -l UtilLib.lib

> > > > -l NumLib.lib

> > > > -l TemplateBuilder.out

> > > >

> > > I see a few problems.

> > > 1) the dsp62x.lib should not be included, as it is compiled for a

> > different

> > > processor.

> > > 2) unless the libraries are all in the same directory as your project

> > (which *I*

> > > would not expect them to be), it is unlikely that the linker will find

> > any of them.

> > > 3) the CCS project build options should have the path for each library

> > file

> > > location.

> > > 4) the CCS project list of files should already contain these libraries

> > in the

> > > 'libraries' section, so they are not needed in the .cmd file.

> > > 5) the CCS project/build options should already have the stack size, so

> > it is

> > > not needed in the .cmd file.

> > >

> > > And now, the main answer to your problem....

> > > 6) the DspLib.lib contains the function DSPF_sp_mat_mul.

> > > 7) the DspLib.h file has to be included in the source, not

> > DSPF_sp_mat_mul.h.

> > >

> > > BTW:

> > > I found everything I needed to answer your question(s) by searching at:

> > > http://www.ti.com

> > >

> > > R. Williams

> > >

> > > ---------- Original Message -----------

> > > From: "Simon E. Mushi"

> > > To: c...

> > > Sent: Thu, 2 Oct 2008 11:42:41 -0400

> > > Subject: Re: Re: [c6x] linker errors using DSPLIB c67x

> > >

> > > > Hi Richard,

> > > > Thanks for those suggestions...I made the changes below but still get

> > > > the same error message.

> > > >

> > > > On Wed, Oct 1, 2008 at 11:23 PM, Richard Williams <

> > r...@lewiscounty.com>wrote:

> > > >

> > > > >

> > > > > Simon,

> > > > >

> > > > > In the ccs project/build options/...

> > > > >

> > > > > contains a line to list all the library directories, separated by

> > > > > semicolons.

> > > > >

> > > >

> > > > I added this line to Build Options -> Linker ->Libraries

> > > > -i"C:\CCStudio_v3.3\c6700\dsplib\include"

> > > >

> > > > >

> > > > > Has that line been updated to include the directory that contains the

> > > > > DSPF_sp_mat_mul.lib library?

> > > > >

> > > >

> > > > I tried using this line #include

> > > > "\CCStudio_v3.3\c6700\dsplib\include\DSPF_sp_mat_mul.h" instead of

> > #include

> > > > and there was no change in my error message

> > > >

> > > > I also have the following lines in a .cmd file for my project:

> > > > -stack 0x1000

> > > > -q

> > > > -i"..\..\Lib\Target"

> > > >

> > > > -l csl6713.lib

> > > > -l HdwLib.lib

> > > > -l ModuleLib.lib

> > > > -l DspLib.lib

> > > > -l dsp67x.lib

> > > > -l dsp62x.lib

> > > > -l UtilLib.lib

> > > > -l NumLib.lib

> > > > -l TemplateBuilder.out

> > > >

> > > > Let me know what you think?

> > > >

> > > > Best regards,

> > > > Simon

> > > >

> > > > > Is the ';' missing from the end of the line that is calling

> > > > > DSPF_sp_mat_mul?

> > > > >

> > > > >

> > > > > R. Williams

> > > > >

> > > > >

> > > > > ---------- Original Message -----------

> > > > > From: "Simon E. Mushi"

> > > > > To: c...

> > > > > Sent: Wed, 1 Oct 2008 21:43:01 -0400

> > > > > Subject: [c6x] linker errors using DSPLIB c67x

> > > > >

> > > > > > Hi,

> > > > > > I have a board based on C6713 and am using some matrix functions in

> > > > > DSPLIB.

> > > > > > I get an error during the link process

> > > > > >

> > > > > > **************************************

> > > > > > [Linking...] "C:\Program Files\C6000 Code Generation Tools

> > > > > 6.0.15\bin\cl6x"

> > > > > > -@"Debug.lkf"

> > > > > >

> > > > > >

> > > > > > undefined first referenced

> > > > > > symbol in file

> > > > > > --------- ----------------

> > > > > > DSPF_sp_mat_mul(float *, int, int, float *, int, float *)

> > > > > >

> > > > > > C:\\Innovative\\M6713\\Examples\\AMBControl\\RingBuffer.obj

> > > > > > >> error: symbol referencing errors - 'ServoTarget.out' not built

> > > > > >

> > > > > > >> Compilation failure

> > > > > >

> > > > > > Build Complete,

> > > > > > 2 Errors, 0 Warnings, 0 Remarks.

> > > > > > **************************************

> > > > > >

> > > > > > These are the steps I have followed:

> > > > > >

> > > > > > 1. Dsplib installed to C:\CCStudio_v3.3\c6700\

> > > > > >

> > > > > > 2. Set the environment variable

> > > > > C_DIR=C:\CCStudio_v3.3\c6700\dsplib\include

> > > > > >

> > > > > > 3. Add #include to my code

> > > > > >

> > > > > > 4. Add rts6700.lib and dspc67x to my CCS project

> > > > > >

> > > > > > Not sure what else to try, so I would appreciate any help from the

> > group.

> > > > > >

> > > > > > Thanks,

> > > > > >

> > > > > > Simon

> > > > > ------- End of Original Message -------

------- End of Original Message -------
Hi,

This fixed my problem:

extern "C" {
#include "DSPF_sp_mat_mul.h"
}

Thanks for the discussions,
Simon

On Thu, Oct 2, 2008 at 10:51 PM, christophe blouet <
c...@hotmail.com> wrote:

> Simon,
>
> I found DSPF_sp_mat_mul in dsplib.rts, rts file is a source library file,
> in this file the function in asm is defined, in the same directory, you
> should find the .h with the prototype, and also the lib file already
> compiled.
> I suggest you do not add too many libraries without knowing what they
> contain, and keep the strict minimum.
> If this still not work, try to extract the source code from the rts file
> and compile it with another funcion name, so you can see if this is due to
> your C++ interface or library problem.
>
> Regards
>
> ------------------------------
> To: c...
> From: m...@virginia.edu
> Date: Thu, 2 Oct 2008 17:51:37 -0400
>
> Subject: Re: Re: [c6x] linker errors using DSPLIB c67x
>
> Hi Richard,
>
> when I add #include I get the same error btw I did a file
> search for DspLib.h and found it in these 3 locations
>
> 1) C:\CCStudio_v3.3\C5400\dsplib\include
> 2) C:\CCStudio_v3.3\C5500\dsplib\include
> 3) C:\Innovative\M6713\Libraries\DspLib
>
> I checked each one out and none of them contain the DSPF_sp_mat_mul
> function. When I ran the C67xDSPLIB_v200.exe (from sprc121) installer I told
> it to put everything in \CCStudio_v3.3\C6700\dsplib\.
>
> Any more ideas,
> Simon
> On Thu, Oct 2, 2008 at 5:28 PM, Richard Williams wrote:
> Simon,
>
> Perhaps I was not clear, when I mentioned how to fix the problem.
>
> add the following to your source file.
>
> #include "DspLib.h"
>
> R. Williams
> ---------- Original Message -----------
> From: "Simon E. Mushi"
> To: c...
> Sent: Thu, 2 Oct 2008 17:25:10 -0400
> Subject: Re: [c6x] linker errors using DSPLIB c67x
>
> > Hi all,
> >
> > Christophe: Sorry but I am just getting a bit confused...on my machine
> > DspLib.h is a library provided by Innovative Integration for their own
> > bells and whistles, and it is already linked into my project. I was
> > following the instructions in section 2.3.2 of spru657/spru657b to get
> > the matrix math header file into my project.
> >
> > According to my .cmd file dsp67x.lib is already being linked in, and
> > if I understand this is where DSPF_sp_mat_mul should be defined in.
> >
> > Mike: Yes. I am using c++, and my function call reads like the following:
> >
> > DSPF_sp_mat_mul(K.ptrC, 4, 30, K.ptrXc, 1, K.ptrY);
> > where K.ptrC and K.ptryXc and K.ptrY are all (float *)...this
> matches
> > DSPF_sp_mat_mul(float *, int, int, float *, int, float *)
> >
> > Richard: Yes, indeed the linker command file I was posted was weird the
> > first time I looked at it too, I tried taking out the dsp62x.lib
> reference
> > but I get a whole slew of more linker errors I think some of the
> Innovative
> > Integ. libraries use functions in there?? When I leave it in it
> > doesn't hurt me.
> >
> > Any more of your thoughts are most welcome,
> >
> > Best,
> > Simon
> >
> > On Thu, Oct 2, 2008 at 4:04 PM, christophe blouet <
> > c...@hotmail.com> wrote:
> >
> > >
> > > good, it took everybody 5 mails to come to the conclusion I posted
> first.
> > >
> > >
> > >
> > > > To: m...@virginia.edu; c...
> > > > From: r...@lewiscounty.com
> > > > Date: Thu, 2 Oct 2008 10:58:51 -0700
> > > > Subject: Re: [c6x] linker errors using DSPLIB c67x
> > >
> > > >
> > > > Simon,
> > > >
> > > > Sorry, I gave you the wrong lib name.
> > > > It is not DSPF_sp_mat_mul.lib
> > > > rather, it is DSPLIB.lib
> > > >
> > > > Also, in looking at this:
> > > > > -i"..\..\Lib\Target"
> > > > >
> > > > > -l csl6713.lib
> > > > > -l HdwLib.lib
> > > > > -l ModuleLib.lib
> > > > > -l DspLib.lib
> > > > > -l dsp67x.lib
> > > > > -l dsp62x.lib
> > > > > -l UtilLib.lib
> > > > > -l NumLib.lib
> > > > > -l TemplateBuilder.out
> > > > >
> > > > I see a few problems.
> > > > 1) the dsp62x.lib should not be included, as it is compiled for a
> > > different
> > > > processor.
> > > > 2) unless the libraries are all in the same directory as your project
> > > (which *I*
> > > > would not expect them to be), it is unlikely that the linker will
> find
> > > any of them.
> > > > 3) the CCS project build options should have the path for each
> library
> > > file
> > > > location.
> > > > 4) the CCS project list of files should already contain these
> libraries
> > > in the
> > > > 'libraries' section, so they are not needed in the .cmd file.
> > > > 5) the CCS project/build options should already have the stack size,
> so
> > > it is
> > > > not needed in the .cmd file.
> > > >
> > > > And now, the main answer to your problem....
> > > > 6) the DspLib.lib contains the function DSPF_sp_mat_mul.
> > > > 7) the DspLib.h file has to be included in the source, not
> > > DSPF_sp_mat_mul.h.
> > > >
> > > > BTW:
> > > > I found everything I needed to answer your question(s) by searching
> at:
> > > > http://www.ti.com
> > > >
> > > > R. Williams
> > > >
> > > > ---------- Original Message -----------
> > > > From: "Simon E. Mushi"
> > > > To: c...
> > > > Sent: Thu, 2 Oct 2008 11:42:41 -0400
> > > > Subject: Re: Re: [c6x] linker errors using DSPLIB c67x
> > > >
> > > > > Hi Richard,
> > > > > Thanks for those suggestions...I made the changes below but still
> get
> > > > > the same error message.
> > > > >
> > > > > On Wed, Oct 1, 2008 at 11:23 PM, Richard Williams <
> > > r...@lewiscounty.com>wrote:
> > > > >
> > > > > >
> > > > > > Simon,
> > > > > >
> > > > > > In the ccs project/build options/...
> > > > > >
> > > > > > contains a line to list all the library directories, separated by
> > > > > > semicolons.
> > > > > >
> > > > >
> > > > > I added this line to Build Options -> Linker ->Libraries
> > > > > -i"C:\CCStudio_v3.3\c6700\dsplib\include"
> > > > >
> > > > > >
> > > > > > Has that line been updated to include the directory that contains
> the
> > > > > > DSPF_sp_mat_mul.lib library?
> > > > > >
> > > > >
> > > > > I tried using this line #include
> > > > > "\CCStudio_v3.3\c6700\dsplib\include\DSPF_sp_mat_mul.h" instead of
> > > #include
> > > > > and there was no change in my error message
> > > > >
> > > > > I also have the following lines in a .cmd file for my project:
> > > > > -stack 0x1000
> > > > > -q
> > > > > -i"..\..\Lib\Target"
> > > > >
> > > > > -l csl6713.lib
> > > > > -l HdwLib.lib
> > > > > -l ModuleLib.lib
> > > > > -l DspLib.lib
> > > > > -l dsp67x.lib
> > > > > -l dsp62x.lib
> > > > > -l UtilLib.lib
> > > > > -l NumLib.lib
> > > > > -l TemplateBuilder.out
> > > > >
> > > > > Let me know what you think?
> > > > >
> > > > > Best regards,
> > > > > Simon
> > > > >
> > > > > > Is the ';' missing from the end of the line that is calling
> > > > > > DSPF_sp_mat_mul?
> > > > > >
> > > > > >
> > > > > > R. Williams
> > > > > >
> > > > > >
> > > > > > ---------- Original Message -----------
> > > > > > From: "Simon E. Mushi"
> > > > > > To: c...
> > > > > > Sent: Wed, 1 Oct 2008 21:43:01 -0400
> > > > > > Subject: [c6x] linker errors using DSPLIB c67x
> > > > > >
> > > > > > > Hi,
> > > > > > > I have a board based on C6713 and am using some matrix
> functions in
> > > > > > DSPLIB.
> > > > > > > I get an error during the link process
> > > > > > >
> > > > > > > **************************************
> > > > > > > [Linking...] "C:\Program Files\C6000 Code Generation Tools
> > > > > > 6.0.15\bin\cl6x"
> > > > > > > -@"Debug.lkf"
> > > > > > >
> > > > > > >
> > > > > > > undefined first referenced
> > > > > > > symbol in file
> > > > > > > --------- ----------------
> > > > > > > DSPF_sp_mat_mul(float *, int, int, float *, int, float *)
> > > > > > >
> > > > > > > C:\\Innovative\\M6713\\Examples\\AMBControl\\RingBuffer.obj
> > > > > > > >> error: symbol referencing errors - 'ServoTarget.out' not
> built
> > > > > > >
> > > > > > > >> Compilation failure
> > > > > > >
> > > > > > > Build Complete,
> > > > > > > 2 Errors, 0 Warnings, 0 Remarks.
> > > > > > > **************************************
> > > > > > >
> > > > > > > These are the steps I have followed:
> > > > > > >
> > > > > > > 1. Dsplib installed to C:\CCStudio_v3.3\c6700\
> > > > > > >
> > > > > > > 2. Set the environment variable
> > > > > > C_DIR=C:\CCStudio_v3.3\c6700\dsplib\include
> > > > > > >
> > > > > > > 3. Add #include to my code
> > > > > > >
> > > > > > > 4. Add rts6700.lib and dspc67x to my CCS project
> > > > > > >
> > > > > > > Not sure what else to try, so I would appreciate any help from
> the
> > > group.
> > > > > > >
> > > > > > > Thanks,
> > > > > > >
> > > > > > > Simon
> > > > > > ------- End of Original Message -------
> ------- End of Original Message -------