microsoft / MIDI

Windows MIDI Services
MIT License
300 stars 24 forks source link

[BUG] BS2UMP transform always sets group to 0 (for a MIDI 1.0 client) #377

Open Psychlist1972 opened 1 month ago

Psychlist1972 commented 1 month ago

Describe the bug group always set to zero

Expected behavior Group needs to match the group index for that midi 1.0 port

Installer Name or Version DP6

m-komo commented 1 month ago

Does this case occur on a USB MIDI 1.0 device running with the USB MIDI 1.0 driver (USBAUDIO.sys)?

Psychlist1972 commented 1 month ago

Does this case occur on a USB MIDI 1.0 device running with the USB MIDI 1.0 driver (USBAUDIO.sys)?

Yes. This applies to MIDI 1.0 devices using a vendor or MIDI 1.0 class driver. It also applies to the older MIDI 1.0 APIs in Windows (but you cannot test that part yet)

This does not apply to anything using the UMP class driver.

m-komo commented 1 month ago

Probably, I don't understand this well, but I would like to share my test result.

  1. Load attached UUT_ZOA_104.zip to the ProtoZOA. This firmware works as a USB MIDI 1.0 device with four input and output ports, and all received messages are echo back to the host.
  2. Attach the device to PC and make sure the device is running with the OS in-box USB MIDI 1.0 driver (USBAUDIO.sys).
  3. Open a console and monitor the attached device.
  4. Open another console and send GrpIndexTest.txt which contains MT2 message with group index of 0-7.

Messages which have group index of 0-3 were sent to the device and other messages were dropped. image

Then all received messages were displayed on the monitor. image

So, it seems everything works as expected...

Psychlist1972 commented 1 month ago

Thanks @m-komo

I just realized that this won't apply to the devices themselves, but only to the older MIDI 1.0 APIs. The devices have the incoming translation happening in the KSA abstraction for this very reason. But when a MIDI 1.0 client connects, it does not have the group # context, so neither does the translation code.

Keeping this open until others are able to test integration with the older winmm and WinRT MIDI 1.0 APIs.