Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Needs testing on more devices #17

Open
LoLei opened this issue Sep 29, 2019 · 11 comments
Open

Needs testing on more devices #17

LoLei opened this issue Sep 29, 2019 · 11 comments
Labels
help wanted Extra attention is needed

Comments

@LoLei
Copy link
Owner

LoLei commented Sep 29, 2019

If anyone has Razer devices, keyboards, mice, headsets, etc., I'd appreciate it if you could test if everything works for you, and if not, tell me, or open a PR yourself!

@LoLei LoLei added the help wanted Extra attention is needed label Sep 29, 2019
@LoLei
Copy link
Owner Author

LoLei commented May 11, 2020

Confirmed working on:

  • BlackWidow X Chroma Tournament Edition
  • Lancehead Tournament Edition
  • BlackWidow Elite
  • BlackWidow Lite

@ifohancroft
Copy link
Contributor

ifohancroft commented Sep 22, 2020

Using the Viper Ultimate wirelessly by plugging the dock with cable into the PC and plugging the dongle in the dock, the following command parameters give the following error:
razer-cli -v, razer-cli -l, razer-cli -ll, razer-cli -d and razer-cli -a

Traceback (most recent call last):
  File "/home/ifohancroft/.local/bin/razer-cli", line 8, in <module>
    sys.exit(main())
  File "/home/ifohancroft/.local/lib/python3.8/site-packages/razer_cli/razer_cli.py", line 314, in main
    color = set_color(args.color)
  File "/home/ifohancroft/.local/lib/python3.8/site-packages/razer_cli/razer_cli.py", line 67, in set_color
    r, g, b = get_x_color()
  File "/home/ifohancroft/.local/lib/python3.8/site-packages/razer_cli/razer_cli.py", line 48, in get_x_color
    r, g, b = util.hex_to_decimal(rgb)
  File "/home/ifohancroft/.local/lib/python3.8/site-packages/razer_cli/util.py", line 6, in hex_to_decimal
    r = int(hex_color[0:2], 16)
ValueError: invalid literal for int() with base 16: ''

Where, razer-cli -v also says: "Starting Razer colors script..." before showing the error.

@LoLei
Copy link
Owner Author

LoLei commented Sep 23, 2020

@ifohancroft Thanks for reporting this! Could you please run the following and tell me the output:
xrdb -query | grep "*color1:" | awk -F '#' '{print $2}'

My guess it it always tries to get colors from Xresources even if none have ever been set.

@ifohancroft
Copy link
Contributor

@LoLei Most welcome! The output is empty.

@LoLei
Copy link
Owner Author

LoLei commented Sep 25, 2020

Please see if the newest version fixes it.

@ifohancroft
Copy link
Contributor

ifohancroft commented Sep 25, 2020

Thank you! All the parameters seems to work now.
There are a couple of problems I have found now:

  1. razer-cli -v or razer-cli --verbose gives me the following info:
Starting Razer colors script...
RBG: 
0 0 0

And regardless of whether I run it on its own or with another parameter, it doesn't seem to have an effect on the verbosity of the output.

  1. The information about my mouse in razer-cli -l or ll is a bit wrong:
Found 1 Razer devices
Razer Viper Ultimate (Wireless):
   type: mouse
   DPI: (0, 0)
   max DPI: 20000
   serial: UNKWN000000002440
   firmware version: v0.0
   driver version: 2.8.0
   effects: ['logo_breath_single', 'logo_reactive', 'logo_static']
   capabilities: {'name': True, 'type': True, 'firmware_version': True, 'serial': True, 'brightness': False, 'macro_logic': False, 'keyboard_layout': False, 'lighting': False, 'lighting_breath_single': False, 'lighting_breath_dual': False, 'lighting_breath_triple': False, 'lighting_breath_random': False, 'lighting_wave': False, 'lighting_reactive': False, 'lighting_none': False, 'lighting_spectrum': False, 'lighting_static': False, 'lighting_starlight_single': False, 'lighting_starlight_dual': False, 'lighting_starlight_random': False, 'lighting_ripple': False, 'lighting_ripple_random': False, 'lighting_pulsate': False, 'lighting_led_matrix': True, 'lighting_led_single': False, 'lighting_logo': True, 'lighting_logo_active': False, 'lighting_logo_blinking': False, 'lighting_logo_brightness': True, 'lighting_logo_pulsate': False, 'lighting_logo_spectrum': True, 'lighting_logo_static': True, 'lighting_logo_none': True, 'lighting_logo_reactive': True, 'lighting_logo_wave': True, 'lighting_logo_breath_single': True, 'lighting_logo_breath_dual': True, 'lighting_logo_breath_random': True, 'lighting_scroll': False, 'lighting_scroll_active': False, 'lighting_scroll_blinking': False, 'lighting_scroll_brightness': False, 'lighting_scroll_pulsate': False, 'lighting_scroll_spectrum': False, 'lighting_scroll_static': False, 'lighting_scroll_none': False, 'lighting_scroll_reactive': False, 'lighting_scroll_wave': False, 'lighting_scroll_breath_single': False, 'lighting_scroll_breath_dual': False, 'lighting_scroll_breath_random': False, 'lighting_left': False, 'lighting_left_active': False, 'lighting_left_brightness': False, 'lighting_left_spectrum': False, 'lighting_left_static': False, 'lighting_left_none': False, 'lighting_left_reactive': False, 'lighting_left_wave': False, 'lighting_left_breath_single': False, 'lighting_left_breath_dual': False, 'lighting_left_breath_random': False, 'lighting_right': False, 'lighting_right_active': False, 'lighting_right_brightness': False, 'lighting_right_spectrum': False, 'lighting_right_static': False, 'lighting_right_none': False, 'lighting_right_reactive': False, 'lighting_right_wave': False, 'lighting_right_breath_single': False, 'lighting_right_breath_dual': False, 'lighting_right_breath_random': False, 'lighting_backlight': False, 'lighting_backlight_active': False, 'lighting_profile_led_red': False, 'lighting_profile_led_green': False, 'lighting_profile_led_blue': False, 'poll_rate': True, 'dpi': True, 'available_dpi': False, 'battery': False}

Here is the list of the wrong things in the info:

  • I haven't set the DPI for X and Y separately, so I am not sure how the output should show it (perhaps show the same number for each axis?) but my DPI is 400 and the output says DPI: (0,0)
  • The serial number is wrong
  • The firmware version is wrong
  • I am not sure about the effects values (seems right at first sight but I feel like it has more effects than that
  • The capabilities are wrong and some are also confusing. I mean for examle 'name': True, 'type': True, 'firmware_version': True, 'serial': True or 'lighting': False (this one should definitely be true). The gist of it is that there are booleans shown where there should be integer or string values. However, at first glance the lighting part of the capabilities seems to be correct as the mouse only has logo lighting.

P.S. I am not sure if openrazer included support for the mouse dock but shouldn't razer-cli also show the dock in the list of the devices?

@LoLei
Copy link
Owner Author

LoLei commented Sep 26, 2020

Glad that is fixed now.

Ad. 1.:
The verbose flag's effects are only visible in certain functions. Essentially, if you look at the code, wherever args.verbose is checked and something is printed. If you want you can certainly add some additional verbose prints and create a PR. It's Hacktoberfest after all.

Ad. 2.:
This information comes directly from openrazer, razer-cli has no real influence on it.

The DPI value works for my mouse. Maybe try setting it once with razer-cli and see if it shows up correctly then? That's not a fix of course, but would be interesting nonetheless.

The serial and firmware numbers are most likely due to openrazer. (openrazer/openrazer#1164, openrazer/openrazer#987, although in theory it should be in v2.8.0.)

The list of effects shows only the intersection of effects the device has and those that are implemented in razer-cli. For all effects, see the capabilities section. This is in fact a map of capabilities to booleans, because it only says whether a certain capability is supported on the device. For example for your mouse, lighting_logo_static is true because this effect can be controlled via the openrazer pylib (called logo_static in razer-cli). lighting itself is a different effect that cannot be activated for this particular device. If you see effect capabilties that are true for your device but are not yet supported in razer-cli, I'd also appreciate a pull request that implements these.

The openrazer mouse dock support still seems to be in progress (openrazer/openrazer#1018).

@ifohancroft
Copy link
Contributor

  1. Python's definitely not my strong suite but I'd definitely play with stuff when I have the time and if I come up with anything worthy, I'll definitely open up a PR.

  2. The DPI is still shown as DPI: (0, 0) even after setting the DPI with razer-cli.

Regarding the list of capabilities - When it comes to lighting and such, it makes sense. I mostly found it weird when it comes to the 'name', 'type' and 'firmware_version' that their values are True instead of a string or an integer.

@LoLei
Copy link
Owner Author

LoLei commented Sep 27, 2020

Alright thanks for testing that out again.

You're right the capabilities are definitely counter-intuitive. It's pretty clear that all devices support the name capability for example.

@LoLei
Copy link
Owner Author

LoLei commented Sep 27, 2020

@all-contributors please add @ifohancroft for bug and userTesting

@allcontributors
Copy link
Contributor

@LoLei

I've put up a pull request to add @ifohancroft! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants