Giter Club home page Giter Club logo

rpi-fan-ctrl's Introduction

A fan controller for the Raspberrypi (Tested on RPI3 B+)

This is a simple fan controller daemon/client that will turn on a fan at a certain CPU temperature. Written in C using the pigpio library.

Building and Installation

Make sure you have pigpio installed on your PI.

$ git clone https://gitlab.com/TheGreatMcPain/rpi-fan-ctrl.git
$ cd rpi-fan-ctrl
$ meson build
$ cd build
$ ninja
$ sudo ninja install

Usage

The single binary acts as both daemon and client.

To start the daemon use the -d option.

Once the daemon is running you can get the status of the daemon like so.

# rpi-fan-ctrl status

The set-upper <temp> and set-lower <temp> client commands can be used to set the daemon's current tempurature thresholds.

Parameters and Variables

# rpi-fan-ctrl <options>
Option Description
-h Displays a help message.
-d Start daemon
Daemon Option (requires -d) Description
-f Run daemon in the foreground
-u <temp> The CPU temperature threshold where the fan will turn on. (defaults to 50)
-l <temp> The CPU temperature threshold where the fan will turn off. (defaults to 40)
Client Options Description
status Get daemon's current status
set-upper <temp> Set daemon's upper tempurature threshold
set-lower <temp> Set daemon's lower tempurature threshold

The RPIFANCTRL_SOCK environment variable sets the unix socket location (default /tmp/rpi-fan-ctrl.sock).

rpi-fan-ctrl's People

Contributors

thegreatmcpain avatar

Watchers

 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.