Help > Laptop Hardware
switching from laptop display w builtin speakers to HDMI video and audio
AnotherUser:
Hi,
I just installed KDE MiniMe 2012.08 on my new Dell Inspiron I5R laptop. Using Synaptic, I then updated everything and after a few minor tweaks to video settings, everything works fine. If I go to a website like YouTube and play a video, I can see it on my laptop screen and the audio comes out of the built-in speakers.
Since this laptop has an HDMI output, I wanted to occasionally use that port to drive a TV for both video and audio. The video part seems to be easy enough. Using xranr, I can find out which modes are supported on my TV using:
--- Code: ---xrandr
Screen 0: minimum 320 x 200, current 1360 x 765, maximum 8192 x 8192
LVDS1 connected 1360x765+0+0 (normal left inverted right x axis y axis) 344mm x 194mm
1360x765_60 60.0*
1280x720_60 60.0
1024x768 60.0
800x600 60.3 56.2
640x480 59.9
VGA1 disconnected (normal left inverted right x axis y axis)
HDMI1 connected (normal left inverted right x axis y axis)
1920x1080 60.0 +
1600x1200 60.0
1400x1050 60.0
1280x1024 60.0
1360x768 60.0
1024x768 75.1 70.1 60.0
800x600 72.2 75.0 60.3 56.2
640x480 72.8 75.0 60.0
720x400 70.1
DP1 disconnected (normal left inverted right x axis y axis)
--- End code ---
Then, to output to the TV I can do
--- Code: ---xrandr --output HDMI1 --mode 1024x768
--- End code ---
This duplicates my current screen on the TV. Question 1: how do I tell xrandr to only output to the TV and not on the laptop (and vice versa)?
Now for the audio part. I do not have PulseAudio installed, so I'm using ALSA. after turning on the TV output, if I then play something from YouTube, the sound still comes out of the built-in laptop speakers. Question 2: Is there a way to switch the audio output to HDMI (and back to laptop) on the fly? Ideally, I'd like to write a bash script that can then be tied to a shortcut to switch everything from laptop to TV and vice versa.
Any advice is much appreciated!
P.S. Anticipating your next question, here's more info on my sound configuration
--- Code: ---$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: CONEXANT Analog [CONEXANT Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
$ aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
pulse
PulseAudio Sound Server
sysdefault:CARD=PCH
HDA Intel PCH, CONEXANT Analog
Default Audio Device
front:CARD=PCH,DEV=0
HDA Intel PCH, CONEXANT Analog
Front speakers
surround40:CARD=PCH,DEV=0
HDA Intel PCH, CONEXANT Analog
4.0 Surround output to Front and Rear speakers
surround41:CARD=PCH,DEV=0
HDA Intel PCH, CONEXANT Analog
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=PCH,DEV=0
HDA Intel PCH, CONEXANT Analog
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=PCH,DEV=0
HDA Intel PCH, CONEXANT Analog
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=PCH,DEV=0
HDA Intel PCH, CONEXANT Analog
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
hdmi:CARD=PCH,DEV=0
HDA Intel PCH, HDMI 0
HDMI Audio Output
--- End code ---
Just17:
--- Quote ---$ aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
pulse
PulseAudio Sound Server
sysdefault:CARD=PCH
HDA Intel PCH, CONEXANT Analog
Default Audio Device
--- End quote ---
Does that not imply that PulseAudio is enabled and has the Analog sound as the default?
I dunno as I have no recollection of the output of aplay -L without PA installed.
If PulseAudio is installed and enabled then the package pavucontrol gives on the fly switching of the output sink .... and remembers the setting from last use of the application.
AnotherUser:
--- Quote from: Just17 on December 01, 2012, 03:43:28 PM ---Does that not imply that PulseAudio is enabled and has the Analog sound as the default?
--- End quote ---
I don't know. Looking for help in this forum.
--- Quote ---If PulseAudio is installed and enabled then the package pavucontrol gives on the fly switching of the output sink .... and remembers the setting from last use of the application.
--- End quote ---
I do not have pav* anywhere on my system. That is what led me to believe that I do not have PulseAudio installed.
daniel:
Search for task-pulseaudio in our synaptic, and install it.
Then go to 'configure your computer' and enable pulseaudio.
See instruction for it http://www.pclinuxos.com/forum/index.php/topic,83740.0.html too...
bicol_willem:
--- Quote from: AnotherUser on December 01, 2012, 03:53:49 PM ---
--- Quote from: Just17 on December 01, 2012, 03:43:28 PM ---Does that not imply that PulseAudio is enabled and has the Analog sound as the default?
--- End quote ---
I don't know. Looking for help in this forum.
--- Quote ---If PulseAudio is installed and enabled then the package pavucontrol gives on the fly switching of the output sink .... and remembers the setting from last use of the application.
--- End quote ---
I do not have pav* anywhere on my system. That is what led me to believe that I do not have PulseAudio installed.
--- End quote ---
Look in synaptic for task-pulse audio and see if it is installed. pavcontrol is a separated package.
Navigation
[0] Message Index
[#] Next page
Go to full version