You are not logged in.

#1 2015-01-03 00:20:31

jforberg
Member
Registered: 2013-04-27
Posts: 9

[SOLVED] Running pulseaudio and timidity++ simultaneously

I've a problem with the sound on my arch system. Have googled extensively but can't find much guidance. Any help is appreciated!

My goal is to run old dos games on Dosbox. For this to work I need both regular wavesound and also midi support. On my machine I run pulseaudio together with ALSA. This takes care of regular wave sound but not midi since my sound card (Intel HDA laptop chip) does not have a built-in synth as far as I can tell.

So I run timidity++, but whenever I start the midi daemon with

<code>$ timidity -iA -Os</code>

Then timidity will grab exclusive access of the soundcard and block wavesound from dosbox, youtube  etc. So I can get it to work with midi or wavesound but not both. Which is no fun.

Perhaps someone else has had the same problem. I will be happy to provide more information about my setup upon request.

Thanks,

Last edited by jforberg (2015-01-05 08:52:18)

Offline

#2 2015-01-03 02:44:51

nagaseiori
Member
Registered: 2012-09-22
Posts: 72

Re: [SOLVED] Running pulseaudio and timidity++ simultaneously

You could try jack2-dbus to have jack and pulseaudio work together.

Offline

#3 2015-01-03 12:10:57

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 14,845

Re: [SOLVED] Running pulseaudio and timidity++ simultaneously

I have found that timidity's deamon mode is NOT needed to have it working with dosbox.

here's how i do it on a PURE ALSA system :

modprobe snd_virmidi  (after you're sure things work, have it autoloaded at boot)

run timidity -iA &

use aconnect to connect timidity and the virtual midi port , see 3.1.3 Connect to virtual MIDI device

make sure you add a midi section in dosbox.conf like this ;

[midi]
#     mpu401: Type of MPU-401 to emulate.
#             Possible values: intelligent, uart, none.
# mididevice: Device that will receive the MIDI data from MPU-401.
#             Possible values: default, win32, alsa, oss, coreaudio, coremidi, none.
# midiconfig: Special configuration options for the device driver. This is usually the id of the device you want to use.
#               See the README/Manual for more details.

mpu401=intelligent
mididevice=alsa
midiconfig=128:0

Configure the application running under dosbox to use a sound device AND the mpu-401 device

Last edited by Lone_Wolf (2015-01-03 12:13:19)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#4 2015-01-03 13:00:13

brebs
Member
Registered: 2007-04-03
Posts: 3,742

Re: [SOLVED] Running pulseaudio and timidity++ simultaneously

Opensuse's source has timidity with 0002-Fix-alsaseq-polling-at-idle-time.patch - maybe it helps.

Offline

#5 2015-01-03 13:24:56

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,076

Re: [SOLVED] Running pulseaudio and timidity++ simultaneously

Does it have to be timidity? I've made pretty good experiences with fluidsynth personally which has a native pulse backend, only thing you have to make sure is to modprobe snd_seq somewhere beforehand, and either set up the systemd service as an user service or simply start it manually with normal user rights, worked pretty flawlessly when I tried in wine but I don't have that game anymore I used to play with so I can't really test

EDIT: Just tried it, timidity works as well, I think the devil lies in the module, so either load snd_seq or Lone_Wolf's snd_virmid before trying, make sure you don't start the midi server as root as that will hog the device.

Last edited by V1del (2015-01-03 14:54:50)

Offline

#6 2015-01-05 08:51:53

jforberg
Member
Registered: 2013-04-27
Posts: 9

Re: [SOLVED] Running pulseaudio and timidity++ simultaneously

Thanks for the pointers!

Fluidsynth seems to work well enough, so I'll stick with that. I suspect that the problems with Timidity are due to some general misconfiguration of my sound system.

Offline

Board footer

Powered by FluxBB