Closed Ao1Pointblank closed 8 months ago
This can somewhat be achieved by assigning a system-wide key-combo in my keyboard settings, and then making piper run that macro.
I don't think there is a better way, sorry. libratbag only configures devices, so we are limited by what device firmware can do.
In theory the only good way to do that would be to send data from the device and listen to it on PC side. If I understand your script right, you are trying to mimic pop-up with new DPI Logitech software for Windows shows when DPI is changed with a button click. I'm now aware of how Logitech mice do it, but on Sinowealth devices when DPI is switched with a button they do send such data. So I think a little program always running in the back listening for such data could be made.
This is currently out of scope of libratbag.
Is your feature request related to a problem? Please describe. On my mouse, Logitech G403, the DPI button is pretty sensitive and can accidentally be pressed in a game, throwing me off. So, I made a script that uses ratbagctl to change the DPI/resolution based on an array stored in the script file. This script displays a notification with osd_cat to let me know I have pressed it by accident. I am contemplating how to make a script that would require the button to be held for a certain time frame before activating it.
Describe the solution you'd like My wish is for .sh or .py scripts to be bound to any mouse key, but in my case just the DPI button.
Describe alternatives you've considered This can somewhat be achieved by assigning a system-wide key-combo in my keyboard settings, and then making piper run that macro. It's not super elegant.
Additional context this is my visual dpi script: (requires
osd_cat
package akaxosd
)