Skip to content

Adds support for a new G PRO X2 variant#478

Open
ChrisLauinger77 wants to merge 1 commit intoSapd:masterfrom
ChrisLauinger77:dev
Open

Adds support for a new G PRO X2 variant#478
ChrisLauinger77 wants to merge 1 commit intoSapd:masterfrom
ChrisLauinger77:dev

Conversation

@ChrisLauinger77
Copy link
Contributor

Adds a new device ID for a previously unsupported variant
of the Logitech G PRO X2.

Adds a new device ID for a previously unsupported variant
of the Logitech G PRO X2.
@ChrisLauinger77
Copy link
Contributor Author

I added the deviceID as described and compiled it.
The battery does not work - I think I need help - how to proceed further ?

{
  "name": "HeadsetControl",
  "version": "continuous-19-gb627b4b-modified",
  "api_version": "1.4",
  "hidapi_version": "0.14.0",
  "device_count": 1,
  "devices": [
    {
      "status": "partial",
      "device": "Logitech G PRO Series",
      "vendor": "Logitech",
      "product": "PRO X 2 LIGHTSPEED",
      "id_vendor": "0x046d",
      "id_product": "0x0af7",
      "capabilities": [
        "CAP_SIDETONE",
        "CAP_BATTERY_STATUS",
        "CAP_INACTIVE_TIME"
      ],
      "capabilities_str": [
        "sidetone",
        "battery",
        "inactive time"
      ],
      "battery": {
        "status": "BATTERY_UNAVAILABLE",
        "level": -1
      },
      "errors": {
        "battery": "Could not open device"
      }
    }
  ]
}```

@ChrisLauinger77
Copy link
Contributor Author

after reboot - it times even out ....
"battery": "Operation timed out

@Sapd
Copy link
Owner

Sapd commented Jan 30, 2026

No other way but to capture the packets the original software sends using wireshark

@ChrisLauinger77
Copy link
Contributor Author

No other way but to capture the packets the original software sends using wireshark

Does it really need to be wireshark on windows ? I have a macbook ...

@Sapd
Copy link
Owner

Sapd commented Jan 30, 2026

No other way but to capture the packets the original software sends using wireshark

Does it really need to be wireshark on windows ? I have a macbook ...

When I remember it right on a Mac it was difficult because of the kernel protections. Best thing there is to use a virtual machine with windows and pass through the usb device to it

@ChrisLauinger77
Copy link
Contributor Author

No other way but to capture the packets the original software sends using wireshark

Does it really need to be wireshark on windows ? I have a macbook ...

When I remember it right on a Mac it was difficult because of the kernel protections. Best thing there is to use a virtual machine with windows and pass through the usb device to it

Alright - VM it is then

@ChrisLauinger77
Copy link
Contributor Author

ChrisLauinger77 commented Jan 30, 2026

Sidetone 0
sidetone0
Sidetone Full (100)
sidetone100

So I could reproduce the screenshots from the guide. Its a start.
No clue about the battery though :(

@ChrisLauinger77
Copy link
Contributor Author

Equalizer seem to be supported, too.
equalizer_ui
changed equalizer in GUI:
equalizer

@ChrisLauinger77
Copy link
Contributor Author

wireshark.zip

@Sapd
Copy link
Owner

Sapd commented Jan 30, 2026

wireshark.zip

Try again:

  • close the driver software completly
  • replug the usb stick
  • start capturing
  • start the driver software now
  • keep it open for some while (min 10 min) and also click around

@ChrisLauinger77
Copy link
Contributor Author

wireshark.zip

better ?

@ChrisLauinger77
Copy link
Contributor Author

maybe also valueable info:

headsetcontrol --dev -- --list

Device Found
  VendorID:  0x046d
  ProductID: 0x0af7
  Path: /dev/hidraw3
  Serial: 0000000000000000
  Manufacturer: Logitech
  Product: PRO X 2 LIGHTSPEED
  Interface: 3
  Usage-Page: 0x000c  Usage-ID: 0x0001

Device Found
  VendorID:  0x046d
  ProductID: 0x0af7
  Path: /dev/hidraw3
  Serial: 0000000000000000
  Manufacturer: Logitech
  Product: PRO X 2 LIGHTSPEED
  Interface: 3
  Usage-Page: 0xff13  Usage-ID: 0x0001

Device Found
  VendorID:  0x046d
  ProductID: 0x0af7
  Path: /dev/hidraw3
  Serial: 0000000000000000
  Manufacturer: Logitech
  Product: PRO X 2 LIGHTSPEED
  Interface: 3
  Usage-Page: 0xffa0  Usage-ID: 0x0001

@Sapd
Copy link
Owner

Sapd commented Jan 30, 2026

@ChrisLauinger77 do you know at which battery percentage you were on your latest capture? and was it loading or discharging?

@ChrisLauinger77
Copy link
Contributor Author

52% not plugged in. So discharging

@Sapd
Copy link
Owner

Sapd commented Jan 30, 2026

Not 100% sure but could be

headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive

The response should be then:

0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00
                                                          ^--- that could be the battery

@ChrisLauinger77
Copy link
Contributor Author

ChrisLauinger77 commented Jan 31, 2026

headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive

0x51 0x03 0x00 0x03 0x1e 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 

@ChrisLauinger77
Copy link
Contributor Author

made a capture during charging - saw also in UI that it went from 52% to 54%
wireshark.zip

@Sapd
Copy link
Owner

Sapd commented Jan 31, 2026

Cant really see the battery status in there, is interrupt IN included too?

You can also try
headsetcontrol --dev -- --receive

repeadtly

@ChrisLauinger77
Copy link
Contributor Author

headsetcontrol --dev -- --receive
You must supply --device VENDORID:PRODUCTID for send/receive operations
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 
christian@debian:~$ headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
  0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
0x51 0x05 0x00 0xff 0x03 0x1e 0x0b 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 

@Sapd
Copy link
Owner

Sapd commented Feb 3, 2026

Looked into it but cannot find it, you probably need to run it with a loop over longer time and while opening the driver application

@ChrisLauinger77
Copy link
Contributor Author

ChrisLauinger77 commented Feb 4, 2026

Hmm ...

I get on windows where the driver application is running (headsetcontrol is the artefact from this PR)

C:\Users\christian\Downloads\headsetcontrol-windows-mingw>headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
Failed to send:

C:\Users\christian\Downloads\headsetcontrol-windows-mingw>headsetcontrol --dev -- --device 0x046d:0x0af7 --send "0xC9, 0x64" --receive
Failed to send:

C:\Users\christian\Downloads\headsetcontrol-windows-mingw>headsetcontrol -o json
{
  "name": "HeadsetControl",
  "version": "0.0.0-unknown",
  "api_version": "1.4",
  "hidapi_version": "0.15.0",
  "device_count": 1,
  "devices": [
    {
      "status": "partial",
      "device": "Logitech G PRO Series",
      "vendor": "Logitech",
      "product": "PRO X 2 LIGHTSPEED",
      "id_vendor": "0x046d",
      "id_product": "0x0af7",
      "capabilities": [
        "CAP_SIDETONE",
        "CAP_BATTERY_STATUS",
        "CAP_INACTIVE_TIME"
      ],
      "capabilities_str": [
        "sidetone",
        "battery",
        "inactive time"
      ],
      "battery": {
        "status": "BATTERY_UNAVAILABLE",
        "level": -1
      },
      "errors": {
        "battery": "HID communication error"
      }
    }
  ]
}


@ChrisLauinger77
Copy link
Contributor Author

when I use the released version of headsetcontrol I get

C:\Program Files\headsetcontrol 0.0.0~continuous-19-gb627b4b\bin>headsetcontrol --dev -- --device 0x046d:0x0af7 --interface 3 --send "0x51 0x0a 0x00 0x03 0x1e 0x00 0x05 0x00 0x07 0x1e 0x01 0x32 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00" --receive
Failed to send: WriteFile: (0x00000001) Unzulõssige Funktion.

C:\Program Files\headsetcontrol 0.0.0~continuous-19-gb627b4b\bin>headsetcontrol.exe -o json
{
  "name": "HeadsetControl",
  "version": "continuous-19-gb627b4b",
  "api_version": "1.4",
  "hidapi_version": "0.15.0",
  "device_count": 0,
  "devices": [

  ]
}

@Sapd
Copy link
Owner

Sapd commented Feb 5, 2026

With other versions too? Not sure what could have caused that in code

@ChrisLauinger77
Copy link
Contributor Author

ChrisLauinger77 commented Feb 5, 2026

With other versions too? Not sure what could have caused that in code

No success on windows with 2 versions. I could also try older releases ...

@Sapd
Copy link
Owner

Sapd commented Feb 5, 2026

I checked it a bit

The Windows issue is that this device variant (0x0af7) exposes completely different HID usage pages than the other G PRO variants. From your --dev --list output:

  Usage-Page: 0x000c  Usage-ID: 0x0001  (consumer controls)
  Usage-Page: 0xff13  Usage-ID: 0x0001  (vendor specific)
  Usage-Page: 0xffa0  Usage-ID: 0x0001  (vendor specific)

But the LogitechGPro class hardcodes usagepage=0xff43, usageid=0x0202 for battery/inactive time (which doesn't exist on your device at all)

On Windows, the code tries to match that usage page first, fails, then falls back to opening the first enumerated HID endpoint (the 0x000c consumer controls one), which is wrong that's why --dev --send fails with "Failed to send".

On Linux it doesn't matter because all three entries resolve to the same /dev/hidraw3, so the timeout there is a separate protocol issue (probably the battery command itself being different).

Could you run --dev --list on Windows too? I'd like to see what usage pages/interfaces it enumerates there they might differ from Linux. That would tell us which usagepage/usageid to set for this variant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants