I need to send absolute coordinates to host PC from the HID mouse i emulated on SAM processor on Due board. To do this i tried to change the HID report descriptor in Mouse.cpp. Following are the changes i made :
#ifdef ABSOLUTE_MOUSE_MODE
0x15, 0x01, // LOGICAL_MINIMUM (1) <<<< This allows us to talk to any display resolution
0x25, 0x64, // LOGICAL_MAXIMUM (100) <<<< as though it was 100x100 pixels
0x75, 0x08, // REPORT_SIZE (8)
0x95, 0x03, // REPORT_COUNT (3)
0x81, 0x02, // INPUT (Data,Var,Abs) <<<< This allows us to moveTo absolute positions
#else
0x15, 0x81, // LOGICAL_MINIMUM (-127)
0x25, 0x7f, // LOGICAL_MAXIMUM (127)
0x75, 0x08, // REPORT_SIZE (8)
0x95, 0x03, // REPORT_COUNT (3)
0x81, 0x06, // INPUT (Data,Var,Rel)
#endif
This made no improvement. leaving stray characters in Mouse.cpp, it compiled. Doesn't look like this is the file used. I changed c:\Program Files(x86)\Arduino\libraies\Mouse\src\Mouse.cpp
Is this the right file ?
Second part of problem: I do not see my mouse at all, looks like frozen. I just did a cursor movement loop as follows:
for(i=1; i<127; i++)
for(j=1; j<127; j++)
Mouse.move(i,j);
This doesn't work either. I have sucessfully added keyboard.Mouse is just not working. The above is with absolute coordinates. I'm a newbie to arduino so kindly bear with me.
Thanks,
Srinivas