Skip to content

Commit bd92a25

Browse files
authored
Merge pull request linux-on-mac#134 from DougBeney/patch-1
TOC, coretemp/applesmc directions, Macbook support, Solus
2 parents f1bdb61 + 7297a18 commit bd92a25

File tree

1 file changed

+63
-35
lines changed

1 file changed

+63
-35
lines changed

README.md

+63-35
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
mbpfan
22
====================
33

4-
Introduction
5-
---------------------
64
This is an enhanced version of [Allan McRae mbpfan](http://allanmcrae.com/2010/05/simple-macbook-pro-fan-daemon/)
75

8-
mbpfan is a daemon that uses input from coretemp module and sets the fan speed using the applesmc module.
6+
mbpfan is a daemon that uses input from coretemp module and sets the fan speed using the applesmc module.
97
This enhanced version assumes any number of processors and fans (max. 10).
108

119
* It only uses the temperatures from the processors as input.
@@ -15,9 +13,24 @@ This enhanced version assumes any number of processors and fans (max. 10).
1513
* Verbose mode for both syslog and stdout
1614
* Users can configure it using the file /etc/mbpfan.conf
1715

16+
**Table Of Contents**
17+
18+
- [Supported GNU/Linux Distributions](#supported-gnulinux-distributions)
19+
- [Tested Macbook Models](#tested-macbook-models)
20+
- [Tested iMac/Mac Mini Models](#tested-imacmac-mini-models)
21+
- [Requirements](#requirements)
22+
- [Installation](#installation)
23+
- [Arch Linux](#arch-linux)
24+
- [Ubuntu](#ubuntu)
25+
- [Gentoo](#gentoo)
26+
- [Generic Install Instructions (All Other Operating Systems)](#generic-install-instructions-all-other-operating-systems)
27+
- [Run Instructions](#run-instructions)
28+
- [Starting at boot](#starting-at-boot)
29+
- [Usage](#usage)
30+
- [License](#license)
31+
32+
## Supported GNU/Linux Distributions
1833

19-
Supported GNU/Linux Distributions
20-
---------------------------------
2134
We provide scripts to to load mbpfan daemon at system boot for many distros.
2235
Please note that the support is provided by volunteers. mbpfan needs tests and bug reports.
2336

@@ -32,12 +45,14 @@ Supported distributions:
3245
- Gentoo
3346
- Alpine
3447
- Trisquel
48+
- Solus
49+
50+
## Tested Macbook Models
3551

36-
Tested MacBook Models
37-
---------------------
38-
This section reports those models where mbpfan was tested successfully. It does not necessarily mean that the daemon does not work on non-listed models.
52+
This section reports those models where mbpfan was tested successfully. It does not necessarily mean that the daemon does not work on non-listed models.
3953

4054
- MacBook Pro 12,1 13" (Intel i5 - Linux 4.20)
55+
- MacBook Pro 11,4 15" (Intel i7 - Linux 4.9.41)
4156
- MacBook Pro 11,1 13" (Intel i5 - Linux 3.14, Linux 3.15)
4257
- MacBook Pro 9,2 13" (Intel i5/i7 - Linux 3.10)
4358
- MacBook Pro 8,2 15" (Intel i7 - Linux 3.6.2)
@@ -51,8 +66,8 @@ This section reports those models where mbpfan was tested successfully. It does
5166
- MacBook Air 7,2 13" (Intel Core Duo - Linux 4.10)
5267
- MacBook 1,1 (Intel Core Duo - Linux 3.16)
5368

54-
Tested iMac/Mac Mini Models
55-
------------------
69+
## Tested iMac/Mac Mini Models
70+
5671
This section reports the iMac/Mac-mini models where mbpfan was tested successfully.
5772

5873
- iMac Retina 16.2 21.5" (Intel i5 - Linux 4.4.0 Ubuntu 16.04)
@@ -62,40 +77,54 @@ This section reports the iMac/Mac-mini models where mbpfan was tested successful
6277
- Mac Mini 5,3 (Core i7 2.0 - Linux 4.4.0 elementary/Ubuntu)
6378
- Mac Mini 6,1 (Core i7 2.3 - Linux 4.7.3-4-ck Archlinux)
6479

65-
Warning
66-
-------
80+
## Requirements
81+
6782
Be sure to load the kernel modules **applesmc** and **coretemp**.
68-
These modules are often automatically loaded when booting up GNU/Linux on a MacBook. If that is not the case, you should make sure to load them at system startup. This is _usually_ achieved by inserting the following two lines in the file `/etc/modules`
83+
84+
These modules are often automatically loaded when booting up GNU/Linux on a MacBook. If that is not the case, you should make sure to load them at system startup.
85+
86+
**How do I know if applesmc and coretemp are loaded?**
87+
88+
In most distributions, you can run the following command:
89+
90+
`lsmod | grep coretemp && lsmod | grep applesmc`
91+
92+
If you see `coretemp` and `applesmc` listed, you are all set.
93+
94+
**If you do not see `coretemp` and `applesmc` listed, you must load them.**
95+
96+
This is _usually_ achieved by inserting the following two lines in the file `/etc/modules`
97+
6998
```
7099
coretemp
71100
applesmc
72101
```
73102

74103
Please check the relevant documentation of your GNU/Linux distribution.
75104

76-
Arch Linux
77-
---------
105+
## Installation
106+
107+
### Arch Linux
108+
78109
See [mbpfan-git at AUR](https://aur.archlinux.org/packages/mbpfan-git/).
79110
Otherwise, please refer to the Generic Instructions.
80111

81112

82-
Ubuntu
83-
------
113+
### Ubuntu
84114

85115
Install the ```build-essential``` package.
86116
Then, refer to the Generic Install Instructions.
87117

88118
Otherwise, a step-by-step [tutorial for beginners is available on my website](https://ineed.coffee/3838/a-beginners-mbpfan-tutorial-for-ubuntu/).
89119

90-
Gentoo
91-
------
120+
### Gentoo
92121

93122
Install the ```mbpfan``` package with:
94123

95124
sudo emerge -av app-laptop/mbpfan
96125

97-
Generic Install Instructions
98-
-------------------------
126+
### Generic Install Instructions (All Other Operating Systems)
127+
99128
Compile with
100129

101130
make
@@ -104,14 +133,14 @@ Install with
104133

105134
sudo make install
106135

107-
It copies mbpfan to /usr/sbin, mbpfan.conf to /etc (and overwrites existing files),
136+
It copies mbpfan to /usr/sbin, mbpfan.conf to /etc (and overwrites existing files),
108137
README.md to /usr/share/doc/mbpfan, and mbpfan.8.gz to /usr/share/man/man8
109138

110139
Run the tests now, see two sections below.
111140

112141
If you would like to compile with Clang instead of GCC, simply set your system's
113142
default compiler to be Clang. Tested with Clang 3.8 and 3.9. Tested with Clang
114-
4.0 along with llvm-lld (The LLVM Linker).
143+
4.0 along with llvm-lld (The LLVM Linker).
115144

116145

117146
Run The Tests (Recommended)
@@ -125,8 +154,8 @@ or
125154
sudo make tests
126155

127156

128-
Run Instructions
129-
----------------
157+
## Run Instructions
158+
130159
If not installed, run with
131160

132161
sudo bin/mbpfan
@@ -140,8 +169,8 @@ If installed and using the init file, run with (Ubuntu example)
140169
sudo service mbpfan start
141170

142171

143-
Starting at boot
144-
----------------
172+
## Starting at boot
173+
145174
**Ubuntu**
146175

147176
For systemd based init systems (Ubuntu 16.04+), the file mbpfan.service
@@ -152,14 +181,14 @@ For using it, execute:
152181
sudo systemctl enable mbpfan.service
153182

154183

155-
For upstart based init systems (Ubuntu before 16.04), an example upstart job has been provided.
184+
For upstart based init systems (Ubuntu before 16.04), an example upstart job has been provided.
156185
For using it, execute:
157186

158187
sudo cp mbpfan.upstart /etc/init/mbpfan.conf
159188
sudo start mbpfan
160189

161190
**Debian**
162-
An init file suitable for /lib/lsb/init-functions (Debian)
191+
An init file suitable for /lib/lsb/init-functions (Debian)
163192
is located in the main folder of the source files, called mbpfan.init.debian
164193
Rename it to mbpfan, give it execution permissions (chmod +x mbpfan)
165194
and move it to /etc/init.d
@@ -197,8 +226,7 @@ To start the service automatically at boot, also execute the following:
197226
sudo systemctl enable mbpfan.service
198227

199228

200-
Usage
201-
-------
229+
## Usage
202230

203231
Usage: ./mbpfan OPTION(S)
204232

@@ -208,13 +236,13 @@ Usage
208236
-v Be (a lot) verbose
209237

210238

211-
License
212-
---------------------
239+
## License
240+
213241
GNU General Public License version 3
214242

215243

216-
Based On
217-
---------------------
244+
**This Project Is Based On:**
245+
218246
* http://allanmcrae.com/2010/05/simple-macbook-pro-fan-daemon/
219247
* http://allanmcrae.com/2011/08/mbp-fan-daemon-update/
220248
* https://launchpad.net/macfanctld

0 commit comments

Comments
 (0)