Rainwarrior, thank you for measuring the ball, roller, and counting the holes on the wheel. I was thinking about it often at work today. You already came up with similar results as below (the measurements suggest about 50 counts per inch), but I wanted to chime in with a different way of explaining how to get there:
How the mouse encoder wheel works: There's two infrared LEDs aligned with two infrared detectors for each wheel. The LEDs and detectors are set up so that when the wheel moves, the detectors change in the following loop:
00
01
11
10
A sequence going down the loop indicates one direction, a sequence going up the loop indicates the opposite direction. The number of detector changes per complete revolution of the wheel is 4 times the number of holes on the wheel. But I don't know if the mouse maps every detector change to 1 count in its report. When I searched for information about mouse encoder wheels, I ended up finding descriptions of
quadrature encoders which say that the count could be triggered on one edge of one detector, both edges of one detector, or both edges of both detectors. So 1 count in the report might represent 1, 2, or 4 detector changes?*
Also, after I thought about it some more, I think it doesn't matter what the size of the ball is, only that the ball is snug in the chamber and smoothly rolls the roller consistently. If the ball moves 1 inch along an axis, the corresponding roller's circumference has also rolled 1 inch. So to determine the mouse resolution in counts per inch, I think we just need to divide the number of counts generated by one revolution of the roller by the roller's circumference in inches.
So if we start with Rainwarrior's measurements:
Wheel: 20 holes
Roller diameter: 0.27 inches
Since there are three possible ways to generate counts per hole:
1 count per hole (1 count per 4 detector changes)
2 counts per hole (1 count per 2 detector changes)
4 counts per hole (1 count per detector change)
I think that means this particular SNES ball mouse has one of these possible resolutions:
20 holes * 1 count per hole : pi * 0.27 inches = about 24 counts per inch
20 holes * 2 counts per hole : pi * 0.27 inches = about 47 counts per inch
20 holes * 4 counts per hole : pi * 0.27 inches = about 93 counts per inch
I guess it's probably the middle one, about 47 counts per inch -- based on Rainwarrior's tests (60 Hz poll at linear sensitivity resulted in a displayed count of 1 representing about 1 inch per second, meaning about 60 counts per inch) and nocash's document (says the SNES mouse resolution is 50 counts per inch +/- 10%).
* I even thought about the possibility of removing an encoder wheel, manually placing and removing small slips of plastic in front of the detectors in the loop sequence above, then manually triggering a mouse read to confirm exactly when a count is triggered. (1 detector change, read mouse, was count 0 or 1? 2 detector changes, read mouse, was count 0 or 1? 4 detector changes, read mouse, was count 0 or 1?) But that might be too difficult or end up damaging the mouse for not much benefit.