arduino speed gate

Hi, I have recently got a scalextric set and I want to know how fast the cars are going and I think a good way to measure the speed is to use a speed gate controlled by the arduino. What I am thinking is that there would be two IR lasers and receivers (perhaps from an old mouse) and when the car breaks the first laser the arduino times how long it takes to reach the second laser. Then the code will do some complicated sums using the time and distance and voila ! You get the speed(hopefully in mph or kmh.

will it work ?

Thanks

Sure will. The calculations are not that complicated. Speed is distance/time. You are measuring the time. The distance is known. The "complicated calculation" is one division operation.

thanks for the reply ! Do you think that you could help me write the code for it as well ?

thanks again

You send my the Arduino, the sensors, and the scalextric set. I'll write the code, make sure it all works, and send everything back.

How much will you pay for the code?

No i cant do that, i'll just work it out my self some other time lol

thanks for the reply ! Do you think that you could help me write the code for it as well ?

I am doing something very similar, measuring the time taken for a car to travel down a track, also reading the speed. I am using two red lasers (IR would be better but much more expensive) and two LDRs.

I can help you with any code you need help with. Are you just wanting to measure the speed or the time taken along a specific part of the track?

You send my the Arduino, the sensors, and the scalextric set. I'll write the code, make sure it all works, and send everything back.

How much will you pay for the code?

;D

Mowcius

Here is what I've made: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1258832174/0#0

/Ulf