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.

Issue in CCS v6.0 for TMS320c6713 eval kit

Dear Friends

I am new in CCS6.0. Previously i was working on CCSv3.1 and CCSv3.3. I have developed one project on CCSv3.1 and now i want run it on ccsv6.0 and load into DSP hardware c6713. I have create new project in ccsv6.0 and import the .c file which was developed and tested successfully. But after the file import, some error are shown. Related error are GPIO function (Error: could not open source file "csl_gpio.h").
But I have followed all the instruction for create a new project  and included c6000-tool-6.0.11 library for TMS320c6713 . How to sure that all functions used in ccsv3.1 will work correctly on CCSv6.0.  

If any body may guide to me properly, kindly inform me.

#include<stdio.h>
#include<string.h>
#include <math.h>
#include <csl_gpio.h>
#include <csl_gpiohal.h>
#include <csl_chip.h>
#include <csl_irq.h>
#include <csl_emifhal.h>
#include <csl_emif.h>



#define ADDRESS 0xA0000000
#define GBLCTL 0x01800000
#define CE2 0x01800010

#define pi 3.14
#define N 712          //32768

extern int *output11=(int *)ADDRESS;
extern int *ce2 = (int *)CE2;
extern int To_DAC=0;

GPIO_Handle hGpio;

GPIO_Config myconfig=
{ 
	0x00000031, /* gpgc */
	0x000000F9, /* gpen */
	0x00000070, /* gdir */
	0x00000082, /* gpval */
	0x00000000, /* gphm */
	0x00000000, /* gplm */
	0x00000030 /* gppol */
};

//----------------------global variables----------------------

//----------------------global variables----------------------

	int  i=0,j=0,mm=0,k=0,g=0,jj=0,d=0;


int round(double number)
{
    return (number >= 0) ? (int)(number + 0.5) : (int)(number - 0.5);
}



void main()
{

		*ce2=0x22A28A22;		

		hGpio =GPIO_open(GPIO_DEV0, GPIO_OPEN_RESET);

	    GPIO_config(hGpio,&myconfig);

	  	GPIO_pinEnable(hGpio, GPIO_PIN3 | GPIO_PIN8 | GPIO_PIN9 | GPIO_PIN10 | GPIO_PIN11 | GPIO_PIN12 | GPIO_PIN13 | GPIO_PIN14);
		
		GPIO_pinDirection(hGpio,GPIO_PIN8,GPIO_OUTPUT);
		GPIO_pinDirection(hGpio,GPIO_PIN3,GPIO_INPUT);

		GPIO_pinDirection(hGpio,GPIO_PIN9,GPIO_OUTPUT); 		//from incremental encoder
		GPIO_pinDirection(hGpio,GPIO_PIN10,GPIO_OUTPUT);

        GPIO_pinDirection(hGpio,GPIO_PIN11,GPIO_INPUT);		//to latch of dac

        GPIO_pinDirection(hGpio,GPIO_PIN12,GPIO_OUTPUT);	//loop time test
		GPIO_pinDirection(hGpio,GPIO_PIN13,GPIO_OUTPUT);
		GPIO_pinDirection(hGpio,GPIO_PIN14,GPIO_OUTPUT);

/* ---------------------------------------------------------------------- */

while(1)
{
	GPIO_pinWrite(hGpio,GPIO_PIN12,1);
	*output11 = 0x0FFF0000;;
	DSK6713_waitusec(227 * 500);
	GPIO_pinWrite(hGpio,GPIO_PIN12,0);		//Initialized as low for inhibit enable(DC-DC Converter
	*output11 = 0x00000000;;
	DSK6713_waitusec(227 * 500);

}
	

}



Wait for your kind help.

  • Hi Gopal,

    Error: could not open source file "csl_gpio.h")

    You have to modify the include option in CCS properties settings.
    The following path should be mentioned in CCS settings.
    C:\ti\C6xCSL\include

    processors.wiki.ti.com/.../Include_paths_and_options

    You won't face any problem after you migrated to new CCS version (CCSv6)
  • Hi Shankari


    Thanks for your kind response. I have followed your instruction and added linked path. After that the same problem has been raised again.

    Could not open any .h header file  and  any function of GPIO library or any other function like  DSK6713_waitusec(227 * 500) is shown compilation error.

    Again i have sent you two sample snaps of my testing project that will help you for idea about my project link file setting and project compilation error.

    and also send you one new project setup snap. Hope that these will help to understand where are my exact problem.

    wait for your reply.

    Please find the attachment

  • Hi Gopal,

    Actually I'm mentioning the different "include option" in CCS properties settings.

    CCS Properties -> Build -> C6000 Compiler -> Include option ->

    Add the following line in "--include_path" section.

    C:\ti\C6xCSL\include

  • Hi Shankari

    I have  checked this path and added "C:\ti\C6xCSL\include".  I have tested with same error. But practically i have seen that inside c://ti/ directory, have no any this type of directory(C6xCSL).  I have search my install compiler directory and added this path(C:\Program Files (x86)\Texas Instruments\C6000 Code Generation Tools 6.0.11\include) in that path and compiled again. But error is not short out. same problem is raised.

    Please see the sample snaps.

  • Hi Gopal,


    I have checked this path and added "C:\ti\C6xCSL\include". I have tested with same error. But practically i have seen that inside c://ti/ directory, have no any this type of directory(C6xCSL).

    Then give this location in include section.
    In my PC, I've those include files in "C:\ti\C6xCSL\include", if you have installed in different location and path then that path needs to be added instead of mine. (for example I've given that location and it need not be the same for you...)

  • Hi Shankari

    My compiler installation location is C:\Program Files (x86)\Texas Instruments\C6000 Code Generation Tools 6.0.11\include. and added it in that position as per your instruction. For my eval kit tms320c6713, i have searched and installed "C6000 Code Generation Tools 6.0.11" tool separately, which snap , i have sent to you my last reply. But after build/compilation, same problem is raised(Error: could not open source file "csl_gpio.h"). I have tried & checked in different way and seen that no any .h file is not open like csl_chip.h, csl_emifhal.h, csl_emif.h etc. is not opened. show same error.
  • Hi Gopal,

    Able to see the include files like this in your PC ?

    You can get this include from the following link.

  • Hi Shankari

    Hope that i have progress about my troubleshoot process. I have installed again TMS320C6000 chip support library in c://ti path and added it as per your previous instruction. Rebuild again, and that previous error not come at this time. But show another error regarding Chip select ("C:/ti/C6xCSL/include/csl_chiphal.h", line 267: fatal error #35: #error NO CHIP DEFINED (use -dCHIP_XXXX where XXXX is chip number, i.e. 6201). I defined in ccsv3.1 tool in build option->preprocessor path with CHIP_6713. But for ccsv6.0, i have not found the exact path where i can define my chip name. Is this same chip name(CHIP_6713) for ccsv6.0 or any other? if possible kindly tell me the option where i can define my chip name.

    wait for your reply.
  • HI Shankari

    Hope that my last reply, you have read and kindly see my next line for my last observation.

    I have tried & defined the CHIP number(CHIP_6713) in this path Project property->general option->Pre define name option. After rebuild, this CHIP define error is not shown, but some error has come regarding "Undefied symbol " (Please find the attachment snap for details)

  • Include any one of this library in your CCS project settings.

    CCS Properties -> Build -> C6000 Linker -> File search path

    C:\ti\C6xCSL\lib_3x\csl6713e.lib
    Or
    C:\ti\C6xCSL\lib_3x\csl6713.lib
  •  Hi Shankari

    Sorry for my late response. Last two days was our office weekend days. so i can't reply at that time.

    I have followed your last instruction and add this  C:\ti\C6xCSL\lib_3x\csl6713.lib in a same way and recompile it, but same error has come.

    kindly find the attachment for my last compilation.

  • Hi Gopal,

    Did you refer this post?

    I was clearly mentioned that you have to include the library in given location but you have added in some where (where we include headers)

    CCS Properties -> Build -> C6000 Linker -> File search path

    C:\ti\C6xCSL\lib_3x\csl6713.lib

    Check the attachment.

    Please create a new post if you have further questions on this.

  • Thanks Shankari for your guide and kind instruction.

    After followed your last instruction, there have no any compilation error messages. But i have felt some another small issues.

    I have seen that there have some error "mark" regarding GPIO declaration & config. These are not omit after build and also show one

    No CHIP Define error. kindly see the attachment please. How to over come these issues?

  • Can you please attach your project ?
  • I have attached my testing Project "12345.zip".  Kindly find the attachment.

    12345.zip

  • Not able to find the source file (test170216.c) to build the project.
    Can you please attach the complete project ?
  • Sorry for my mistake. I have attached complete project again.(Find the attachment)

    But , i thing , i want to tell you that when i closed my project completely and imported this project again.

    I have not seen any error message & any error symbol in c code and it is working correctly.

    I want to tell one more, if i use one library function "DSK6713_waitusec()" in my c code which worked in  previous CCSv3.1 successfully,

    but here it show error. Kindly see the matter, what is the exact cause.

    Again thanks a lot to you  for your kind guide to solve my problem .

    6153.12345.zip

    Wait for your reply.

  • Hi Gopal,

    But , i thing , i want to tell you that when i closed my project completely and imported this project again.

    I have not seen any error message & any error symbol in c code and it is working correctly.

    Rebuild the project and confirm again.
    I'm able to build your project in CCSv6.1.2


    I want to tell one more, if i use one library function "DSK6713_waitusec()" in my c code which worked in previous CCSv3.1 successfully,

    but here it show error. Kindly see the matter, what is the exact cause.

    What error are you getting ?
    Are you sure that you have used everything in CCSv6 like CCSv3 ?

    Can you attach the CCSv3 based project ?
  • Hi Shankari, at last , i have overcome all issues what i have said to you. basically, i have observed that one more library file has to added (dsk6713bsl.lib) in property and also added dsk6713.h header file into my project file. after that these function are working correctly.

    Thanks Shankari for your great support and cooperate with me to solve my all issue.

    Further if any doubt or quires , i will mail to you.

    Bye & Take Care...

  • Hi Gopal,

    Glad to hear.

    You are welocme.