poetter-sebastian / pi-fan-controll

A kernel program to control a 12v fan with a raspberry pi.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fan-controll-for-raspberry-pi


picture of distribution of duties on a 4 core cpu

Requirements:

Hardware

  • Raspberry Pi with Raspbian (Kernelversion 4.x)
  • BME280 Module
  • 4 Pin Fan (12v-VCC, GND, RPM, PWM)

Software

  • Access to the kernel (load and unload kernel modules)

Setup:

Install required software

To get access to the kernel you have to do the folowing:

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install git bc bison flex libssl-devsudo apt-get install libncurses5-dev
sudo wget https://raw.githubusercontent.com/notro/rpi-source/master/rpi-source -O /usr/local/bin/rpi-source && sudo chmod +x /usr/local/bin/rpi-source && /usr/local/bin/rpi-source -q –tag-update
sudo rpi-source

Now you can view your kernel version (uname -r) and load/unload kernel modules.

load kernel module:
sudo insmod {kernel module}*.ko 

unload kernel module:
sudo rmmod {kernel module}*.ko

show all loaded kernel modules:
lsmod

show detailed information about a module:
modeinfo {kernel module}

show kernel log:
dmesg

About

A kernel program to control a 12v fan with a raspberry pi.


Languages

Language:C 98.1%Language:C++ 1.4%Language:Makefile 0.6%