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.

CCS/LAUNCHXL-CC1352P: CCS/LAUNCHXL-CC1352P:

Part Number: LAUNCHXL-CC1352P

Tool/software: Code Composer Studio

In the SCS I am using the sensor handler A to generate task alerts ( Io rising edge callback) :

fwGenAlertInterrupt();

evhSetupGpioTrigger(0, AUXIO_I_EXT, EXT_INT_SET, EVH_GPIO_TRIG_ON_EDGE);

In the CCS task process the alert with the following function:

void scTaskAlertCallback(void)
{
// Clear the ALERT interrupt source
scifClearAlertIntSource();

// Wake up the OS task
platfromExtSensorEvent();

// Acknowledge the ALERT event

scifAckAlertEvents();


} //

problem is scTaskAlertCallback() is called endless even alert is cleared and no interrupt generated on GPIO. 

  • Hi Amit, 

    Are you calling fwGenAlertInterrupt() from the event handler code? See the button debouncer example in SCS and how an gpio event is used to trigger event code. 

    -Simon

  • Hi Simon,

    Followed button debouncer example in SCS on my platform, but still alert interrupt is not cleared and scTaskAlertCallback() invoked infinitely.

    If I do not use SCS code, interrupt handling and clearing is working  correctly.

    void scTaskAlertCallback(void)
    {
         // Clear the ALERT interrupt source
        scifClearAlertIntSource();
    // Do smthing ;
        // Acknowledge the ALERT event
        scifAckAlertEvents();
    } // scTaskAlertCallback
  • Hi Simon,

    I think I found what is causing the issue:

    On CPU task  ( Signaled by scTaskAlertCallback())  there is a call to :   GPIO_enableInt(Board_GPIO_INT_VOX).

    Board_GPIO_INT_VOX is trigger GPIO.

    Looks like calling to GPIO_enableInt() from CPU triggers SCS event handler.

    After removing  he call to  GPIO_enableInt(), scTaskAlertCallback() is called only once and unable to get the next interrupts . 

    Any idea ? 

  • Hi, 

    It looks like you try to control a pin from both the CPU and the SC. A pin can only be allocated by either the CPU or the SC. 

    -Simon

  • Hi Simon,

    Got you. Modified accordingly.

    My target PCB uses 4 different GPIO as triggers .

    SCS limits GPIO event trigger to 3.

    How can have trigger handler for 4th GPIO ?  

  • You can "or" multiple GPIOs to one event if you need more than 3 events. 

    -Simon

  • H Simon,

    I mapped all GPIO to one event handler.

    On event handler using evhGetActiveTrigger(bvEvent)  to determine which event index  (GPIO) triggered the event handler code,

    however index are limited to 3.

    How can determine which event index  (GPIO) triggered if 4 GPIO's can trigger ? 

  • That's not possible. 

    How fast do you need to handle the interrupts? One alternative would be to poll each pin.