Ubuntu 14 保存屏幕亮度解决方法

来源:互联网 发布:向大大内衣淘宝网真假 编辑:程序博客网 时间:2024/05/02 01:26
Ubuntu 14 LTS不能自动保存亮度:每次登陆、解锁后,都是最大亮度,非常讨厌!
1、打开终端,输入命令查看本机支持的最大亮度值
cat /sys/class/backlight/acpi_video0/max_brightness

我的笔记本支持最大亮度为100
kashu@ubuntu:~$ cat /sys/class/backlight/acpi_video0/max_brightness
100

2、编辑这个文件
sudo gedit /etc/rc.local
打开后你会看到如下内容:
#!/bin/sh -e  
#  
# 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.  
  
#exit 0

插入这句话到代码中:
echo 100 > /sys/class/backlight/acpi_video0/brightness

就像我下面的一样:
kashu@ubuntu:~$ cat /etc/rc.local 
#!/bin/sh -e
#
# 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 100 > /sys/class/backlight/acpi_video0/brightness
exit 0

其中echo 后面的值为0-100,对应为0到100%,如echo 50表示一半亮度

3、保存后退出,重启就可以了
0 0
原创粉丝点击