Spurious Analog inputs when connected a DC fan

If you have nothing connected to an I/O pin its voltage "floats" in a completely unpredictable way. The small disturbances caused by the motor could easily give rise to strange values.

...R