This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

RTX: osSignalSet wakes a lower priority thread.

Hello.

I have a thread that waits for up to n signals before sending a specific message.

This is a low priority thread that should only send the message after the higher priority thread sleeps.

The high priority thread code works like this:

    if (a)
        osSignalSet(threadid, EVENT_A);
    if (b)
        osSignalSet(threadid, EVENT_B);
    if (c)
        osSignalSet(threadid, EVENT_C);
    if (d)
        osSignalSet(threadid, EVENT_D);

My issue is that if 'a' and 'b' are true for example, sometimes the message thread will send two messages, one for EVENT_A signal and a second for EVENT_B signal.

Shouldn't the lower priority thread process all signal at once?

I'm using ARM:CMSIS 5.0.0 pack for STM32F103.

Thanks in advance.

Parents Reply Children
No data