pwr-Solaar / Solaar

Linux device manager for Logitech devices
https://pwr-solaar.github.io/Solaar
GNU General Public License v2.0
5.45k stars 404 forks source link

Turning off high scroll wheel resolution on g shift #2495

Closed ghost closed 5 months ago

ghost commented 5 months ago

Information

``` Lightspeed Receiver Device path : /dev/hidraw4 USB id : 046d:C539 Serial : 771BE0ED Firmware : 39.06.B0040 Bootloader : 02.09 Other : AA.BE Has 1 paired device(s) out of a maximum of 1. Notifications: wireless, software present (0x000900) Device activity counters: (empty) 1: G604 Device path : /dev/hidraw5 WPID : 4085 Codename : G604 Kind : mouse Protocol : unknown (device is offline) Report Rate : 8msms Serial number: D85A7960 The power switch is located on the base. Battery: unknown (device is offline). G604 Wireless Gaming Mouse Device path : /dev/hidraw6 USB id : 046d:B024 Codename : G604 Kind : mouse Protocol : HID++ 4.2 Report Rate : 1ms Serial number: Model ID: B02440850000 Unit ID: D85A7960 Bootloader: BL1 04.01.B0014 Firmware: MPM 21.01.B0014 Other: Supports 32 HID++ 2.0 features: 0: ROOT {0000} V0 1: FEATURE SET {0001} V0 2: DEVICE FW VERSION {0003} V2 Firmware: Bootloader BL1 04.01.B0014 0000B01B3067 Firmware: Firmware MPM 21.01.B0014 B024B01B3067 Firmware: Other Unit ID: D85A7960 Model ID: B02440850000 Transport IDs: {'btleid': 'B024', 'wpid': '4085'} 3: DEVICE NAME {0005} V0 Name: G604 Wireless Gaming Mouse Kind: mouse 4: WIRELESS DEVICE STATUS {1D4B} V0 5: CONFIG CHANGE {0020} V0 6: BATTERY STATUS {1000} V0 Battery: 90%, discharging, next level 50%. 7: COLOR LED EFFECTS {8070} V4 LED Control (saved): Device LED Control : Device LEDs Primary : None 8: LED CONTROL {1300} V0 9: ONBOARD PROFILES {8100} V0 Device Mode: On-Board Onboard Profiles (saved): Profile 1 Onboard Profiles : Profile 1 10: MOUSE BUTTON SPY {8110} V0 11: REPORT RATE {8060} V0 Report Rate: 1ms Report Rate (saved): 1ms Report Rate : 1ms 12: ADJUSTABLE DPI {2201} V1 Sensitivity (DPI) (saved): 2000 Sensitivity (DPI) : 2000 13: DEVICE RESET {1802} V0 internal, hidden 14: unknown:1803 {1803} V0 internal, hidden 15: OOBSTATE {1805} V0 internal, hidden 16: CONFIG DEVICE PROPS {1806} V4 internal, hidden 17: unknown:1813 {1813} V0 internal, hidden 18: unknown:1830 {1830} V0 internal, hidden 19: unknown:1890 {1890} V5 internal, hidden 20: unknown:1891 {1891} V5 internal, hidden 21: unknown:1861 {1861} V0 internal, hidden 22: unknown:1801 {1801} V0 internal, hidden 23: unknown:18B1 {18B1} V0 internal, hidden 24: unknown:1DF3 {1DF3} V0 internal, hidden 25: unknown:1E00 {1E00} V0 hidden 26: unknown:1EB0 {1EB0} V0 internal, hidden 27: unknown:1E22 {1E22} V0 internal, hidden 28: HIRES WHEEL {2121} V0 Multiplier: 8 Has invert: Normal wheel motion Has ratchet switch: Normal wheel mode Low resolution mode HID notification Scroll Wheel Direction (saved): False Scroll Wheel Direction : False Scroll Wheel Resolution (saved): False Scroll Wheel Resolution : False Scroll Wheel Diversion (saved): False Scroll Wheel Diversion : False 29: unknown:18C0 {18C0} V0 internal, hidden 30: CHANGE HOST {1814} V1 Change Host : 2:localhost 31: HOSTS INFO {1815} V1 Host 0 (unpaired): localhost Host 1 (paired): localhost Battery: 90%, discharging, next level 50%. ```

Is your feature request related to a problem? Please describe. I use a Logitech G604 and have it configured such that holding the g-key turns the scroll wheel into a volume wheel. This seems to be working on Linux, however, I have run into issues with the hi-res functionality. Turning it off creates "hiccups", where the first few scrolls don't go through but get stacked onto the fourth scroll (interestingly, this only happens when using the LIGHTSPEED receiver, and not when using the mouse via Bluetooth). Turning it on does produce smoother scrolling, but makes the volume change way too fast. Ignoring it produces the same effects as keeping the hi-res on.

Describe the solution you'd like Ideally, I would like to be able to have my mouse wheel be on high resolution normally, but somehow turn off when I press the g shift key. Alternatively, I would like to get rid of that "hiccup" I described.

Describe alternatives you've considered I considered accomplishing this via rules, but nothing I make seems to work, even after manually installing the udev rule as per the documentation.

Additional context Add any other context or screenshots about the feature request here.

pfps commented 5 months ago

How are you turning the scroll wheel into a volume wheel? This will likely impact any way of solving your problem.

There may also be an interaction with the Linux HID++ driver, provided that your mouse is recognized by the smooth scrolling code in it. (The coverage of this code has changed several times over the last year or so.)

ghost commented 5 months ago

Apologies. I have my scroll up and scroll down functions set to be g-shifted to volume up and volume down, respectively. I am mostly sure that my problem stems from the fact that the hi-res wheel sends many more, smaller scroll events, which translates to many more, same-size volume changes when I press the g-shift button.

I've seen people with similar issues say to blacklist the hid-logitech-hidpp driver, but this has done nothing for me unfortunately. The hiccup remains, but only when using the lightspeed receiver with hi-res off.

pfps commented 5 months ago

How do you have your "scroll up and scroll down functions set to be g-shifted to volume up and volume down, respectively."?

ghost commented 5 months ago

They are reprogrammed onto the mouse. I used the Onboard Memory Manager a long time ago on Windows to save it directly to the mouse.

pfps commented 5 months ago

If you set your wheel to low-res mode then vertical scrolling is likely to be very slow. The HID++ driver implements smooth scrolling by counting scrolls and only creating a regular scroll event for every 8 (for this this mouse) scroll events, as high-res scrolling emits 8 (for this mouse) times as many scrolls. If the driver is not loaded then this multiplication and division does not happen.

ghost commented 5 months ago

If you set your wheel to low-res mode then vertical scrolling is likely to be very slow. The HID++ driver implements smooth scrolling by counting scrolls and only creating a regular scroll event for every 8 (for this this mouse) scroll events, as high-res scrolling emits 8 (for this mouse) times as many scrolls. If the driver is not loaded then this multiplication and division does not happen.

That doesn't seem to explain why, at low-res, it seems to ignore the first three notches of the physical wheel (where each notch, I'm guessing, would be 8 hi-res events). This happened before and after unloading the hid-logitech-hidpp driver.

pfps commented 5 months ago

Aaah, some sort of onboard profile stuff. Solaar should understand this. Can you run solaar profiles 'G604 Wireless Gaming Mouse' and post the output?

ghost commented 5 months ago

Here you go:

#Dumping profiles from G604 Wireless Gaming Mouse
!OnboardProfiles
buttons: 0x10
count: 0x5
gbuttons: 0x10
name: G604 Wireless Gaming Mouse
profiles:
  0x1: !OnboardProfile
    angle_snap: 0x0
    blue: 0xff
    buttons:
    - !Button {behavior: 8, type: 1, value: 1}
    - !Button {behavior: 8, type: 1, value: 2}
    - !Button {behavior: 8, type: 1, value: 4}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 224}
    - !Button {behavior: 8, type: 1, value: 8}
    - !Button {behavior: 8, type: 1, value: 16}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 225}
    - !Button {behavior: 9, data: 0xff, value: 11}
    - !Button {behavior: 8, modifiers: 0x1, type: 2, value: 28}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 227}
    - !Button {behavior: 8, modifiers: 0x21, type: 2, value: 15}
    - !Button {behavior: 9, data: 0xff, value: 1}
    - !Button {behavior: 9, data: 0xff, value: 2}
    - !Button {behavior: 9, data: 0xff, value: 16}
    - !Button {behavior: 9, data: 0xff, value: 17}
    - !Button {behavior: 9, data: 0xff, value: 0}
    enabled: 0x1
    gbuttons:
    - !Button {behavior: 8, type: 3, value: 3277}
    - !Button {behavior: 8, type: 3, value: 3298}
    - !Button {behavior: 9, data: 0xff, value: 0}
    - !Button {behavior: 9, data: 0xff, value: 10}
    - !Button {behavior: 9, data: 0xff, value: 0}
    - !Button {behavior: 9, data: 0xff, value: 0}
    - !Button {behavior: 9, data: 0xff, value: 0}
    - !Button {behavior: 9, data: 0xff, value: 11}
    - !Button {behavior: 8, modifiers: 0x3, type: 2, value: 16}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 41}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 9}
    - !Button {behavior: 8, type: 3, value: 3254}
    - !Button {behavior: 8, type: 3, value: 3253}
    - !Button {behavior: 8, type: 3, value: 3306}
    - !Button {behavior: 8, type: 3, value: 3305}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 11}
    green: 0xff
    lighting:
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    name: PROFILE_NAME_DEFAULT
    po_timeout: 0xffff
    power_mode: 0xff
    ps_timeout: 0xffff
    red: 0xff
    report_rate: 0x1
    reserved: !!binary |
      //////////8=
    resolution_default_index: 0x0
    resolution_shift_index: 0x0
    resolutions:
    - 0x7d0
    - 0x0
    - 0x0
    - 0x0
    - 0x0
    sector: 0x1
    write_count: 0xffff
  0x2: !OnboardProfile
    angle_snap: 0x0
    blue: 0xff
    buttons:
    - !Button {behavior: 8, type: 1, value: 1}
    - !Button {behavior: 8, type: 1, value: 2}
    - !Button {behavior: 8, type: 1, value: 4}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 92}
    - !Button {behavior: 8, type: 1, value: 8}
    - !Button {behavior: 8, type: 1, value: 16}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 95}
    - !Button {behavior: 9, data: 0x0, value: 11}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 97}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 86}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 87}
    - !Button {behavior: 9, data: 0x0, value: 1}
    - !Button {behavior: 9, data: 0x0, value: 2}
    - !Button {behavior: 9, data: 0x0, value: 16}
    - !Button {behavior: 9, data: 0x0, value: 17}
    - !Button {behavior: 9, data: 0x0, value: 0}
    enabled: 0x1
    gbuttons:
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 47}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 48}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 51}
    - !Button {behavior: 9, data: 0xff, value: 10}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 62}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 63}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 64}
    - !Button {behavior: 9, data: 0xff, value: 11}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 66}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 84}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 85}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 80}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 79}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 81}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 82}
    - !Button {behavior: 9, data: 0xff, value: 0}
    green: 0xff
    lighting:
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    name: PROFILE_NAME_DEFAULT
    po_timeout: 0xffff
    power_mode: 0xff
    ps_timeout: 0xffff
    red: 0xff
    report_rate: 0x1
    reserved: !!binary |
      //////////8=
    resolution_default_index: 0x0
    resolution_shift_index: 0x0
    resolutions:
    - 0x834
    - 0x0
    - 0x0
    - 0x0
    - 0x0
    sector: 0x2
    write_count: 0xffff
  0x3: !OnboardProfile
    angle_snap: 0x0
    blue: 0xff
    buttons:
    - !Button {behavior: 8, type: 1, value: 1}
    - !Button {behavior: 8, type: 1, value: 2}
    - !Button {behavior: 8, type: 1, value: 4}
    - !Button {behavior: 9, data: 0x0, value: 7}
    - !Button {behavior: 8, type: 1, value: 8}
    - !Button {behavior: 8, type: 1, value: 16}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 32}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 31}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 30}
    - !Button {behavior: 9, data: 0x0, value: 4}
    - !Button {behavior: 9, data: 0x0, value: 3}
    - !Button {behavior: 9, data: 0x0, value: 1}
    - !Button {behavior: 9, data: 0x0, value: 2}
    - !Button {behavior: 9, data: 0x0, value: 16}
    - !Button {behavior: 9, data: 0x0, value: 17}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    enabled: 0x0
    gbuttons:
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    green: 0xff
    lighting:
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    name: ''
    po_timeout: 0xffff
    power_mode: 0xff
    ps_timeout: 0xffff
    red: 0xff
    report_rate: 0x1
    reserved: !!binary |
      //////////8=
    resolution_default_index: 0x1
    resolution_shift_index: 0x0
    resolutions:
    - 0x190
    - 0x320
    - 0x640
    - 0xc80
    - 0x0
    sector: 0x3
    write_count: 0xffff
  0x4: !OnboardProfile
    angle_snap: 0x0
    blue: 0xff
    buttons:
    - !Button {behavior: 8, type: 1, value: 1}
    - !Button {behavior: 8, type: 1, value: 2}
    - !Button {behavior: 8, type: 1, value: 4}
    - !Button {behavior: 9, data: 0x0, value: 7}
    - !Button {behavior: 8, type: 1, value: 8}
    - !Button {behavior: 8, type: 1, value: 16}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 32}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 31}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 30}
    - !Button {behavior: 9, data: 0x0, value: 4}
    - !Button {behavior: 9, data: 0x0, value: 3}
    - !Button {behavior: 9, data: 0x0, value: 1}
    - !Button {behavior: 9, data: 0x0, value: 2}
    - !Button {behavior: 9, data: 0x0, value: 16}
    - !Button {behavior: 9, data: 0x0, value: 17}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    enabled: 0x0
    gbuttons:
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    green: 0xff
    lighting:
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    name: ''
    po_timeout: 0xffff
    power_mode: 0xff
    ps_timeout: 0xffff
    red: 0xff
    report_rate: 0x1
    reserved: !!binary |
      //////////8=
    resolution_default_index: 0x1
    resolution_shift_index: 0x0
    resolutions:
    - 0x190
    - 0x320
    - 0x640
    - 0xc80
    - 0x0
    sector: 0x4
    write_count: 0xffff
  0x5: !OnboardProfile
    angle_snap: 0x0
    blue: 0xff
    buttons:
    - !Button {behavior: 8, type: 1, value: 1}
    - !Button {behavior: 8, type: 1, value: 2}
    - !Button {behavior: 8, type: 1, value: 4}
    - !Button {behavior: 9, data: 0x0, value: 7}
    - !Button {behavior: 8, type: 1, value: 8}
    - !Button {behavior: 8, type: 1, value: 16}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 32}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 31}
    - !Button {behavior: 8, modifiers: 0x0, type: 2, value: 30}
    - !Button {behavior: 9, data: 0x0, value: 4}
    - !Button {behavior: 9, data: 0x0, value: 3}
    - !Button {behavior: 9, data: 0x0, value: 1}
    - !Button {behavior: 9, data: 0x0, value: 2}
    - !Button {behavior: 9, data: 0x0, value: 16}
    - !Button {behavior: 9, data: 0x0, value: 17}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    enabled: 0x0
    gbuttons:
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    - !Button {behavior: 0xf, bytes: !!binary "/////w==\n"}
    green: 0xff
    lighting:
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: 0}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    - !LEDEffectSetting {ID: null, bytes: !!binary "//////////////8=\n"}
    name: ''
    po_timeout: 0xffff
    power_mode: 0xff
    ps_timeout: 0xffff
    red: 0xff
    report_rate: 0x1
    reserved: !!binary |
      //////////8=
    resolution_default_index: 0x1
    resolution_shift_index: 0x0
    resolutions:
    - 0x190
    - 0x320
    - 0x640
    - 0xc80
    - 0x0
    sector: 0x5
    write_count: 0xffff
sectors: 0x10
size: 0xff
version: 0x3
pfps commented 5 months ago

What you may need to do is to capture the input events that Linux sees. evtest is probably the best tool for this.

ghost commented 5 months ago

Ah, yes. Here you can see the "hiccupping", on low-res, lightspeed, where an extra command seems to be sent every four physical notches:

Event: time 1716506303.751302, -------------- SYN_REPORT ------------
Event: time 1716506304.794479, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506304.794479, -------------- SYN_REPORT ------------
Event: time 1716506305.794473, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506305.794473, -------------- SYN_REPORT ------------
Event: time 1716506306.527473, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506306.527473, -------------- SYN_REPORT ------------
Event: time 1716506307.032477, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506307.032477, type 2 (EV_REL), code 8 (REL_WHEEL), value 1
Event: time 1716506307.032477, -------------- SYN_REPORT ------------
Event: time 1716506308.129483, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506308.129483, -------------- SYN_REPORT ------------
Event: time 1716506308.708475, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506308.708475, -------------- SYN_REPORT ------------
Event: time 1716506309.172483, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506309.172483, -------------- SYN_REPORT ------------
Event: time 1716506309.599480, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506309.599480, type 2 (EV_REL), code 8 (REL_WHEEL), value 1
Event: time 1716506309.599480, -------------- SYN_REPORT ------------
Event: time 1716506310.589478, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506310.589478, -------------- SYN_REPORT ------------
Event: time 1716506311.048476, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506311.048476, -------------- SYN_REPORT ------------
Event: time 1716506311.529477, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506311.529477, -------------- SYN_REPORT ------------
Event: time 1716506311.946340, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506311.946340, -------------- SYN_REPORT ------------
Event: time 1716506313.330478, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506313.330478, -------------- SYN_REPORT ------------
Event: time 1716506313.762471, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506313.762471, -------------- SYN_REPORT ------------
Event: time 1716506314.183480, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506314.183480, -------------- SYN_REPORT ------------
Event: time 1716506314.599476, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506314.599476, type 2 (EV_REL), code 8 (REL_WHEEL), value 1
Event: time 1716506314.599476, -------------- SYN_REPORT ------------

And here with lightspeed, hi-res, where the code 8 ones happen at every physical notch, with hi-res ones being sent between physical notches:

Event: time 1716506436.697489, -------------- SYN_REPORT ------------
Event: time 1716506436.708378, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506436.708378, -------------- SYN_REPORT ------------
Event: time 1716506436.717474, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506436.717474, -------------- SYN_REPORT ------------
Event: time 1716506436.727490, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506436.727490, -------------- SYN_REPORT ------------
Event: time 1716506436.740334, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506436.740334, -------------- SYN_REPORT ------------
Event: time 1716506436.944490, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506436.944490, -------------- SYN_REPORT ------------
Event: time 1716506437.088493, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506437.088493, -------------- SYN_REPORT ------------
Event: time 1716506437.516489, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506437.516489, -------------- SYN_REPORT ------------
Event: time 1716506437.551319, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506437.551319, type 2 (EV_REL), code 8 (REL_WHEEL), value 1
Event: time 1716506437.551319, -------------- SYN_REPORT ------------
Event: time 1716506437.560490, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506437.560490, -------------- SYN_REPORT ------------
Event: time 1716506437.568348, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506437.568348, -------------- SYN_REPORT ------------
Event: time 1716506437.578352, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506437.578352, -------------- SYN_REPORT ------------
Event: time 1716506437.596277, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506437.596277, -------------- SYN_REPORT ------------
Event: time 1716506438.577492, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506438.577492, -------------- SYN_REPORT ------------
Event: time 1716506438.687517, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506438.687517, -------------- SYN_REPORT ------------
Event: time 1716506439.199485, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506439.199485, -------------- SYN_REPORT ------------
Event: time 1716506439.226466, type 2 (EV_REL), code 11 (REL_WHEEL_HI_RES), value 15
Event: time 1716506439.226466, type 2 (EV_REL), code 8 (REL_WHEEL), value 1
ghost commented 5 months ago

On the low-res setting, it seems that it ignores the hi-res codes, and only pays attention to the low-res ones, and since the low-res ones start AFTER the hi-res ones, there's a wait at the beginning. However, it seems to start paying attention to the hi-res codes once it sees that first low-res code. Again, on the low-res setting, the hi-res codes are sent at every physical notch, whereas, on the hi-res setting, as you suggested, 8 hi-res codes are sent per physical notch.

ghost commented 5 months ago

When I use Bluetooth (which is considered a separate mouse), code 8s are sent with every code 11 -- just 8x as many are sent when hi-res is on.

pfps commented 5 months ago

This looks like a problem with the HID++ driver, or maybe multiple problems. Somehow the driver recognizes the device as a hi-res device when connected via the receiver but not when connected.

The one-every-four behaviour may have some different cause.

To get this fixed you'll have to submit a bug against the driver.

pfps commented 5 months ago

I don't think that there is anything that can be done to make what you want work perfectly. The problem is that any rule, or indeed any external processing, will take some time and the first few scroll events may still be in high resolution.

ghost commented 5 months ago

This looks like a problem with the HID++ driver, or maybe multiple problems. Somehow the driver recognizes the device as a hi-res device when connected via the receiver but not when connected.

The one-every-four behaviour may have some different cause.

To get this fixed you'll have to submit a bug against the driver.

Yeah, I'm seeing that now...

I don't think that there is anything that can be done to make what you want work perfectly. The problem is that any rule, or indeed any external processing, will take some time and the first few scroll events may still be in high resolution.

For now, I'll stick to using my mouse on Bluetooth as a workaround, as that works well enough for me. Not being able to use Lightspeed as I want to bugs me, but I'll come back to it later. I also can't seem to get any rule to work, but that's another problem (I'm on Wayland, and I installed the udev rule but I'm not sure if I can do anything... but I can't think of any test I can do that I'm sure should work).