PSoc 4 BLE CyBle_Start callback ISR

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
D_Sd_3235936
Level 4
Level 4
25 sign-ins 50 questions asked 25 replies posted

I use some debug code in the callback function processing BLE events.

I use it in CyBle_Start(MyProcessEventsDebug ​)

Question: is the callback function (passed to CyBle_Start) called via ISR? Where is it called from? and can it interfere in the middle of another activity?

And in general , What is the priority of this callback??

Note: From a quick check that I did using below function, the callback function did not appear to be an ISR.

bool IsInsideISR(void) // funciton that i added to the callback function to determine if it is an ISR

{

    boll bAns = False;

    bAns = ( (SCB->ICSR & SCB_ICSR_VECTACTIVE_Msk) != 0u ) ? True : False;

    return bAns;

}

Thanks

0 Likes
1 Reply
VenkataD_41
Moderator
Moderator
Moderator
750 replies posted 500 replies posted 250 solutions authored

Hi,

Question: is the callback function (passed to CyBle_Start) called via ISR? Where is it called from? and can it interfere in the middle of another activity?

No. This is not the callback. The function "MyProcessEventsDebug" in your case gets executed when you call the API Cy_BLE_ProcessEvents(). This is the reason why we recommend to call the API Cy_BLE_ProcessEvents() once in every connection interval of time.

Hope this helps !

Thanks

Ganesh

0 Likes