- The CY_CALLBACK_EVENTS enum type values can be read only as part of the callback function registered using the CySetEventNotification() API.
- Please add the below function block as a callback function.
void callbackFunc(UINT16 bitmask)
/* bitmask can be read here to identify the event occurred */
The below statement registers the callback function to be executed whenever there is a CY_CALLBACK_EVENTS event.
rStatus = CySetEventNotification(handle, &callbackFunc);
So, the correct answer is that there is no way to read the bits. thanks. Why not just say that?
As I had mentioned earlier, the status bits can be read when there is an occurrence of the event. The CySetEventNotification() API is used to set the function pointer that is to be invoked when there is an event occurrence. This call back function indicates the event through a bit-mask.