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.

Using dmtimer in DSPBIOS 6

Other Parts Discussed in Thread: SYSBIOS

Hi guys,

I am trying to configure/use a dmtimer using DSP/BIOS 6 timer module:

Below is a snippet of my :

#include <ti/sysbios/timers/dmtimer/Timer.h>
#include <ti/sysbios/hal/Hwi.h>

Timer_Handle timerHandle;

void fxn( UInt32 TimerPeriod)
{
    Timer_Params timerParams;
    ti_sysbios_hal_Hwi_Params HwiParams;
    UInt key;
    ti_sysbios_hal_Hwi_Params_init(&HwiParams);
    Timer_Params_init(&timerParams);
    timerParams.periodType = Timer_PeriodType_MICROSECS;
    timerParams.hwiParams = &HwiParams;
    timerHandle = Timer_create(Timer_ANY, slpm_TimerExpireFxn, &timerParams , NULL );
. . .

 

But I am getting an exception in run time in the Timer_create():

E_exception: id = 3, pc = 0000cipc_proc_sync_start failed: status [0xffffffff]

Do you know If I am missing something?


Thanks in advance.


  • The problem appears to be due to a mismatch between the physical timer base addresses used by Ducati and the virtual timer base addresses used by the host. The base addresses used in the ti.sysbios.timer.dmtimer.Timer module can be modified to match the virtual addresses used by the host by adding the following to your configuration script:

    var Timer = xdc.useModule('ti.sysbios.timers.dmtimer.Timer');

    Timer.timerSettings[0].baseAddr = 0xA8034000;

    Timer.timerSettings[1].baseAddr = 0xA8036000; 

    Timer.timerSettings[2].baseAddr = 0xA803E000; 

    Timer.timerSettings[3].baseAddr = 0xA8088000;

  • Hi

    we found the cause of this particualr issue

    - In first place we should override the baseAddr of timers as Alan suggested

    Another issue was that we need to enable first the clock of the Timer at Host side using the following API

    omap_dm_timer_request_specific(GPTIMER_3);

    This API should enable the CLK at GPTimer and now we were able to use it from Ducati side

     

    Thanks Alan and Armando for their help