PDA

View Full Version : help running ZC in linux



iwn12
07-01-2007, 06:11 PM
ok. I don't know what I'm doing wrong, but I can't get ZC to load. It wont load and when I try to run it from Konsole, I get "Permission Denied" I am using Kubuntu 7.04.

koopa
07-02-2007, 07:17 AM
I have Xubuntu (Feisty) myself (I'm one of the guys that does the linux builds, btw) and with the standard allegro library, I always got that error - I had to install the ubuntu-specific one (from synaptic, universe) and the error went away.

If that doesn't help, what (if anything) does the file allegro.log in your ZC directory contain?

Finally, did you chmod +x the executable? (If you don't know what that is, I'll explain, but if you know about Konsole I'll assume you do)

iwn12
07-04-2007, 12:18 AM
OK. I used the ubuntu specific one and it seems to be working fine now. I just have a problem with the sound. It should work with my sound system, right? (ALSA)

koopa
07-04-2007, 02:24 AM
I haven't got sound to work myself yet ... "failed to load sound driver". I think I'm missing a device to play MIDI files ... if you get it to work, I'd much like to know how, I'm still trying. ALSA should work if it's all installed and set up correctly, I suppose.

iwn12
07-04-2007, 05:08 PM
same here. I also have trouble using MIDI, so I'll look into that.

EDIT: Shouldn't OpenAL be installed?

koopa
07-10-2007, 04:05 AM
I tried replacing alsa with oss today and while allegro fund the sound driver and the actual sounds worked, I couldn't hear any midi. It did also break my other sound settings (in particular my web radio client) so I'll uninstall it again, but I'll mention it just in case you feel like trying.

EDIT: Almost got it to work.
I installed timidity and freepats. Start timidity -iA & in a console to get the server running (on 128:0, among other things). Now pmidi -p 128:0 zelda.mid plays midis ... almost there, just have to set allegro up for it.

iwn12
07-13-2007, 02:04 AM
I also get this.
"ALSA lib rawmidi_hw.c:233:(snd_rawmidi_hw_open) open /dev/snd/midiC0D0 failed: No such file or directory"

koopa
07-13-2007, 04:24 AM
Try the new build I committed, I added some things that might help.

If you get the ALSA message it means allegro has found and loaded a sound driver, which is already good, the rest unfortunately is not ZC but your system that you'll need to set up. Your message seems to hint that you don't have a midi output device configured. What does pmidi -l give you?

A safe option - because it doesn't require a supported sound card - is to use timidity and virmidi to do the job via software.

I set up my system according to this tutorial (http://wiki.allegro.cc/UsingTimidityWithALSARawMIDI), tell me if it helps you.

For the modprobe, I had to do sudo modprobe snd-virmidi snd_index=1 (try numbers from 1 on if it doesn't work at first) until a pmidi -l command showed up a virmidi device alongside timidity:

laptop:~/zcx/trunk$ pmidi -l
Port Client name Port name
14:0 Midi Through Midi Through Port-0
20:0 Virtual Raw MIDI 1-0 VirMIDI 1-0
21:0 Virtual Raw MIDI 1-1 VirMIDI 1-1
22:0 Virtual Raw MIDI 1-2 VirMIDI 1-2
23:0 Virtual Raw MIDI 1-3 VirMIDI 1-3
128:0 TiMidity TiMidity port 0
128:1 TiMidity TiMidity port 1
128:2 TiMidity TiMidity port 2
128:3 TiMidity TiMidity port 3

then connect the timidity to the virtual raw:
aconnect 20:0 128:0

next, add this to ag.cfg in your ZC directory:


[sound]
alsa_device = hw:1,0
alsa_rawmidi_device = hw:1,0


This tells ZC what device to use.

This works for me ... good luck!

iwn12
07-16-2007, 08:16 AM
I didn't have pmidi installed... I installed it and got this:

Port Client name Port name
14:0 Midi Through Midi Through Port-0
128:0 TiMidity TiMidity port 0
128:1 TiMidity TiMidity port 1
128:2 TiMidity TiMidity port 2
128:3 TiMidity TiMidity port 3

I followed the tutorial exactly and it seems to work fine.

when running ZC, I now get this new error:

ALSA lib pcm_hw.c:1351:(_snd_pcm_hw_open) Invalid value for card

EDIT: originally, typing sudo modprobe snd-virmidi snd_index=1 did not work. I simply tried it without "snd_index=1" and now pmidi -l reads:

Port Client name Port name
14:0 Midi Through Midi Through Port-0
20:0 Virtual Raw MIDI 1-0 VirMIDI 1-0
21:0 Virtual Raw MIDI 1-1 VirMIDI 1-1
22:0 Virtual Raw MIDI 1-2 VirMIDI 1-2
23:0 Virtual Raw MIDI 1-3 VirMIDI 1-3
128:0 TiMidity TiMidity port 0
128:1 TiMidity TiMidity port 1
128:2 TiMidity TiMidity port 2
128:3 TiMidity TiMidity port 3


and the sound works great now! both midi and sfx. thanks for your help.

EDIT AGAIN: after the above sound problem was fixed, zquest-l fails to run now. :( I've tried a few things already but I think I'll try re-downloading the file. the file checker in Zlaunch-l says that zelda.dat is missing, but I can find it myself in the folder.

iwn12
07-19-2007, 01:46 AM
zquest-l still dosen't work. here is allegro.log:

ZQuest v2.11 Beta (Build 18)
Allocating tunes buffer (12.00k/12.00k)... OK
Allocating map buffer (807.50k/819.50k)... OK
Allocating combo buffer (5.98k/825.48k)... OK
Allocating string buffer (9.75M/10.56M)... OK
Allocating door combo buffer (159.50k/10.71M)... OK
Allocating dmap buffer (234.00k/10.94M)... OK
Allocating combo buffer (1.62M/12.56M)... OK
Allocating color data buffer (158.11k/12.71M)... OK
Allocating tile buffer (511.88k/21.21M)... OK
Allocating tile grab buffer (511.88k/29.71M)... OK
Allocating trash buffer (97.66k/29.80M)... OK
Allocating item buffer (21.00k/29.83M)... OK
Allocating weapon buffer (2.00k/29.83M)... OK
Allocating guy buffer (20.00k/29.85M)... OK
Allocating combo class buffer (29.91k/29.88M)... OK
Allocating combo undo buffer (1.62M/31.49M)... OK
Allocating new undo tile buffer (511.88k/31.99M)... OK
Resetting new tile buffer...OK
Allocating file path buffers (14.00k/32.00M)... OK
Initializing Allegro... OK
Loading data files:
Fonts.Dat...OK
QST.Dat...ZQuest.Dat...OK

Incompatible version of qst.dat.
Please upgrade to v2.11 Build 0


what does that mean? what build do I have to download to get the right version?

Nicholas Steel
07-19-2007, 02:08 AM
the newest build.

iwn12
07-19-2007, 05:51 AM
build 468 is the latest build. that's probably the only reason the sound works too

koopa
07-20-2007, 10:53 AM
Zquest (latest linux) fails for me too, but it's not anything you can do something about. It's a version problem that you can blame entirely on us developers. To be fixed ...

EDIT : new commit coming as I type. This should fix it.

Sephiroth
07-20-2007, 05:30 PM
I don't have TMidity or whatever it's called installed under Fedora, and I have SFX, but not MIDI. O_o;

iwn12
07-20-2007, 08:40 PM
excellent work!

I just wanted to let you know that all fullscreen modes work with my ati driver (fglrx) but after I made a few major updates, the driver stopped working, it freezes upon loading kdm, so I had to go back to the standard vesa driver. (the open source "radeon" driver also freezes upon loading kdm) and the fullscreen modes do not work with the standard vesa driver.

I don't think it's a problem with ZC, but a problem with the driver. But still, it is worth noting.

koopa
07-21-2007, 09:40 AM
Sephiroth, do you have a (linux-compatible) midi-capable sound card? Can pmidi play midis on your machine?

Timidity++ is a software synthesizer which you only need if you sound card can't do midi (rare) or it's midi features aren't yet supported under linux (sadly, not at all rare).