Arduino Robot with Sharp IR Sensor

Ditch the lib you don't need it. The wiring is power to +5, ground to ground and the output to an analog pin. The you just use analogRead() to get the range when ever you want it. The graph in the datasheet is used to convert to cm if you want.

Mark