added a thinkpad fan controller module (because that isnt inbuilt???)
This commit is contained in:
8
flake.lock
generated
8
flake.lock
generated
@@ -374,11 +374,11 @@
|
||||
"wshowkeys": "wshowkeys"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1787685448,
|
||||
"narHash": "sha256-gvdmxEM49ZE6KqosyKIHsQ6V6NHcYrw9in2TpuFad4I=",
|
||||
"lastModified": 1787750232,
|
||||
"narHash": "sha256-Kx0A+ytaYCyuzdA4ROeFh5kHsgh3N510KdXHuMTRclA=",
|
||||
"ref": "refs/heads/main",
|
||||
"rev": "0c27e34df40ba4865cb8d9838b80685fc3b79785",
|
||||
"revCount": 69,
|
||||
"rev": "a85e6b79b88045e91055e2564ffdaab2c8e23f11",
|
||||
"revCount": 74,
|
||||
"type": "git",
|
||||
"url": "https://git.voidarc.co.uk/voidarc/hypr"
|
||||
},
|
||||
|
||||
@@ -45,6 +45,7 @@
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gsettings-desktop-schemas
|
||||
glib
|
||||
];
|
||||
|
||||
system.activationScripts.hyprRuntimeEnv = lib.stringAfter ["specialfs"] ''
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
mobile03Configuration
|
||||
intelDrivers
|
||||
development
|
||||
thinkpadFanControl
|
||||
upower
|
||||
({...}: {
|
||||
hyprland.enablePlugins = true;
|
||||
|
||||
27
modules/system/drivers/thinkpadFanControl.nix
Normal file
27
modules/system/drivers/thinkpadFanControl.nix
Normal file
@@ -0,0 +1,27 @@
|
||||
{
|
||||
self,
|
||||
moduleWithSystem,
|
||||
...
|
||||
}: {
|
||||
flake.nixosModules.thinkpadFanControl = moduleWithSystem ({inputs', ...}: {
|
||||
# Enable fan control for the thinkpad module (why is this not the default??)
|
||||
boot.extraModprobeConfig = ''
|
||||
options thinkpad_acpi fan_control=1
|
||||
'';
|
||||
|
||||
services.thinkfan = {
|
||||
enable = true;
|
||||
|
||||
extraArgs = ["-s" "5"];
|
||||
|
||||
levels = [
|
||||
[0 0 55]
|
||||
[1 50 60]
|
||||
[3 58 68]
|
||||
[5 65 75]
|
||||
[7 73 85]
|
||||
["level disengaged" 82 32767]
|
||||
];
|
||||
};
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user