Reply
 
Thread Tools Display Modes
  #1  
Old 07-19-2012, 09:17 PM
David30 David30 is offline
Senior Member
 
Join Date: Jun 2012
Posts: 325
Thanks: 20
Thanked 28 Times in 27 Posts
Default Sound settings: should change "on the fly"?
I'm still a newbie to PC-BSD, but having followed the instructions for installing the beta updates, I have PC-BSD 9.1-BETA1 (amd64) installed.

The sound needs to be manually changed every time I switch between my speakers and headphones. I can do this with the "Sound Configuration" in the Control Panel. My USB microphone is recognised but does not work.

I wonder if the sound devices could be changed on the fly? In other words, if I connect my headphones to the front panel of the PC, they should work instead of the speakers - and if I disconnect my headphones, the sound should then go through the speakers.

Why does my USB microphone not work? It works in Ubuntu on the same computer.

Any ideas on what I can do to help fix this problem? I would be happy to help, if I can help without performing any complicated technical steps.

Cheers.
Reply With Quote
  #2  
Old 07-20-2012, 10:41 AM
fluca1978 fluca1978 is offline
Senior Member
 
Join Date: Mar 2011
Posts: 353
Thanks: 2
Thanked 18 Times in 14 Posts
Default
I suspect your hardware is not well supported by FreeBSD (and therefore by PCBSD). Can you provide more info about the hardware? Have you checked the laptop compatibility list? Have also a look at the man page of snd to see if your hardware is supported.
Reply With Quote
  #3  
Old 07-20-2012, 11:46 AM
David30 David30 is offline
Senior Member
 
Join Date: Jun 2012
Posts: 325
Thanks: 20
Thanked 28 Times in 27 Posts
Default
I have a desktop PC, I can try to provide you with the info you need. The sound is built into the motherboard, Asus P67 Sabertooth revision 3.0

How do I go about finding the right info you need? I will have a look at the man page of snd, but I want to post the right info on here.
Reply With Quote
  #4  
Old 07-20-2012, 01:05 PM
kmoore134's Avatar
kmoore134 kmoore134 is offline
Administrator
 
Join Date: May 2005
Location: Knoxville, TN
Posts: 2,428
Thanks: 0
Thanked 103 Times in 85 Posts
Default Sound settings: should change "on the fly"?
You can paste the output of "dmesg | grep hda" and "cat /dev/sndstat"

FWIW, some devices do the headphone switching automatically, it depends
upon the driver.
__________________
----
Kris Moore
PC-BSD Founder
Reply With Quote
  #5  
Old 07-20-2012, 06:02 PM
David30 David30 is offline
Senior Member
 
Join Date: Jun 2012
Posts: 325
Thanks: 20
Thanked 28 Times in 27 Posts
Default
Below are the outputs pasted from both, with the USB microphone connected and no headphones - just the speakers on.

Here's the output after doing "dmesg | grep hda":

hdac0: <NVIDIA GF110 HDA Controller> mem 0xf6080000-0xf6083fff irq 17 at device 0.1 on pci1
hdac1: <Intel Cougar Point HDA Controller> mem 0xf6620000-0xf6623fff irq 22 at device 27.0 on pci0
hdacc0: <NVIDIA (0x0016) HDA CODEC> at cad 0 on hdac0
hdaa0: <NVIDIA (0x0016) Audio Function Group> at nid 1 on hdacc0
pcm0: <NVIDIA (0x0016) (HDMI/DP 8ch)> at nid 5 on hdaa0
hdacc1: <NVIDIA (0x0016) HDA CODEC> at cad 1 on hdac0
hdaa1: <NVIDIA (0x0016) Audio Function Group> at nid 1 on hdacc1
pcm1: <NVIDIA (0x0016) (HDMI/DP 8ch)> at nid 5 on hdaa1
hdacc2: <NVIDIA (0x0016) HDA CODEC> at cad 2 on hdac0
hdaa2: <NVIDIA (0x0016) Audio Function Group> at nid 1 on hdacc2
pcm2: <NVIDIA (0x0016) (HDMI/DP 8ch)> at nid 5 on hdaa2
hdacc3: <NVIDIA (0x0016) HDA CODEC> at cad 3 on hdac0
hdaa3: <NVIDIA (0x0016) Audio Function Group> at nid 1 on hdacc3
pcm3: <NVIDIA (0x0016) (HDMI/DP 8ch)> at nid 5 on hdaa3
hdac1: Command timeout on address 3
hdac1: Command timeout on address 3
hdac1: CODEC is not responding!
hdacc4: <Realtek ALC892 HDA CODEC> at cad 0 on hdac1
hdaa4: <Realtek ALC892 Audio Function Group> at nid 1 on hdacc4
pcm4: <Realtek ALC892 (Rear Analog 7.1/2.0)> at nid 20,22,21,23 and 24,26 on hdaa4
pcm5: <Realtek ALC892 (Front Analog)> at nid 27 and 25 on hdaa4
pcm6: <Realtek ALC892 (Rear Digital)> at nid 30 on hdaa4
pcm7: <Realtek ALC892 (Onboard Digital)> at nid 17 on hdaa4
__________

Here's the output from cat /dev/sndstat:

FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
Installed devices:
pcm0: <NVIDIA (0x0016) (HDMI/DP 8ch)> (play)
pcm1: <NVIDIA (0x0016) (HDMI/DP 8ch)> (play)
pcm2: <NVIDIA (0x0016) (HDMI/DP 8ch)> (play)
pcm3: <NVIDIA (0x0016) (HDMI/DP 8ch)> (play)
pcm4: <Realtek ALC892 (Rear Analog 7.1/2.0)> (play/rec) default
pcm5: <Realtek ALC892 (Front Analog)> (play/rec)
pcm6: <Realtek ALC892 (Rear Digital)> (play)
pcm7: <Realtek ALC892 (Onboard Digital)> (play)
pcm8: <USB audio> (rec)
____________

When selecting the sound device from the Sound Configuration for playback, the "Realtek" entries work for playback; pcm4 for speakers and pcm5 for headphones. USB microphone not working in any program, even when its selected.

I appreciate the help. So I don't forget to say this, the computer is stable and never crashes/freezes, it has the latest BIOS etc - no hardware problems at all.
Reply With Quote
  #6  
Old 07-22-2012, 08:43 PM
David30 David30 is offline
Senior Member
 
Join Date: Jun 2012
Posts: 325
Thanks: 20
Thanked 28 Times in 27 Posts
Default
Has my previous post about the sound revealed any useful information?
Reply With Quote
  #7  
Old 07-23-2012, 02:52 PM
mav@ mav@ is offline
Junior Member
 
Join Date: May 2010
Posts: 15
Thanks: 0
Thanked 1 Time in 1 Post
Default
As I see, your front panel headphones connectors configured as separate audio device. FreeBSD sound subsystem does not support auto switching in such case at this moment. What you can do now is reconfigure them to become part of the same device as rear connectors. In that case snd_hda(4) driver will handle switching by itself. It could be done by adding few line to /boot/loader.conf file. Unluckily there is not enough info provided to give you specific line. Please show
Code:
sysctl dev.hdaa.4
output from your system.
Reply With Quote
  #8  
Old 07-23-2012, 04:22 PM
David30 David30 is offline
Senior Member
 
Join Date: Jun 2012
Posts: 325
Thanks: 20
Thanked 28 Times in 27 Posts
Default
Here's the output from running sysctl dev.hdaa.4

dev.hdaa.4.%desc: Realtek ALC892 Audio Function Group
dev.hdaa.4.%driver: hdaa
dev.hdaa.4.%location: nid=1
dev.hdaa.4.%pnpinfo: type=0x01 subsystem=0x10438436
dev.hdaa.4.%parent: hdacc4
dev.hdaa.4.nid17_config: 0x99430140 as=4 seq=0 device=SPDIF-out conn=Fixed ctype=ATAPI loc=Onboard color=Unknown misc=1
dev.hdaa.4.nid17_original: 0x99430140 as=4 seq=0 device=SPDIF-out conn=Fixed ctype=ATAPI loc=Onboard color=Unknown misc=1
dev.hdaa.4.nid18_config: 0x411111f0 as=15 seq=0 device=Speaker conn=None ctype=1/8 loc=Rear color=Black misc=1
dev.hdaa.4.nid18_original: 0x411111f0 as=15 seq=0 device=Speaker conn=None ctype=1/8 loc=Rear color=Black misc=1
dev.hdaa.4.nid20_config: 0x01014010 as=1 seq=0 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Green misc=0
dev.hdaa.4.nid20_original: 0x01014010 as=1 seq=0 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Green misc=0
dev.hdaa.4.nid21_config: 0x01011012 as=1 seq=2 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Black misc=0
dev.hdaa.4.nid21_original: 0x01011012 as=1 seq=2 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Black misc=0
dev.hdaa.4.nid22_config: 0x01016011 as=1 seq=1 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Orange misc=0
dev.hdaa.4.nid22_original: 0x01016011 as=1 seq=1 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Orange misc=0
dev.hdaa.4.nid23_config: 0x01012014 as=1 seq=4 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Grey misc=0
dev.hdaa.4.nid23_original: 0x01012014 as=1 seq=4 device=Line-out conn=Jack ctype=1/8 loc=Rear color=Grey misc=0
dev.hdaa.4.nid24_config: 0x01a19850 as=5 seq=0 device=Mic conn=Jack ctype=1/8 loc=Rear color=Pink misc=8
dev.hdaa.4.nid24_original: 0x01a19850 as=5 seq=0 device=Mic conn=Jack ctype=1/8 loc=Rear color=Pink misc=8
dev.hdaa.4.nid25_config: 0x02a19c60 as=6 seq=0 device=Mic conn=Jack ctype=1/8 loc=Front color=Pink misc=12
dev.hdaa.4.nid25_original: 0x02a19c60 as=6 seq=0 device=Mic conn=Jack ctype=1/8 loc=Front color=Pink misc=12
dev.hdaa.4.nid26_config: 0x0181305f as=5 seq=15 device=Line-in conn=Jack ctype=1/8 loc=Rear color=Blue misc=0
dev.hdaa.4.nid26_original: 0x0181305f as=5 seq=15 device=Line-in conn=Jack ctype=1/8 loc=Rear color=Blue misc=0
dev.hdaa.4.nid27_config: 0x02214c20 as=2 seq=0 device=Headphones conn=Jack ctype=1/8 loc=Front color=Green misc=12
dev.hdaa.4.nid27_original: 0x02214c20 as=2 seq=0 device=Headphones conn=Jack ctype=1/8 loc=Front color=Green misc=12
dev.hdaa.4.nid28_config: 0x411111f0 as=15 seq=0 device=Speaker conn=None ctype=1/8 loc=Rear color=Black misc=1
dev.hdaa.4.nid28_original: 0x411111f0 as=15 seq=0 device=Speaker conn=None ctype=1/8 loc=Rear color=Black misc=1
dev.hdaa.4.nid29_config: 0x4005e601 as=0 seq=1 device=Line-out conn=None ctype=Optical loc=0x00 color=White misc=6
dev.hdaa.4.nid29_original: 0x4005e601 as=0 seq=1 device=Line-out conn=None ctype=Optical loc=0x00 color=White misc=6
dev.hdaa.4.nid30_config: 0x01456130 as=3 seq=0 device=SPDIF-out conn=Jack ctype=Optical loc=Rear color=Orange misc=1
dev.hdaa.4.nid30_original: 0x01456130 as=3 seq=0 device=SPDIF-out conn=Jack ctype=Optical loc=Rear color=Orange misc=1
dev.hdaa.4.nid31_config: 0x411111f0 as=15 seq=0 device=Speaker conn=None ctype=1/8 loc=Rear color=Black misc=1
dev.hdaa.4.nid31_original: 0x411111f0 as=15 seq=0 device=Speaker conn=None ctype=1/8 loc=Rear color=Black misc=1
dev.hdaa.4.config: forcestereo,ivref50,ivref80,ivref100,ivref,vref
dev.hdaa.4.gpi_state:
dev.hdaa.4.gpio_state: 0=disabled 1=disabled
dev.hdaa.4.gpio_config: 0=keep 1=keep
dev.hdaa.4.gpo_state:
dev.hdaa.4.gpo_config:
dev.hdaa.4.reconfig: 0
Reply With Quote
  #9  
Old 07-23-2012, 04:42 PM
mav@ mav@ is offline
Junior Member
 
Join Date: May 2010
Posts: 15
Thanks: 0
Thanked 1 Time in 1 Post
Default
Add to your /boot/loader.conf lines:
Code:
hint.hdac.1.cad0.nid27.config="as=1 seq=15"
hint.hdac.1.cad0.nid25.config="as=5 seq=1"
, and reboot. After that pcm4 device will represent all analog connectors and auto redirection should work.
Reply With Quote
  #10  
Old 07-23-2012, 10:54 PM
David30 David30 is offline
Senior Member
 
Join Date: Jun 2012
Posts: 325
Thanks: 20
Thanked 28 Times in 27 Posts
Default
Thank you so much mav@ - it works!

With pcm4 selected in the Sound Configuration, I can now switch between the speakers and headphones, without having to manually change settings every time. Now when I unplug the headphones, the sound then goes through the speakers, as intended. When I plug the headphones in (the front of the PC) the sound goes straight to the headphones. BRILLIANT.

Could this behaviour of changing the sound "on the fly" be the default in PC-BSD 9.1 and later?
Reply With Quote
Reply

Tags
sound microphone

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


All times are GMT. The time now is 01:23 PM.


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

Copyright 2005-2010, The PC-BSD Project. PC-BSD and the PC-BSD logo are registered trademarks of iXsystems.
All other content is freely available for sharing under the terms of the Creative Commons Attribution License.