Add joystick offset
This commit is contained in:
parent
370b500cbc
commit
87fecccad4
2 changed files with 21 additions and 2 deletions
|
@ -32,6 +32,8 @@ in
|
||||||
pkgs.dbus
|
pkgs.dbus
|
||||||
pkgs.xdg-utils
|
pkgs.xdg-utils
|
||||||
pkgs.spamassassin
|
pkgs.spamassassin
|
||||||
|
#pkgs.docker
|
||||||
|
pkgs.linuxConsoleTools
|
||||||
];
|
];
|
||||||
|
|
||||||
# enable spamd
|
# enable spamd
|
||||||
|
@ -188,7 +190,9 @@ in
|
||||||
# enable more codecs
|
# enable more codecs
|
||||||
hardware.bluetooth.settings = {
|
hardware.bluetooth.settings = {
|
||||||
General = {
|
General = {
|
||||||
Enable = "Source,Sink,Media,Socket";
|
Enable = "Source,Sink,Media";
|
||||||
|
Disable = "Socket";
|
||||||
|
MultiProfile= "multiple";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
hardware.pulseaudio = {
|
hardware.pulseaudio = {
|
||||||
|
@ -207,4 +211,20 @@ in
|
||||||
|
|
||||||
# fix Steam glXChooseVisual failed
|
# fix Steam glXChooseVisual failed
|
||||||
hardware.opengl.driSupport32Bit = true;
|
hardware.opengl.driSupport32Bit = true;
|
||||||
|
|
||||||
|
# "fix" broken gamepad
|
||||||
|
#services.cron = {
|
||||||
|
# enable = true;
|
||||||
|
# systemCronJobs = [
|
||||||
|
# "* * * * * root evdev-joystick --e /dev/input/by-id/usb-ShanWan_Xbox360_For_Windows_10F36D6-event-joystick --minimum -32767 --maximum 0 --a 3; evdev-joystick --e /dev/input/by-id/usb-ShanWan_Xbox360_For_Windows_10F36D6-event-joystick --minimum 0 --maximum 32767 --a 4"
|
||||||
|
# ];
|
||||||
|
#};
|
||||||
|
|
||||||
|
systemd.services.fix-gamepad = {
|
||||||
|
enable = true;
|
||||||
|
unitConfig.Type = "simple";
|
||||||
|
description = "fix the gamepad by adding offset to the right stick";
|
||||||
|
serviceConfig.ExecStart = "/run/current-system/sw/bin/bash -c 'while true; do /run/current-system/sw/bin/evdev-joystick --e /dev/input/by-id/usb-ShanWan_Xbox360_For_Windows_10F36D6-event-joystick --minimum -32767 --maximum 0 --a 3; /run/current-system/sw/bin/evdev-joystick --e /dev/input/by-id/usb-ShanWan_Xbox360_For_Windows_10F36D6-event-joystick --minimum 0 --maximum 32767 --a 4; sleep 5; done'";
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,7 +42,6 @@ in
|
||||||
pkgs.python312
|
pkgs.python312
|
||||||
pkgs.blueman
|
pkgs.blueman
|
||||||
pkgs.dnsutils
|
pkgs.dnsutils
|
||||||
pkgs.docker
|
|
||||||
pkgs.gnome.gnome-keyring
|
pkgs.gnome.gnome-keyring
|
||||||
pkgs.pandoc
|
pkgs.pandoc
|
||||||
pkgs.cinny-desktop
|
pkgs.cinny-desktop
|
||||||
|
|
Loading…
Reference in a new issue