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

Add support for the NZXT HUE 2 #64

Merged
merged 2 commits into from Nov 10, 2019
Merged

Add support for the NZXT HUE 2 #64

merged 2 commits into from Nov 10, 2019

Conversation

@jonasmalacofilho
Copy link
Owner

jonasmalacofilho commented Oct 31, 2019

This modifies the driver originally built for Smart Device V2 to also support the HUE 2.

Related: #61 ("Support for NXZT AER 2 120mm and NZXT HUE 2")

@jonasmalacofilho

This comment has been minimized.

Copy link
Owner Author

jonasmalacofilho commented Oct 31, 2019

@CaseySJ can I ask you to check if I broken something with these patches?

@CaseySJ

This comment has been minimized.

Copy link
Contributor

CaseySJ commented Oct 31, 2019

Certainly. Will test the latest commit most likely this evening.

@CaseySJ

This comment has been minimized.

Copy link
Contributor

CaseySJ commented Nov 1, 2019

Just tested the add-support-for-hue2 branch, and it works! This has the expected_prefixes code.

Caseys-iMac-Pro:driver casey_sj$ liquidctl list
Device 0, NZXT Kraken X (X42, X52, X62 or X72)
Device 1, NZXT Smart Device V2 (experimental)

Caseys-iMac-Pro:driver casey_sj$ liquidctl -d 1 initialize

Caseys-iMac-Pro:driver casey_sj$ liquidctl -d 1 status
Device 1, NZXT Smart Device V2 (experimental)
Fan 2 duty                              50  %
Fan 2 speed                           1018  rpm
Firmware version                     1.5.0  
LED 1 accessory 1          HUE 2 LED Strip  
LED 1 accessory 2    HUE 2 Underglow 200mm  
LED 1 accessory 3    HUE 2 Underglow 200mm  
LED 2 accessory 1          AER RGB 2 140mm  
LED 2 accessory 2          AER RGB 2 140mm  
LED 2 accessory 3          AER RGB 2 140mm  
LED 2 accessory 4          AER RGB 2 120mm  
Noise level                             64  dB
@jonasmalacofilho

This comment has been minimized.

Copy link
Owner Author

jonasmalacofilho commented Nov 1, 2019

Hm, did you only merge/copy the specific driver? Because the output doesn't match what has been on the master branch since I reworked the device discovery process.

@CaseySJ

This comment has been minimized.

Copy link
Contributor

CaseySJ commented Nov 1, 2019

Hm, did you only merge/copy the specific driver? Because the output doesn't match what has been on the master branch since I reworked the device discovery process.

Correct -- I tested only the modified Smart Device driver.

@CaseySJ

This comment has been minimized.

Copy link
Contributor

CaseySJ commented Nov 1, 2019

Now, after copying latest *.py files from the liquidctl folder and drivers folder, here is the revised output. But there is a problem -- notice that the device id is not remaining consistent between runs.

  • When running liquidctl list two times in a row, we get two different device assignments.
  • When invoking liquidctl -d 0 status two times in a row, we get the status of the two different devices.

Could this be due to the way I updated the Python files?

Caseys-iMac-Pro:bin casey_sj$ liquidctl list
Device ID 0: NZXT Kraken X (X42, X52, X62 or X72)
Device ID 1: NZXT Smart Device V2 (experimental)

Caseys-iMac-Pro:bin casey_sj$ liquidctl list
Device ID 0: NZXT Smart Device V2 (experimental)
Device ID 1: NZXT Kraken X (X42, X52, X62 or X72)

Caseys-iMac-Pro:bin casey_sj$ liquidctl -d 0 status
NZXT Kraken X (X42, X52, X62 or X72)
├── Liquid temperature     21.9  °C
├── Fan speed               634  rpm
├── Pump speed             1838  rpm
└── Firmware version      6.0.2  

Caseys-iMac-Pro:bin casey_sj$ liquidctl -d 0 status
NZXT Smart Device V2 (experimental)
├── Fan 2 duty                              50  %
├── Fan 2 speed                           1038  rpm
├── Firmware version                     1.5.0  
├── LED 1 accessory 1          HUE 2 LED Strip  
├── LED 1 accessory 2    HUE 2 Underglow 200mm  
├── LED 1 accessory 3    HUE 2 Underglow 200mm  
├── LED 2 accessory 1          AER RGB 2 140mm  
├── LED 2 accessory 2          AER RGB 2 140mm  
├── LED 2 accessory 3          AER RGB 2 140mm  
├── LED 2 accessory 4          AER RGB 2 120mm  
└── Noise level                             66  dB
@CaseySJ

This comment has been minimized.

Copy link
Contributor

CaseySJ commented Nov 1, 2019

Here's the liquidctl --debug list output from 2 consecutive runs:

Run #1:

Caseys-iMac-Pro:driver casey_sj$ liquidctl --debug list
[DEBUG] liquidctl.cli: running liquidctl v1.2.0
[DEBUG] liquidctl.driver.usb: searching GenericHidBus (api=hid, drivers=[CommonSmartDeviceDriver, CorsairHidPsuDriver, KrakenTwoDriver, SeasonicEDriver, SmartDeviceDriver, SmartDeviceDriverV2])
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x2006
[DEBUG] liquidctl.driver.usb: instanced driver for NZXT Smart Device V2 (experimental)
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x170e
[DEBUG] liquidctl.driver.usb: instanced driver for NZXT Kraken X (X42, X52, X62 or X72)
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5ac:0x256
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5ac:0x256
[DEBUG] liquidctl.driver.usb: searching PyUsbBus (drivers=[AsetekDriver, CommonAsetekDriver, CorsairAsetekDriver, LegacyAsetekDriver])
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x170e
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x2006
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5e3:0x608
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0x82d
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5e3:0x608
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5ac:0x256
Device ID 0: NZXT Smart Device V2 (experimental)
├── Vendor ID: 0x1e71
├── Product ID: 0x2006
├── Release number: 0x0200
├── Serial number: 00000000001A
├── Bus: hid
├── Address: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/BXBR@1,2/IOPP/BYUP@0/IOPP/BYD8@8/IOPP/XHC0@0,3/XHC0@61000000/PRT6@61500000/USB2.0 Hub@61500000/AppleUSB20Hub@61500000/AppleUSB20HubPort@61510000/NZXT USB Device@61510000/IOUSBHostInterface@0/IOUSBHostHIDDevice@61510000,0
└── Driver: SmartDeviceDriverV2 using module hid
[DEBUG] liquidctl.cli: hierarchy: CommonSmartDeviceDriver, UsbHidDriver, BaseUsbDriver, BaseDriver; HidapiDevice

Device ID 1: NZXT Kraken X (X42, X52, X62 or X72)
├── Vendor ID: 0x1e71
├── Product ID: 0x170e
├── Release number: 0x0200
├── Serial number: 6D73078C495
├── Bus: hid
├── Address: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/BXBR@1,2/IOPP/BYUP@0/IOPP/BYD8@8/IOPP/XHC0@0,3/XHC0@61000000/PRT6@61500000/USB2.0 Hub@61500000/AppleUSB20Hub@61500000/AppleUSB20HubPort@61540000/NZXT USB Device@61540000/IOUSBHostInterface@0/IOUSBHostHIDDevice@61540000,0
└── Driver: KrakenTwoDriver using module hid
[DEBUG] liquidctl.cli: hierarchy: UsbHidDriver, BaseUsbDriver, BaseDriver; HidapiDevice

And Run #2:

Caseys-iMac-Pro:driver casey_sj$ liquidctl --debug list
[DEBUG] liquidctl.cli: running liquidctl v1.2.0
[DEBUG] liquidctl.driver.usb: searching GenericHidBus (api=hid, drivers=[CommonSmartDeviceDriver, CorsairHidPsuDriver, KrakenTwoDriver, SeasonicEDriver, SmartDeviceDriver, SmartDeviceDriverV2])
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x170e
[DEBUG] liquidctl.driver.usb: instanced driver for NZXT Kraken X (X42, X52, X62 or X72)
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5ac:0x256
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x2006
[DEBUG] liquidctl.driver.usb: instanced driver for NZXT Smart Device V2 (experimental)
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5ac:0x256
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: searching PyUsbBus (drivers=[AsetekDriver, CommonAsetekDriver, CorsairAsetekDriver, LegacyAsetekDriver])
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x170e
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x1e71:0x2006
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5e3:0x608
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0x82d
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5e3:0x608
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x46d:0xc52b
[DEBUG] liquidctl.driver.usb: probing drivers for device 0x5ac:0x256
Device ID 0: NZXT Kraken X (X42, X52, X62 or X72)
├── Vendor ID: 0x1e71
├── Product ID: 0x170e
├── Release number: 0x0200
├── Serial number: 6D73078C495
├── Bus: hid
├── Address: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/BXBR@1,2/IOPP/BYUP@0/IOPP/BYD8@8/IOPP/XHC0@0,3/XHC0@61000000/PRT6@61500000/USB2.0 Hub@61500000/AppleUSB20Hub@61500000/AppleUSB20HubPort@61540000/NZXT USB Device@61540000/IOUSBHostInterface@0/IOUSBHostHIDDevice@61540000,0
└── Driver: KrakenTwoDriver using module hid
[DEBUG] liquidctl.cli: hierarchy: UsbHidDriver, BaseUsbDriver, BaseDriver; HidapiDevice

Device ID 1: NZXT Smart Device V2 (experimental)
├── Vendor ID: 0x1e71
├── Product ID: 0x2006
├── Release number: 0x0200
├── Serial number: 00000000001A
├── Bus: hid
├── Address: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/BXBR@1,2/IOPP/BYUP@0/IOPP/BYD8@8/IOPP/XHC0@0,3/XHC0@61000000/PRT6@61500000/USB2.0 Hub@61500000/AppleUSB20Hub@61500000/AppleUSB20HubPort@61510000/NZXT USB Device@61510000/IOUSBHostInterface@0/IOUSBHostHIDDevice@61510000,0
└── Driver: SmartDeviceDriverV2 using module hid
[DEBUG] liquidctl.cli: hierarchy: CommonSmartDeviceDriver, UsbHidDriver, BaseUsbDriver, BaseDriver; HidapiDevice
@jonasmalacofilho

This comment has been minimized.

Copy link
Owner Author

jonasmalacofilho commented Nov 1, 2019

I opened a new issue for the device listing problem on macOS (see #65).

@jonasmalacofilho jonasmalacofilho force-pushed the add-support-for-hue2 branch 2 times, most recently from 8afefd4 to 8487ee2 Nov 1, 2019
@jonasmalacofilho jonasmalacofilho force-pushed the add-support-for-hue2 branch from 8487ee2 to ea4d75f Nov 3, 2019
@jonasmalacofilho jonasmalacofilho removed this from the v1.3.0 milestone Nov 3, 2019
@jonasmalacofilho jonasmalacofilho merged commit 110e16b into master Nov 10, 2019
12 checks passed
12 checks passed
build (ubuntu-latest, 3.6)
Details
build (ubuntu-latest, 3.6)
Details
build (ubuntu-latest, 3.7)
Details
build (ubuntu-latest, 3.7)
Details
build (ubuntu-latest, 3.8)
Details
build (ubuntu-latest, 3.8)
Details
build (macOS-latest, 3.6)
Details
build (macOS-latest, 3.6)
Details
build (macOS-latest, 3.7)
Details
build (macOS-latest, 3.7)
Details
continuous-integration/appveyor/branch AppVeyor build succeeded
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
@jonasmalacofilho jonasmalacofilho deleted the add-support-for-hue2 branch Nov 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.