diff --git a/README.md b/README.md index e63b286f..f07930fa 100644 --- a/README.md +++ b/README.md @@ -131,6 +131,7 @@ See code for all available configurations. | [Asus TUF FX504GD](asus/fx504gd) | `` | `asus-fx504gd` | | [Asus TUF FX506HM](asus/fx506hm) | `` | `asus-fx506hm` | | [Asus TUF FA506IC](asus/fa506ic) | `` | `asus-fa506ic` | +| [Asus TUF FA506IC](asus/fa506nc) | `` | `asus-fa506nc` | | [Asus TUF FA507RM](asus/fa507rm) | `` | `asus-fa507rm` | | [Asus TUF FA507NV](asus/fa507nv) | `` | `asus-fa507nv` | | [Asus TUF FA706IC](asus/fa706ic) | `` | `asus-fa706ic` | diff --git a/asus/fa506nc/README.md b/asus/fa506nc/README.md new file mode 100644 index 00000000..80f904ee --- /dev/null +++ b/asus/fa506nc/README.md @@ -0,0 +1,74 @@ +# ASUS TUF A15 FA506NC + +- GPU switching to the nvidia card works fine through supergfxd. +- Power profiles autoswitch through asusctl in tandem with power-profiles-daemon. +- The batter charge limit configuration through ../battery.nix did not work, + setting a limit through asusd works. + +## Configuring AsusCTL + +To declaratively configure asusd you can control the whole config file through +the asusd service (same for fan curves and keyboard leds): + +```nix +services.asusd.asusdConfig.text = '' + ( + charge_control_end_threshold: 80, + base_charge_control_end_threshold: 80, + disable_nvidia_powerd_on_battery: true, + ac_command: "", + bat_command: "", + platform_profile_linked_epp: true, + platform_profile_on_battery: Quiet, + change_platform_profile_on_battery: true, + platform_profile_on_ac: Performance, + change_platform_profile_on_ac: true, + profile_quiet_epp: Power, + profile_balanced_epp: BalancePower, + profile_custom_epp: Performance, + profile_performance_epp: Performance, + ac_profile_tunings: { + Performance: ( + enabled: false, + group: {}, + ), + Quiet: ( + enabled: false, + group: {}, + ), + Balanced: ( + enabled: false, + group: {}, + ), + }, + dc_profile_tunings: { + Quiet: ( + enabled: false, + group: {}, + ), + Balanced: ( + enabled: false, + group: {}, + ), + Performance: ( + enabled: false, + group: {}, + ), + }, + armoury_settings: {}, + ) +''; +``` + +Here you can set the battery charge limit and other settings like which profile to +use on batter and which on power. + +## More optimizations + +You may also want to enable thermald and powertop for the optimizations mentioned in +https://nixos.wiki/wiki/Laptop. + +```nix +services.thermald.enable = true; +powerManagement.powertop.enable = true; +``` diff --git a/asus/fa506nc/default.nix b/asus/fa506nc/default.nix new file mode 100644 index 00000000..f1228587 --- /dev/null +++ b/asus/fa506nc/default.nix @@ -0,0 +1,32 @@ +{ lib, ... }: + +{ + imports = [ + ../../common/cpu/amd + ../../common/cpu/amd/pstate.nix + ../../common/gpu/amd + ../../common/gpu/nvidia/prime.nix + ../../common/gpu/nvidia/ampere + ../../common/pc/laptop + ../../common/pc/ssd + ]; + + hardware.nvidia = { + dynamicBoost.enable = lib.mkDefault true; + + prime = { + amdgpuBusId = "PCI:5:0:0"; + nvidiaBusId = "PCI:1:0:0"; + }; + }; + + # AMD has better battery life with PPD over TLP: + # https://community.frame.work/t/responded-amd-7040-sleep-states/38101/13 + services.power-profiles-daemon.enable = lib.mkDefault true; + + services = { + # https://asus-linux.org/manual/asusctl-manual/ + asusd.enable = lib.mkDefault true; + supergfxd.enable = lib.mkDefault true; + }; +} diff --git a/flake.nix b/flake.nix index 191e62f5..b2e69669 100644 --- a/flake.nix +++ b/flake.nix @@ -72,6 +72,7 @@ asus-fx504gd = import ./asus/fx504gd; asus-fx506hm = import ./asus/fx506hm; asus-fa506ic = import ./asus/fa506ic; + asus-fa506nc = import ./asus/fa506nc; asus-fa507nv = import ./asus/fa507nv; asus-fa507rm = import ./asus/fa507rm; asus-fa706ic = import ./asus/fa706ic;