Something about Laptop/Desktop FreeBSD

2009-05-13 01:58:12来源:未知 阅读 ()

新老客户大回馈,云服务器低至5折


               
               
               
               
               
                自从上个月把笔记本从FreeBSD5.4升到6.0stable,这一个月的也算是搞定了一些笔记本或是桌面应用的问题。记录于此。
freebsd 6.0-stable
xorg 6.8.2 (xorg-server-6.8.99.903)
* PENTIUM-M SPEEDSTEP
I didnot make it until last month, which was nearly half a year since I started to use freebsd for my laptop desktop. They say in FreeBSD5, there are est/estctrl ports. I havent tried that when I was in 5.4 version, however. Now I am using FreeBSD6. est/estctrl were broken, but finally I got from the net the way to make use of SpeedStep of my PentiumM.
Simply add this to loader.conf:
    cpufreq_load="YES"
(Here one may aslo compile "device cpufreq" into the channel. I did not try it)
and add this to rc.conf:
    powerd_enable="YES"
    powerd_flags="-a maximum -b adaptive -n adaptive"
here -a stands for "AC", -b for "batt", -n for "unknow". And "adaptive" means the freq could be adjusted on the fly. This is a new feature of powerd, in FreeBSD5 only two freq steps can be manually set.
Now the battery can hold for over 30% longer than before.
* MULTIMEDIA KEYS
Some window managers (eg. gnome) enable one to config the multimedia keys on laptop keyboard. However, my WindowMaker does not provide that feature. I found xbindkeys (/usr/ports/x11) can do me the favor.
This is the format of ~/.xbindkeysrc enties
    "command to start"
        associated key
So I added the following lines to my ~/.xbindkeysrc
    "mixer vol +10"
        m:0x0 + c:176
    "mixer vol -10"
        m:0x0 + c:174
    "mixermute.sh"
      m:0x0 + c:160
Here "m:0x0 + c:176" is the key code, which can be obtained with
    xbindkeys -mk
And mixermute.sh is a script by myself
    #!/bin/sh
    if [ -e ~/.mixermute ]; then        mixer vol `cat ~/.mixermute`        rm ~/.mixermute    else        mixer vol | sed -n "s/.*://p" > ~/.mixermute        mixer vol mute    fiNote that xbindkeys seemed to conflict with xmodmap in some cases. When both are used in .xprofile (or .xsession), sometimes wmaker may not start, sometimes it starts but keyboard disabled.  

标签:

版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com
特别注意:本站所有转载文章言论不代表本站观点,本站所提供的摄影照片,插画,设计作品,如需使用,请与原作者联系,版权归原作者所有

上一篇:关于FreeBSD的版本分支

下一篇:freebsd 自带防火墙一(PF)