Overclock.net › Forums › Components › Mice › MouseTester Software
New Posts  All Forums:Forum Nav:

MouseTester Software

post #1 of 111
Thread Starter 
I wrote this to be a simple mouse testing software that has built-in plotting, CSV save and load, and plot export to PNG capability.

Full source code can be found on GitHub, just search for MouseTester by microe1.

It uses an open source (MIT License) plotting library called OxyPlot that can also be found on GitHub.

Requires the Microsoft .NET 4 Framework. You will need to have this framework installed to run, can be found on Microsoft's site.

Built-in plotting includes:
  • Raw counts vs time = for detecting limited data paths and skipping counts (e.g. 8-bit reporting that caps at +/- 127)
  • Update time per report = for detecting unstable polling rates (on my system it can do 1 ms reliably, YMMV)
  • Velocity vs time (calculated based on cpi) = for tracking speed type measurements
  • Raw X-Y count plotting = for acceleration, jitter, and angle snapping testing, plots a path based on raw counts

MouseTester_v1.1.zip 147k .zip file

Changes in v1.1, February 15, 2015
  • Fix for log file save region decimal symbol
  • Added logging mode
  • Set processor affinity to core #2

MouseTester_v1.2.zip 148k .zip file

Last updated: July 29, 2015

Changes in v1.2
  • Fixed up description handling for plot and save
  • Report total number of events collected
  • Report X/Y displacement from start in counts and distance
  • Report piece-wise linear total path length in counts and distance
  • Added line / stem options to plots

Edited by microe - 7/29/15 at 6:22pm
post #2 of 111
Thread Starter 
Basic Instructions

First, specify the resolution of the mouse by either typing in a value or by clicking the Measure button and following the instructions in the text box at the bottom. Helpful hint, the program does not intercept clicks or movements from the system so I usually just click in the text box area when starting the data collection.

Second, collect some mouse data by clicking the Collect button (or the Log Start button) and following the instructions in the text box at the bottom.

After that you can Plot the data you have collected using the specified cpi for calculations.

You can also save and load your data to .csv for future reference or importing into other programs like excel or [R] etc...

As far as the plots are concerned, first thing I do is window the data (to hide the garbage at the beginning and end of the collection) using the Data Point Start and Data Point End. From there it depends on the movement that was recorded. Here are some examples:

Count vs. Time: This is for looking at the raw counts from the mouse. The line is a moving average of the data and is provided as a general reference to gauge the consistency of the reporting from the mouse. For a mouse that does not loose tracking you will see the counts generally bouncing above and below the line without much deviation. If the counts deviate too much from the line then the mouse tracking may not appear smooth. If the mouse looses tracking then you will see the counts go erratic. You can also sometimes see angle snapping / prediction here (the counts will go to zero and hold there even though you moved the mouse with a slight arc). You can also see data path clipping here if the data plateaus at a fixed value (e.g. 127 for 8-bit mice). If the mouse is performing some form of multiplication for cpi boosting then you may be able to see that here as skipped counting steps.

Velocity vs. Time: This uses the time interval between updates, the cpi, and the counts to calculate the velocity of the mouse movement. Using fast swipes you can try to get the malfunction rate of the mouse here. Just like Counts vs. Time going erratic, when the tracking is lost the velocity goes erratic as well.

Interval vs. Time: This is for checking the consistency of the update rate from the mouse (i.e. 1000 Hz mouse updates every 1 ms).

X vs. Y: This is just plotting the data that you collected as a path. Like paint testing you can draw arbitrary shapes and see the exact raw mouse reports (e.g. jitter, angle snapping, stair stepping, etc...). Arbitrary movements can be used for acceleration and accuracy testing using this kind of plot as well. For example accuracy can be tested by starting from some point "A", moving the mouse (e.g. varying speed / angles) and then returning to point A. You should see the path that you moved the mouse along with the start and end points being roughly the same. You can do fast swipe / slow swipe back to the same point movements for acceleration testing. You can also do things like move the mouse in a bunch of circles and seeing if the path drifts away.
Edited by microe - 2/15/15 at 6:52am
post #3 of 111
Thread Starter 
FAQ
Quote:
OMG this is a virus!

Some anti-virus software will flag this program because it probably looks like a keylogger and/or because of the hooks into win32 libraries. Full source code is available in case you want to compile your own binary. All you need is the (as of this post still available and still free from Microsoft) Visual C# 2010 Express.
Edited by microe - 1/12/15 at 5:43pm
post #4 of 111
Thread Starter 
Known Issues

Windows region settings can cause issues with import and export of log files when comma is used as the decmial symbol. Fixed in v1.1

Description not applied to save / plots. Fixed in v1.2
Edited by microe - 7/29/15 at 6:23pm
post #5 of 111
Thread Starter 
Other Notes

Mice have some characteristics that we have in general classified using the following terms:

Tracking Speed: Moving the mouse quickly is reported correctly by the mouse. Some mice when you move them too fast will lose tracking and either stop reporting entirely or spaz out and give you random reports or cap out at some count.
Move the mouse very quickly and look at the velocity. In general you should see a curve that is unbroken and maybe has some jitter at high speeds. If the velocity drops to zero or there is some garbage then the mouse lost tracking. The highest velocity along the curve that still looks okay is in general the max tracking speed. Some mice the top of the curve is a plateau, this is indicative of internal data path saturation in the mouse sensor or firmware which results in negative acceleration. Others have used Enotus in the past, but without the data curve plotted you can't see if Enotus is falsely reporting because of some garbage or jitter from the mouse.

Acceleration: Moving the mouse the same distance fast results in different total reported counts than when we move it slow. Can be positive (moves farther the faster the mouse moves) or negative (moves less the faster you move the mouse).
Move the mouse fast in one direction and then move the mouse slow back to exactly the original position. If you plot the X-Y you should see the mouse counts return exactly back to the origin. You can also do this test in game and there are some youtube videos of in-game tests.

Jitter: Moving the mouse in a relatively straight line results in an inconsistent (random staircase) movement.
Move the mouse slowly in a diagonal motion and view the data in the X-Y plot. You are looking for big stair-step or non-linearity along the path. Look around for old Razer Abyssus paint plots.

Angle Snapping/Prediction/Drift Control: This one has been called a few things but in general it is the mouse reporting straight line movement even when the user might have meant to draw a slight angle or curve.
You can sometimes see this during the fast swipes for max tracking rate. The "Y" reports from the mouse will go to zero and hold there (which is highly unlikely from swiping your mouse fast). The other way is to draw a circle and see if the mouse "forces" a straight line. People have done this in paint or you can do this with the X-Y plot and capturing a circle. One of the nice things with my tool is you can draw the shapes in paint and then plot the corresponding raw data with my tool, as long as it is one complete motion and you hold the button down the entire time.

Excessive Anti-Jitter: Moving the mouse slightly or very slowly from a standstill may result in a delay or no movement registration.
Move the mouse very slowly and see what the counts reports look like. This one is kind of hard to test.

Polling Rate Consistency: Move the mouse and see if the report rate from the mouse is consistent at the supposed setting (125, 500, 1000 Hz). Some mice have had a problem with 1000 Hz in the past.
Just move the mouse around and plot the interval. It should be a relatively straight line at the desired report rate. 1ms = 1000 Hz of course. There are other report rate measuring tools out there.

Interpolation: Scaling the counts from a mouse to one that is not native to the sensor. Magnified counts is a form of interpolating CPI up, while halving counts can be seen as a form of interpolating down. Doesn't have to be a power of two, can be any factor since it's just math. Mouse driver sensitivity slider is a form of interpolation that runs on the PC.
This one you can't really see with my tool alone. If I had an oscilloscope and captured the communications from the sensor to the mouse microprocessor and compared that to the counts from the microprocessor reported to the PC then I could see if the mouse microprocessor is interpolating the data.

Measuring CPI: 400 DPI/CPI isn't necessarily 400 CPI! Due to manufacturing tolerance and other factors the CPI that you set may not be exact. You can use my tool to measure the "real" CPI and compare that to the "desired" CPI setting. Some mice are way off, others are dead on. Ruler + counts doesn't lie, but of course take into account human error and maybe do some averaging. Moving the mouse quickly is reported correctly by the mouse. Some mice when you move them too fast will lose tracking and either stop reporting entirely or spaz out and give you random reports or cap out at some count.
Move the mouse very quickly and look at the velocity. In general you should see a curve that is unbroken and maybe has some jitter at high speeds. If the velocity drops to zero or there is some garbage then the mouse lost tracking. The highest velocity along the curve that still looks okay is in general the max tracking speed. Some mice the top of the curve is a plateau, this is indicative of internal data path saturation in the mouse sensor or firmware which results in negative acceleration. Others have used Enotus in the past, but without the data curve plotted you can't see if Enotus is falsely reporting because of some garbage or jitter from the mouse.

Smoothing/Frame-Induced Delay:This is a new one that has come up recently but unfortunately it is very difficult to measure, the following is my somewhat simplified understanding of the process. The mouse sensor acquires images of the surface called "frames". The frame rate of the sensor may or may not be constant. There are signal processing algorithms that takes these frames and translates them into counts. Depending on the signal processing algorithm there is an inherent latency from when the movement occurs to when the sensor has the counts available in the motion registers (frame delay). These counts are acquired from the sensor by an external microcontroller which accumulates these counts, optionally does some additional processing, finally sending a value to the PC on the next USB poll. Measuring these delays would take specialized equipment.

It may be possible to test the relative mouse to PC delay with a modification to the software so that it captures data from two mice simultaneously and stores the results on a per mouse basis. There is some normalizing of counts so you can compare the movements accurately on the time scale. You can probably get relative time to within a millisecond or so before the PC / USB polling rate becomes the limiting factor.
Edited by microe - 1/12/15 at 6:18pm
post #6 of 111
Thank you for this invaluable utility
post #7 of 111
Very informative. Thanks for the effort. Added for later read.
Old but gold
(14 items)
 
  
CPUMotherboardGraphicsRAM
Intel Core i7-2600K (@4,6GHz 1,30v) Asrock z77 Extreme4 Nvidia MSI GTX 960 Gaming G2 16GB Crucial, 1866 MHz (8,8,8,22,1T) 
Hard DriveHard DriveCoolingMonitor
Samsung 850 EVO (SSD) 500GB Samsung (HDD) 2TB Enermax ETS T40 @ T.B Vegas Duo  Samsung Syncmaster 2233RZ (120hz) 
MonitorKeyboardPowerMouse
Samsung Syncmaster T220 (60hz) Logilink LED keyboard CoolerMaster GX 750w Logitech mx300 @ 3310 (400/800/1600@1K) 
Mouse PadAudio
Razer Megasoma 2 Creative XFI 
  hide details  
Reply
Old but gold
(14 items)
 
  
CPUMotherboardGraphicsRAM
Intel Core i7-2600K (@4,6GHz 1,30v) Asrock z77 Extreme4 Nvidia MSI GTX 960 Gaming G2 16GB Crucial, 1866 MHz (8,8,8,22,1T) 
Hard DriveHard DriveCoolingMonitor
Samsung 850 EVO (SSD) 500GB Samsung (HDD) 2TB Enermax ETS T40 @ T.B Vegas Duo  Samsung Syncmaster 2233RZ (120hz) 
MonitorKeyboardPowerMouse
Samsung Syncmaster T220 (60hz) Logilink LED keyboard CoolerMaster GX 750w Logitech mx300 @ 3310 (400/800/1600@1K) 
Mouse PadAudio
Razer Megasoma 2 Creative XFI 
  hide details  
Reply
post #8 of 111
Oh wow! with the x vs y plot, I can draw things! =P

Anyways, my update time only varied at the start where I drew triangles. But circles, figures of 8, horizontal and vertical, are all at 8. Update time 8 and Time has 8ms gaps. So my mouse is 8ms?
post #9 of 111
Thread Starter 
8 ms between updates so 125 Hz polling rate (updates per second).
post #10 of 111
Ahaha, I was wondering why my mouse seemed different the last month, was checking out the lazer version of this mouse. Classic, I started using the optical due to precision and being able to handle 500hz, could possibly do more, but 2ms is all good. Nice app, if it wasn't for this I wouldn't have known that it reset to 125hz, just proves it works. thumb.gif
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Mice
Overclock.net › Forums › Components › Mice › MouseTester Software