g920 support on nixdesk
This commit is contained in:
parent
601e875be2
commit
72d057a4c1
2 changed files with 26 additions and 0 deletions
|
|
@ -51,6 +51,7 @@
|
|||
hardware.steam-hardware
|
||||
hardware.bluetooth
|
||||
hardware.qmk
|
||||
hardware.g920
|
||||
|
||||
network.networkd
|
||||
network.avahi
|
||||
|
|
|
|||
25
sys/profiles/hardware/g920.nix
Normal file
25
sys/profiles/hardware/g920.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{pkgs, ...}: {
|
||||
# hardware.usb-modeswitch.enable = true;
|
||||
hardware.xpadneo.enable = true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
oversteer
|
||||
];
|
||||
|
||||
environment.etc = {
|
||||
# Creates /etc/usb_modeswitch.d/046d:c261
|
||||
"usb_modeswitch.d/046d:c261" = {
|
||||
text = ''
|
||||
# Logitech G920 Racing Wheel
|
||||
DefaultVendor=046d
|
||||
DefaultProduct=c261
|
||||
MessageEndpoint=01
|
||||
ResponseEndpoint=01
|
||||
TargetClass=0x03
|
||||
MessageContent="0f00010142"
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
services.udev.extraRules = "ATTR{idVendor}==\"046d\", ATTR{idProduct}==\"c261\", RUN+=\"${pkgs.usb-modeswitch}/bin/usb_modeswitch -c '/etc/usb_modeswitch.d/046d\:c261'\"";
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue