Even though it sorely needs an improvement, this is a quick and entertaining project, that allows customizations.
When I decided to make a speedometer with Arduino, I googled around and immediately found this project by John Boxall (see https://tronixstuff.com/2011/06/22/tutorial-arduino-timing-methods-with-millis/), that unfortunately did not include circuit schematics and wasn't tested with an actual reed switch.
I adapted it to a different type of LCD display and tried unsuccessfully to implement hardware and software debouncing - unfortunately, quite often the interrupt is called twice, because the magnet causes a second raise in voltage while leaving the sensor - in that case, the speed will be doubled.
In any case, I deem the project interesting because it demonstrates how interrupts work in Arduino.
I thank you anybody who can provide effective suggestions for debouncing: cross-switch capacitor, delay and Schmitt trigger proved ineffective.
Comments