The MODM_RESET message requests a MIDI output driver to stop sending output data and return all output buffers to the client.
The driver should return MMSYSERR_NOERROR if the operation succeeds. Otherwise it should return one of the MMSYSERR or MIDIERR error codes defined in mmsystem.h. See midiOutReset return values in the Win32 SDK.
A client sends the MODM_RESET message by calling the user-mode driver’s modMessage entry point, passing the specified parameters.
If the driver’s output queue contains any output buffers (see MODM_LONGDATA) whose contents have not been sent to the kernel-mode driver, the driver should set the MHDR_DONE flag and clear the MHDR_INQUEUE flag in each buffer’s MIDIHDR structure, and then send the client a MOM_DONE callback message for each buffer.
Typically, the user-mode driver stops device output by calling DeviceIoControl, sending the kernel-mode driver an IOCTL_MIDI_SET_STATE control code.
If the device is an internal synthesizer, the driver should turn off all notes.
For additional information, see Transferring MIDI Output Data.