> - The problem with the reed switch you describe is unlikely to happen in > real life, and can be easily remedied in software. Just check for minimum > time b/w pulses, or implement an even more clever algorithm. I have no idea > why Olin thinks it is not a good choice (it's certainly good enough for > commercial speedos). As you say, to get the problem described is practically impossible. The wheel needs to move a reasonable distance to toggle the reed switch. There's a reason reed switches are used, well, several actually. They're cheap, simple, work, and use no power. Even the cheap bike lights have gone to reed switch & magnet assemblies for the on/off switches these days, it makes waterproofing easier. Calculation time between pulses is pretty easy. A bike wheel is a bit over 2000mm in diameter, say 2100mm. Assume a top speed of 100km/h. 100km = 100,000,000mm, so to travel that distance the wheel rotates 100,000,000 / 2100, or 47,619 times. Divide by 60 to get RPM = 793, divide by 60 again to get revolutions per second = 13.2. So at 100km/h the sensor is sending out a 13Hz signal, giving you 0.075 seconds between each pulse. A second pulse arriving under that time can be ignored (especially since 50km/h is a more realistic figure for most people). Tony (The metric challenged are welcome to use miles, feet & cubits to check my figures) -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist