Apple System Management Controller (SMC) API in pure C from user space for Intel based Macs. The API works by talking to the AppleSMC.kext (kernel extension), the closed source driver for the SMC.
For a Swift based version see SMCKit.
"The System Management Controller (SMC) is an internal subsystem introduced by Apple Inc. with the introduction of their new Intel processor based machines in 2006. It takes over the functions of the SMU. The SMC manages thermal and power conditions to optimize the power and airflow while keeping audible noise to a minimum. Power consumption and temperature are monitored by the operating system, which communicates the necessary adjustments back to the SMC. The SMC makes the changes, slowing down or speeding up fans as necessary." -via Wikipedia
For more see:
Via clib
$ clib install beltex/libsmc
- OS X 10.6+
While the Swift based version of the API is preferred, there are several reasons why the C based one might be needed:
- Wider OS X target range
- Since Swift on OS X is only supported on 10.9 and above
- Application written primarily in C
- Based off of fork from osx-cpu-temp
With credits to:
- Apple System Management Control (SMC) Tool by devnull
- smcFanControl
- iStat Pro
Handy I/O Kit references:
- iOS Hacker's Handbook
- Mac OS X and iOS Internals: To the Apple's Core
- OS X and iOS Kernel Programming
This project is under the GNU General Public License v2.0.