アルモバ対応に必要
beatmania IIDX controller Entry Model
Konami Amusement
18, // bLength 1, // bDescriptorType 0x00, 0x02, // bcdUSB 0, // bDeviceClass 0, // bDeviceSubClass 0, // bDeviceProtocol 64, // bMaxPacketSize0 0xcf, // idVendor[0] 0x1c, // idVendor[1] 0x48, // idProduct[0] 0x80, // idProduct[1] 0x00, 0x10, // bcdDevice (=version number) 1, // iManufacturer 2, // iProduct 0, // iSerialNumber 1 // bNumConfigurations
9, // bLength; 2, // bDescriptorType; 34, 0, // wTotalLength 1, // bNumInterfaces 1, // bConfigurationValue 0, // iConfiguration 0x80, // bmAttributes 50, // bMaxPower // interface descriptor 9, // bLength 4, // bDescriptorType 0, // bInterfaceNumber 0, // bAlternateSetting 1, // bNumEndpoints (is 2 if the device has INTR_IN) 0x03, // bInterfaceClass (0x03 = HID) 0x00, // bInterfaceSubClass (0x00 = No Boot) 0x00, // bInterfaceProtocol (0x00 = No Protocol) 0, // iInterface // HID interface descriptor 9, // bLength 0x21, // bDescriptorType 0x11, 0x01, // bcdHID 0, // bCountryCode 1, // bNumDescriptors 0x22, // bDescriptorType 50, 0, // wDescriptorLength // endpoint descriptor 7, // bLength 5, // bDescriptorType 1 | 0x80, // bEndpointAddress (|0x80=in) 0x03, // bmAttributes (0x03=intr) 64, 0, // wMaxPacketSize 4 // bInterval
0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x04, // Usage (Joystick) 0xA1, 0x01, // Collection (Application) 0x09, 0x01, // Usage (Pointer) 0xA1, 0x00, // Collection (Physical) 0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x30, // Usage (X) 0x09, 0x31, // Usage (Y) 0x15, 0x81, // Logical Minimum (-127) 0x25, 0x7F, // Logical Maximum (127) 0x75, 0x08, // Report Size (8) 0x95, 0x02, // Report Count (2) 0x81, 0x02, // Input (Data,Var,Abs) 0x05, 0x09, // Usage Page (Button) 0x19, 0x01, // Usage Minimum (0x01) 0x29, 0x10, // Usage Maximum (0x10) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x01, // Logical Maximum (1) 0x75, 0x01, // Report Size (1) 0x95, 0x10, // Report Count (16) 0x81, 0x02, // Input (Data,Var,Abs) 0x75, 0x08, // Report Size (8) 0x95, 0x01, // Report Count (1) 0x81, 0x03, // Input (Const,Var,Abs) 0xC0, // End Collection 0xC0 // End Collection
struct hidreport_t { signed char x; signed char y; unsigned char key; // (0-6 : B1-B7) unsigned char ekey; // (0-3 : E1-E4) unsigned char dummy; // always 0x00 };