Compare commits
No commits in common. "d374e94b0489cbe63f4cbabd06aabd3ed3babd95" and "ca25ef34645cf01876fc4f0af1d10f46b4d9d9d2" have entirely different histories.
d374e94b04
...
ca25ef3464
18
flake.lock
18
flake.lock
|
@ -267,16 +267,16 @@
|
|||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1729802774,
|
||||
"narHash": "sha256-pssdzH1vOnTWvoGwfy3OfqY2oA6tKAHLGJFm5FeXYCI=",
|
||||
"owner": "8bitbuddhist",
|
||||
"lastModified": 1729143336,
|
||||
"narHash": "sha256-0RtqGBSp9PYpQg/+ZOgJ79ypUt/Sf1dv/ym/xMmyaE0=",
|
||||
"owner": "mexisme",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "52323ec811f4c94b2f32ba1c83d86f0594977dc8",
|
||||
"rev": "5871b0a32ec6bc9420795dcede8c644a5fe0d85d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "8bitbuddhist",
|
||||
"ref": "ms-surface/update-kernel-6.11.4",
|
||||
"owner": "mexisme",
|
||||
"ref": "ms-surface/update-kernel-6.10.10",
|
||||
"repo": "nixos-hardware",
|
||||
"type": "github"
|
||||
}
|
||||
|
@ -331,11 +331,11 @@
|
|||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1729691686,
|
||||
"narHash": "sha256-BAuPWW+9fa1moZTU+jFh+1cUtmsuF8asgzFwejM4wac=",
|
||||
"lastModified": 1729449015,
|
||||
"narHash": "sha256-Gf04dXB0n4q0A9G5nTGH3zuMGr6jtJppqdeljxua1fo=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "32e940c7c420600ef0d1ef396dc63b04ee9cad37",
|
||||
"rev": "89172919243df199fe237ba0f776c3e3e3d72367",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
@ -42,7 +42,7 @@
|
|||
|
||||
# NixOS hardware quirks
|
||||
#nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
||||
nixos-hardware.url = "github:8bitbuddhist/nixos-hardware?ref=ms-surface/update-kernel-6.11.4";
|
||||
nixos-hardware.url = "github:mexisme/nixos-hardware?ref=ms-surface/update-kernel-6.10.10";
|
||||
};
|
||||
|
||||
outputs =
|
||||
|
|
|
@ -13,10 +13,6 @@ let
|
|||
sudo rmmod hid_xpadneo && sudo modprobe hid_xpadneo
|
||||
sudo systemctl restart bluetooth.service
|
||||
'';
|
||||
|
||||
# FIXME: replace with real vendorID and product ID for Victrix Pro BFG controller
|
||||
vendorID = "0e6f";
|
||||
productID = "024b";
|
||||
in
|
||||
{
|
||||
options = {
|
||||
|
@ -36,25 +32,6 @@ in
|
|||
# Enable Xbox controller driver (XPadNeo)
|
||||
hardware.xpadneo.enable = true;
|
||||
|
||||
# Create udev rule to force PDP Victrix controller to use xpadneo
|
||||
# Udev rule taken from https://github.com/atar-axis/xpadneo/blob/master/hid-xpadneo/etc-udev-rules.d/60-xpadneo.rules
|
||||
# Also see https://www.reddit.com/r/linuxquestions/comments/rcx182/why_cant_i_write_to_sysbushiddriversxpadneonew_id/
|
||||
services.udev.extraRules = ''
|
||||
ACTION=="add", ATTRS{id/vendor}==${vendorID}, ATTRS{id/product}==${productID}, RUN+="${pkgs.bash}/bin/bash -c 'echo 0x03 ${vendorID} ${productID} > /sys/bus/hid/drivers/xpadneo/new_id && echo 0x05 ${vendorID} ${productID} > /sys/bus/hid/drivers/xpadneo/new_id'"
|
||||
'';
|
||||
/*
|
||||
services.udev.packages = [
|
||||
(pkgs.writeTextFile {
|
||||
name = "victrix-pro-bfg.rules";
|
||||
executable = true;
|
||||
destination = "/etc/udev/rules.d/70-victrix-pro-bfg.rules";
|
||||
text = ''
|
||||
ACTION=="add", ATTRS{id/vendor}==${vendorID}, ATTRS{id/product}==${productID}, RUN+="${pkgs.bash}/bin/bash -c 'echo 0x03 ${vendorID} ${productID} > /sys/bus/hid/drivers/xpadneo/new_id && echo 0x05 ${vendorID} ${productID} > /sys/bus/hid/drivers/xpadneo/new_id'"
|
||||
'';
|
||||
})
|
||||
];
|
||||
*/
|
||||
|
||||
# Add script to restart xpadneo in case of issues
|
||||
aux.system.packages = [ reset-controllers-script ];
|
||||
|
||||
|
|
Loading…
Reference in a new issue