Some testing to get it working on W10
This commit is contained in:
parent
54bb7db8dc
commit
e0595c1da8
1 changed files with 19 additions and 5 deletions
24
src/main.rs
24
src/main.rs
|
@ -71,16 +71,19 @@ fn main() -> ! {
|
||||||
USB_HID = Some(HIDClass::new(
|
USB_HID = Some(HIDClass::new(
|
||||||
USB_BUS.as_ref().unwrap(),
|
USB_BUS.as_ref().unwrap(),
|
||||||
MouseReport::desc(),
|
MouseReport::desc(),
|
||||||
60,
|
10,
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
unsafe {
|
unsafe {
|
||||||
USB_DEVICE = Some(
|
USB_DEVICE = Some(
|
||||||
UsbDeviceBuilder::new(USB_BUS.as_ref().unwrap(), UsbVidPid(0x046d, 0x101b))
|
UsbDeviceBuilder::new(USB_BUS.as_ref().unwrap(), UsbVidPid(0x6666, 0x0789))
|
||||||
.manufacturer("Logitech")
|
// .manufacturer("Logitech")
|
||||||
.product("Marathon Mouse/Performance Plus M705")
|
// .product("Marathon Mouse/Performance Plus M705")
|
||||||
.serial_number("B14D65DA")
|
// .serial_number("B14D65DA")
|
||||||
|
.manufacturer("KOBA789")
|
||||||
|
.product("RustyKeys")
|
||||||
|
.serial_number("789")
|
||||||
.build(),
|
.build(),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -99,6 +102,17 @@ fn main() -> ! {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[allow(unused)]
|
||||||
|
fn reworked_mouse_descriptor() -> &'static [u8] {
|
||||||
|
&[
|
||||||
|
5, 1, 9, 2, 161, 1, 9, 1, 161, 0, 5, 9, 25, 1, 41, 8, 21, 0, 37, 1, 117, 1, 149, 8,
|
||||||
|
// add usage vendor here manually
|
||||||
|
9, 2, // Input starts here
|
||||||
|
129, 2, 5, 1, 9, 48, 23, 129, 255, 255, 255, 37, 127, 117, 8, 149, 1, 129, 6, 9, 49, 129,
|
||||||
|
6, 9, 56, 129, 6, 5, 12, 10, 56, 2, 129, 6, 192, 192,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
fn mouse_move(delay: &mut Delay, wait_time: u32, v: i8) {
|
fn mouse_move(delay: &mut Delay, wait_time: u32, v: i8) {
|
||||||
delay.delay_ms(wait_time);
|
delay.delay_ms(wait_time);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue