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.

C28m35 Concerto problem

Other Parts Discussed in Thread: CONTROLSUITE, SYSBIOS

Hi,

I am new ti/concerto/ccsv5 and playing around with a c28m35 controlcard to learn more. I am trying to convert the blinky_dc_28 and blinky_dc_m3 example provided by the controlSuite package to SYSBIOS project. I have successfully converted the the blinky_dc_28 code, but when I try to convert the m3 code I am getting some trouble. Below is the error code outputted by the ccsv5. I hope someone could help me to figure out what I have done wrong

#66 expected a ";"      blinky_SYSBIOS_M3                      line 29, external location: C:\ti\controlSUITE\device_support\f28m35x\v150\F28M35x_headers\include\F28M35x_Device.h       C/C++ Problem

#66 expected a ";"      blinky_SYSBIOS_M3                      line 30, external location: C:\ti\controlSUITE\device_support\f28m35x\v150\F28M35x_headers\include\F28M35x_Device.h       C/C++ Problem

Here is what I added to a generic SYSBIOS swi M3 example:

#include <xdc/std.h>

#include <xdc/runtime/System.h>

 

#include <ti/sysbios/BIOS.h>

#include <ti/sysbios/knl/Swi.h>

#include <ti/sysbios/knl/Task.h>

#include <ti/sysbios/knl/Clock.h>

#include <ti/sysbios/knl/Semaphore.h>

 

#include <xdc/cfg/global.h>

 

//***** Extra added header files (in addition to header files added by SYSBIOS) *****//

#include <hw_memmap.h>

#include <hw_gpio.h>

#include <hw_types.h>

#include <hw_sysctl.h>

#include <sysctl.h>

#include <gpio.h>

In main:

    //*************** Code added *****************//

    // Disable Protection

    HWREG(SYSCTL_MWRALLOW) =  0xA5A5A5A5;

 

    // Sets up PLL, M3 running at 100MHz and C28 running at 100MHz

    SysCtlClockConfigSet(SYSCTL_USE_PLL | (SYSCTL_SPLLIMULT_M & 0xA) |

                         SYSCTL_SYSDIV_1 | SYSCTL_M3SSDIV_1 |

                         SYSCTL_XCLKDIV_4);

    // Enable clock supply for GPIOC

    SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOC);

 

 

    // Give C28 control of Port C pin 6 (flashed from c28x kernal)

    GPIOPinConfigureCoreSelect(GPIO_PORTC_BASE, 0x40, GPIO_PIN_C_CORE_SELECT);

 

    // Disable clock supply for the watchdog modules

    SysCtlPeripheralDisable(SYSCTL_PERIPH_WDOG1);

    SysCtlPeripheralDisable(SYSCTL_PERIPH_WDOG0);

 

 

    BIOS_start();

 

 here is the external files which the compiler is complaining at:

extern __cregister volatile unsigned int IFR; (line 29 in F28M35x_Device.h)
extern __cregister volatile unsigned int IER; (line 30 in F28M35x_Device.h)

  • Hi Jorgen,

    jorgen heggebo said:
    extern __cregister volatile unsigned int IFR; (line 29 in F28M35x_Device.h)
    extern __cregister volatile unsigned int IER; (line 30 in F28M35x_Device.h)

    this header file is to be used by the C28.

    Code for the the M3 should be referencing the header files in the "MWare" sub-directory. (e.g. \device_support\f28m35x\v150\MWare\..)

    If you take a look at the MCU SDK (TI-RTOS) product, you'll find examples and documentation on how to use SYS/BIOS on concerto's M3.

  • Hi Tom,

    Thx for reply, I have now change the include path to the MWare directory and included the wanted .c files directly into the project. I now get some problem with some unresolved symbol

    #10010 errors encountered during linking; "blinky_SYSBIOS_M3.out" not          blinky_SYSBIOS_M3                                     C/C++ Problem

    <a href="file:/C:/ti/ccsv5/tools/compiler/dmed/HTML/10099.html">#10099-D</a>  run placement fails                F28M35x_Headers_BIOS.cmd  /blinky_SYSBIOS_M3    line 115                C/C++ Problem

    <a href="file:/C:/ti/ccsv5/tools/compiler/dmed/HTML/10234.html">#10234-D</a>  unresolved symbols remain                blinky_SYSBIOS_M3                                     C/C++ Problem

    unresolved symbol WatchdogReloadSet, first referenced in ./sysctl.obj             blinky_SYSBIOS_M3                                     C/C++ Problem

    unresolved symbol WatchdogRunning, first referenced in ./sysctl.obj  blinky_SYSBIOS_M3                                     C/C++ Problem

     

    The only error message that I could trace ends in F28M35x_Headers_BIOS.cmd file and complains on the following line:

    PieVectTableFile        : >  PIEVECT,   PAGE = 1      

  • Hi Jorgen,

    jorgen heggebo said:
    un placement fails                F28M35x_Headers_BIOS.cmd  /blinky_SYSBIOS_M3    line 115                C/C++ Problem

    now the project is getting linked to a C28 linker.cmd file.

    I'd try to create an example SYS/BIOS project (Project >> New CCS Project) from the project wizard (or try the MCU SDK's example project linker.cmd file) and copy that .cmd file into your project.

  • Thanks Tom,

    Now my led is flashing :)

    Cheers

    Jorgen