diff options
| -rw-r--r-- | hid-tmt300rs.h | 44 | ||||
| -rw-r--r-- | ps4-input.txt | 54 |
2 files changed, 89 insertions, 9 deletions
diff --git a/hid-tmt300rs.h b/hid-tmt300rs.h index 3c3a3a9..f50e789 100644 --- a/hid-tmt300rs.h +++ b/hid-tmt300rs.h @@ -274,10 +274,10 @@ static u8 t300rs_rdesc_ps4_fixed[] = { 0x09, 0x05, /* Usage (GamePad) */ 0xa1, 0x01, /* Collection (Application) */ 0x85, 0x01, /* Report ID (1) */ - 0x09, 0x30, /* Usage (X) */ - 0x09, 0x31, /* Usage (Y) */ - 0x09, 0x32, /* Usage (Z) */ - 0x09, 0x35, /* Usage (Rz) */ + 0x09, 0x00, /* Usage (U) (was X) */ + 0x09, 0x00, /* Usage (U) (was Y) */ + 0x09, 0x00, /* Usage (U) (was Z) */ + 0x09, 0x00, /* Usage (U) (was Rz)*/ 0x15, 0x00, /* Logical minimum (0) */ 0x26, 0xff, 0x00, /* Logical maximum (255) */ 0x75, 0x08, /* Report size (8) */ @@ -307,17 +307,43 @@ static u8 t300rs_rdesc_ps4_fixed[] = { 0x95, 0x01, /* Report count (1) */ 0x81, 0x02, /* Input (Variable, Absolute) */ 0x05, 0x01, /* Usage page (Generic Desktop) */ - 0x09, 0x33, /* Usage (Rx) */ - 0x09, 0x34, /* Usage (Ry) */ + 0x09, 0x00, /* Usage (U) (was Rx)*/ + 0x09, 0x00, /* Usage (U) (was Ry) */ 0x15, 0x00, /* Logical minimum (0) */ 0x26, 0xff, 0x00, /* Logical maximum (255) */ 0x75, 0x08, /* Report size (8) */ 0x95, 0x02, /* Report count (2) */ 0x81, 0x02, /* Input (Variable, Absolute) */ - 0x06, 0x00, 0xff, /* Usage page (Vendor 1) */ - 0x09, 0x21, /* Usage (33) */ - 0x95, 0x36, /* Report count (54) */ + 0x05, 0x01, /* Usage page (Vendor 1) */ + /* constant zero? */ + 0x09, 0x00, /* Usage (33) */ + 0x95, 0x21, /* Report count (54) */ + 0x81, 0x03, /* Input (Variable, Absolute, Constant) */ + /* wheel */ + 0x09, 0x30, /* Usage (X) */ + 0x15, 0x00, /* Logical minimum (0) */ + 0x27, 0xff, 0xff, 0x00, 0x00, /* Logical maximum (65535) */ + 0x35, 0x00, /* Physical minimum (0) */ + 0x47, 0xff, 0xff, 0x00, 0x00, /* Physical maximum (65535) */ + 0x75, 0x10, /* Report size (16) */ + 0x95, 0x01, /* Report count (1) */ + 0x81, 0x02, /* Input (Variable, Absolute) */ + /* gas */ + 0x09, 0x31, /* Usage (Y) */ + 0x81, 0x02, /* Input (Variable, Absolute) */ + /* brake */ + 0x09, 0x32, /* Usage (Z) */ 0x81, 0x02, /* Input (Variable, Absolute) */ + /* clutch */ + 0x09, 0x35, /* Usage (Rz) */ + 0x81, 0x02, /* Input (Variable, Absolute) */ + /* no clue */ + 0x09, 0x00, /* Usage (U) */ + 0x75, 0x08, /* Report size (8) */ + 0x95, 0x0d, /* Report count (13) */ + 0x81, 0x03, /* Input (Variable, Absolute, Constant) */ + /* continue unmodified */ + 0x06, 0x00, 0xff, /* Usage page (Vendor defined 1) */ 0x85, 0x60, /* Report ID (5) (change to 0x60?) */ 0x09, 0x60, /* Usage (34) (change to 0x60?) */ 0x95, 0x1f, /* Report count (31) () */ diff --git a/ps4-input.txt b/ps4-input.txt new file mode 100644 index 0000000..9286c7e --- /dev/null +++ b/ps4-input.txt @@ -0,0 +1,54 @@ +1 ff00.0021 = 0 +2 ff00.0021 = 0 +3 ff00.0021 = 0 +4 ff00.0021 = 0 +5 ff00.0021 = 0 +6 ff00.0021 = 0 +7 ff00.0021 = 0 +8 ff00.0021 = 0 +9 ff00.0021 = 0 +10 ff00.0021 = 0 +11 ff00.0021 = 0 +12 ff00.0021 = 0 +13 ff00.0021 = 0 +14 ff00.0021 = 0 +15 ff00.0021 = 0 +16 ff00.0021 = 0 +17 ff00.0021 = 0 +18 ff00.0021 = 0 +19 ff00.0021 = 0 +20 ff00.0021 = 0 +21 ff00.0021 = 0 +22 ff00.0021 = 0 +23 ff00.0021 = 0 +24 ff00.0021 = 0 +25 ff00.0021 = 0 +26 ff00.0021 = 0 +27 ff00.0021 = 0 +28 ff00.0021 = 0 +29 ff00.0021 = 0 +30 ff00.0021 = 0 +31 ff00.0021 = 0 +32 ff00.0021 = 0 +33 ff00.0021 = 0 +34 ff00.0021 = 226 /* wheel */ +35 ff00.0021 = 125 /* wheel */ +36 ff00.0021 = 255 /* gas */ +37 ff00.0021 = 255 /* gas */ +38 ff00.0021 = 255 /* brake */ +39 ff00.0021 = 255 /* brake */ +40 ff00.0021 = 255 /* clutch */ +41 ff00.0021 = 255 /* clutch */ +42 ff00.0021 = 0 +43 ff00.0021 = 255 +44 ff00.0021 = 255 +45 ff00.0021 = 0 +46 ff00.0021 = 0 +47 ff00.0021 = 0 +48 ff00.0021 = 0 +49 ff00.0021 = 0 +50 ff00.0021 = 0 +51 ff00.0021 = 0 +52 ff00.0021 = 0 +53 ff00.0021 = 0 +54 ff00.0021 = 0 |
