These methods enable or disable invocation of all component events. These methods are usually supported only if the component services any interrupt vector. The method DisableEvent may cause disabling of the interrupt, if it is not required by the component functionality or shared with another component. The method usually does not disable either peripheral or the component functionality.
MAIN.C
void main(void)
{
...
B1_EnableEvent(); /* enable the component events */
/* component events may be invoked */
B1_DisableEvent(); /* disable the component events */
/* component events are disabled */
...
}