bardelli
Joined: 14 Oct 2007 Posts: 3
|
MOUSE USB |
Posted: Sun Oct 14, 2007 7:16 pm |
|
|
Hello All..
I was look the ex_usb_mouse.c that comes with CCS PICC and i really dont know what this piece of code do:
out_data[0]=0; //button state goes here
out_data[1]=mouse_seq[x_seq];
out_data[2]=mouse_seq[y_seq];
out_data[3]=0; //wheel state goes here
if (usb_put_packet(1,out_data,4,USB_DTS_TOGGLE))
If you look the descriptor file, you will see the author configures a three button mouse. So, I dont know why he uses only out_data[0] to delivery information to the computer about the mouse buttons. I think it should be a 3 bit information [out_data[0], out_data[1], out_data[2]]
What is the whell state information?. If you check de descriptor file, there is nothing about it.
thanks... |
|