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.

AM5728: DSP program load issue in RTOS

Part Number: AM5728
Other Parts Discussed in Thread: SYSBIOS

Dear TI, I have two copies of near identical code to test communication between the DSPs using messageQ   However, when I go through the process of:

1.  launching the configuration

2.  CDonnecting to Cortex A15_0 with button press on EVM module

2.  connecting to DSP1

3.  connecting to DSP2

everything is fine...

Now I try and 'Load Program' for DSP1 & DSP2.

DSP1 seems to load fine, but DSP is getting stuck in timer.c function. on:

while(Timer_getCount(&tempObj) < timerCountStart + TIMERCOUNTS);

itleast when I pause the processor this is where it is at.

What might be the problem?  Is this s SYS/BIOS startup procedure that is locking up so that it never reaches the main function?  why might it be locking up here?

Thanks.

  • The RTOS team have been notified. They will respond here.
  • Hi,

    There is a similar one, e2e.ti.com/.../2241182 please check if this helps.

    Regards, Eric
  • It is definitely related.  However I can get DSP1 to get to main, but when I load DSP2 it is the one that gets caught in the same spot.

    It states GPEVM_AM572X_SiReva.ccxml, I'm not familiar with the IDK vs GP differences.

    Is there just a GEL file I need to run to enable a timer for DSP?  I am not running anything manually, just the GEL files that run when I connect to the A15_0, then I connect to the DSPs with no additional manually run GEL files.

  • Hi,

    What is the CCS version and the GEL file used? What timer is used in DSP1 and DSP2? Please try to use a newer CCS version, e.g. CCS 7.3. After running the default script on A15, can you run the GEL function AM572x_MULTICORE_EnableAllCores to see if the behavior changes?

    Regards, Eric
  • Also,

    in the above function, what if remove the suspend control of timer 5 and 6:
    WR_MEM_32(DRM_SUSPEND_CTRL_TIMER5, (DRM_SUSPEND_SRC_DSP1 << 4) | 0x1);
    WR_MEM_32(DRM_SUSPEND_CTRL_TIMER6, (DRM_SUSPEND_SRC_DSP2 << 4) | 0x1);

    Regards, Eric
  • I'm using code composer v7.4.0
    I'm not certain, but when I select the Cortex part and view the Gel files it lists:
    gpevm_am572x.gel
    AM572x_startup_common.gel
    AM572x_prcm_config.gel
    AM572x_pad_config.gel
    AM572xmulticore_reset.gel
    AM572x_emif_macros.gel
    AM572x_ddr_config.gel
    AM572x_PRCM_Get_Config.gel

    I'm not that familiar with GEL files, I assume this is what runs when I go through the procedure of selecting Launch Selected configuration and then pressing connect to the cortex A15_0 and pressing the button on the board. This is the list when I select the A15_0 and goto tools and GEL files.

    As for what timer the DSPs are using, I haven't a clue. I'm using SYS/BIOS and assume it is using/setting them up. In my code I make no specific use of the timers. This is startup code (timer.c) supplied by you TI being called by SYS/BIOS, not me.

    I went to scripts and tried the enable all cores script. Unfortunately no change in response.
  • Silly question, where is the GEL file located? I've searched the drive and can't find where it's located, is it named differently? I assume you wish me to remove the above two lines from AM572x_MULTICORE_EnableAllCores.gel correct?
  • Rob,

    I found the issue is that: By default, BIOS uses GPtimer5 to source the clock ticks in the BIOS clock module. The GEL was created with the assumption that the DSP1 developers will use GPtimer5 and DSP2  users will use GPtimer6 to source clock module. This means that DSP2 developers will need to add configuration script to change the clock source to GPtimer6.

    So, don't change the GEL file and add the following in your dsp2 .cfg and let me know if this works.
    /* --------------------------- TICK --------------------------------------*/
    var Clock = xdc.useModule('ti.sysbios.knl.Clock');
    /* Changes the BIOS clock source as GPTimer6 */
    Clock.timerId = 5;

    I can't build your project but I tried a simple RTOS hello world example, without this change, it can load into DSP1 and go main, but stuck at DSP2 when loaded. After add those two lines in .cfg, I can load and run on DSP2 without problem. I also attached my CCS project for your reference.

    Regards, Erichello_GPEVM_AM572X_C66XX.zip

  • Thanks Eric, that definitely resolved the issue.  Both DSPs come up now and allow me to debug it.

    Thanks.