調節亮度 ios
sudo vim /etc/X11/xorg.conf vim
加一句:Option "RegistryDwords" "EnableBrightnessControl=1" ide
保存亮度 ui
一、解決reboot後沒法保存屏幕亮度: this
sudo gedit /etc/rc.local google
插入這句話到代碼中: spa
echo 0 > /sys/class/backlight/acpi_video0/brightness ip
以下: it
#!/bin/sh -e io
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will 「exit 0″ on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
echo 0 > /sys/class/backlight/acpi_video0/brightness
exit 0
其中echo 後面的值爲0-10,對應爲0到100%,如echo 5表示一半亮度
保存後退出,重啓就能夠了。
注意:大多數人都是acpi_video0,根據本身/sys/class/backlight/下面文件決定
二、亮度調節
亮度調節依賴與你的bios和內核版本,你能夠嘗試如下代碼:
kernel boot選項:
當你啓動系統時,出如今grup的屏幕時,按e鍵進行編輯,在kernel這一行添加:
nomodeset acpi_backlight=vendor
Intel - nomodeset acpi_backlight=intel Acer - acpi_backlight=acer_acpi or even acpi_osi=Linux acpi_backlight=legacy.
quiet splash nomodeset acpi_backlight=vendor
# command line
sudo -e /etc/default/grub
# graphical
gksu gedit /etc/default/grub
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nomodeset acpi_backlight=vendor"