I recently installed the c2000 launchpad and managed to compile and debug the demo program (CCS V5_2).
So far, so good.
Then I tried to create my first program (just blinking an led) and found some issues :
I added the launchpad folder under controlsuite as include path for the compiler and as search path for the linker, that way I managed to have the incldues resolved (clk.h etc).
Now, if I hit "build" the compiler seems to do it's job without complaining, tried to add an error to the code and it is correctly displayed as error.
However I get a variable number of linker errors such as
unresolved symbol _CLK_init, first referenced in ./main.obj led2 C/C++
I assume that symbol should be defined somewhere in "C:\ti\controlSUITE\development_kits\C2000_LaunchPad\f2802x_common\lib" which I added in the linker search path, am I wrong?.
Also, if I check the run/debug settings -> launch configuration I get this error related to the "program" tab :
Specified Program ( Texas Instruments XDS100v1 USB Emulator/C28xx ) does not exist
What does this mean?
I am a bit lost, suggestions are welcome :)
Find out which c file has the CLK_init function and add it to your project: Project->Add Files. To find which file has the missing function, you could run this command from the command line, for example: findstr /s /i /c:"CLK_init" *.* That just searches within all files for the CLK_init phrase.
"Specified Program ( Texas Instruments XDS100v1 USB Emulator/C28xx ) " means CCS can't find your jtag programmer, which is on board your dev kit. Check device manager under USB, do you see anything named XDS?
In reply to Jut Shanahan:
actually I found a workaround , but I am trying to understand which folders need to be included each time I start a new project.
The workaround I used was to clone the demo project, remove the source code and add my main.c
That worked, however trying to include the same folders in a new project did not... so I am definitely missing something.
Same thing about the jtag emulator : it is exactly the same as i the demo project (and indeed the device selected is the same), but in the demo (or in the cloed project) it works, in the one I created from scratch it does not (it gives that weird error at least).
I believe that the clk.h adc.h etc are generic for the device family (with each device having its own set of headers, but with the same name / prototypes across the family) so I would not expect them to be be specific for the demo project.
I checked various user guides, but did not find anything about the functions (i.e. GPIO_setMode() etc) with some documentation on what they do, in which files are supported etc etc.
Basically, when I start a new CSS Project for the C2000 Piccolo, besides selecting the specific device and the jtag programmer, what else should I modify in the project properties?
Is there any documentation at all for this? I probably missed it
In reply to Francesco Agosti:
You may need to modify compiler and/or linker search paths so they can locate necessary header files and libraries. This stuff is probably documented in the ccs user guide (i've never looked at it though).
Well, that's exactly my point :)
Was not able to find that info in the docs, not sure which doc should I check for it either....
I did not go through the "optimizing C/C++ compiler" so far, might be that one, not sure.
Hopefully it's one of these, anyways http://www.ti.com/tool/launchxl-f28027?DCMP=c2x-launchpad&HQS=c2000-launchpad#Technical Documents
I believe you are missing the driverllib.lib file which is located in f2802x_common/lib. This library file contains pre-compiled objects for the driver library. All of the example projects should have the driver library linked to them (you should be able to see it in the project navigator. Additionally there is a project for the driver library which can be imported, modified, and recompiled if changes to the driver library need to be made for your applications.
LaunchPad Applications Manager
In reply to Trey German289:
That was definitely it.
Just in case others are stuck with the same issue :
Basically, creating a new project from scratch and having selected device = TMS320F28027 and XDS100V1 Usb Emulator, I had to :
1) in project -> properties -> CCS Build -> C2000 Compiler -> Include Options -> add dir : "C:\ti\controlSUITE\development_kits\C2000_LaunchPad"
2) in project -> properties -> CCS Build -> C2000 Linker -> File Search Path -> Include library : "C:\ti\controlSUITE\development_kits\C2000_LaunchPad\f2802x_common\lib\driverlib.lib"
No problem! Glad to hear you got it working!
When i start the project from scratch do i have to add the c2000 compiler & c2000 linker path all the time ?
and my project is not loading from Flash. what are the step that i should do in the program to make my program to load from Flash
In reply to manoj venkat cj:
Try importing one of the example projects in controlSUITE for the LaunchPad. Each of these projects has two different build configurations. One builds and links the project to run from RAM, the other Flash.
If you dig deeper in the project properties you'll see that the main thing that changes is the linker command file used. There are also some #defines that are activated in flash builds (for instance the call to memcpy).
i follow your guide and the compilation is good.
Just left one warning. function declared implicitly on below line
usually occur when encounter this line.
Any idea on this problem?
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.