pwr-Solaar / Solaar

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

Small popup issue when loading the system using the G903 and a Powerplay #1930

Closed luisalvarado closed 1 year ago

luisalvarado commented 1 year ago

Information

Linux 5.19.0-26-generic x86_64 GNU/Linux

``` luis@xtreme:~$ solaar show solaar version 1.1.8rc3+git1940-4e7b6b3 USB and Bluetooth Devices 1: G935 Gaming Headset Device path : /dev/hidraw6 USB id : 046d:0A87 Codename : G935 Headset Kind : headset Protocol : HID++ 4.2 Serial number: Model ID: 000000000A87 Unit ID: FFFFFFFF Firmware: U1 29.00.B0012 Supports 9 HID++ 2.0 features: 0: ROOT {0000} V0 1: FEATURE SET {0001} V0 2: DEVICE FW VERSION {0003} V2 Firmware: Firmware U1 29.00.B0012 0A87 Unit ID: FFFFFFFF Model ID: 000000000A87 Transport IDs: {'btid': '0000', 'btleid': '0000'} 3: DEVICE NAME {0005} V0 Name: G935 Gaming Headset Kind: None 4: COLOR LED EFFECTS {8070} V0 5: GKEY {8010} V0 Divert G Keys (saved): False Divert G Keys : False 6: EQUALIZER {8310} V0 7: SIDETONE {8300} V0 Sidetone (saved): 0 Sidetone : 0 8: ADC MEASUREMENT {1F20} V0 Battery status unavailable. Battery status unavailable. Lightspeed Receiver Device path : /dev/hidraw10 USB id : 046d:C53A Serial : 4E4E9946 Firmware : 40.01.B0007 Bootloader : 02.09 Other : AA.CA Has 2 paired device(s) out of a maximum of 1. Notifications: wireless, software present (0x000900) Device activity counters: (empty) 1: G903 LIGHTSPEED Wireless Gaming Mouse w/ HERO Device path : /dev/hidraw13 WPID : 4087 Codename : G903 LS Kind : mouse Protocol : HID++ 4.2 Polling rate : 1 ms (1000Hz) Serial number: 3EF038B9 Model ID: 4087C0910000 Unit ID: 3EF038B9 Bootloader: BL1 06.01.B0013 Firmware: MPM 23.01.B0013 Other: The power switch is located on the base. Supports 31 HID++ 2.0 features: 0: ROOT {0000} V0 1: FEATURE SET {0001} V0 2: DEVICE FW VERSION {0003} V2 Firmware: Bootloader BL1 06.01.B0013 0000047072FE Firmware: Firmware MPM 23.01.B0013 4087047072FE Firmware: Other Unit ID: 3EF038B9 Model ID: 4087C0910000 Transport IDs: {'wpid': '4087', 'usbid': 'C091'} 3: DEVICE NAME {0005} V0 Name: G903 LIGHTSPEED Wireless Gaming Mouse w/ HERO Kind: mouse 4: WIRELESS DEVICE STATUS {1D4B} V0 5: CONFIG CHANGE {0020} V0 6: BATTERY VOLTAGE {1001} V2 Battery: 90% 4079mV , discharging. 7: RGB EFFECTS {8071} V0 8: ONBOARD PROFILES {8100} V0 Device Mode: On-Board Onboard Profiles (saved): Enable Onboard Profiles : Enable 9: MOUSE BUTTON SPY {8110} V0 10: REPORT RATE {8060} V0 Polling Rate (ms): 1 Polling Rate (ms) (saved): 1 Polling Rate (ms) : 1 11: ADJUSTABLE DPI {2201} V1 Sensitivity (DPI) (saved): 6400 Sensitivity (DPI) : 6400 12: DFUCONTROL SIGNED {00C2} V0 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:1811 {1811} V0 internal, hidden 18: unknown:1830 {1830} V0 internal, hidden 19: unknown:1890 {1890} V4 internal, hidden 20: unknown:1891 {1891} V4 internal, hidden 21: unknown:18A1 {18A1} 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:1863 {1863} V0 internal, hidden 28: unknown:1E22 {1E22} V0 internal, hidden 29: 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 30: unknown:18C0 {18C0} V0 internal, hidden Battery: 90% 4079mV , discharging. 7: Candy companion chip Device path : /dev/hidraw14 Codename : Candy Kind : touchpad Protocol : HID++ 4.2 Serial number: 4E4E9946 Model ID: 405F00000000 Unit ID: 34304713 Firmware: CC 07.00.B0010 Bootloader: BOT 32.00.B0010 Supports 12 HID++ 2.0 features: 0: ROOT {0000} V0 1: FEATURE SET {0001} V0 2: DEVICE FW VERSION {0003} V2 Firmware: Firmware CC 07.00.B0010 405F Firmware: Bootloader BOT 32.00.B0010 405F Unit ID: 34304713 Model ID: 405F00000000 Transport IDs: {'wpid': '405F'} 3: DEVICE NAME {0005} V0 Name: Candy companion chip Kind: touchpad 4: unknown:18A1 {18A1} V0 internal, hidden 5: unknown:1E00 {1E00} V0 hidden 6: unknown:1EB0 {1EB0} V0 internal, hidden 7: DFUCONTROL SIGNED {00C2} V0 8: unknown:1801 {1801} V0 internal, hidden 9: DEVICE RESET {1802} V0 internal, hidden 10: unknown:1803 {1803} V0 internal, hidden 11: COLOR LED EFFECTS {8070} V4 Battery status unavailable. ```
``` - 1.1.8rc3+git1940-4e7b6b3 - _NAME: G903 LIGHTSPEED Wireless Gaming Mouse w/ HERO _absent: [hi-res-scroll, lowres-scroll-mode, smart-shift, thumb-scroll-invert, thumb-scroll-mode, pointer_speed, speed-change, backlight, backlight-timed, fn-swap, reprogrammable-keys, persistent-remappable-keys, divert-keys, disable-keyboard-keys, crown-smooth, divert-crown, divert-gkeys, m-key-leds, mr-key-led, multiplatform, change-host, gesture2-gestures, gesture2-divert, gesture2-params, sidetone, equalizer] _battery: 4097 _modelId: 4087C0910000 _sensitive: {hires-smooth-resolution: true} _serial: A9C5F99B _unitId: A9C5F99B _wpid: '4087' dpi: 3200 hires-scroll-mode: false hires-smooth-invert: false hires-smooth-resolution: false onboard_profiles: 1 report_rate: 1 - _NAME: G903 LIGHTSPEED Wireless Gaming Mouse w/ HERO _absent: [hi-res-scroll, lowres-scroll-mode, smart-shift, thumb-scroll-invert, thumb-scroll-mode, pointer_speed, speed-change, backlight, backlight-timed, fn-swap, reprogrammable-keys, persistent-remappable-keys, divert-keys, disable-keyboard-keys, crown-smooth, divert-crown, divert-gkeys, m-key-leds, mr-key-led, multiplatform, change-host, gesture2-gestures, gesture2-divert, gesture2-params, sidetone, equalizer, scroll-ratchet] _battery: 4097 _modelId: 4087C0910000 _sensitive: {hires-smooth-resolution: true} _serial: 3EF038B9 _unitId: 3EF038B9 _wpid: '4087' dpi: 6400 hires-scroll-mode: false hires-smooth-invert: false hires-smooth-resolution: false onboard_profiles: 1 report_rate: 1 - _NAME: Candy companion chip _absent: [hi-res-scroll, lowres-scroll-mode, hires-smooth-invert, hires-smooth-resolution, hires-scroll-mode, smart-shift, thumb-scroll-invert, thumb-scroll-mode, onboard_profiles, report_rate, pointer_speed, dpi, speed-change, backlight, backlight-timed, fn-swap, reprogrammable-keys, persistent-remappable-keys, divert-keys, disable-keyboard-keys, crown-smooth, divert-crown, divert-gkeys, m-key-leds, mr-key-led, multiplatform, change-host, gesture2-gestures, gesture2-divert, gesture2-params, sidetone, equalizer, scroll-ratchet] _battery: 0 _modelId: 405F00000000 _serial: 4E4E9946 _unitId: '34304713' _wpid: 405F - _NAME: G903 Hero Gaming Mouse _absent: [hi-res-scroll, lowres-scroll-mode, smart-shift, thumb-scroll-invert, thumb-scroll-mode, pointer_speed, speed-change, backlight, backlight-timed, fn-swap, reprogrammable-keys, persistent-remappable-keys, divert-keys, disable-keyboard-keys, crown-smooth, divert-crown, divert-gkeys, m-key-leds, mr-key-led, multiplatform, change-host, gesture2-gestures, gesture2-divert, gesture2-params, sidetone, equalizer] _battery: 4097 _modelId: 4087C0910000 _unitId: A9C5F99B dpi: 3200 hires-scroll-mode: false hires-smooth-invert: false hires-smooth-resolution: true onboard_profiles: 1 report_rate: 1 - _NAME: G935 Gaming Headset _absent: [hi-res-scroll, lowres-scroll-mode, hires-smooth-invert, hires-smooth-resolution, hires-scroll-mode, smart-shift, thumb-scroll-invert, thumb-scroll-mode, onboard_profiles, report_rate, pointer_speed, dpi, speed-change, backlight, backlight-timed, fn-swap, reprogrammable-keys, persistent-remappable-keys, divert-keys, disable-keyboard-keys, crown-smooth, divert-crown, m-key-leds, mr-key-led, multiplatform, change-host, gesture2-gestures, gesture2-divert, gesture2-params, equalizer, scroll-ratchet] _battery: 0 _modelId: 000000000A87 _unitId: FFFFFFFF divert-gkeys: false sidetone: 0 - _NAME: Candy companion chip _absent: [hi-res-scroll, lowres-scroll-mode, hires-smooth-invert, hires-smooth-resolution, hires-scroll-mode, smart-shift, thumb-scroll-invert, thumb-scroll-mode, onboard_profiles, report_rate, pointer_speed, dpi, speed-change, backlight, backlight-timed, fn-swap, reprogrammable-keys, persistent-remappable-keys, divert-keys, disable-keyboard-keys, crown-smooth, divert-crown, divert-gkeys, m-key-leds, mr-key-led, multiplatform, change-host, gesture2-gestures, gesture2-divert, gesture2-params, sidetone, equalizer] _battery: 0 _modelId: 405F00000000 _serial: 981F96BE _unitId: 3031470A _wpid: 405F ```

Describe the bug A clear and concise description of what the bug is.

A popup shows whenever I reboot the computer that says:

A receiver dev/hidraw2 but did not have permission to open it

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Screenshots If applicable, add screenshots to help explain your problem.

This is the popup

image

This is the menu with the Logitech Powerplay. Even though I can connect the G903 to its own Receiver, the powerplay also offers the option of connecting the G903 to it so I can save one usb slot on the PC, meaning I can connect the G903 to the Powerplay receiver and both would use the same usb connection.

image

This is how it looks connected directly to the Powerplay receiver:

image

Also, it confused me when I saw Candy instead of Logitech Powerplay

Additional context Add any other context about the problem here.

pfps commented 1 year ago

The popup is created when Solaar finds a device that it thinks it should connect to but it can't open the /dev/hidrawN file for it.

There are several potential causes but the most likely one is that Solaar is running at a time when permissions are not correctly set up for the /dev/hidrawN node (shown in the output of solaar show) for the headset. Run ls -l /dev/hidraw* and look to see whether there is a + on the line for the headset. If there is no + there, then something weird is going on. Try disconnecting and reconnecting the headset. If this works then the above cause almost certainly the correct one. Terminate Solaar and start it up again. If it works correctly then the above cause is even more likely the correct one.

The solution is then likely to be to start up Solaar a bit later. I don't know how you have Solaar starting up but it is best to only start Solaar after user login and after window system start.

The Logitech PowerPlay is a strange device. As far as Solaar can see, it is a Lightspeed Receiver plus the Candy touchpad. Logitech software may provide a different name for the device's parts but Solaar is using what the parts identify themselves as. The Candy touchpad is also connected to the receiver using an unusual device number.

luisalvarado commented 1 year ago

The popup is created when Solaar finds a device that it thinks it should connect to but it can't open the /dev/hidrawN file for it.

There are several potential causes but the most likely one is that Solaar is running at a time when permissions are not correctly set up for the /dev/hidrawN node (shown in the output of solaar show) for the headset. Run ls -l /dev/hidraw* and look to see whether there is a + on the line for the headset. If there is no + there, then something weird is going on. Try disconnecting and reconnecting the headset. If this works then the above cause almost certainly the correct one. Terminate Solaar and start it up again. If it works correctly then the above cause is even more likely the correct one.

The solution is then likely to be to start up Solaar a bit later. I don't know how you have Solaar starting up but it is best to only start Solaar after user login and after window system start.

The Logitech PowerPlay is a strange device. As far as Solaar can see, it is a Lightspeed Receiver plus the Candy touchpad. Logitech software may provide a different name for the device's parts but Solaar is using what the parts identify themselves as. The Candy touchpad is also connected to the receiver using an unusual device number.

Thank you so much for a thorough reply. Here is the image about the hidraw devices

image

So yes, it has a + sign

luisalvarado commented 1 year ago

I followed your advice, so on the startup application app I did the following:

bash -c "sleep 2 && solaar --window=hide"

And now it does not show. Thank you friend.

pfps commented 1 year ago

How do you start up Solaar?

luisalvarado commented 1 year ago

You type start in the gnome search and get the startup application (I know we can do it with run and rc and etc... but I am lazy:

image

Then you select solaar here:

image

Lastly just edit the code. I had to push it to 5 seconds this time:

image

luisalvarado commented 1 year ago

This is still a bug, like, maybe an option that does not show the popup until X amount of retries during a certain amount of time. Instead of failing on the first one would help.

pfps commented 1 year ago

I've never seen this problem before. It may be related to how Gnome or Wayland does things. But it does seem worthwhile to retry and only complain if the retries fail.

pfps commented 1 year ago

PR #1933 should fix your problem. It retries opening devices when there are permissions errors after several seconds.

To clone and use Solar from its GitHub repository

git clone https://github.com/pwr-Solaar/Solaar.git
cd Solaar

Run Solaar as bin/solaar from this directory.

To run PR #1933, first clone Solaar if you have not already done so and cd to the clone directory. The first time you download the pull request, fetch it into a new branch and checkout that branch, as in:

git fetch origin pull/1933/head:pull_1933
git checkout pull_1933

To download a new version of the pull request, fetch it and then set your pull branch to the new fetch, as in:

git checkout pull_1933
git fetch origin pull/1933/head
git reset --hard FETCH_HEAD
luisalvarado commented 1 year ago

Awesome sauce, let me test tomorrow (I am super sick) But amazing work buddy,