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.

LAUNCHXL-CC1312R1: SCS & Timer_open

Part Number: LAUNCHXL-CC1312R1

Hi

I have setup and I am using timer1 in Sensor Controller Studio, I have also setup timer0 in CCS code, but I cant open timer0,  fails on Timer_open(CONFIG_TIMER_0, &timparams); below 

Timer_Params_init(&timparams);
timparams.period = 1000000;
timparams.periodUnits = Timer_PERIOD_US;
timparams.timerMode = Timer_CONTINUOUS_CALLBACK;
timparams.timerCallback = timerCallback;

timer0 = Timer_open(CONFIG_TIMER_0, &timparams);
if (timer0 == NULL) {
    /* Failed to initialized timer */
    while (1) {}
}

Regards

David

  • I am not able to re-create the problem. I took the timerled example (using CONFIG_TIMER_0) from the latest SDK and added some SC code using Timer 1:

    // Generate timer event after 200 us
    timer1Start(TIMER1_MODE_SINGLE, 4800, 0);
    gpioSetOutput(AUXIO_O_LED);
    
    // Wait for the timeout
    timer1Wait();
    gpioClearOutput(AUXIO_O_LED);
    
    // Schedule the next execution
    fwScheduleTask(1);

    I did not have any problems doing:

     timer0 = Timer_open(CONFIG_TIMER_0, &params);

    Siri