Scripts + Services I'm using to set my razer's DPI to the preferred 600 x 600 every time I switch off my work PC and onto my personal PC
Find a file
2025-10-28 13:59:02 -06:00
README.md Update README.md 2025-10-11 20:32:47 -06:00
set-dpi-on-login-after-boot.service Add .service to support set dpi on initial login 2025-10-11 20:27:34 -06:00
set-dpi.sh Add set-dpi.sh 2025-10-11 20:14:46 -06:00
unlock-listener.desktop Add .desktop for systemd 2025-10-11 20:19:54 -06:00
unlock-listener.sh Update unlock-listener.sh 2025-10-28 13:59:02 -06:00

razer-set-dpi

Scripts + Services I'm using to set my razer's DPI to the preferred 600 x 600 every time I switch off my work PC and onto my personal PC

  • set-dpi.sh is the main script; it just handles calls to the log and execution of the razer-cli command.
  • The .desktop is a systemd service that that should be handled by the session itself. This picks up on signals in DBUS that are specific to session unlock (ie you've locked the screen and are now unlocking it) and session resume-after-sleep (ie your machine went to sleep and is now waking)
  • The .service file should run on sesssion initialization, so the very first login

I'm not super knowledgeable about systemd but this seems to have done the trick of correcting the session DPI from every known entry point.