hardware: Add IIO sensor support

Doesn't seem to work yet but shouldn't hurt to add for now.
This commit is contained in:
Donovan Glover 2024-06-20 11:07:26 -04:00
parent 30198aa23d
commit 700f9aa564
No known key found for this signature in database
GPG Key ID: EA7408A77AE1BE65

View File

@ -4,7 +4,7 @@ let
inherit (lib) mkEnableOption mkIf getExe singleton; inherit (lib) mkEnableOption mkIf getExe singleton;
inherit (pkgs) piper interception-tools; inherit (pkgs) piper interception-tools;
inherit (pkgs.interception-tools-plugins) dual-function-keys; inherit (pkgs.interception-tools-plugins) dual-function-keys;
inherit (cfg) mouseSettings disableLaptopKeyboard lidIgnore powerIgnore keyboardBinds bluetooth phone; inherit (cfg) mouseSettings disableLaptopKeyboard lidIgnore powerIgnore keyboardBinds bluetooth phone sensor;
inherit (builtins) toJSON; inherit (builtins) toJSON;
dualFunctionKeysConfig = "dual-function-keys.yaml"; dualFunctionKeysConfig = "dual-function-keys.yaml";
@ -20,10 +20,14 @@ in
lidIgnore = mkEnableOption "ignoring the laptop lid on close"; lidIgnore = mkEnableOption "ignoring the laptop lid on close";
powerIgnore = mkEnableOption "ignoring the power button on press"; powerIgnore = mkEnableOption "ignoring the power button on press";
phone = mkEnableOption "Phone support"; phone = mkEnableOption "Phone support";
sensor = mkEnableOption "IIO sensor";
}; };
config = { config = {
hardware.bluetooth.enable = mkIf bluetooth true; hardware = {
bluetooth.enable = mkIf bluetooth true;
sensor.iio.enable = mkIf sensor true;
};
services = { services = {
ratbagd.enable = mkIf mouseSettings true; ratbagd.enable = mkIf mouseSettings true;