summaryrefslogtreecommitdiffstats
path: root/lass/1systems/xerxes
diff options
context:
space:
mode:
Diffstat (limited to 'lass/1systems/xerxes')
-rw-r--r--lass/1systems/xerxes/config.nix28
-rw-r--r--lass/1systems/xerxes/physical.nix10
2 files changed, 11 insertions, 27 deletions
diff --git a/lass/1systems/xerxes/config.nix b/lass/1systems/xerxes/config.nix
index 2d25bc88a..8630d0f4b 100644
--- a/lass/1systems/xerxes/config.nix
+++ b/lass/1systems/xerxes/config.nix
@@ -28,6 +28,12 @@
export SYSTEM="$1"
$(nix-build $HOME/sync/stockholm/lass/krops.nix --no-out-link --argstr name "$SYSTEM" -A deploy)
'';
+ usb-tether-on = pkgs.writeDash "usb-tether-on" ''
+ adb shell su -c service call connectivity 33 i32 1 s16 text
+ '';
+ usb-tether-off = pkgs.writeDash "usb-tether-off" ''
+ adb shell su -c service call connectivity 33 i32 0 s16 text
+ '';
};
services.xserver = {
@@ -66,26 +72,8 @@
programs.adb.enable = true;
- services.logind.lidSwitch = "ignore";
- services.acpid = {
- enable = true;
- lidEventCommands = ''
- export DISPLAY=:${toString config.services.xserver.display}
- case "$1" in
- "button/lid LID close")
- ${pkgs.xorg.xinput}/bin/xinput disable 'pointer: Mouse for Windows'
- ${pkgs.xorg.xinput}/bin/xinput disable 'keyboard: Mouse for Windows'
- ${pkgs.acpilight}/bin/xbacklight -get > /tmp/pre_lid_brightness
- ${pkgs.acpilight}/bin/xbacklight -set 0
- ;;
- "button/lid LID open")
- ${pkgs.xorg.xinput}/bin/xinput enable 'pointer: Mouse for Windows'
- ${pkgs.xorg.xinput}/bin/xinput enable 'keyboard: Mouse for Windows'
- ${pkgs.acpilight}/bin/xbacklight -set $(cat /tmp/pre_lid_brightness)
- ;;
- esac
- '';
- };
+ services.logind.lidSwitch = "suspend";
+ lass.screenlock.enable = lib.mkForce false;
systemd.services.suspend-again = {
after = [ "suspend.target" ];
diff --git a/lass/1systems/xerxes/physical.nix b/lass/1systems/xerxes/physical.nix
index 5d60dfc45..77cf2206b 100644
--- a/lass/1systems/xerxes/physical.nix
+++ b/lass/1systems/xerxes/physical.nix
@@ -13,9 +13,8 @@
};
boot.loader.efi.canTouchEfiVariables = true;
- # TODO fix touchscreen
boot.blacklistedKernelModules = [
- "goodix"
+ "sdhci_pci"
];
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usbhid" "sd_mod" ];
@@ -46,7 +45,7 @@
swapDevices = [ ];
boot.extraModprobeConfig = ''
- options zfs zfs_arc_max=1073741824
+ options zfs zfs_arc_max=107374182
'';
nix.maxJobs = lib.mkDefault 4;
@@ -74,13 +73,10 @@
services.xserver = {
videoDrivers = [ "intel" ];
- deviceSection = ''
- Option "TearFree" "true"
- '';
displayManager.sessionCommands = ''
echo nonono > /tmp/xxyy
(sleep 2 && ${pkgs.xorg.xrandr}/bin/xrandr --output eDP1 --rotate right)
- (sleep 2 && ${pkgs.xorg.xinput}/bin/xinput set-prop 'Goodix Capacitive TouchScreen' 'Coordinate Transformation Matrix' 0 1 0 -1 0 1 0 0 1)
+ (sleep 2 && ${pkgs.xorg.xinput}/bin/xinput set-prop "pointer:Goodix Capacitive TouchScreen" --type=float "Coordinate Transformation Matrix" 0 1 0 -1 0 1 0 0 1)
'';
};
}