Using Linux Virtual Midi with WINE does not work
Using Linux Virtual Midi with WINE does not work
Hi,
I have recently started using WINE with the wineasio driver to run my Windows audio apps. In Windows I did a lot of work using MIDI Yoke (a virtual 'MIDI cable' driver). The Linux equivalent is the snd-virmidi ALSA driver. I find, however, that WINE does not send MIDI messages throught the virmidi ports to Linux Apps.
I have tried this on Ubuntu 8.04 and Puppy Linux 4.0 using WINE 1.1.6. Am I doing something wrong or does WINE not support the virmidi driver?
I have tried to use the snd-virmidi ports with wineasio installed and without wineasio installed. So wineasio is not messing up anything.
I would like to know if someone else has succesfully used the snd-virmidi virtual midi ports in a WINE app?
Thanks,
Graham
Johannesburg, South Africa
I have recently started using WINE with the wineasio driver to run my Windows audio apps. In Windows I did a lot of work using MIDI Yoke (a virtual 'MIDI cable' driver). The Linux equivalent is the snd-virmidi ALSA driver. I find, however, that WINE does not send MIDI messages throught the virmidi ports to Linux Apps.
I have tried this on Ubuntu 8.04 and Puppy Linux 4.0 using WINE 1.1.6. Am I doing something wrong or does WINE not support the virmidi driver?
I have tried to use the snd-virmidi ports with wineasio installed and without wineasio installed. So wineasio is not messing up anything.
I would like to know if someone else has succesfully used the snd-virmidi virtual midi ports in a WINE app?
Thanks,
Graham
Johannesburg, South Africa
Last edited by ggoode.sa on Sun Nov 30, 2008 11:27 am, edited 1 time in total.
After I read your post this morning, I did a test of my Wine version (1.1.9), which does misbehave from time to time, but this time just to see whether my MIDI works. And I found, that for the moment it did not work.
But then I also did some Linux-side troubleshooting, and found out that even my Linux program "KMid" would not produce sound, because my own "Tiimidity" server had locked up.
Long story short, by restarting my own Tmidity server, I found I was able to get my own Wine-MIDI interface working again, such that "Noteworthy Composer" plays correctly. Thus, I concluded that on the surface, using the ALSA Wine drivers, getting MIDI to work is possible.
But this does not mean, to upgrade to version 1.1.9 of Wine immediately, because just doing these upgrades may in fact just expose you to regressions.
If I could make a guess: You meed to be very sure of exactly which "Virtual MIDI" kernel modules you have loaded, because the kernel modules named along with "Virtual MIDI" can mean different things. One of them is a module, which just sends MIDI sequences to its port, to the hardware MIDI output of the sound card. Even if you have no sound font loaded. While another one has to do with USB-MIDI-Cables. And another definition for 'Virtual MIDI' has to do with the Virtual Controllers for pitch, amplitude and so on, of which there are many. The responsible drivers and modules all seem to have similar names, so beware!
Just to see whether the Virtual / Cable MIDI ports are working under Linux, first try running a Linux app to use them as its output. If you don't have one, try "KMid" ?
If the port works with a Linux app, then you know it's not a Wine issue, because I think that to the applications the ports all 'look' the same.
BTW, I only have my own MIDI server, no cables yet, on my own PC.
Secondly, I'm not sure whether I can recognize which Wine driver you're referring to as "wineaseo" ? I do know that Wine makes no promise to emulate Windows-installed drivers. So if you installed drivers specifically for use with Wine - again - beware. Wine is based entirely on the assumption, of using Linux drivers, to make them look like Windows resources. And the FAQ seems to say, that the only exception planned for the future, may be printers ?
Anyhow, I hope you get it sorted out.
Dirk
But then I also did some Linux-side troubleshooting, and found out that even my Linux program "KMid" would not produce sound, because my own "Tiimidity" server had locked up.
Long story short, by restarting my own Tmidity server, I found I was able to get my own Wine-MIDI interface working again, such that "Noteworthy Composer" plays correctly. Thus, I concluded that on the surface, using the ALSA Wine drivers, getting MIDI to work is possible.
But this does not mean, to upgrade to version 1.1.9 of Wine immediately, because just doing these upgrades may in fact just expose you to regressions.
If I could make a guess: You meed to be very sure of exactly which "Virtual MIDI" kernel modules you have loaded, because the kernel modules named along with "Virtual MIDI" can mean different things. One of them is a module, which just sends MIDI sequences to its port, to the hardware MIDI output of the sound card. Even if you have no sound font loaded. While another one has to do with USB-MIDI-Cables. And another definition for 'Virtual MIDI' has to do with the Virtual Controllers for pitch, amplitude and so on, of which there are many. The responsible drivers and modules all seem to have similar names, so beware!
Just to see whether the Virtual / Cable MIDI ports are working under Linux, first try running a Linux app to use them as its output. If you don't have one, try "KMid" ?
If the port works with a Linux app, then you know it's not a Wine issue, because I think that to the applications the ports all 'look' the same.
BTW, I only have my own MIDI server, no cables yet, on my own PC.
Secondly, I'm not sure whether I can recognize which Wine driver you're referring to as "wineaseo" ? I do know that Wine makes no promise to emulate Windows-installed drivers. So if you installed drivers specifically for use with Wine - again - beware. Wine is based entirely on the assumption, of using Linux drivers, to make them look like Windows resources. And the FAQ seems to say, that the only exception planned for the future, may be printers ?
Anyhow, I hope you get it sorted out.
Dirk
Hi Dirk and others,
The custom audio driver is 'wineasio' (ASIO driver for WINE). You can do a google for wineasio and find out more if you need to. This allows high level ASIO audio input and output via the Jack Audio Connection Kit server.
Running 'modprobe snd-virmidi index=1' configures the virtual midi ports (1-4) for me. Linux Apps can use the ports with No Problem. Wine Apps can't.
This is regardless of whether I'm using the plain ALSA sound, JACK sound, or wineasio. All my other MIDI devices work perfectly. The snd-virmidi devices show up in Wine Apps, they just don't work - no MIDI data transferred.
Thanks
Graham Goode
The custom audio driver is 'wineasio' (ASIO driver for WINE). You can do a google for wineasio and find out more if you need to. This allows high level ASIO audio input and output via the Jack Audio Connection Kit server.
Running 'modprobe snd-virmidi index=1' configures the virtual midi ports (1-4) for me. Linux Apps can use the ports with No Problem. Wine Apps can't.
This is regardless of whether I'm using the plain ALSA sound, JACK sound, or wineasio. All my other MIDI devices work perfectly. The snd-virmidi devices show up in Wine Apps, they just don't work - no MIDI data transferred.
Thanks
Graham Goode
I thought that I should look up 'wineasio', since I have no experience with ASIO myself. Here is a link I could suggest to you, to compare using your Wine apps, where this Web pages sets up the arbitrary ASIO app "XT2". Thus, Don't follow every instruction here literally. But you may find some observations helpful:
http://www.kvraudio.com/forum/viewtopic.php?t=182682
Now the most important statement I was able to find here, was also the very last statement, in that wineasio MIDI does not work with Jack, whereas other ASIO, Audio emulation does. So what they write here, is ONLY TO HAVE Alsa CHECKED OFF.
Also, there was a second search result from AltaVista, reminding us that wineasio is not meant for Jack, if you're going to use the MIDI.
But then ultimately I guess that for serious musicians, ASIO is a b***h to set up.
You'd have to set it up for use with Alsa on your Linux side then, from the beginning, and let me guess, does that throw a monkey-wrench into your plans?
Dirk
http://www.kvraudio.com/forum/viewtopic.php?t=182682
Now the most important statement I was able to find here, was also the very last statement, in that wineasio MIDI does not work with Jack, whereas other ASIO, Audio emulation does. So what they write here, is ONLY TO HAVE Alsa CHECKED OFF.
Also, there was a second search result from AltaVista, reminding us that wineasio is not meant for Jack, if you're going to use the MIDI.
But then ultimately I guess that for serious musicians, ASIO is a b***h to set up.

You'd have to set it up for use with Alsa on your Linux side then, from the beginning, and let me guess, does that throw a monkey-wrench into your plans?

Dirk
Dirk,
You have missed the point here. I have WineAsio working. All of my MIDI keyboards work. The MIDI Thru port works perfectly.
I don't have snd-virmidi working. The Virtual MIDI ports do not work in Wine regardless of whether I'm using wineasio or not.
The Virtual MIDI ports provided by the snd-virmidi kernel driver are listed and work with Linux MIDI apps. They are listed BUT do not work with WINE MIDI apps.
I don't know enough to say whether this is a bug, or a configuration issue.
Thanks for looking into things though. It's great to know that someone 'out there' is trying
Graham
You have missed the point here. I have WineAsio working. All of my MIDI keyboards work. The MIDI Thru port works perfectly.
I don't have snd-virmidi working. The Virtual MIDI ports do not work in Wine regardless of whether I'm using wineasio or not.
The Virtual MIDI ports provided by the snd-virmidi kernel driver are listed and work with Linux MIDI apps. They are listed BUT do not work with WINE MIDI apps.
I don't know enough to say whether this is a bug, or a configuration issue.
Thanks for looking into things though. It's great to know that someone 'out there' is trying

Graham
I'm going to go out on a limb here, and guess that it's not by design, then, that you would have chosen the Jack driver in your winecfg panel, but just an attempt to get Wine to accept your MIDI.
But here is my point more concisely: If under the Jack audio drivers branch of the winecfg window, there are no MIDI entries, because I also don't see MIDI entries there, it means that you won't have access to your Linux-MIDI ports from within Wine, if you go with Jack. At first I thought, though, that you had a specific reason to do so.
But let's assume that you don't really care just yet, whether you have Alsa as the Linux basis for your sound. According to what I've read, Alsa is really the way to go anyway.
I assume that even with the Alsa branch of your winecfg window uniquely checked off, Wine may not be able to connect to your Linux-MIDI ports, unless you also have the kernel module 'snd-seq' loaded. So to see if it is loaded, you might just try
lsmod | grep snd-seq
If this turns up nothing, you'd next try
su
modprobe snd-seq
Of course, you never run Wine as root.
Now I'm biting my nails over this advice to you, because I don't know whether this module is compatible with 'snd-virmidi' or not. If it isn't, your kernel could freeze. Yet, by supplying Wine users with Alsa MIDI, but no Jack MIDI, this kernel module just might be needed BY WINE ITSELF, for no better reason than 'just because'.
But if your lsmod query shows you, that as a dependency of the other kernel modules snd-seq is already loaded, then I can offer you no other advice. Good luck!
Dirk
[EDIT] Mind you, if issuing the query
lsmod | grep snd-seq
should reveal that you already have the kernel module loaded, named
snd-seq-oss
then one solution to your problem might be, just to check off (uniquely) the "OSS" branch, in the Audio tab, of the winecfg window, because each of these modules causes additional modules to be loaded, and in that case you'd already be set up, for your Linux sound to be coming through the OSS drivers.
Even if ASIO should be called ASIO-Jack under Windows, it will no longer belong to Jack under Wine. As long as you have ASIO installed, it could recognize the Linux drivers for either Alsa or OSS and function, giving you ASIO-Jack virtually under Wine then.
But, It's also possible that your whole problem is a bug in Wine, as you suggested, or that it's a bug in how you have wineasio installed.
But here is my point more concisely: If under the Jack audio drivers branch of the winecfg window, there are no MIDI entries, because I also don't see MIDI entries there, it means that you won't have access to your Linux-MIDI ports from within Wine, if you go with Jack. At first I thought, though, that you had a specific reason to do so.
But let's assume that you don't really care just yet, whether you have Alsa as the Linux basis for your sound. According to what I've read, Alsa is really the way to go anyway.
I assume that even with the Alsa branch of your winecfg window uniquely checked off, Wine may not be able to connect to your Linux-MIDI ports, unless you also have the kernel module 'snd-seq' loaded. So to see if it is loaded, you might just try
lsmod | grep snd-seq
If this turns up nothing, you'd next try
su
modprobe snd-seq
Of course, you never run Wine as root.
Now I'm biting my nails over this advice to you, because I don't know whether this module is compatible with 'snd-virmidi' or not. If it isn't, your kernel could freeze. Yet, by supplying Wine users with Alsa MIDI, but no Jack MIDI, this kernel module just might be needed BY WINE ITSELF, for no better reason than 'just because'.
But if your lsmod query shows you, that as a dependency of the other kernel modules snd-seq is already loaded, then I can offer you no other advice. Good luck!
Dirk
[EDIT] Mind you, if issuing the query
lsmod | grep snd-seq
should reveal that you already have the kernel module loaded, named
snd-seq-oss
then one solution to your problem might be, just to check off (uniquely) the "OSS" branch, in the Audio tab, of the winecfg window, because each of these modules causes additional modules to be loaded, and in that case you'd already be set up, for your Linux sound to be coming through the OSS drivers.
Even if ASIO should be called ASIO-Jack under Windows, it will no longer belong to Jack under Wine. As long as you have ASIO installed, it could recognize the Linux drivers for either Alsa or OSS and function, giving you ASIO-Jack virtually under Wine then.
But, It's also possible that your whole problem is a bug in Wine, as you suggested, or that it's a bug in how you have wineasio installed.
Using Linux Virtual Midi with WINE does not work
Hi,
As an experiment, Graham, can you try following Dave Hayes' instructions for
Reaper, here:
http://www.davehayes.org/2007/04/27/how ... h-wineasio
Read all the comments below the instructions before you start -- I'm not sure
he fully updated with the suggestions.
Regards,
-- Peter
ggoode.sa wrote:
As an experiment, Graham, can you try following Dave Hayes' instructions for
Reaper, here:
http://www.davehayes.org/2007/04/27/how ... h-wineasio
Read all the comments below the instructions before you start -- I'm not sure
he fully updated with the suggestions.
Regards,
-- Peter
ggoode.sa wrote:
Hi,
I have recently started using WINE with the wineasio driver to run my
Windows audio apps. In Windows I did a lot of work using MIDI Yoke (a
virtual 'MIDI cable' driver). The Linux equivalent is the snd-virmidi ALSA
driver. I find, however, that WINE does not send MIDI messages throught the
virmidi ports to Linux Apps.
I have tried this on Ubuntu 8.04 and Puppy Linux 4.0 using WINE 1.1.6. Am I
doing something wrong or does WINE not support the virmidi driver?
Thanks,
Graham Johannesburg, South Africa
Hi Peter and all who follow this thread,
I have wineasio working. Wineasio is NOT the problem - pleased forget wineasio.
I don't have the Virtual Midi Ports provided by the snd-virmidi kernel module working.
To create the virtual midi ports do 'modprobe snd-virmidi index=1'. Configure WINE to use ALSA. Install MIDI-OX in WINE. Configure MIDI-OX to accept MIDI signals from the 1st virtual midi port and Map the input through to the 2nd virtual midi port. Link the 1st virtual midi port to your MIDI keyboard using aconnect. Start Qsynth in Linux and configure input from the 2nd virtual midi port. Play notes. Nothing. Link MIDI keyboard straight to Qsynth, play notes - sound plays.
Conclusion - snd-virmid driver does not work in WINE, OR, snd-virmidi is not correctly set up for WINE to use.
Which one is correct?
Graham
I have wineasio working. Wineasio is NOT the problem - pleased forget wineasio.
I don't have the Virtual Midi Ports provided by the snd-virmidi kernel module working.
To create the virtual midi ports do 'modprobe snd-virmidi index=1'. Configure WINE to use ALSA. Install MIDI-OX in WINE. Configure MIDI-OX to accept MIDI signals from the 1st virtual midi port and Map the input through to the 2nd virtual midi port. Link the 1st virtual midi port to your MIDI keyboard using aconnect. Start Qsynth in Linux and configure input from the 2nd virtual midi port. Play notes. Nothing. Link MIDI keyboard straight to Qsynth, play notes - sound plays.
Conclusion - snd-virmid driver does not work in WINE, OR, snd-virmidi is not correctly set up for WINE to use.
Which one is correct?
Graham
Hi,
I am now changing my tactics and am going to try using the 'snd-seq-dummy' module. I did some research on this module this morning and have found the module option for creating more than one MIDI Through port:
'modprobe snd-seq-dummy ports=4'
If this works i'll add it to my modprobe.conf file.
Graham
I am now changing my tactics and am going to try using the 'snd-seq-dummy' module. I did some research on this module this morning and have found the module option for creating more than one MIDI Through port:
'modprobe snd-seq-dummy ports=4'
If this works i'll add it to my modprobe.conf file.
Graham