https://bugs.winehq.org/show_bug.cgi?id=43725
Bug ID: 43725 Summary: Unable to access MIDI ports from application running inside wine Product: Wine Version: 2.15 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: winealsa.drv Assignee: wine-bugs@winehq.org Reporter: aaahaaap@gmail.com Distribution: ---
When running an application in wine that produces MIDI I'm unable to access alsa MIDI port created by wine. I don't know why this is, but I noticed a couple of strange things: - The port is automatically connected to my soundcard - I'm unable to disconnect wine's MIDI output port. When doing so using "aconnect -d 129 16" I get the following error message "Disconnection failed (Operation not permitted)"
Some relevant output: $ aconnect -l client 0: 'System' [type=kernel] 0 'Timer ' 1 'Announce ' Connecting To: 128:0, 130:0 client 16: 'Saffire 6 USB' [type=kernel,card=0] 0 'Saffire 6 USB MIDI 1' Connecting To: 128:0[real:0], 129:1 Connected From: 128:0, 129:0 client 129: 'WINE midi driver' [type=user,pid=17198] 0 'WINE ALSA Output' Connecting To: 16:0 1 'WINE ALSA Input ' Connected From: 16:0
$ cat /proc/asound/seq/clients Client info cur clients : 4 peak clients : 6 max clients : 192
Client 0 : "System" [Kernel] Port 0 : "Timer" (Rwe-) Port 1 : "Announce" (R-e-) Connecting To: 128:0 Client 16 : "Saffire 6 USB" [Kernel] Port 0 : "Saffire 6 USB MIDI 1" (RWeX) Connecting To: 128:0[r:0], 129:1 Connected From: 128:0, 129:0 Client 128 : "a2jmidid" [User] Port 0 : "port" (rw--) Connecting To: 16:0 Connected From: 0:1, 16:0[r:0] Input pool : Pool size : 200 Cells in use : 0 Peak cells in use : 3 Alloc success : 54 Alloc failures : 0 Client 129 : "WINE midi driver" [User] Port 0 : "WINE ALSA Output" (r-e-) Connecting To: 16:0 Port 1 : "WINE ALSA Input" (-we-) Connected From: 16:0 Input pool : Pool size : 200 Cells in use : 0 Peak cells in use : 0 Alloc success : 0 Alloc failures : 0
If some more info is needed to debug this please let me know.
https://bugs.winehq.org/show_bug.cgi?id=43725
--- Comment #1 from aaahaaap@gmail.com --- Judging by the info here https://wiki.winehq.org/MIDI#Selecting_the_Output_-_the_MIDI_mapper I think this is just expected behaviour. Especially the sentence "In Wine, the mapper forwards to the first device (number 0) by default." seems to indicate this happens automatically. I've also been able to get a usable port by adding snd-seq-dummy/Midi Through as the first port, this one I can actually use with software synths.
It does seem like the docs are out of date, since there's no screen winecfg that shows the available devices as mentioned in these sentences: "The order is shown in winecfg, with device #0 occuring topmost. If this happens to be the "MIDI through" port on your system with SW-only synthesizers, you need to change the configuration via the registry."
It would be nice if there would a configurable option in wine to choose which device to use.