3 Commits
Author SHA1 Message Date
moxiuandGitHub 0461488cf2 add downloading section 2026-07-29 21:20:11 +02:00
moxiu 3c62c2e928 add wireless support 2026-07-29 21:16:35 +02:00
moxiu de20c7002d tf i'm doing 2026-07-29 20:49:47 +02:00
4 changed files with 15 additions and 6 deletions
+3
View File
@@ -5,6 +5,9 @@
a driver for K1NG PRO (4K) mouse from redragon
### Downloading
u can download the driver from [Release's](https://github.com/cfels/K1NG-Driver/releases)
### Compiling
```
+6 -2
View File
@@ -7,8 +7,12 @@
#include <stdbool.h>
#include "libusb-1.0.30/libusb/libusb.h"
// mouse pid
// mouse pids
#define TARGET_VID 0x3554
#define TARGET_PID 0xf54d
#define TARGET_PID_WIRED 0xf54d
#define TARGET_PID_WIRELESS 0xf54f
// mouse pid helper
#define IS_TARGET_PID(pid) ((pid) == TARGET_PID_WIRED || (pid) == TARGET_PID_WIRELESS)
#endif
-3
View File
@@ -1,8 +1,5 @@
#include "includes/include.h"
#include "src/driver.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(int argc, char *argv[]) {
int sens;
+6 -1
View File
@@ -10,7 +10,12 @@ void run_driver(int sens) {
return;
}
handle = libusb_open_device_with_vid_pid(NULL, TARGET_VID, TARGET_PID);
// wired/wireless support
handle = libusb_open_device_with_vid_pid(NULL, TARGET_VID, TARGET_PID_WIRED);
if (!handle) {
handle = libusb_open_device_with_vid_pid(NULL, TARGET_VID, TARGET_PID_WIRELESS);
}
if (!handle) {
fprintf(stderr, "mouse not found!!\n");
libusb_exit(NULL);