You are not logged in.
Pages: 1
Topic closed
I have recently discovered dosbox to play old abandonware games.
I am having some troubles making the sound work and no matter how I modify the dosbox config file, I always get an error.
I am trying to make the sound work with this game
I have unzipped the file in a folder and then from a terminal I cd to the game directory and run
dosbox SIMPSONS.EXE
The game starts fine, but with no sound, some errors were shown in the terminal.
Googling a bit I have found that there are some settings I had to set,
so I run
aconnect -i
which gives in output
client 0: 'System' [type=kernel]
0 'Timer '
1 'Announce '
client 14: 'Midi Through' [type=kernel]
0 'Midi Through Port-0'
I modified the dosbox config file accordingly and now some of the errors have disappeared but dosbox still produces the following message:
dosbox SIMPSONS.EXE
DOSBox version 0.74
Copyright 2002-2010 DOSBox Team, published under GNU GPL.
---
CONFIG:Loading primary settings from config file /home/luca/.dosbox/dosbox-0.74.conf
MIXER:Got different values from SDL: freq 44100, blocksize 512
ALSA:Client initialised [14:0]
MIDI:Opened device:alsa
I have tried to change the [sdl] section in the dosbox config file, but I always get the error message about the MIXER.
Can you please help me fixing it?
Thanks a lot in advance,
Cheers,
Luca
Last edited by lucacerone (2014-08-01 11:33:10)
Offline
First create a copy of dosbox.conf for this game:
grep -v \# $HOME/.dosbox/dosbox-0.74.conf > simpsons.conf
Edit it changing in the [mixer] section blocksize to suggested 512 value. Frequencies should match also. Go to the [midi] section and edit midiconfig/config line appending your midi clients address. The value usually suggested is 128:0, but may differ. Would I be testing this with my midi emulator, I would have had to use 131:0. Should you want to use timidity, look here.
That part would automatically connect dosbox to your midi client, so no further user involvement is/would be necessary.
Add the obvious mounting commands so that the game can be started.
[autoexec]
mount c "/tmp/SIMPSONS/"
c:
cls
SIMPSONS.EXE
exit
To run this configuration:
dosbox -conf simpsons.conf
In good spirits I obviously assume there are no legal issues involved.
Last edited by emeres (2014-07-24 13:23:59)
Offline
Thanks emeres,
first of all: I own the original KONAMI game, I just downloaded it from there because it was faster then going through my basement and find it, but no legal infringement.
I tried to follow your advices, but they do not work:
My midi address is 14:0 (at least, this is what I understood from the output of aconnect -i (I posted it in my first post).
If I change the value of the mixer as you suggested to 512, now I still got the same error, but with a different value (256):
CONFIG:Loading primary settings from config file simpsons.conf
MIXER:Got different values from SDL: freq 44100, blocksize 256
ALSA:Client initialised [14:0]
MIDI:Opened device:alsa
I don't know what it means, but if I use different values, I always get the same error except that the number in the error message is half of the value I set
(e.g. if I set the blocksize to 2048, the message will say that SDL sends a blocksize of 1024, if I set it to 1024, the error message will say blocksize is 512, and so on).
Anyway I thank you for your help,
but unfortunately the sound still does not work.
Offline
Post your configuration file (simpsons.conf). Port 14:0 is midi through according to your first post. What is supposed to be receiving the midi data? What is your output in other words.
Offline
Thanks emeres,
the output when I launch dosbox is the one I posted in the previous posts:
CONFIG:Loading primary settings from config file simpsons.conf
MIXER:Got different values from SDL: freq 44100, blocksize 256
ALSA:Client initialised [14:0]
MIDI:Opened device:alsa
my simpsons.conf file contains the following instead:
[sdl]
fullscreen=false
fulldouble=false
fullresolution=original
windowresolution=original
output=surface
autolock=true
sensitivity=100
waitonerror=true
priority=higher,normal
mapperfile=mapper-0.74.map
usescancodes=true
[dosbox]
language=
machine=svga_s3
captures=capture
memsize=16
[render]
frameskip=0
aspect=false
scaler=normal2x
[cpu]
core=normal
cputype=auto
cycles=auto
cycleup=10
cycledown=20
[mixer]
nosound=false
rate=44100
blocksize=1024
prebuffer=100
[midi]
mpu401=intelligent
mididevice=alsa
midiconfig=128:0
config=128:0
[sblaster]
sbtype=sb16
sbbase=220
irq=7
dma=1
hdma=5
sbmixer=true
oplmode=auto
oplemu=default
oplrate=44100
[gus]
gus=false
gusrate=44100
gusbase=240
gusirq=5
gusdma=3
ultradir=C:\ULTRASND
[speaker]
pcspeaker=true
pcrate=44100
tandy=auto
tandyrate=44100
disney=true
[joystick]
joysticktype=auto
timed=true
autofire=false
swap34=false
buttonwrap=false
[serial]
serial1=dummy
serial2=dummy
serial3=disabled
serial4=disabled
[dos]
xms=true
ems=true
umb=true
keyboardlayout=auto
[ipx]
ipx=false
[autoexec]
mount c "/home/luca/Desktop/SIMPSONS/"
c:
cls
SIMPSONS.EXE
exit
thanks again for the help!
Last edited by lucacerone (2014-07-25 07:06:23)
Offline
That is not what I meant. You do not seem to understand how midi works. You need a midi device (either software or hardware), that would receive the midi data and convert it into sound, in other words synthesize sound, like timidity. The configuration file, as I posted in my first reply, should be stripped from comments with grep. Please correct your post by editing it.
Edit: Read this part of the wiki about midi also. I assume that you do not have a hardware midi synthesizer, so choose a software one. Also you apparently skipped the part about autoexec I posted previously.
Last edited by emeres (2014-07-24 23:17:35)
Offline
Oh thanks emeres, yes I do not know how midi works.
I will go through the documentation you sent me and will write back in the post if I have any doubt, sorry if I misunderstood your replies.
About the autoexec, yes I figured I could do those step manually (and I couldn't really understand if the /tmp/SIMPSONS line has to be mounted as C:,
or if you meant that I have to mount the directory containing the game).
Thanks again for all the help!
Offline
Hi emeres,
I have stripped the comments from the config file and added the autoexec part.
I also have read about how midi works (interesting).
I am now trying to configure timidity, hopefully I will have it working soon!
Thanks again!
Offline
The '/tmp/SIMPSONS' would have been the directory I would have used for temporarily get the game running. You need to change that to your games directory and you already did that according to the configuration file. To run timidity as a midi server/synthesizer or fluidsynth, which also wiki mentions, or to play a midi file, run these:
#Midi
timidity -OjS -EFreverb=0 -c /etc/timidity++/timidity-freepats.cfg '/hdd/Music/Bokiv - PE Explorer 1.98 crk.mid' #play a midi file
timidity -c /etc/timidity++/timidity-freepats.cfg -iA #run as server
timidity -c /etc/timidity++/timidity-freepats.cfg -iA -OjS #run as server with jack output
fluidsynth -a alsa -m alsa_seq -l -i /usr/share/soundfonts/FluidR3_GM2-2.sf2 -s #run as server
fluidsynth -a alsa -m alsa_seq -l -i /usr/share/soundfonts/FluidR3_GM2-2.sf2 '/hdd/Music//Bokiv - PE Explorer 1.98 crk.mid' #play a midi file
Read the appropriate manuals for those applications for more explanation. I tested these yesterday, you may need to change them. Remember to install timidity-freepats for timidity or soundfont-fluid for fluidsynth. You can test the configuration playing a midi file, like above.
After that check what ports the synthesizer you choose occupies with 'aconnect -l'. Then change the midiconfig/config line under midi section to that port. Running dosbox with -conf switch pointing to the configuration, like I already posted above, should give you the sound.
Offline
Finally it worked!
I runned timidity without the -c option and kept getting no sound!
When I used the second of the MIDI commands you posted, it worked like a champ!
Thanks a lot!
Before I mark it as SOLVED: what are possible drawbacks of starting timidity++ at startup?
Offline
Having a little less ram and cpu cycles ready? You would have to search for any specific drawbacks. Since this is apparently your first time with midi, I would suggest you start timidity only when you really want to, otherwise it will just sit there 99% of time. Consider using a script for starting a dosbox game:
#!/bin/bash
if [ ! $(pidof timidity) ]; then
timidity -c /etc/timidity++/timidity-freepats.cfg -iA & >/dev/null; fi
dosbox -conf "$HOME/.dboxfe/Daggerfall.conf" && pkill -9 timidity;
Untested, since I do not use timidity for dosbox myself.
Edit: Added killing timidity after dosbox quits.
Last edited by emeres (2014-07-25 17:02:47)
Offline
Thank you emeres. On my machine (Lubuntu 14.04), this worked:
timidity -c /etc/timidity/freepats.cfg -iA -j
Last edited by Marco Sulla (2016-02-27 00:26:14)
Offline
Offline
Pages: 1
Topic closed