Code Monkey home page Code Monkey logo

thinkfan's Introduction

thinkfan Total alertsLanguage grade: C/C++

Thinkfan is a simple, lightweight fan control program.

WARNING

There's only very basic sanity checking on the configuration (semantic plausibility). You can set the temperature limits as insane as you like.

Any change to fan behaviour that results in higher temperatures in some parts of the system will shorten your system's lifetime and/or cause weird hardware bugs that'll make you pull out your hair.

No warranties whatsoever

If this program steals your car, kills your horse, smokes your dope or pees on your carpet... too bad, you're on your own.

Building and installing

To compile thinkfan, you will need to have the following things installed:

  • A recent C++ compiler (GCC >= 4.8 or clang)
  • pkgconfig or an equivalent (pkgconf or pkg-config)
  • cmake (and optionally a cmake GUI if you want to configure interactively)
  • optional: libyaml-cpp for YAML support (the -dev or -devel package)
  1. In the thinkfan main directory, do

    mkdir build && cd build
  2. Then configure your build, either interactively:

    ccmake ..

    Or set your build options from the command line. E.g. to configure a build with full debugging support:

     cmake -D CMAKE_BUILD_TYPE:STRING=Debug ..

    CMAKE_BUILD_TYPE:STRING can also be Release, which produces a fully optimized binary, or RelWithDebInfo, which is also optimized but can still be debugged with gdb.

    Other options are:

    USE_NVML:BOOL (default: ON) Allows thinkfan to read GPU temperatures from the proprietary nVidia driver. The interface library is loaded dynamically, so it does not need to be installed when compiling.

    USE_ATASMART:BOOL (default: OFF) Enable libatasmart to read temperatures directly from hard disks. Use this only when you really need it, since libatasmart is unreasonably CPU-intensive.

    USE_LM_SENSORS:BOOL (default: ON) Use LM sensors to read temperatures directly from Linux drivers. The libsensors library needs to be installed for this feature, probably with required headers and development files (e.g., libsensors-dev).

    USE_YAML:BOOL (default: ON) Support config file in the new, more flexible YAML format. The old config format will be deprecated after the thinkfan 1.0 release. New features will be supported in YAML configs only. See examples/thinkfan.conf.yaml. Requires libyaml-cpp.

  3. To compile simply run:

    make
  4. If you did not change CMAKE_INSTALL_PREFIX, thinkfan will be installed under /usr/local by doing:

    sudo make install

    CMake will detect whether you use OpenRC or systemd and install some appropriate service files. With systemd, you can edit the commandline arguments of the thinkfan service with systemctl edit thinkfan. With OpenRC, we install only a plain initscript (edit /etc/init.d/thinkfan to change options).

Documentation

thinkfan's People

Contributors

vmatare avatar evgeni avatar calvinrw avatar koutheir avatar kyrias avatar ivan-aksamentov avatar torsten-pf avatar whissi avatar susanwl avatar akheron avatar mariobl avatar leonardohn avatar mowgli avatar yhaenggi avatar geckoneer avatar cbrown0x90 avatar acarapetis avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.