Tekk-Know / RazerBatteryTaskbar

45 stars 18 forks source link

Add support for Razer Viper V2 Wired #12

Closed somerandoname closed 4 days ago

somerandoname commented 7 months ago

The wireless version is working but the entry for the wired one is missing.

The PID is 0x00a5.

richfaj commented 2 weeks ago

I added the device profile to main.js and that got it working for me. For wired just change to 0x00A5. Also looks like the source file includes support for both, but the latest release does not have it.

0x00A6: {
    name: 'Razer Viper V2 Pro Wireless',
    wireless: true,
    transactionId: 0x1f
},
pneumuh commented 2 weeks ago

I’m sorry for my noob question. But can you please tell me how I can install this on my computer?

somerandoname commented 1 week ago

@pneumuh If you mean the application, then just go to the releases page and download the latest setup exe:
https://github.com/Tekk-Know/RazerBatteryTaskbar/releases

For manually adding support for the Razer Viper V2, navigate to the installation directory, locate the main.js file, and open it in a text editor. Then append these two entries to the similar looking ones, save and restart the app:

    0x00a5: {
        name: 'Razer Viper V2 Pro Wired',
        transactionId: 0x1f
    },
    0x00a6: {
        name: 'Razer Viper V2 Pro Wireless',
        transactionId: 0x1f
    },
Tekk-Know commented 4 days ago

Please try this release: https://github.com/Tekk-Know/RazerBatteryTaskbar/releases/tag/v1.0.7

somerandoname commented 3 days ago

Thanks, for the update. The wired version is now being identified.

However, the wireless one isn't anymore. It seems to be due to this line change:

    - let msg = Buffer.from([0x00, mouse.transactionId, 0x00, 0x00, 0x00, 0x02, 0x07, 0x80]);
    + let msg = Buffer.from([0x00, mouse.transactionId || 0xFF, 0x00, 0x00, 0x00, 0x02, 0x07, 0x80]);

Reverting the change or changing 0xFF to 0x00 seems to fix it for me.

Tekk-Know commented 3 days ago

@somerandoname made updated build, thanks for feedback.