FBSD7.1 KDE4.2 sound ?

Hi,
Since upgrading from KDE3.5 to KDE4.x I've not been able to hear sound through mplayer.

I'm running FBSD 7.1-p3
KDE4.2.0

Code:
more /boot/loader.conf
geom_mirror_load=YES
snd_cmi_load="YES"
accf_http_load="YES"
atapicam_load="YES"

Code:
kldstat
Id Refs Address    Size     Name
 1   16 0xc0400000 95a508   kernel
 2    1 0xc0d5b000 16268    geom_mirror.ko
 3    1 0xc0d72000 5878     snd_cmi.ko
 4    3 0xc0d78000 4a3c8    sound.ko
 5    1 0xc0dc3000 2404     accf_http.ko
 6    1 0xc0dc6000 4d60     atapicam.ko
 7    1 0xc0dcb000 6a2c4    acpi.ko
 8    1 0xc57b2000 4000     ipdivert.ko
 9    1 0xc583d000 23000    linux.ko

Code:
cat /dev/sndstat
FreeBSD Audio Driver (newpcm: 32bit 2007061600/i386)
Installed devices:
pcm0: <CMedia CMI8738> at io 0xa400 irq 16 kld snd_cmi [MPSAFE] (1p:1v/1r:1v channels duplex default)

Code:
more /var/log/messages
kernel: pcm0: <CMedia CMI8738> port 0xa400-0xa4ff irq 16 at device 4.0 on pci3                                                                                     
kernel: pcm0: [ITHREAD]

Code:
ls /dev/dsp*
/dev/dsp0.0

Code:
sysctl -aeh | more
hw.snd.latency_profile=1
hw.snd.latency=5
hw.snd.report_soft_formats=1
hw.snd.compat_linux_mmap=0
hw.snd.feeder_buffersize=16384
hw.snd.feeder_rate_round=25
hw.snd.feeder_rate_max=2016000
hw.snd.feeder_rate_min=1
hw.snd.verbose=1
hw.snd.maxautovchans=16
hw.snd.default_unit=0
hw.snd.version=2007061600/i386
hw.snd.default_auto=0
dev.pcm.0.%desc=CMedia CMI8738
dev.pcm.0.%driver=pcm
dev.pcm.0.%location=slot=4 function=0
dev.pcm.0.%pnpinfo=vendor=0x13f6 device=0x0111 subvendor=0x13f6 subdevice=0x0111 class=0x040100
dev.pcm.0.%parent=pci3
dev.pcm.0.play.vchans=1
dev.pcm.0.play.vchanrate=48000
dev.pcm.0.play.vchanformat=s16le
dev.pcm.0.rec.vchans=1
dev.pcm.0.rec.vchanrate=48000
dev.pcm.0.rec.vchanformat=s16le
dev.pcm.0.buffersize=16384
dev.pcm.0.spdif_enabled=0

Code:
mixer
Mixer vol      is currently set to  75:75
Mixer bass     is currently set to  50:50
Mixer treble   is currently set to  50:50
Mixer synth    is currently set to  75:75
Mixer pcm      is currently set to  75:75
Mixer speaker  is currently set to  75:75
Mixer line     is currently set to  75:75
Mixer mic      is currently set to   0:0
Mixer cd       is currently set to  75:75
Mixer igain    is currently set to  75:75
Mixer ogain    is currently set to  50:50
Mixer monitor  is currently set to  75:75
Recording source: mic, cd

Code:
ps -ax | more
 1422  ??  Is     0:00.20 /usr/local/bin/dbus-daemon --system
  1662  ??  I      0:00.02 hald-runner
 1669  ??  I      0:00.06 hald-addon-mouse-sysmouse: /dev/psm0 (hald-addon-mouse-sy)
 1673  ??  S      0:00.65 hald-addon-storage: /dev/cd0 (hald-addon-storage)

Have I built KDE4.2 correctly? What sound system does it use, arts? Have I built required ports correctly, phonon, libxine?

any advice much appreciated.
 
I found that building phonon with pulseaudio made my system very unstable and unable to hear sound. After I rebuilt phonon and switched to OSS as backend, no more problems.
 
no sound

I took a look at phonon to see if there is a knob to configure at build.

Code:
 9# cd ../../multimedia/phonon
[/usr/ports/multimedia/phonon]
 10# make config
===> No options to configure
Leaves me unsure if phonon was built with or without pulseaudio.

Anyway, I installed oss. During the installation it correctly detected the CMI8738 audio. I edited /etc/rc.conf to enable. And I started the daemon.

Couldn't quite tell if it is really running. There's no pid file i could easily see in /var/run.

Code:
 13# /usr/local/etc/rc.d/oss status
/usr/local/etc/rc.d/oss: unknown directive 'status'.
Usage: /usr/local/etc/rc.d/oss [fast|force|one](start|stop|restart|rcvar)

 14# ossinfo
Version info: OSS 4.1 (b 1051/200903170547) (0x00040100) BSD
Platform: FreeBSD/i386 7.1-RELEASE-p3 FreeBSD 7.1-RELEASE-p3 #0: Thu Feb 19 21:11:34 PST 2009     marc@motive.marcandkayoko.net:/usr/obj/usr/src/sys/MOTIVE (motive.marcandkayoko.net)

Number of audio devices:        0
Number of audio engines:        0
Number of mixer devices:        0


Device objects


Mixer devices

Audio devices
I opened the KDE4 control center and manually assigned audio to Open Sound System, and checked the duplex option. Only thing that makes me think oss might be running is:

Code:
17807  ??  S      0:00.69 /usr/local/bin/artsd -F 10 -S 4096 -a oss -d -s 60 -m artsmessage
But even that's not so convincing..

using mplayer with option -ao oss fails to produce sound. Using cat {filename} > /dev/dsp, or dsp0.0 gives nothing either. Searching on the net I found a site that suggested CMI8378 was supported by oss. So maybe theres some setting I missed ..

Also, I wonder why artsd is running on my box. Is it the sound server by default? should I focus my time on getting arts working?

I read on some site to build libxine with xcb supprt, but again there was not knob for it..

Code:
OPTIONS=        ARTS "Enable aRts support" off \
                CACA "Enable libcaca support" off \
                ESOUND "Enable EsounD support" off \
                JACK "Enable JACK support" off \
                GNOMEVFS2 "Enable GnomeVFS2 support" off \
                PULSEAUDIO "Enable PulseAudio support" off \
                XVMC "Enable XvMC support" off \
                SMB "Enable SMB protocol support" off \
                AALIB "Enable aalib support" off \
                IMAGEMAGICK "Enable ImageMagick support" off \
                GTK2 "Enable gdkpixbuf support" off \
                WAVPACK "Enable WavPack support" on \
                FAAD "Enable external faad support" off
I didnt change the default options above when last building ports after upgrading to 7.1. There must be something I've not built correctly..
 
My bad, it's x11/kdebase4-runtime that has the pulseaudio option. With OSS I meant the plain OSS that is in the base system. Though installing the port doesn't hurt, the drivers work better for most people.

Duplex option is actually a bad idea. It will claim device exclusively, so no other sound daemon or program wanting to use /dev/dsp can touch it. Your problem is likely the running arts daemon. Arts has been killed in KDE-4, though it's still running for me as well, for KDE 3 applications.

If you have arts with duplex configured, that is likely your problem. Since there's no more control module for it, you may have to dig into ~/.kde and find where it's configured.
 
Sound, period?

I think this has less to do with KDE and more to do with hardware. I'm just not getting any sound at all, period. I sign on to a shell, no KDM.

Code:
 5# mixer
Mixer vol      is currently set to  75:75
Mixer bass     is currently set to  50:50
Mixer treble   is currently set to  50:50
Mixer synth    is currently set to  75:75
Mixer pcm      is currently set to  75:75
Mixer speaker  is currently set to  75:75
Mixer line     is currently set to  75:75
Mixer mic      is currently set to   0:0
Mixer cd       is currently set to  75:75
Mixer igain    is currently set to  75:75
Mixer ogain    is currently set to  50:50
Mixer monitor  is currently set to  75:75
Recording source: mic, cd

 7# cat KonquerorBookmarks.html > /dev/dsp

nothing.
Code:
 8# ls -la /dev/dsp*
crw-rw-rw-  1 root  wheel    0, 118 Mar 18 20:06 /dev/dsp0.0
FWIW the oss port didnt seem to recognize my card. Or rather it did, but couldnt find a mixer..
Code:
 9# more /var/log/soundon.log
Open Sound System starting Tue Mar 17 15:17:11 PDT 2009
OSS version:  4.1 (b 1051/200903170547)
Kernel version:  FreeBSD motive.marcandkayoko.net 7.1-RELEASE-p3 FreeBSD 7.1-RELEASE-p3 #0: Thu Feb 19 21:11:34 PST 2009 :/usr/obj/usr/src/sys/MOTIVE i386
+++ ossinfo -v3 +++
Version info: OSS 4.1 (b 1051/200903170547) (0x00040100) BSD
Platform: FreeBSD/i386 7.1-RELEASE-p3 FreeBSD 7.1-RELEASE-p3 #0: Thu Feb 19 21:11:34 PST 2009     :/usr/obj/usr/src/sys/MOTIVE (motive.marcandkayoko.net)

Number of audio devices:        0
Number of audio engines:        0
Number of mixer devices:        0


Device objects
 0: oss_imux0 OSS IMUX driver


Mixer devices

Audio devices
+++ /dev/sndstat +++
FreeBSD Audio Driver (newpcm: 32bit 2007061600/i386)
Installed devices:
pcm0: <CMedia CMI8738> at io 0xa400 irq 16 kld snd_cmi [MPSAFE] (1p:1v/1r:1v channels duplexdefault)

++ dmesg ++

+++ OSS devices +++
0 audio devices
0 mixer devices
ls: /dev/oss/*/*: No such file or directory
crw-rw-rw-  1 root  wheel    0, 119 Mar 17 14:52 /dev/dsp0.0
crw-rw-rw-  1 root  wheel    0, 121 Mar 17 14:52 /dev/dsp0.1
crw-rw-rw-  1 root  wheel    0, 122 Mar 17 14:52 /dev/dsp0.2
crw-rw-rw-  1 root  wheel    0, 124 Mar 17 14:52 /dev/dsp0.3
crw-rw-rw-  1 root  wheel    0, 120 Mar 17 14:52 /dev/dsp_mmap0.0
crw-rw-rw-  1 root  wheel    0, 123 Mar 17 14:52 /dev/dsp_mmap0.1
crw-rw-rw-  1 root  wheel    0, 125 Mar 17 14:52 /dev/dsp_mmap0.2
crw-rw-rw-  1 root  wheel    0, 118 Mar 17 14:52 /dev/mixer
crw-rw-rw-  1 root  wheel    0,  38 Mar 17 14:52 /dev/mixer0
cr--r--r--  1 root  wheel    0,   5 Mar 17 14:52 /dev/sndstat
No mixers in the system

 10# ossmix
Mixer device 0 doesn't exist.
So I'm not sure artsd is the problem since it isn't running just after I sign on to shell. Any advice on checking if the hardware really is working much appreciated. Handbook only goes into so much detail.
 
[SOLVED] KDE 4.2 sound

the combination of:
* compiling sound & snd_cmi devices into kernel
* upgrading latest phonon with xine backend

have now produced sound - both in KDE and from the terminal. I removed directives from /boot/loader.conf.

However volume is very weak even with every mixer setting pegged to 100. Seriously low levels.
 
Back
Top