ADL Event API

Hiya,

I’m trying to use the adl Event API to manage interaction between an ISR and a management task (as demonstrated in the uart_access sample application).

adl_eventWait() takes a bitmask with the event bits to wait on, and will wait for any (via ADL_EVENT_WAIT_ANY) of the event bits to be set elsewhere using a adl_eventSet() call.

What is not clear to me is how to work out which event bit was set when I am waiting on any one of a number of events to be set.

There is an option to pass in an outEventFlags variable to adl_eventWait(). I read (hoped?) that this variable would have the bit set according to which event had been set in the ISR, but my experimentation to date shows that it’s simply a copy of the inEventFlags mask (i.e. the event bit mask I am already waiting on). The return value from adl_eventWait() doesn’t give any hints either - the return value simply indicates the success or failure (and error code) of the function call.

How do I get which event bit was set after waiting on a call to adl_eventWait()?

Q2686/Open AT 2.37.6/FW 7.47.6

Thanks, Dave

Hiya,

I’ve misread the results of the adl_eventWait() call.

The outEventFlags variable to the adl_eventWait() call DOES return the event matched in the Wait - but this may not be a single bit depending on the value to the adl_eventSet() call…

ciao, Dave