-
Notifications
You must be signed in to change notification settings - Fork 54
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ps2: moved ps2 microsoft mouse example
- moved example of host-to-mouse configuration and mouse-to-host movement packets for a 4-byte Microsft Mouse communicating with a Windows host into ps2/mouse directory - Added README for the ps2/mouse directory, explaining the two examples
- Loading branch information
Showing
2 changed files
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
-------------------------------- | ||
PS/2 Mouse | ||
-------------------------------- | ||
|
||
This is a collection of PS/2 mice communication examples. | ||
|
||
For details see: | ||
http://www-ug.eecg.utoronto.ca/desl/nios_devices_SoC/datasheets/PS2%20Protocol.htm | ||
http://www-ug.eecg.utoronto.ca/desl/nios_devices_SoC/datasheets/PS2%20Mouse%20Protocol.htm | ||
|
||
|
||
ps2_mouse_host_setup_and_movement.sr | ||
------------------------------ | ||
|
||
This file contains a portion of setup from a QNX host to a trackball PS2 mouse. | ||
The mouse packets are 3 bytes long (standard mouse, no scrollwheel) | ||
The sample includes x movement, y movement, and a click. | ||
|
||
|
||
ps2_microsoft_mouse_initialize_and_move.sr | ||
------------------------------ | ||
|
||
This file contains setup and communication between a Windows host and a microsoft mouse. | ||
The host releases the clock simultaneous to pulling the data low, which makes it challenging to | ||
distinguish between "request-to-send" and a regular start-bit. | ||
|
||
Initialize a ps2 mouse, configure it; the mouse then reports movement data. | ||
|
||
- host resets device, waits for reset to complete | ||
- host sets sample rate to 200, 100, 80 - this activates reporting scroll wheel data is available | ||
- host sets device to maximum sample rate: 200; resolution=1: 2 count/mm; 1:1 scaling, stream mode | ||
- host gets device id, enable data reporting | ||
- after a delay, the mouse is moved, and reports it's changing location, in sequences of 4 bytes: | ||
- flags, x movement, y movement, z (scroll wheel) movement. | ||
- the sample data does not include any button presses or scroll wheel movement | ||
|
File renamed without changes.