diff --git a/converter/adb_usb/config.h b/converter/adb_usb/config.h index 3500188d..70c5e67d 100644 --- a/converter/adb_usb/config.h +++ b/converter/adb_usb/config.h @@ -39,6 +39,9 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE +// Mouse Extended Report +#define MOUSE_EXT_REPORT + /* ADB port setting */ #define ADB_PORT PORTD diff --git a/converter/adb_usb/matrix.c b/converter/adb_usb/matrix.c index 7ef6657b..845c7fab 100644 --- a/converter/adb_usb/matrix.c +++ b/converter/adb_usb/matrix.c @@ -346,8 +346,10 @@ void adb_mouse_task(void) x = xx * mouseacc; y = yy * mouseacc; + #ifndef MOUSE_EXT_REPORT x = (x > 127) ? 127 : ((x < -127) ? -127 : x); y = (y > 127) ? 127 : ((y < -127) ? -127 : y); + #endif if (scroll_enable) { scroll_state -= y; @@ -364,7 +366,7 @@ void adb_mouse_task(void) mouse_report.y = y; } - dmprintf("[B:%02X X:%d(%d) Y:%d(%d) A:%d]\n", mouse_report.buttons, mouse_report.x, xx, mouse_report.y, yy, mouseacc); + dmprintf("[B:%02X X:%d(%d) Y:%d(%d) V:%d A:%d]\n", mouse_report.buttons, mouse_report.x, xx, mouse_report.y, yy, mouse_report.v, mouseacc); // Send result by usb. host_mouse_send(&mouse_report);