The WIDM_START message requests a waveform input driver to begin recording.
The driver should return MMSYSERR_NOERROR if the operation succeeds. Otherwise it should return one of the MMSYSERR or WAVERR error codes defined in mmsystem.h. See waveInStart return values in the Win32 SDK.
A client sends the WIDM_START message by calling the user-mode driver’s widMessage entry point, passing the specified parameters.
If the message is received after input has been started, the driver should return MMSYSERR_NOERROR.
User-mode waveform input drivers should handle input asynchronously, by creating a separate thread to handle communication with the kernel-mode driver. Typically, the new thread starts recording by calling DeviceIoControl to send the kernel-mode driver an IOCTL_WAVE_SET_STATE control code, and by calling ReadFileEx to request the kernel-mode driver to fill client-supplied buffers (see WIDM_ADDBUFFER). When the kernel-mode driver returns a filled buffer, the user-mode driver should:
To avoid unnecessarily locking too much memory, do not send the kernel-mode driver too many buffers at once, or buffers that are excessively large.
Recording should continue until the client sends WIDM_STOP or WIDM_RESET.
For additional information, see Transferring Waveform Input Data.