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.

TMS320F28388D: system clock configuration

Part Number: TMS320F28388D


hello

I am working on TMS320F28388 control card.

I have created project for SPI-C communication.The project is building but while executing it, it is getting stuck in below function present in Device_init() fuction.

SysCtl_delay(23U)

But when i am using SPI loopback example code.I am able to compile and flash  and execute the code even though I am using same Device_init() function

what possible reason can you suggest for this scenario .

Any input will be appreciable

thanks in advance

  • Hi,

    What are your compile options for your code? Are you using COFF or EABI? Also have you included #define SYSCTL_DELAY in your code?


    //
    // Define to isolate inline assembly
    //
    #define SYSCTL_DELAY        __asm(" .if __TI_EABI__\n"                         \
                                      " .asg    SysCtl_delay    , _SysCtl_delay\n" \
                                      " .endif\n"                                  \
                                      " .def _SysCtl_delay\n"                      \
                                      " .sect \".TI.ramfunc\"\n"                   \
                                      " .global  _SysCtl_delay\n"                  \
                                      "_SysCtl_delay:\n"                           \
                                      " SUB    ACC,#1\n"                           \
                                      " BF     _SysCtl_delay, GEQ\n"               \
                                      " LRETR\n")

    Best Regards,

    Nirav

  • I am setting output format as EABI in project properties and also I have included sysctl.c driver libery file in which  #define  SYSCTL_DELAY micro is defined .Code is  still getting  stuck at same function in debug mode .

  • Hi Aruna,

    Is your application getting reset and re-invoking the setClock function again and again? Or is it stuck in delay function without moving to the next line?

    Regards,

    Veena

  • HI Veena

    My application is getting stuck in delay function without moving to next line.

    Regards,

    Aruna

  • Hi Aruna,

    Have you done any changes to the Device_init function or the linker command file? Is it possible to share the code so that we can reproduce the issue at our end?

    Regards,

    Veena