I installed Virtual MIDI Keyboard (vmpk) using apt-get install
. I also have Jack control
and Qsynth
installed. When I open vmpk, I cannot hear the sound coming from it. How can I do the setting to let the sound come out?
-
1Have you wired the midi-out of vmpk to the midi-in of qsynth in your Jack Control Connections window? And the audio-out of Qsynth to your soundcard?– daithib8Apr 10, 2011 at 19:03
-
3I can see vmpk on Jack control but when I try to open qsynth while running Jack control, qsynth says "Failed to create the audio driver (jack)" and "fluidsynth: error: Faimed to connect to Jack server."– sawaApr 10, 2011 at 19:13
-
Jack starts okay. But qsynth has the problem. Thanks anyway.– sawaApr 10, 2011 at 20:05
3 Answers
An alternative solution:
In Qsynth:
List item
MIDI tab: Enable MIDI Input box checked ALSA Sequencer Client ID: Qsynth1 Audio tab: Audio driver: alsa Soundfonts tab: SFID 1; Name /usr/share/sounds/sf2/FluidR3_GM.sf2; Offset 0
In VMPK:
-->Edit -->Connections: "Enable Thru on MIDI Output" checked
Input MIDI Connection <blank>
Output MIDI Connection FLUID Synth (Qsynth1):0
-
1
-
2Also, make sure to run
QSynth
viaqsynth -a alsa
, otherwise it will default toJACK
. Aug 5, 2015 at 17:38
vmpk is a virtual MIDI Master keyboard, and does not produce any sound. To generate sound, you must
- connect the MIDI output from vmpk to the MIDI input of some tone generator (e.g. qsynth). If you then
- connect the audio output from the tone generator to the audio input for your monitors,
you should hear some sounds.
In your specific situation, where you want to use vmpk, qsynth, and jack control, I would recommend the following procedure to generate audio based on virtual keystrokes:
- Install the "patchage" and "fluid-soundfont-gm" packages
- Open Jack Control
- Review JACK configuration to ensure it is attached to your preferred audio interface
- Start JACK (the big play button)
- Open Patchage
- Open vmpk
- Open Qsynth
- In patchage, connect vmpk MIDI out to Qsynth MIDI in
- In patchage, connect Qsynth audio out to your audio interface (both left and right channels)
- In Qsynth, load a soundfont from
/usr/share/sounds/sf2/FluidR3_GM.sf2
- Virtually press any key in vmpk to hear sound
Although the specific tools in use differ slightly, you may find the guidance at Ubuntu Wiki helpful. The primary difference is that you will be using a virtual keyboard rather than a physical keyboard, but patchage should not be able to tell the difference.
-
2for jack install jackd, so a useful command:
sudo apt-get install jackd patchage vmpk qsynth
– RegiszJan 24, 2015 at 21:15 -
As running
APT
withinstall qsynth
will automatically detectjackd
as dependency and install it, there is no need to specify it. Aug 5, 2015 at 8:32
vmpk produces sound by default on Ubuntu 20.04
I don't fully understand the details, but on Ubuntu 20.04 I just get sound out of the box from vmpk (not using Qsynth and JACK).
Likely the relevant settings which make it work by default are:
- Edit
- MIDI Connections
- MIDI OUT Driver: Sonivox EAS
Working with ALSA
If you want to pipe ALSA output to another synthesizer of your choice, in the MIDI Setup you can set instead:
- MIDI OUT Driver: ALSA
then I can get some sound as follows:
sudo apt install fluidsynth
fluidsynth -a alsa /usr/share/sounds/sf2/FluidR3_GM.sf2
Then I list all input and output alsa ports with:
aconnect -l
which gives:
client 0: 'System' [type=kernel]
0 'Timer '
1 'Announce '
client 14: 'Midi Through' [type=kernel]
0 'Midi Through Port-0'
Connected From: 129:0
client 128: 'VMPK Input' [type=user,pid=584368]
0 'in '
client 129: 'VMPK Output' [type=user,pid=584368]
0 'out '
Connecting To: 14:0
client 130: 'FLUID Synth (586186)' [type=user,pid=586186]
0 'Synth input port (586186:0)'
So we connect the vmpk output to the FLUID Synth input with:
aconnect 129:0 130:0
and fluidsynth starts producing some sound now as we touch the vmpk keys!
The sf2 instruments present by default on the VMPK GUI via Bank/Program pairs are the same as present in /usr/share/sounds/sf2/FluidR3_GM.sf2
as can be seen with:
sf2text /usr/share/sounds/sf2/FluidR3_GM.sf2 | less
e.g.:
(0 "Gun Shot" (preset 127) (bank 0)
QSynth setup
Got it working too with ALSA:
sudo apt install qsynth
qsynth -a alsa
Now in the QSynth GUI go:
- Setup
- Soundfonts
- Open
and select /usr/share/sounds/sf2/FluidR3_GM.sf2
.
Now aconnect
works exactly as before, as qsynth must be using it on the backend. Once connected, I now hear the sound, and playing with QSynth reverb/chorus effects did affect the sound output as expected.
Save to MIDI file