All:
IRQ_enable( ) gets used in my code and in the example code. However, it differs from most of the other functions in the interrupt support in the value it returns. Most other functions return an error or CSL_OK. IRQ_enable returns an error or a "previous bit mask value."
If I do a test for the error, can I also get confused with a "previous bit mask value" having the same value as the error?
I would like to add this to code that calls IRQ_enable:
...setup code for UART...
retVal = IRQ_enable(UART_EVENT); // Enable Uart interrupt
if(retVal != CSL_ESYS_INVPARAMS) // Check for error response.
{
retVal = 0; // if no error, then set return value to 0.
}
return(retVal); // Return from setup.
Is there a better way to handle the "previous bit mask value" so that I can get a return of error or CSL_OK?