https://wiki.archlinux.org/api.php?action=feedcontributions&user=Jeanlandim&feedformat=atomArchWiki - User contributions [en]2024-03-29T09:37:45ZUser contributionsMediaWiki 1.41.0https://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291983ASUS Eee PC 1025c2014-01-08T02:37:10Z<p>Jeanlandim: /* Audio */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==Audio==<br />
===Mono Issues===<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted missed voices or instruments. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart [[Advanced_Linux_Sound_Architecture|Alsa]].<br />
<br />
=====Mono on PulseAudio=====<br />
<br />
To set mono in a [[PulseAudio|PulseAudio]] system. Run on terminal:<br />
<br />
$ pacmd list-sinks | grep name | head -n1 <br />
<br />
To get the master device name. The output of command will look like this:<br />
<br />
name: <alsa_output.pci-0000_00_1b.0.analog-stereo><br />
<br />
Put device name (in my case ''alsa_output.pci-0000_00_1b.0.analog-stereo'') in field 'master' of the command below:<br />
<br />
$ pacmd load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono<br />
<br />
So this command just will work if PulseAudio is already started.<br />
<br />
To make this permanent, (as root) put the argument of pacmd command on last line of file ''/etc/pulse/default.pa'':<br />
<br />
# echo "load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono" >> /etc/pulse/default.pa<br />
<br />
'''Warning''': Be sure, of don't run an audio application with this configuration above (Maybe mpg123 to start a sound theme in a session of [[Xfce|Xfce]]) before PulseAudio starts, in a session. It's probably the PulseAudio will not working.<br />
<br />
And after, reboot your machine and every session startup, this will work.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291982ASUS Eee PC 1025c2014-01-08T02:29:46Z<p>Jeanlandim: /* Audio */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==Audio==<br />
===Mono Issues===<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart [[Advanced_Linux_Sound_Architecture|Alsa]].<br />
<br />
=====Mono on PulseAudio=====<br />
<br />
To set mono in a [[PulseAudio|PulseAudio]] system. Run on terminal:<br />
<br />
$ pacmd list-sinks | grep name | head -n1 <br />
<br />
To get the master device name. The output of command will look like this:<br />
<br />
name: <alsa_output.pci-0000_00_1b.0.analog-stereo><br />
<br />
Put device name (in my case ''alsa_output.pci-0000_00_1b.0.analog-stereo'') in field 'master' of the command below:<br />
<br />
$ pacmd load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono<br />
<br />
So this command just will work if PulseAudio is already started.<br />
<br />
To make this permanent, (as root) put the argument of pacmd command on last line of file ''/etc/pulse/default.pa'':<br />
<br />
# echo "load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono" >> /etc/pulse/default.pa<br />
<br />
'''Warning''': Be sure, of don't run an audio application with this configuration above (Maybe mpg123 to start a sound theme in a session of [[Xfce|Xfce]]) before PulseAudio starts, in a session. It's probably the PulseAudio will not working.<br />
<br />
And after, reboot your machine and every session startup, this will work.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291979ASUS Eee PC 1025c2014-01-08T02:24:38Z<p>Jeanlandim: /* Mono on PulseAudio */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==Audio==<br />
===Mono Issues===<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart [[Advanced_Linux_Sound_Architecture|Alsa]].<br />
<br />
=====Mono on PulseAudio=====<br />
<br />
To set mono in a [[PulseAudio|PulseAudio]] system. Run on terminal:<br />
<br />
$ pacmd list-sinks | grep name | head -n1 <br />
<br />
To get the master device name. The output of command will look like this:<br />
<br />
name: <alsa_output.pci-0000_00_1b.0.analog-stereo><br />
<br />
Put device name (alsa_output.pci-0000_00_1b.0.analog-stereo) in field 'master' of the command below:<br />
<br />
$ pacmd load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono<br />
<br />
'''Warning''': The device name can be different, so take attention!<br />
<br />
So this command just will work if PulseAudio is already started.<br />
<br />
To make this permanent, (as root) put the argument of pacmd command on last line of file ''/etc/pulse/default.pa'':<br />
<br />
# echo "load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono" >> /etc/pulse/default.pa<br />
<br />
'''Warning''': Be sure, of don't run an audio application with this configuration above (Maybe mpg123 to start a sound theme in a session of [[Xfce|Xfce]]) before PulseAudio starts, in a session. It's probably the PulseAudio will not working.<br />
<br />
And after, reboot your machine and every session startup, this will work.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291926ASUS Eee PC 1025c2014-01-07T21:06:02Z<p>Jeanlandim: /* Audio */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==Audio==<br />
===Mono Issues===<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart [[Advanced_Linux_Sound_Architecture|Alsa]].<br />
<br />
=====Mono on PulseAudio=====<br />
<br />
To put in mono in a [[PulseAudio|PulseAudio]] system. Run on terminal:<br />
<br />
$ pacmd list-sinks | grep name | head -n1 <br />
<br />
To get the master device name. The output of command will look like this:<br />
<br />
name: <alsa_output.pci-0000_00_1b.0.analog-stereo><br />
<br />
Put device name (alsa_output.pci-0000_00_1b.0.analog-stereo) in field 'master' of the command below:<br />
<br />
$ pacmd load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono<br />
<br />
'''Warning''': The device name can be different, so take attention!<br />
<br />
So this command just will work if PulseAudio is already started.<br />
<br />
To make this permanent, (as root) put the argument of pacmd command on last line of file ''/etc/pulse/default.pa'':<br />
<br />
# echo "load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono" >> /etc/pulse/default.pa<br />
<br />
'''Warning''': Be sure, of don't run an audio application with this configuration above (Maybe mpg123 to start a sound theme in a session of [[Xfce|Xfce]]) before PulseAudio starts, in a session. It's probably the PulseAudio will not working.<br />
<br />
And after, reboot your machine and every session startup, this will work.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291924ASUS Eee PC 1025c2014-01-07T20:59:57Z<p>Jeanlandim: </p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==Audio==<br />
===Mono Issues===<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart '''Alsa''' or your '''Desktop Manager Session'''.<br />
<br />
=====Mono on PulseAudio=====<br />
<br />
To put in mono in a [[PulseAudio|PulseAudio]] system. Run on terminal:<br />
<br />
$ pacmd list-sinks | grep name | head -n1 <br />
<br />
To get the master device name. The output of command will look like this:<br />
<br />
name: <alsa_output.pci-0000_00_1b.0.analog-stereo><br />
<br />
Put device name (alsa_output.pci-0000_00_1b.0.analog-stereo) in field 'master' of the command below:<br />
<br />
$ pacmd load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono<br />
<br />
'''Warning''': The device name can be different, so take attention!<br />
<br />
So this command just will work if PulseAudio is already started.<br />
<br />
To make this permanent, (as root) put the argument of pacmd command on last line of file ''/etc/pulse/default.pa'':<br />
<br />
# echo "load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono" >> /etc/pulse/default.pa<br />
<br />
'''Warning''': Be sure, of don't run an audio application with this configuration above (Maybe mpg123 to start a sound theme in a session of [[Xfce|Xfce]]) before PulseAudio starts, in a session. It's probably the PulseAudio will not working.<br />
<br />
And after, reboot your machine and every session startup, this will work.<br />
<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291923ASUS Eee PC 1025c2014-01-07T20:57:06Z<p>Jeanlandim: /* Mono Issues */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291921ASUS Eee PC 1025c2014-01-07T20:53:50Z<p>Jeanlandim: /* Mono on PulseAudio */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
====Mono Issues====<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart '''Alsa''' or your '''Desktop Manager Session'''.<br />
<br />
=====Mono on PulseAudio=====<br />
<br />
To put in mono in a [[PulseAudio|PulseAudio]] system. Run on terminal:<br />
<br />
$ pacmd list-sinks | grep name | head -n1 <br />
<br />
To get the master device name. The output of command will look like this:<br />
<br />
name: <alsa_output.pci-0000_00_1b.0.analog-stereo><br />
<br />
Put device name (alsa_output.pci-0000_00_1b.0.analog-stereo) in field 'master' of the command below:<br />
<br />
$ pacmd load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono<br />
<br />
'''Warning''': The device name can be different, so take attention!<br />
<br />
So this command just will work if PulseAudio is already started.<br />
<br />
To make this permanent, (as root) put the argument of pacmd command on last line of file ''/etc/pulse/default.pa'':<br />
<br />
# echo "load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono" >> /etc/pulse/default.pa<br />
<br />
'''Warning''': Be sure, of don't run an audio application with this configuration above (Maybe mpg123 to start a sound theme in a session of [[Xfce|Xfce]]) before PulseAudio starts, in a session. It's probably the PulseAudio will not working.<br />
<br />
And after, reboot your machine and every session startup, this will work.<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291920ASUS Eee PC 1025c2014-01-07T20:50:46Z<p>Jeanlandim: /* Mono Issues */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
====Mono Issues====<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart '''Alsa''' or your '''Desktop Manager Session'''.<br />
<br />
=====Mono on PulseAudio=====<br />
<br />
To put in mono in a [[PulseAudio|PulseAudio]] system. Run on terminal:<br />
<br />
$ pacmd list-sinks | grep name | head -n1 <br />
<br />
To get the master device name. The output of command will look like this:<br />
<br />
name: <alsa_output.pci-0000_00_1b.0.analog-stereo><br />
<br />
Put device name (alsa_output.pci-0000_00_1b.0.analog-stereo) in field 'master' of the command above:<br />
<br />
$ pacmd load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono<br />
<br />
'''Warning''': The device name can be different, so take attention!<br />
<br />
So this command just will work if PulseAudio is already started.<br />
<br />
To make this permanent, (as root) put the argument of pacmd command on last line of file ''/etc/pulse/default.pa'':<br />
<br />
# echo "load-module module-remap-sink sink_name=mono master=alsa_output.pci-0000_00_1b.0.analog-stereo channels=2 channel_map=front-right,mono" >> /etc/pulse/default.pa<br />
<br />
'''Warning''': Be sure, of don't run an audio application with this configuration above (Maybe mpg123 to start a sound theme in a session of [[Xfce|Xfce]]) before PulseAudio starts, in a session. It's probably the PulseAudio will not working.<br />
<br />
And after, reboot your machine and every session startup, this will work.<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291916ASUS Eee PC 1025c2014-01-07T19:52:05Z<p>Jeanlandim: /* Mono Issues */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
====Mono Issues====<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart '''Alsa''' or your '''Desktop Manager Session'''.<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291915ASUS Eee PC 1025c2014-01-07T19:51:12Z<p>Jeanlandim: /* Mono Issues */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
====Mono Issues====<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. So will only using the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart '''Alsa''' or your '''Desktop Manager Session'''.<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291913ASUS Eee PC 1025c2014-01-07T19:48:00Z<p>Jeanlandim: /* Mono Issues */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
====Mono Issues====<br />
<br />
Maybe you want hear some MP3 files in stereo format and you'll noted some voices or instruments who are missed. The solution is change some settings to play all sounds in mono format. . So will be necessary some tricks for this, using only the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart '''Alsa''' or your '''Desktop Manager Session'''.<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandimhttps://wiki.archlinux.org/index.php?title=ASUS_Eee_PC_1025c&diff=291911ASUS Eee PC 1025c2014-01-07T19:35:26Z<p>Jeanlandim: /* Audio */</p>
<hr />
<div>[[Category:ASUS]]<br />
{{Warning|I am learning linux with arch and my Eee PC. So my solutions may be not the best.}}<br />
<br />
==Bootloader==<br />
You have to use an i686 boot ISO even though the Intel ARK says that the computer's CPU supports Intel 64. If you're using the dual-architecture ISO (which is downloaded by default), then the ISO will auto-detect it as i686.<br />
<br />
The BIOS doesn't seem to support EFI boot on an ArchISO USB stick, even though it detects it as a UEFI bootable medium. Install with a BIOS bootloader unless you know what you're doing. If you are able to boot in UEFI mode, then please add a tutorial.<br />
<br />
==HDMI==<br />
===Video===<br />
You have to change the [[Poulsbo|video driver]]. <br />
If the HDMI cable is plugged in on boot it is enabled automatically. If it is plugged in after boot you can use [[xrandr]] to enable the second monitor:<br />
<br />
# xrandr --output DVI-0 --auto<br />
<br />
===Audio===<br />
You need to know the number of your sound card and the the number of HDMI device:<br />
<br />
{{hc|aplay -l|2=<nowiki><br />
**** Liste der Hardware-Geräte (PLAYBACK) ****<br />
Karte 0: Intel [HDA Intel], Gerät 0: ALC269VB Analog [ALC269VB Analog]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
Karte 0: Intel [HDA Intel], Gerät 3: HDMI 0 [HDMI 0]<br />
Sub-Geräte: 1/1<br />
Sub-Gerät #0: subdevice #0<br />
</nowiki>}}<br />
<br />
====Global====<br />
<br />
In /usr/shared/alsa/alsa.conf search the lines<br />
default.pcm.card 0<br />
default.pcm.device 0<br />
<br />
If you change the numbers to your card and device (in my case card is 0 and device is 3) and reboot the audio output switches to HDMI.<br />
<br />
====User specific====<br />
do [[Advanced_Linux_Sound_Architecture#HDMI_Output_Does_Not_Work|this]] and reboot<br />
<br />
====Dynamic====<br />
The audio device can also be configured with /etc/asound.conf <br />
So you can create a script that links asound.conf to a configuration depending on the hdmi cable plugged in or not: (for some reason my HDMI device is listed as DVI)<br />
<br />
{{hc|hdmi_switched.sh|2=<nowiki><br />
#! /bin/bash<br />
hdmi_status="$(cat /sys/class/drm/card0-DVI-D-1/status)"<br />
ln -f "/etc/alsa/hdmi_$hdmi_status" /etc/alsa/asound.conf<br />
alsactl restore<br />
</nowiki>}}<br />
<br />
Configuration files:<br />
{{hc|hdmi_connected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 3 <br />
}<br />
</nowiki>}}<br />
<br />
{{hc|hdmi_disconnected|2=<nowiki><br />
pcm.!default {<br />
type hw<br />
card 0<br />
device 0 <br />
}<br />
</nowiki>}}<br />
<br />
Create a symbolic link to /etc/asound.conf<br />
<br />
ln -s /etc/alsa/asound.conf /etc/asound.conf<br />
<br />
If the user is allowed to run the hdmi_switch.sh script and is also allowed to change files in /etc/alsa folder you can bind that script to a key :D<br />
If you also want to change to monitor read [[Advanced_Linux_Sound_Architecture#Using_udev_to_automatically_turn_HDMI_audio_on_or_off|this]].<br />
<br />
====Mono Issues====<br />
<br />
Maybe you want hear some MP3 files in stereo format, so will be necessary some tricks for this, using only the [[Advanced_Linux_Sound_Architecture|Alsa]] you have to create a file called ''.asoundrc'' (if you have this file, so make a backup for safety) and put this content below:<br />
<br />
{{hc|~/.asoundrc|2=<nowiki><br />
pcm.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
ctl.card0 {<br />
type hw<br />
card 0<br />
}<br />
<br />
pcm.monocard {<br />
slave.pcm card0<br />
slave.channels 2<br />
# type plug<br />
type route<br />
ttable {<br />
# Copy both input channels to output channel 0 (Left). <br />
0.0 1<br />
1.0 1<br />
# Send nothing to output channel 1 (Right). <br />
0.1 0<br />
1.1 0<br />
}<br />
}<br />
<br />
ctl.monocard {<br />
type hw<br />
card 0<br />
} <br />
<br />
pcm.!default monocard<br />
</nowiki>}}<br />
<br />
Save on your home directory and restart '''Alsa''' or your '''Desktop Manager Session'''.<br />
<br />
==Screen Brightness==<br />
===acpi===<br />
Setting brightness in /sys/class/backlight/acpi_video0/ with the scripts for [[acpid#Enabling_backlight_control|acpid]] change the values of the files ''brightness'' and ''actual_brightness'' but do not have any effect on current screen brightness.<br />
<br />
Set the [[Backlight#ACPI|following]] as kernel parameters in your bootloader<br />
acpi_osi=Linux acpi_backlight=vendor<br />
<br />
To make this permant [[Kernel_parameters#GRUB|see here]]<br />
<br />
==== FN Keys ====<br />
Now there is a folder ''eeepc-wmi'' in /sys/class/backlight and the scripts need to be updated<br />
{{hc|/etc/acpi/actions/bl_up.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)+1)) >$bl_device<br />
</nowiki>}}<br />
<br />
{{hc|/etc/acpi/actions/bl_down.sh|<nowiki><br />
#!/bin/sh<br />
bl_device=/sys/class/backlight/eeepc-wmi/brightness<br />
echo $(($(cat $bl_device)-1)) >$bl_device<br />
</nowiki>}}<br />
<br />
The scripts change the screen brightness everytime I run them. Unfortunately the acpi events for brightnessup and brightnessdown are not available anymore although the brightnessup key sets brightness to maximum and the brightnessdown key sets the brightness to max_brightness-1 :( (do not now where this happens) --> [https://bbs.archlinux.org/viewtopic.php?pid=1200593&ei=NZLMUPKhLonasgbX74CgBw&usg=AFQjCNG2D4H-8dfxK1wGjs78YDjvy-kH_A&bvm=bv.1355325884,d.Yms this may help]<br />
<br />
When using the [[Enlightenment]] 17 window manager, the brightness keys will work without any additional configuration and the backlight can be adjusted using the built-in backlight widget.<br />
<br />
==== AC plug / unplug ====<br />
{{hc|/etc/acpi/handler.sh|<nowiki><br />
..<br />
ac_adapter)<br />
case "$2" in<br />
ACPI0003:00)<br />
case "$4" in<br />
00000000)<br />
logger 'AC unpluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)/2)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
00000001)<br />
logger 'AC pluged'<br />
echo $(($(cat /sys/class/backlight/eeepc-wmi/max_brightness)-1)) > /sys/class/backlight/eeepc-wmi/brightness<br />
;;<br />
esac<br />
;;<br />
*)<br />
logger "AC Adapter ACPI action undefined: $2"<br />
;;<br />
esac<br />
;;<br />
..<br />
</nowiki>}}</div>Jeanlandim