nix-git/modules/tuxedo-rs.nix

44 lines
1.5 KiB
Nix
Raw Normal View History

2024-01-27 15:53:27 +01:00
{ config, pkgs, ... }:
{
2024-09-02 12:45:13 +02:00
# Much quieter CPU fan on Tuxedo AMD Ryzen laptop.
# https://github.com/AaronErhardt/tuxedo-rs?tab=readme-ov-file#nixos
# Check if the configuration is still valid:
# systemctl status tailord.service
# #=> Starting Tuxedo Tailor hardware control service...
# #=> INFO start_runtime: tailord: Starting tailord
# #=> INFO start_runtime: tailord::profiles: Loaded profile at `/etc/tailord/active_profile.json`: ...
# #=> INFO ...
# There should be no error messages!
2024-01-27 15:53:27 +01:00
hardware.tuxedo-rs = {
enable = true;
# Whether to enable tailor-gui, an alternative to TUXEDO Control Center, written in Rust.
# tailor-gui: Rust GUI for interacting with hardware from TUXEDO Computers.
tailor-gui.enable = true;
};
2024-09-02 12:45:13 +02:00
environment.etc."tailord/active_profile.json".source = "/etc/tailord/profiles/custom.json";
environment.etc."tailord/profiles/custom.json".text = ''
{"fans":["custom"],"leds":[{"device_name":"platform:tuxedo_keyboard","function":"kbd_backlight","profile":"custom","mode":"Monochrome"}],"performance_profile":"power_save"}
'';
environment.etc."tailord/keyboard/custom.json".text = ''
"None"
'';
# https://github.com/AaronErhardt/tuxedo-rs/blob/910e73794b80843faa49a630d7c2a114daef508c/tailord/src/fancontrol/profile.rs#L122
environment.etc."tailord/fan/custom.json".text = ''
2024-01-27 15:53:27 +01:00
[
{"temp":50,"fan":0},
{"temp":55,"fan":10},
{"temp":60,"fan":20},
{"temp":65,"fan":30},
{"temp":70,"fan":40},
{"temp":80,"fan":70},
{"temp":90,"fan":100}
]
'';
}