之前在论坛里面看到了类似的问题,但是没有结贴。
我也遇到了,做了一个鼠标,使用绝对坐标系,报告描述符如下:
DB 05H, 01H // USAGE_PAGE (Generic Desktop)
DB 09H, 02H // USAGE (Mouse)
DB a1H, 01H // COLLECTION (Application)
DB 09H, 01H // USAGE (Pointer)
DB a1H, 00H // COLLECTION (Physical)
DB 05H, 09H // USAGE_PAGE (Button)
DB 19H, 01H // USAGE_MINIMUM (Button 1)
DB 29H, 03H // USAGE_MAXIMUM (Button 3)
DB 15H, 00H // LOGICAL_MINIMUM (0)
DB 25H, 01H // LOGICAL_MAXIMUM (1)
DB 75H, 01H // REPORT_SIZE (1)
DB 95H, 03H // REPORT_COUNT (3)
DB 81H, 02H // INPUT (Data,Var,Abs)
DB 75H, 01H // REPORT_SIZE (1)
DB 95H, 05H // REPORT_COUNT (5)
DB 81H, 03H // INPUT (Cnst,Var,Abs)
DB 05H, 01H // USAGE_PAGE (Generic Desktop)
DB 09H, 30H // USAGE (X)
DB 15H, 00H // LOGICAL_MINIMUM (0)
DB 26H, 55H, 05H // LOGICAL_MAXIMUM (1365)
DB 35H, 00H // PHYSICAL_MINIMUM (0)
DB 46H, 55H, 05H // PHYSICAL_MAXIMUM (1365)
DB 75H, 08H // REPORT_SIZE (16)
DB 95H, 02H // REPORT_COUNT (1)
DB 81H, 02H // INPUT (Data,Var,Abs)
DB 09H, 31H // USAGE (Y)
DB 15H, 00H // LOGICAL_MINIMUM (0)
DB 26H, ffH, 02H // LOGICAL_MAXIMUM (767)
DB 35H, 00H // PHYSICAL_MINIMUM (0)
DB 46H, ffH, 02H // PHYSICAL_MAXIMUM (767)
DB 75H, 08H // REPORT_SIZE (16)
DB 95H, 02H // REPORT_COUNT (1)
DB 81H, 02H // INPUT (Data,Var,Abs)
DB c0H // END_COLLECTION
DB c0h
只能在一个小范围内移动。描述符参照了论坛里tanganrong给的例子,这里先谢谢啦^^
各位高手能否帮我看看有什么问题? |