Forums » Linux

[Ubuntu 9.10] [Audio] Random cracking noises

12»
Oct 19, 2009 Detructor link
Hi there,

I'm new to this game (just played some hours, and it's cool ;) physic mode ftw!) and I've a problem: Sometimes, I get cracking noises, instead of the "real" audio.

After sometime it get's back to the "normal" audio and after a few moments back to the cracking noises.

All other sound applications (banshee, Heroes of Newerth, AlienArena, Firefox/Youtube) are working without any problem.

I'm using Alsa ingame. I guess that this is a pulseaudio problem, or a problem with the alsa librarys.

Here is the content from the error.log located in ~/.vendetta
[quote]
[Mon Oct 19 22:24:36 2009] Found driver: "Open Sound System driver". Type 1, Version 8.1. Load @0x095963b8
[Mon Oct 19 22:24:36 2009] Instantiate address: 0x7a26c0
[Mon Oct 19 22:24:36 2009] Found driver: "OpenGL Reference GKGL driver". Type 5, Version 78.0. Load @0x09596c00
[Mon Oct 19 22:24:36 2009] Instantiate address: 0x42fd80
[Mon Oct 19 22:24:36 2009] Found driver: "ALSA driver". Type 1, Version 8.1. Load @0x095977d0
[Mon Oct 19 22:24:36 2009] Instantiate address: 0x8b9ea0
ALSA initialized: 44100Hz, 16bit stereo, 92ms latency (16 periods x 256 samples)
[Mon Oct 19 22:24:38 2009] load_sample_ogg: Couldn't open sound/mission.updated.ogg (mission.updated)
[Mon Oct 19 22:24:38 2009] load_sample: Couldn't open sound/mission.updated.ogg (mission.updated)
[Mon Oct 19 22:24:38 2009] load_sample_ogg: Couldn't open sound/nfz.warning.enter.ogg (nfz.warning.enter)
[Mon Oct 19 22:24:38 2009] load_sample: Couldn't open sound/nfz.warning.enter.ogg (nfz.warning.enter)
[Mon Oct 19 22:24:38 2009] load_sample_ogg: Couldn't open sound/nfz.warning.leave.ogg (nfz.warning.leave)
[Mon Oct 19 22:24:38 2009] load_sample: Couldn't open sound/nfz.warning.leave.ogg (nfz.warning.leave)
/dev/js0: No such file or directory
Found joystick 'Mega World USB Game Controllers (/dev/input/js0)'
numaxes = 6
numbuttons = 8
/dev/js1: No such file or directory
/dev/input/js1: No such file or directory
/dev/js2: No such file or directory
/dev/input/js2: No such file or directory
/dev/js3: No such file or directory
/dev/input/js3: No such file or directory
Found 1 joystick(s)
allocated pipes: 15->14, 17->16
[Mon Oct 19 22:24:40 2009] Flight-Assist mode disabled.
[Mon Oct 19 22:24:40 2009] Auto-Aim disabled.
[/quote]
(there is only one joystick and I'm able to use/calibrate it ingame, so no problem there)

and some informations about my soundchip that is beeing used
[quote]
/proc/asound$ cat cards
0 [SB ]: HDA-Intel - HDA ATI SB
HDA ATI SB at 0xfe9f4000 irq 16
1 [HDMI ]: HDA-Intel - HDA ATI HDMI
HDA ATI HDMI at 0xfeaec000 irq 19
[/quote]

[quote]
lspci | grep Audio
00:14.2 Audio device: ATI Technologies Inc SBx00 Azalia (Intel HDA)
01:00.1 Audio device: ATI Technologies Inc HD48x0 audio
[/quote]

PulseAudio version: pulseaudio 0.9.19
Alsa version: 1.0.20
Oct 19, 2009 raybondo link
Can you try to not use pulseaudio? Try switching VO to OSSSound instead? I'm not familiar with all the different linux sound drivers.
Oct 20, 2009 Detructor link
I'll try that today...but it would be nice if the game works with PulseAudio, too.

For me, it seems that the sound buffer (from the game) is not big enough, I had the same problem with mumble, can I adjust that somewhere?!
Oct 20, 2009 PaKettle link
Usb can produce this type of problem as well. The direct output of the sound card may not have the problem.
Oct 20, 2009 Detructor link
> Usb can produce this type of problem as well. The direct output of the sound card may not have the problem.

? erhm. I don't know if I understood you right, but my soundcard has no USB connector.

It's a soundchip with simple lineout 3.5mm/3.5mm linein/3.5mm mic and some other 3.5mm connectors (IIRC for dolby sorround, which I don't use)

*edit
oh and can please somebody tell me how to quote in this forum?!
Oct 20, 2009 raybondo link
There is a way to set the buffer size for alsa in VO.

You'll have to edit your config.ini file and find the [alsa] section. If there is none, you can add it to the end of the file.
Set or change the periodsize value. It defaults to 256 if not present. Here's an example:

[alsa]
periodsize=512

Try 512 or 1024. If you know how alsa works, there's also nperiods which defaults to 16, but I don't know that changing that would help any. Making it bigger may make the sound more laggy.

There's no way to quote with this forum.
Oct 20, 2009 Detructor link
> There's no way to quote with this forum.

oh, okay.

There was no alsa section in the config file, I created one and added the periodsize, will try it now.

padsp helped, but doesn't make it go away. I'll try with the periodsize in a few moments.
Oct 20, 2009 Detructor link
nope, doesn't work...strange
Oct 20, 2009 raybondo link
Hmm. There should be a line like this:
"ALSA initialized: 44100Hz, 16bit stereo, 92ms latency (16 periods x 256 samples)"

in your errors.log file.

After looking further, you'll need to pair the periodsize with nperiods. periodsize should be 4096/nperiods.

For example, if you set periodsize to 512, you'll have to set nperiods to 8.
Oct 20, 2009 raybondo link
Edit: DUH, I forgot you posted your ALSA version already.
Oct 21, 2009 PaKettle link
No theres no dierct usb connection. If you use a usb headset there is a bandwidth issue which causes the crackling.
Oct 21, 2009 raybondo link
I finally managed to get my sound working in Ubuntu 9.04 with ALSA 1.0.20 and didn't hear any crackling noises. While reading about how to upgrade ALSA, I found some blurbs about being able to increase the internal ALSA sound buffers. I didn't see the exact details though.
Oct 21, 2009 Detructor link
okay, I've tried now with nperiods set to 8 and periodsize set to 512 and WITH PulseAudio, so far only 2 times crackling noises, and for a short periode (about 10 secs).

Both times I was in a fight...I think when I make the periodsize/nperiods higher, I won't get any crackling noises.

but now, my test time has expired...*need paypal*
Oct 21, 2009 mr_spuck link
Running the game through pasuspender might be worth a try.
Oct 22, 2009 Detructor link
> Running the game through pasuspender might be worth a try.

I tried, but it I got much more crackling noises. strange...I'll go for periodsize 1024 and nperiods to 4.
Oct 23, 2009 Detructor link
> I'll go for periodsize 1024 and nperiods to 4.
okay, bad idea. It was like I changed it back to the very first time I started the game.

I guess "nperiods" is the amount of buffers and periodsize is the size?

However: I've noticed that when I'm flying in or around asteroid fields, I get much more crackling noises then elsewhere...strange...
Nov 02, 2009 dannyowelch link
I was having the same issue in Ubuntu 9.10 using one of the Plantronics Gamecom USB headsets. Periodsize 1024 and nperiods 4 cleared up the audio problems for me. Thanks!
Nov 04, 2009 mr_spuck link
It also does the cracking thing with 9.10 under VirtualBox. 9.04 works fine.
Dec 21, 2009 Captain86 link
Hi all

Ubuntu 9.10 64bit amd 64 x2 3800

I'm having the crackling noise as well.
It did not have any problems for the entire training sessions, only when I completed those training session did it start doing that.

It finally fizzled out and eventually locked up the machine.
After many time trying and many crackling out
I'm now in space and controls frozen, but sounds great LOL
I login it takes me to the ship view screen and I can't control the ship I see people chatting but no controls and can't change screens.

I just add the following line to the config.ini ?

[alsa]
periodsize=1024

And that seems to work good.

Thanks
Jan 31, 2010 Captain86 link
I've since noticed after the latest vendetta update that the video became a little jittery and mouse and joystick movement was also jittery.

I since increased the periods to 2048 in the config.ini of ./vendetta

And the jitters went away and mouse and joystick movement is perfect again.

the pulse audio and alsa is likely the problem but adjusting the periods seems to always fix any crackling,video,mouse,or joystick movement topics I've had thus far.

FYI on my latest experience with Ubuntu 9.10 64

Happy shooting