- // Kensington Turbo Mouse 5
- if (len == 8 && buf[0] == 0x4B && buf[1] == 0x4D && buf[2] == 0x4C && buf[3] == 0x31) {
- xprintf("Turbo Mouse 5\n");
-
- // Turbo Mouse command sequence to enable four buttons
- // https://elixir.bootlin.com/linux/v4.4/source/drivers/macintosh/adbhid.c#L1176
- // https://github.com/NetBSD/src/blob/64b8a48e1288eb3902ed73113d157af50b2ec596/sys/arch/macppc/dev/ams.c#L261
- static uint8_t cmd1[] = { 0xE7, 0x8C, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x94 };
- static uint8_t cmd2[] = { 0xA5, 0x14, 0x00, 0x00, 0x69, 0xFF, 0xFF, 0x27 };
+ if (len) {
+ xprintf("Ext: [", len);
+ for (int8_t i = 0; i < len; i++) xprintf("%02X ", buf[i]);
+ xprintf("] cpi=%d\n", mouse_cpi);
+ }