sharp gp2y0a21yk-How to get sensor readings

Hello there,

I am trying to use the readings from my sharp gp2y0a21yk sensor in order to have my robot avoiding obstacles. Is there any idea on how I could get those readings?

I mean something like a sample code on this specific sensor!!

Thanks a lot in advance.

http://bildr.org/2011/03/various-proximity-sensors-arduino/