BOOL DriverCallback(dwCallBack, uFlags, hDevice, uMsg, dwUser, dwParam1, dwParam2)
This function notifies a client application by sending a message to a window or callback function or by unblocking a task.
DCB_NOSWITCH | Use this if you know you have enough stack space for the callback; otherwise MMSYSTEM will switch your stack for you. |
DCB_FUNCTION | The application is notified by sending a message to a callback function. The dwCallback parameter specifies a procedure-instance address. |
DCB_WINDOW | The application is notified by sending a message to a window. The low-order word of the dwCallback parameter specifies a window handle. |
DCB_TASK | The application is notified by sending a message to the application or task. The low-order word of the dwCallback parameter specifies a task handle. |
This function can be called at interrupt time.
The client specifies how it wants to be notified when it opens the device. The flags DCB_FUNCTION and DCB_WINDOW are equivalent to the high-order word of the corresponding flags CALLBACK_FUNCTION and CALLBACK_WINDOW specified in the dwParam2 parameter of the _OPEN message when the device was opened.
If notification is done with a callback function, hDevice, uMsg, dwUser, dwParam1, and dwParam2 are passed to the callback. If notification is done with a window, only uMsg, hDevice, and dwParam1 are passed to the window.