Serial mouse fixes for external GPS on Win 7

One of the back burner projects I’ve been pursuing has been to participate in the global network of ADSB receivers for aircraft tracking. I’ll post more separately on that but as part of it I am running a GPS connected to the laptop where my RTL-SDR receiver connects. The GPS is attached via a USB to serial converter cable based on the Prolific chip or a clone. This seemed to run well, until I rebooted the laptop. At which time the utility I was using stopped being able to talk to the GPS, the com port disappeared and the mouse started acting up. A reboot later, the GPS locked onto the satellites  immediately as shown by its flashing 1PPS light but the mouse was jumping all over my screen even before I could login.  After various bits of research I found that this is a well known issue inherent in windows and is a legacy behaviour.  Windows looks at the serial ports including any virtual ones and if it sees any data it assumes that a serial mouse is connected. It then enumerates that mouse and installs a driver. To be more precise it installs a Microsoft Serial Ballpoint.  Of course the GPS is sending lots of NMEA data on its serial port in a  constant stream so windows thinks it has a mouse attached.

If you research the problem you find that in Win NT, 2000 and XP there was a boot.ini change that you could make and a command line that could be run to disable this. In Win7 the only solution is to edit the registry.

Here’s a nice tutorial that I found. I have only tried the Win7 fix.

Here is the entry you need to change.

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\sermouse
The ‘start’ parameter needs to be changed to 4 from 3 to disable the mouse on startup.
Use the command ‘regedit‘ from a command line and before making a change backup the registry by exporting it.

Be warned though.. when you reboot the first time you must not have the GPS attached… if you do it resets the change to the registry and the NMEA messages are interpreted as mouse movement again.

Once you have rebooted once sucessfully, the registry change sticks and you can leave the GPS plugged in on future reboots. It is still enumerated as a serial ballpoint and displays a mouse icon in my case, but that part of the driver is off and the COM port is now open. The perfectionist in me is frustrated that the GPS and serial port adapter are misnamed, but at least it works.

serialmouse1                                     serialmouse2
I also have an FTDI UART adapter on this laptop that does not cause this problem… although that might be because the Arduino attached does not send anything until the laptop has booted.
It remains to be seen whether this ‘fix’ survives a windows update cycle… I’ll let you know.