I’m working with a dead-simple bicycle computer mod and Arduino to send pulses to a Processing application. The result is a powerful and flexible bicycle speedometer. Eventually I’m hoping to turn it into a video game of sorts; something to vary my workouts and make them more entertaining. Longer term it could be cool to port it for iTouch… but lets not get ahead of ourselves ;)
What can YOU do with it? Just install the Arduino code on your Arduino board (duh), plug your reed switch into pins 0 and GND (doesn’t matter which is which, just plug ‘em in), and run the processing application. Let me know how it goes!
ReedTachometerV001_Arduino.zip
ReedTachometerV005_Processing.zip
|
Adam O'Hern is an industrial design consultant specializing in visual brand languages, and has designed products ranging from laptops to power tools, classroom toys to bathroom fixtures, and robots to lint rollers. He has published with 3DWorld Magazine, CGTuts+, and Luxology, and works with Josh Mings of SolidSmack.com on EngineerVsDesigner.com. |







Posted new code here:
http://adam.theoherns.com/2010/03/10/simple-graphic-trainer/
Haha, yeah my wife hates the target speed too :) Wussies! j/k
I’m actually going the opposite direction with it; my next trick will be to make a moving target speed, so that you have to pay attention. That way you can do hills and intervals, and the timer reset thing is just incentive to keep at it. If you have any other ideas for how to motivate me to keep going strong, I’d love to hear them!
Sounds like you’ve got a pretty cool rig going. You should document it sometime and post it up on the web somewhere. Maybe when I do my next release of the software I’ll add a photo tutorial as well.
That might be it – I think my circuit pulls the pin up to 5V when the reed switch is closed so that may be causing the issue. My circuit is also a bit more complicated as it has hardware debouncing but that shouldn’t make a difference.
I also made some minor modifications to the processing code (basically stripped out the target speed functionality).
I’ll let you know if I fix the issue and may play with it a bit more later this week.
Steve
Really nice work!
Works wonderfully. I hadn’t used processing before and was foolishly trying to write a display for my speedometer using Perl/Tk!
This is a much nicer solution.
I have noticed an issue where the software isn’t detecting when the wheel stops turning – try pedaling really fast and then slam on the brakes, the speed will remain constant even though the wheel has stopped moving.
Steve
Sweet!! I’m so glad you were able to use it! I’m new to processing as well, but I’m totally hooked. It’s by far the easiest way to work with graphical processing that I’ve found. Really elegant, and really well documented.
As for your issue with stopping, for some reason I’m not able to replicate it on my end. If it stops getting signals, the graph should drop. Hmmm… unless… could you do me a favor and try swapping the poles of the reed switch on the Arduino for me? Theoretically that might do what you’re describing I think, but I thought I’d tested for that already.
Do let me know what you figure out, and I’ll take a closer look later today as well.
Adam
Adam,
Thanks for sharing your work. I had been tossing around the same idea for a while and just got started on it last week. I am still working on the Arduino end of things. Having your example to follow has been very helpful.
Gregory
Glad to help, Gregory! Let me know when you get it sorted out; I’d love to see what you’re doing with it!
Hi
Nice work of art!
Can you help me code a 3 x 7-seg LED to work as a speedometer to my car ? I got a arduino mega and a hall-sensor. (I will mount the sensor at the driveshaft)
Hi Mikael:
I might be able to help. If you give it a shot, I can look at your code and help you work out the details.
Adam