WakeUp time WaitCommEvent

  • Thread starter Thread starter pen_ch
  • Start date Start date
P

pen_ch

Guest
For a critical application using the serial port (RS232) I want to use events instead of polling in order to read the serial communication buffer.

As described in
Serial Communications
I plan to use the function WaitCommEvent() in order to do that.

The documentation of WaitCommEvent() is here:
WaitCommEvent function (winbase.h)

Unfortunately something is missing in the documentation:

I rely very much on how fast the sleeping thread is wakened-up after the event happens. Is the wake up time somehow specified. How does the windows scheduler handle the wake-up of the waiting thread? Is it completely up to the OS when to do it? could it be that the Message on the serial Port happens and the scheduler still decides to not wake the thread in order to process something else the scheduler thinks is more important?

Thanks very much for clarifying.

Continue reading...
 
Back
Top