by amandaghassaei instructables.com:
Monitor your road speed using the Arduino. This project uses a magnetic switch (also called a reed switch) to measure the speed of one of the bike’s wheels. The Arduino calculates the mph, and send this information out to the LCD screen on the handlebars as you ride. It is compatible with any kind of bike/wheel, simply enter the radius of the wheel in the firmware to calibrate the device for your setup.
Arduino Bike Speedometer – [Link]