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.

TMS320F28069: Need suggestions for AC input to ADC and PID controls

Part Number: TMS320F28069
Other Parts Discussed in Thread: TIDM-1001, TIDM-1007, TIDM-02008, C2000WARE-DIGITALPOWER-SDK, C2000WARE

Dear All,

I am working in a project where, a AC to DC converter is taking part for a battery charger( 120vdc/50A). F28069 is my goal for control the whole system considering ADC, PWM switching, shunt sensing and battery charging and discharing monitoring.

Kindly suggest me code expamples for how to call registers/channels/polarity/ interrupt for 3 input AC signal R, S, T for ISR function.

How to generate PWM for IGBT switching? How to determine the channel current and voltage coding. 

Any related EVM source code and related documentation is required.

Thanks.

  • Please use our latest MCU F280049 for you AC/DC project. Multiple reference designs are available. Please review these: TIDM-1007/TIDM-02008, TIDM-2000, TIDM-1001. These include complete h/w design, documentation, User guide and software.

    Shamim

  • @Shamim. 

    Thanks for your response . 

    Please review these: TIDM-1007/TIDM-02008, TIDM-2000, TIDM-1001. These include complete h/w design, documentation, User guide and software.

    You have said well, but I found  F28069 comparative cheaper to go for it.

    I have a reference design F\W, It was debug in CCS version  v.5. 

    For three phase I started with following for AC R phase  initialization 

    #include "AC_SYNC.h"
    #include "Register.h"
    #include "LED.h"
    #include "Message.h"
    #include "PWM.h"


    BOOL bACSync;
    int AC_R_SyncIndex;


    ////////////////////////////////////////// AC Sync
    void InitAC_Sync(void)
    {
    GpioIntRegs.GPIOXINT1SEL.bit.GPIOSEL = 23; // XINT1 is GPIO23, XINT1 Source Select Register,This is multiplexing MUX PIE table 

    XINT1 = &XINT_AC_R_ISR; // XINT1 External Interrupt 1,that is called as a function of Interrupt enable register(IER) in pie vector table
    PieCtrlRegs.PIEIER1.bit.INTx4 = 1; // Enable PIE Group 1 INT4
    XIntruptRegs.XINT1CR.bit.POLARITY = 1; // Riging edge, XINT1CR is external intrurrept control from GPIOINT1SL MUX [ 4:0], polarity determines rising or falling edge of a signal, 1 means EN

    GpioCtrlRegs.GPAPUD.bit.GPIO23 = 0; // Pull UP,GPAPUD Enable the internal pullup on the specified pin,default for GPIO12-GPIO31
    GpioCtrlRegs.GPAMUX2.bit.GPIO23 = 0; // GPIO, GPIO23 is A MUX 2 Register, address 0x6F88, size 2*16,EALLOW-Protected
    GpioCtrlRegs.GPADIR.bit.GPIO23 = 0; // INPUT, GPIO Port A Direction, 0 means Configures the GPIO pin as an input( default)

    BOOL is not a assembly language or floating unit? 

    Currently I am using Project>properties>General > In advance setting I am using compiler v TIv6.0.2 , Liner command file  F28069_CLA_lnk.cmd  and rts2800_fpu32.lib for runtime support lib.

    At Project>properties>Built>C2000 Compiler> at add  # include search path I have have  adding F2806x common and header files and CG_TOOL_ROOT.

    At Project>properties>C2000 linker >file search path I have added  "C:\F2806x_common\F2806x_common\lib\SFO_TI_Build_V6b_FPU.lib"

    "rts2800_fpu32.lib" in include library. 

    In dir to lib search path I added "${CG_TOOL_ROOT}/include", "C:\F2806x_common\F2806x_common\lib","${CG_TOOL_ROOT}/lib"

    My project is non bios,

    problem says, 
    #5 could not open source file "DSP28x_Project.h"

    Document I have gone through, SPRUH18h, SPRAA85a, 

    What do you think ?

     

     

  • Hi,

    I recommend you use the examples in C2000Ware-DigitalPower-SDK as a reference point as these are the latest and greatest examples. Do note that any of these examples can be ported to run on different devices. Does the file "DSP28x_Project.h" exist in the project? Are you using an example provided by C2000? Can you send me the console output error?

    In the future, please do not upload code to the forum unless asked to do so. if attaching code, you should use the code feature to insert code as part of a reply.

    Regards,

    Ozino

  • I recommend you use the examples in C2000Ware-DigitalPower-SDK as a reference point as these are the latest and greatest examples. Do note that any of these examples can be ported to run on different devices. Does the file "DSP28x_Project.h" exist in the project? Are you using an example provided by C2000? Can you send me the console output error?

    In the future, please do not upload code to the forum unless asked to do so. if attaching code, you should use the code feature to insert code as part of a reply.

    Dear Sir Odharo,

    Nice to get your response in this thread. Lets accept your C2000Ware-DigitalPower-SDK as a starting point.

    I have my custom board, what I can do is I can read all c files like  adc.c, massage.c, CAN_module.c ,main.c, control.c ..etc.

    Yesterday I have been deleted those .asm file those were inactivated while I built my program.  

    I find them in this position of my work place. "C:\F2806x_common" and  "C:\F2806x_headers" at  Project>properties>Built>C2000 compiler>  add dir search path.

    Take a look this 2 important windows 

    In  F28069_CLA_lnk.cmd file its written that

     / For Code Composer Studio V2.2 and later
    // ---------------------------------------
    // In addition to this memory linker command file,
    // add the header linker command file directly to the project.
    // The header linker command file is required to link the
    // peripheral structures to the proper locations within
    // the memory map.
    //
    // The header linker files are found in <base>\F2806x_headers\cmd
    //
    // For BIOS applications add: F2806x_Headers_BIOS.cmd
    // For nonBIOS applications add: F2806x_Headers_nonBIOS.cmd

    Still the problem is fatal error #5: could not open source file "F2806x_Adc.h.consol says it comes from DSP28x_Project.h. and "could not open source file "F2806x_Adc.h"

    I have  "DSP28x_Project.h  file. attached  here.

    DSP28x_Project.h

    Errors are as follows 

    C:\ti\ccsv5\utils\bin\gmake -k all 
    'Building file: ../AC_SYNC.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="AC_SYNC.pp"  "../AC_SYNC.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../AC_SYNC.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [AC_SYNC.obj] Error 1
    'Building file: ../ADC.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="ADC.pp"  "../ADC.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../ADC.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [ADC.obj] Error 1
    'Building file: ../CAN_Module.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="CAN_Module.pp"  "../CAN_Module.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../CAN_Module.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [CAN_Module.obj] Error 1
    'Building file: ../CLA.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="CLA.pp"  "../CLA.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../CLA.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [CLA.obj] Error 1
    'Building file: ../CLATask.cla'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="CLATask.pp"  "../CLATask.cla"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../CLATask.cla".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [CLATask.obj] Error 1
    'Building file: ../ChargeNDischarge.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="ChargeNDischarge.pp"  "../ChargeNDischarge.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../ChargeNDischarge.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [ChargeNDischarge.obj] Error 1
    'Building file: ../Control.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="Control.pp"  "../Control.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../Control.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [Control.obj] Error 1
    'Building file: ../D_OUT.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="D_OUT.pp"  "../D_OUT.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../D_OUT.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [D_OUT.obj] Error 1
    'Building file: ../EEPRom.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="EEPRom.pp"  "../EEPRom.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../EEPRom.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [EEPRom.obj] Error 1
    'Building file: ../Global.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="Global.pp"  "../Global.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../Global.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [Global.obj] Error 1
    'Building file: ../LED.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="LED.pp"  "../LED.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../LED.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [LED.obj] Error 1
    'Building file: ../Main_Timer.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="Main_Timer.pp"  "../Main_Timer.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../Main_Timer.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [Main_Timer.obj] Error 1
    'Building file: ../Message.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="Message.pp"  "../Message.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../Message.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [Message.obj] Error 1
    'Building file: ../PRCharger.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="PRCharger.pp"  "../PRCharger.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../PRCharger.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [PRCharger.obj] Error 1
    'Building file: ../PRRect.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="PRRect.pp"  "../PRRect.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../PRRect.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [PRRect.obj] Error 1
    'Building file: ../PWM.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="PWM.pp"  "../PWM.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../PWM.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [PWM.obj] Error 1
    'Building file: ../Register.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="Register.pp"  "../Register.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../Register.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [Register.obj] Error 1
    'Building file: ../SCI.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="SCI.pp"  "../SCI.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../SCI.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [SCI.obj] Error 1
    'Building file: ../Serial.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="Serial.pp"  "../Serial.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../Serial.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [Serial.obj] Error 1
    'Building file: ../eCAN.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="eCAN.pp"  "../eCAN.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../eCAN.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [eCAN.obj] Error 1
    'Building file: ../main.c'
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g -O3 --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/ti/ccsv5/tools/compiler/c2000/lib" --include_path="C:/F2806x_common" --include_path="C:/F2806x_headers" --diag_warning=225 --display_error_number --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --preproc_with_compile --preproc_dependency="main.pp"  "../main.c"
    "..\DSP28x_Project.h", line 173: fatal error #5: could not open source file "F2806x_Adc.h"
    1 fatal error detected in the compilation of "../main.c".
    Compilation terminated.
    
    >> Compilation failure
    gmake: *** [main.obj] Error 1
    gmake: Target `all' not remade because of errors.
    
    **** Build Finished ****

    IER, ISR, CLk such kind of interrupt service routines are required. PI and PID control is necessary. I have been go through some of the periferal H/C files instruction from TI C/C++, read some assembly coding parameters.

    NB: My F2806x_Device.h is a big file, if I dont include 100+ error comes. 

    F2806x_Device.h

  • Hi,

    Can you please update your CCS environment to the latest version publicly available? Additionally, I'm noticing that there is a weird symbol being used in place of the '/'. Can you update the paths in the two include windows. 

    I will strongly recommend using one of the examples provided in C2000Ware as a starting point and adding your customizations on top of that.

    Regards,

    Ozino

  • Hello Sir,

    Nice to get your feedback again. I found that some of driver files used in this project is mismatched on date.

    So, again I created this project with those same .src, asm, .h and .c files.

    Now looking that the previous version ccs v.5,  I found a document named " TMS320C28x Optimizing C/C++
    Compiler v6.0" which was exactly same compiler I used previously.

    I managed to build this program with this instruction with "Invoking the C/C++ Compiler". Lot of Compiler's Behavior With Options chages accordingly. And as a result I got 0 error.

    C2000Ccompiler.pdf

    but, console says following warning,

    >> WARNING: invalid compiler option -tack (ignored)
    >> WARNING: invalid compiler option --undef_sym=__cla_scratchpad_start (ignored)

    Take a look the console here

    **** Build of configuration Debug for project Demo ****
    
    C:\ti\ccsv5\utils\bin\gmake -k all 
    'Invoking: C2000 Compiler'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" --cmd_file="C:\F2806x_common\cmd\F28069_CLA_lnk.cmd" --cmd_file="C:\F2806x_common\cmd\F28069.cmd" --cmd_file="C:\F2806x_common\cmd\28069_RAM_CLA_C_lnk.cmd"  -v28 -mt -ml -g -O2 -ms --embedded_cpp --relaxed_ansi --rtti --program_level_compile --include_path="C:/ti/ccsv5/tools/compiler/c2000/include" --include_path="C:/F2806x_headers/F2806x_headers/include" --include_path="C:/F2806x_common/include" --diag_warning=225 --write_diagnostics_file --diag_remark=Number of errors --display_error_number --no_warnings --issue_remarks --tool_version --gen_func_subsections=on --sat_reassoc=off --no_fast_branch --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --optimizer_interlist --call_assumptions=2 --remove_hooks_when_inlining --opt_for_speed=1 --gen_opt_info=1 --entry_parm=name --exit_parm=name --printf_support=minimal --std_lib_func_redefined -k --c_src_interlist --asm_listing --output_all_syms --syms_ignore_case --asm_remarks --cdebug_asm_data --asm_includes --cross_reference --asm_dependency --asm_directory="C:/F2806x_common/cmd"  "../AC_SYNC.c" "../ADC.c" "../CAN_Module.c" "../CLA.c" "../ChargeNDischarge.c" "../Control.c" "../D_OUT.c" "../EEPRom.c" "../F2806x_CpuTimers.c" "../F2806x_DefaultIsr.c" "../F2806x_GlobalVariableDefs.c" "../F2806x_PieCtrl.c" "../F2806x_PieVect.c" "../F2806x_SysCtrl.c" "../Global.c" "../LED.c" "../Main_Timer.c" "../Message.c" "../PRCharger.c" "../PRRect.c" "../PWM.c" "../Register.c" "../SCI.c" "../Serial.c" "../eCAN.c" "../main.c"  "../CLATask.cla"  "../F2806x_CSMPasswords.asm" "../F2806x_CodeStartBranch.asm" "../F2806x_DBGIER.asm" "../F2806x_DisInt.asm" "../F2806x_usDelay.asm"  
    TMS320C2000 C/C++ Compiler              v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    
    >> WARNING: invalid compiler option -tack (ignored)
    >> WARNING: invalid compiler option --undef_sym=__cla_scratchpad_start (ignored)
    TMS320C2000 C/C++ Parser                v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C/C++ File Merge            v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C/C++ Optimizer             v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C/C++ Codegen               v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Assembler                   v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Embed Utility               v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C Source Interlister        v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Linker                      v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Absolute Lister             v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Strip Utility               v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Post Link Optimizer         v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 XREF Utility                v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C++ Demangler               v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Hex Converter               v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Library Builder             v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Name Utility                v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Object File Display         v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Archiver                    v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    'Finished building: AC_SYNC.obj'
    ' '
    'Building target: Demo.out'
    'Invoking: C2000 Linker'
    "C:/ti/ccsv5/tools/compiler/c2000/bin/cl2000" --cmd_file="C:\F2806x_common\cmd\F28069_CLA_lnk.cmd" --cmd_file="C:\F2806x_common\cmd\F28069.cmd" --cmd_file="C:\F2806x_common\cmd\28069_RAM_CLA_C_lnk.cmd"  -v28 -mt -ml -g -O2 -ms --embedded_cpp --relaxed_ansi --rtti --program_level_compile --diag_warning=225 --write_diagnostics_file --diag_remark=Number of errors --display_error_number --no_warnings --issue_remarks --tool_version --gen_func_subsections=on --sat_reassoc=off --no_fast_branch --cla_support=cla0 --float_support=fpu32 --vcu_support=vcu0 --optimizer_interlist --call_assumptions=2 --remove_hooks_when_inlining --opt_for_speed=1 --gen_opt_info=1 --entry_parm=name --exit_parm=name --printf_support=minimal --std_lib_func_redefined -k --c_src_interlist --asm_listing --output_all_syms --syms_ignore_case --asm_remarks --cdebug_asm_data --asm_includes --cross_reference --asm_dependency --asm_directory="C:/F2806x_common/cmd" -z -m"Demo.map" --stack_size=0x300 --disable_pp --set_error_limit=100 --emit_warnings_as_errors --no_demangle --warn_sections -i"C:/ti/ccsv5/tools/compiler/c2000/lib" -i"C:/F2806x_common/lib" -i"C:/ti/ccsv5/tools/compiler/c2000/include" --priority --reread_libs --relocatable --make_static --no_symtable --scan_libraries --undef_sym=% --rom_model --disable_clink --runpath="C:/" -o "Demo.out"   "AC_SYNC.obj" -l"C:\F2806x_common\lib\SFO_TI_Build_V6b_FPU.lib" -l"C:\F2806x_common\cmd\F28069_CLA_lnk.cmd" -l"C:\F2806x_common\cmd\28069_RAM_CLA_C_lnk.cmd" "../28069_RAM_lnk.cmd" "../F28069_CLA_lnk.cmd" "../F2806x_Headers_nonBIOS.cmd" "F2806x_CSMPasswords.obj" "F2806x_CodeStartBranch.obj" "F2806x_DBGIER.obj" "F2806x_DisInt.obj" "F2806x_usDelay.obj" 
    TMS320C2000 C/C++ Compiler              v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    
    >> WARNING: invalid compiler option -tack (ignored)
    >> WARNING: invalid compiler option --undef_sym=__cla_scratchpad_start (ignored)
    TMS320C2000 C/C++ Parser                v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C/C++ File Merge            v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C/C++ Optimizer             v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C/C++ Codegen               v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Assembler                   v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Embed Utility               v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C Source Interlister        v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Linker                      v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Absolute Lister             v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Strip Utility               v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Post Link Optimizer         v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 XREF Utility                v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 C++ Demangler               v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Hex Converter               v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Library Builder             v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Name Utility                v6.0.2
    Build Number 1LHVI-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Object File Display         v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    TMS320C2000 Archiver                    v6.0.2
    Build Number 1LHVJ-KDADEMDK-RTARQ-TAV-ZAZH_W_Q_S
    'Finished building target: Demo.out'
    ' '
    
    **** Build Finished ****
    

    I am not sure my code is running well since have haven't go with  traget/build/run/load program.

    Mathematically I cant play with registers and variables.  Let me know whether I can play with your suggested C2000Ware-DigitalPower-SDK. or you can suggest me to simulate those system. Hope you will help me.

  • Additionally, I'm noticing that there is a weird symbol being used in place of the '/'. Can you update the paths in the two include windows.

    Well noticed, I am using a PC with Korean windows language version. Let me try what you have said, 6 years ago one expert from ST said the same.

  • Hi,

    Can you send a screenshot of the compiler flags. See Preferences -> C200 Compiler. Looks like you have incorrectly defined flags.

    You will need to modify the flags to remove references to the CLA_scratchpad as that device does not have a CLA core.

    Regards,

    Ozino

  • Dear Sir, 

    Nice to get your comment here. Its help full indeed. I am drifting in a huge files management.  

    Can you send a screenshot of the compiler flags. See Preferences -> C200 Compiler.

    In c.c.s version 5, Preferences is in  Window>Preferences, in this section flags are not defined .

    You will need to modify the flags to remove references to the CLA_scratchpad as that device does not have a CLA core.

    --cla_support says 

    Specifies TMS320C28x Control Law Accelerator (CLA) version 0 support. This option is useful only if the source is assembly code,
    written for the CLA. The option is ignored for C/C++ code. This option does not need any special library support at the linker; the libraries
    used for C28x with/without FPU support should be sufficient.

    I can show you, Project>properties>C2000 Compiler  views. Lot more confusing categories stated on C2000Ccompiler.pdf

    Take a look  one by one, first screenshot may give you clue , few of them I have skipped. 

  • Hi Sir,

    >> WARNING: invalid compiler option --undef_sym=__cla_scratchpad_start (ignored) 

    this  comes from Project>properties> C2000 Linker > Symbol Management.

    Do you want  me to uncheck the box? Even if I unchecked it, warning shows the same.  

    Do you want me to remove,  F28069_CLA_lnk.cmd files?

    My source files contains many assembly part , but my project tree contains CLA.c and CLA.h where sintables has made, different functions has made  from user defined Register.h. CLA1mathTables  variablehas used.

  • Hi,

    I misspoke about CLA support for the device. It is supported as you mentioned. Though it looks like the compiler flag is incorrectly defined. Please refer to one of the CLA based examples provided in C2000Ware to understand the compiler flag.

    I notice some the same weird path symbols in some of the file system path references in your project settings. Can you ensure that they are correctec.

    Are you actually able to build and run the project with no errors, just warnings?

  • I misspoke about CLA support for the device. It is supported as you mentioned. Though it looks like the compiler flag is incorrectly defined. Please refer to one of the CLA based examples provided in C2000Ware to understand the compiler flag.

    Dear Sir,

    Nice to get your feedback again. I would be glad if I can know which flags are inappropriate. I have a CLA based example like here

      C:\F2806x_examples_ccsv5\F2806x_examples_ccsv5\cla_adc

    But if I can want to open this existing project  and tried to build it, console says "make" is not found in PATH. Should  I make a new project and copy those file in project tree?

    I notice some the same weird path symbols in some of the file system path references in your project settings. Can you ensure that they are correctec.

    I am pretty sure  weird path symbol does not make any problem, windows in Korean version is running in this PC.

    Are you actually able to build and run the project with no errors, just warnings?

    Its a vital question, I just wanted to know is there any build problem or not. For doing so I have copied this whole project in another  workspace and follow C2000Ccompiler.pdf . In previous setting I got, #5 could not open source file "DSP28x_Project.h".

    Even its build successfully, or I am pretending  errors by project property settings. I have not go for Debug>configuration target>load program>run and burn .bin/.out/.hex file in target. My colleague says this project has problem for CAN / eCAN communication protocol.

    Kindly let me know where the .obj/.output file can generate ? or any specific setting for them. Can you suggest me any method not to use JTAG or program debugger. Is there any simulation method offered by TI? PICCOLO_EVM_28069 ? Any simulation tool?

    Do you want me to go through, https://software-dl.ti.com/ccs/esd/documents/sdto_ccs_build-errors.html

    Its a versatile FW project with external SW in evolvement. Customized code has been made for many purpose, even register files are made separately. 

    Could you suggest any TI document to understand   AC to DC converter control theory and application? I want to know about control mathematics for this power circuit. For example should it be PF correction/ load shared  etc.

     

     

  • Hi,

    In response to your questions regarding the AC to DC converter application. Please check out our DIgitalPower SDK offering and reference the AC/DC section. See for an overview: https://dev.ti.com/tirex/explore/node?node=APhjFJpcExlrndhPu186Iw__5C6SEVO__LATEST

    As for trying to build your solution without errors, I would recommend you start by importing an example provided in C2000Ware. Then, as you already mentioned, you will add you project specific source files (.c/.h) and linker command file. Then build the project and then resolve any errors present in the console window. 

    Hope this helps.

    Regards,

    Ozino

  • Dear Sir, @Odharo

    Thank you very much. I was in summer vacation, I was waiting for your response.

    I will follow for sure.

    Looking at my complex project which had  been developed from PICCOLO series EVM I guess.

    32 bit MCU group in Houston wrote an wonderful power point presentation. 

  • Okay, do create a new thread if you have anymore questions.