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.

TMS320F28379D: Unplugged interrupt flagged: intr# 19

Part Number: TMS320F28379D
Other Parts Discussed in Thread: SYSBIOS

Dear support,

I'm working on LAUNCHXL-F28379D evaluation board.

If my code executes the DELAY_US macro, I get:

ti.sysbios.family.c28.Hwi: line 1022: E_unpluggedInterrupt: Unplugged interrupt flagged: intr# 19
xdc.runtime.Error.raise: terminating execution

#define DELAY_US(A) F28x_usDelay(((((long double) A * 1000.0L) / (long double)CPU_RATE) - 9.0L) / 5.0L)

#define CPU_RATE 10.00L // for a 100MHz CPU clock speed (SYSCLKOUT)

Here is the code of F28x_usDelay() from F2837xD_usDelay.asm:

       .def _F28x_usDelay

       .cdecls LIST ;;Used to populate __TI_COMPILER_VERSION__ macro
       %{
       %}

       .if __TI_COMPILER_VERSION__
       .if __TI_COMPILER_VERSION__ >= 15009000
       .sect ".TI.ramfunc"      ;;Used with compiler v15.9.0 and newer
       .else
       .sect "ramfuncs"         ;;Used with compilers older than v15.9.0
       .endif
       .endif

        .global  __F28x_usDelay
_F28x_usDelay:
        SUB    ACC,#1
        BF     _F28x_usDelay,GEQ    ;; Loop if ACC >= 0
        LRETR

Please advise.

Alex.

  • The issue was solved after adding "_FLASH" to the predefined symbols.

    Now the below code is active and there is no problem running the F28x_usDelay(x)

    void InitSysCtrl(void)
    {
        //
        // Disable the watchdog
        //
        DisableDog();
    
    #ifdef _FLASH
        //
        // Copy time critical code and Flash setup code to RAM. This includes the
        // following functions: InitFlash()
        //
        // The  RamfuncsLoadStart, RamfuncsLoadSize, and RamfuncsRunStart
        // symbols are created by the linker. Refer to the device .cmd file.
        //
        memcpy(&RamfuncsRunStart, &RamfuncsLoadStart, (size_t)&RamfuncsLoadSize);
    
        //
        // Call Flash Initialization to setup flash waitstates. This function must
        // reside in RAM.
        //
        InitFlash();
    #endif