DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 20th July 2008
troberts troberts is offline
Port Guard
 
Join Date: May 2008
Posts: 27
Default Problem with no sound in games

I am not able to hear sound while playing games and I am not sure how to track down the problem. I am using the SoundBlaster Live! 24-bit sound card which, from what I have gathered, is not FreeBSD "friendly". Since I cannot use one of the sound drivers that come with FreeBSD I am using the OSS driver, the one in ports, not from 4front Technologies. To get the sound working with XMMS, Sonata (i.e. MPD), MPlayer I added the line ln -sf /dev/oss/audigyls0/pcm1 /dev/dsp in my /usr/local/etc/rc.d/oss file. The entire file is:
Code:
#!/bin/sh

# PROVIDE: oss
# REQUIRE: DAEMON
# KEYWORD: nojail shutdown

. /etc/rc.subr

name="oss"
rcvar=`set_rcvar`

stop_cmd="oss_stop"
start_cmd="oss_start"

load_rc_config $name

: ${oss_enable=NO}

oss_start()
{
	echo "Starting Open Sound System"
	/usr/local/sbin/soundon
	ln -sf /dev/oss/audigyls0/pcm1 /dev/dsp
}

oss_stop()
{
	echo "Stopping Open Sound System"
	/usr/local/sbin/soundoff
}

run_rc_command "$1"
The output of osstest is:
Code:
Sound subsystem and version: OSS 4.0 (b1016/200807160409) (0x00040003)
Platform: FreeBSD/i386 7.0-STABLE FreeBSD 7.0-STABLE #1: Wed Jul 16 14:44:12 EDT 2008     root@:/usr/obj/usr/src/sys/GENERIC

*** Scanning sound adapter #-1 ***
/dev/oss/audigyls0/pcm0 (audio engine 0): AudigyLS front
- Performing audio playback test... 
  <left> Device returned error: Input/output error
/dev/oss/audigyls0/pcm1 (audio engine 1): AudigyLS front (VMIX0)
- Performing audio playback test... 
  <left> OK <right> OK <stereo> OK <measured srate 47946.00 Hz (-0.11%)> 
/dev/oss/audigyls0/pcm2 (audio engine 2): AudigyLS front (VMIX0)
- Skipping virtual device (use -V to force test)
/dev/oss/audigyls0/pcm3 (audio engine 3): AudigyLS front (VMIX0)
- Skipping virtual device (use -V to force test)
/dev/oss/audigyls0/pcm4 (audio engine 4): AudigyLS front (VMIX0)
- Skipping virtual device (use -V to force test)
/dev/oss/audigyls0/pcm5 (audio engine 5): AudigyLS (shadow)
- Skipping device (card already tested)
/dev/oss/audigyls0/pcm6 (audio engine 6): AudigyLS center/lfe
- Performing audio playback test... 
  <left> Device returned error: Input/output error
/dev/oss/audigyls0/pcm7 (audio engine 7): AudigyLS surround
- Performing audio playback test... 
  <left> Device returned error: Input/output error
/dev/oss/audigyls0/pcm8 (audio engine 8): AudigyLS 5.1 output
- Skipping multi channel device

*** Some errors were detected during the tests ***
The output of ls -l /dev/dsp* is:
Code:
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp -> /dev/oss/audigyls0/pcm1
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp0 -> /dev/oss/audigyls0/pcm0
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp1 -> /dev/oss/audigyls0/pcm1
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp10 -> /dev/oss/vmix0/pcm5
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp11 -> /dev/oss/vmix0/pcm6
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp12 -> /dev/oss/vmix0/pcm7
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp13 -> /dev/oss/audigyls0/pcm5
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp14 -> /dev/oss/audigyls0/pcm6
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp15 -> /dev/oss/audigyls0/pcm7
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp16 -> /dev/oss/audigyls0/pcm8
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp2 -> /dev/oss/audigyls0/pcm2
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp3 -> /dev/oss/audigyls0/pcm3
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp4 -> /dev/oss/audigyls0/pcm4
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp5 -> /dev/oss/vmix0/pcm0
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp6 -> /dev/oss/vmix0/pcm1
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp7 -> /dev/oss/vmix0/pcm2
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp8 -> /dev/oss/vmix0/pcm3
lrwxr-xr-x  1 root  wheel  19 Jul 18 14:29 dsp9 -> /dev/oss/vmix0/pcm4
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp_ac3 -> /dev/oss/audigyls0/pcm0
lrwxr-xr-x  1 root  wheel   8 Jul 18 14:29 dsp_in -> /dev/dsp
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp_mmap -> /dev/oss/audigyls0/pcm0
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp_multich -> /dev/oss/audigyls0/pcm4
lrwxr-xr-x  1 root  wheel  23 Jul 18 14:29 dsp_out -> /dev/oss/audigyls0/pcm0
When I use xterm to start lbreakout2 it displays a list of the sound files it tried to open and at the end, in parenthesis, is says (Audio device hasn't been opened).
Reply With Quote
  #2   (View Single Post)  
Old 20th July 2008
graudeejs's Avatar
graudeejs graudeejs is offline
Real Name: Aldis Berjoza
ISO Quartermaster
 
Join Date: Jul 2008
Location: Riga, Latvia
Posts: 589
Default

I have same sound card...... for some reason (i don't remember what it was) i don't use it....
I use my integrated ICH sound card

It'll try to find out, why i gave up on SB
Reply With Quote
  #3   (View Single Post)  
Old 20th July 2008
Carpetsmoker's Avatar
Carpetsmoker Carpetsmoker is offline
Real Name: Martin Tournoij
Tcpdump Spy
 
Join Date: Apr 2008
Location: Ireland
Posts: 2,245
Default

What games don't have sound?

For some linux games (i.e. Q3, ET) you need to set:
# sysctl hw.snd.compat_linux_mmap=1
Reply With Quote
  #4   (View Single Post)  
Old 20th July 2008
troberts troberts is offline
Port Guard
 
Join Date: May 2008
Posts: 27
Default

LBreakout2 - When I start it from a terminal it lists all the sound files it tried to open and at the end of each line it has (Audio device hasn't been opened). After I exit the game it displays the following:

Client finalized
GUI finalized
STK finalized
SDL finalized

BurgerSpace - The message *** Sound device not available *** appears on the game screen.

LTris - This gives the messages:

audio_open: can't open audio device: Couldn't set audio blocking mode
sound_chunk_load: cannot load WAV 'click.wav' as audio device isn't initiated properly

Game - No audio: Couldn't set audio blocking mode

LMarbles - Similar to LTris

sound_chunk_load: cannot load WAV 'teleport.wav' as audio device isn't initiated properly
Reply With Quote
  #5   (View Single Post)  
Old 20th July 2008
TerryP's Avatar
TerryP TerryP is offline
Arp Constable
 
Join Date: May 2008
Location: USofA
Posts: 1,547
Default

Some thing may be blocking it,

for example if you are running aRts (common on KDE) and launch TeamSpeak, aRts will sometimes prevent TS from accessing the sound device.
__________________
My Journal

Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''.
Reply With Quote
  #6   (View Single Post)  
Old 21st July 2008
troberts troberts is offline
Port Guard
 
Join Date: May 2008
Posts: 27
Default

I am using neither GNOME nor KDE. My system is GTK-based. After posting last time I installed Heretic and it has sound. Before I jump out of the frying pan and into the fire how does the AC97 audio codec work in FreeBSD 7.0-STABLE #1?

I forgot to include the /dev/sndstat output so here it is:
Code:
OSS 4.0 (b1016/200807160409) BSD (C) 4Front Technologies 1996-2008
Kernel: FreeBSD 7.0-STABLE #1: Wed Jul 16 14:44:12 EDT 2008
    root@:/usr/obj/usr/src/sys/GENERIC


Audio devices:
0: AudigyLS front (DUPLEX)
   Engine 1 opened INOUT by VMIX/0 @ 48000/48000 Hz Fragment: 2048/192000 (10.6 msec)
   Engine 2 opened OUT by mpd/3421 @ 44100/48000 Hz Fragment: 2048/192000 (10.6 msec)
1: AudigyLS front (VMIX0) (DUPLEX)
   Engine 1 opened OUT by mpd/3421 @ 44100/48000 Hz Fragment: 2048/192000 (10.6 msec)
2: AudigyLS front (VMIX0) (DUPLEX)
3: AudigyLS front (VMIX0) (DUPLEX)
4: AudigyLS front (VMIX0) (DUPLEX)
5: (Undefined or removed device)
6: (Undefined or removed device)
7: (Undefined or removed device)
8: (Undefined or removed device)
9: (Undefined or removed device)
10: (Undefined or removed device)
11: (Undefined or removed device)
12: (Undefined or removed device)
13: AudigyLS (shadow) (DUPLEX)
14: AudigyLS center/lfe (OUTPUT)
15: AudigyLS surround (OUTPUT)
16: AudigyLS 5.1 output (OUTPUT)

Mixers:
0: AudigyLS Mixer

History:
/dev/oss/audigyls0/pcm1.01: pid 3421 cmd 'mpd' OUT 
/dev/oss/audigyls0/pcm1.01: pid 3421 cmd 'mpd' OUT 
/dev/oss/audigyls0/pcm1.01: pid 3421 cmd 'mpd' OUT 
/dev/oss/audigyls0/pcm1.01: pid 3421 cmd 'mpd' OUT 
/dev/oss/audigyls0/pcm1.01: pid 3421 cmd 'mpd' OUT 


WARNING! Legacy device numbering in /dev/sndstat is different from actual device numbering
Reply With Quote
  #7   (View Single Post)  
Old 21st July 2008
graudeejs's Avatar
graudeejs graudeejs is offline
Real Name: Aldis Berjoza
ISO Quartermaster
 
Join Date: Jul 2008
Location: Riga, Latvia
Posts: 589
Default

My AC97 Works fine on 6.1, 6.2, 7.0 release
It SHOULD work fine
Reply With Quote
  #8   (View Single Post)  
Old 21st July 2008
Carpetsmoker's Avatar
Carpetsmoker Carpetsmoker is offline
Real Name: Martin Tournoij
Tcpdump Spy
 
Join Date: Apr 2008
Location: Ireland
Posts: 2,245
Default

Why are you using OSS from ports? Why not just use the OSS that comes with FreeBSD?
In my experience it usually works better and it's a lot easier to set up...
Reply With Quote
  #9   (View Single Post)  
Old 21st July 2008
troberts troberts is offline
Port Guard
 
Join Date: May 2008
Posts: 27
Default

Quote:
Originally Posted by Carpetsmoker View Post
Why are you using OSS from ports? Why not just use the OSS that comes with FreeBSD?
I did not know FreeBSD came with its own OSS. Where is it and where do I find the documentation to get it set up? I tried the man pages (man oss) but nothing was shown.
Reply With Quote
Old 21st July 2008
adamk adamk is offline
Spam Deminer
 
Join Date: May 2008
Posts: 250
Default

Quote:
Originally Posted by Carpetsmoker View Post
Why are you using OSS from ports? Why not just use the OSS that comes with FreeBSD?
In my experience it usually works better and it's a lot easier to set up...
The OSS in ports is the version directly from 4Front. It supports more audio cards, including the AudigyLS & Live! 24-bit, which is what the OP is using. None of the drivers that come with FreeBSD support that chipset.

Adam
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
your 3 favorite games welkin FreeBSD Ports and Packages 17 5th June 2010 08:26 PM
Recording sound with external sound card backrow OpenBSD General 5 21st August 2009 08:17 PM
Sound Problem. MetalHead OpenBSD General 3 16th November 2008 09:27 PM
Sound problem renej FreeBSD General 18 12th September 2008 07:30 PM
problem with Virtual Sound Channels in FreeBSD 7 casper007 FreeBSD Installation and Upgrading 3 16th July 2008 04:22 PM


All times are GMT. The time now is 09:26 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick