Subversion Repositories group.electronics

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
7 pfowler 1
#include <avr/pgmspace.h>
2
 
3
const PROGMEM char usbHidReportDescriptor[42] = {
4
    0x05, 0x01,                    // USAGE_PAGE (Generic Desktop)
5
    0x09, 0x05,                    // USAGE (Game Pad)
6
    0xa1, 0x01,                    // COLLECTION (Application)
7
    0x09, 0x01,                    //   USAGE (Pointer)
8
    0xa1, 0x00,                    //   COLLECTION (Physical)
9
    0x09, 0x30,                    //     USAGE (X)
10
    0x09, 0x31,                    //     USAGE (Y)
11
    0x15, 0x00,                    //     LOGICAL_MINIMUM (0)
12
    0x25, 0x02,                    //     LOGICAL_MAXIMUM (2)
13
    0x75, 0x02,                    //     REPORT_SIZE (2)
14
    0x95, 0x02,                    //     REPORT_COUNT (2)
15
    0x81, 0x02,                    //     INPUT (Data,Var,Abs)
16
    0xc0,                          //   END_COLLECTION
17
    0x05, 0x09,                    //   USAGE_PAGE (Button)
18
    0x19, 0x01,                    //   USAGE_MINIMUM (Button 1)
19
    0x29, 0x04,                    //   USAGE_MAXIMUM (Button 4)
20
    0x15, 0x00,                    //   LOGICAL_MINIMUM (0)
21
    0x25, 0x01,                    //   LOGICAL_MAXIMUM (1)
22
    0x75, 0x01,                    //   REPORT_SIZE (1)
23
    0x95, 0x04,                    //   REPORT_COUNT (4)
24
    0x81, 0x02,                    //   INPUT (Data,Var,Abs)
25
    0xc0                           // END_COLLECTION
26
};
27