From c694034dc4b31f0c522bde5b1515e78eac3b32df Mon Sep 17 00:00:00 2001 From: simon-wh Date: Tue, 10 Oct 2023 10:41:46 +0100 Subject: [PATCH] Add support for Wooting UwU and Wooting UwU RGB --- wooting-analog-plugin/src/lib.rs | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/wooting-analog-plugin/src/lib.rs b/wooting-analog-plugin/src/lib.rs index 4254ea9..af0c619 100644 --- a/wooting-analog-plugin/src/lib.rs +++ b/wooting-analog-plugin/src/lib.rs @@ -245,6 +245,34 @@ impl DeviceImplementation for Wooting60HEARM { } } } + +#[derive(Debug, Clone)] +struct WootingUwU(); + +impl DeviceImplementation for WootingUwU { + fn device_hardware_id(&self) -> DeviceHardwareID { + DeviceHardwareID { + vid: WOOTING_VID, + pid: 0x1500, + usage_page: 0xFF54, + has_modes: true, + } + } +} + +#[derive(Debug, Clone)] +struct WootingUwURgb(); + +impl DeviceImplementation for WootingUwURgb { + fn device_hardware_id(&self) -> DeviceHardwareID { + DeviceHardwareID { + vid: WOOTING_VID, + pid: 0x1510, + usage_page: 0xFF54, + has_modes: true, + } + } +} /// A fully contained device which uses `device_impl` to interface with the `device` struct Device { pub device_info: DeviceInfo, @@ -445,6 +473,8 @@ impl WootingPlugin { Box::new(WootingTwoHEARM()), Box::new(Wooting60HE()), Box::new(Wooting60HEARM()), + Box::new(WootingUwU()), + Box::new(WootingUwURgb()), ]; let mut hid = match HidApi::new() { Ok(mut api) => {