Electrical Engineering Stack Exchange is a question and answer site for electronics and electrical engineering professionals, students, and enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This might sound a bit weird, but does anybody here know of a exercise bicycle that is hackable? What I would like to do is to connect it to a PC (don't care how, usb, parallel port, serial...) to transfer the current speed in real time. My ultimate goal would be to modify an open source racing game in such a way that the speed on the bike determines the speed of a bike/car in the racing game.

EDIT: By "bicycle ergometer" I mean something that you would find in a fitness center. It is not a real bicycle at all and it usually already comes with an integrated computer. The problem is getting the information out of that computer. Sorry if I caused any confusion, but English is not my native language and "bicycle ergometer" is what my dictionary told me.

share|improve this question
"Ergometer" would seem to mean something for measuring work in Nm or Joules, but you seem to require a speedometer. – Leon Heller May 10 '11 at 11:40
I edited my question to make sure it is clear what kind of "ergometer" I mean. – Kim Stebel May 10 '11 at 13:27
Have you thought about converting a regular bicycle into an exercise bicycle? I've seen devices that lift the back tire off the ground and add resistance using a fan. They look relatively in expensive. This would solve the problem of attaching to a wheel-less exercise bike. – mjh2007 May 10 '11 at 14:32
This sounds interesing. But I'd rather not build something from scratch. The project seems difficult enough to me as it is and I am not an engineer but a programmer with some knowledge of electronics. – Kim Stebel May 10 '11 at 15:01
If you want to avoid changing the electronics and want to do everything in software then you are going to need to find an exercise bike that has a PC interface RS-232, USB, or Ethernet and publishes the protocol details. Good luck. – mjh2007 May 11 '11 at 13:42
up vote 4 down vote accepted

Maybe I misunderstood your question, since all answers describe so far how to build a system that measures the pedal RPMs (rounds per minute) of a bike or something like that.

However, you just asked for a bicycle ergometer such as in fitness studios which can be connected to a PC to read its current speed and so on. Well, that's quite simple. For instance there are a lot of Kettler ergometers with USB or RS232 port that allow you to connect the ergometer to your PC, send commands from your PC to your ergometer and receive information about your current speed, pedal RPM, pulse, power, ...

Moreover, Kettler uses a very simple, character-based communication protocol in their ergometer devices - or at least in the AX1, E3, E5, Ergorace, X3, X7, and RX7 - that are the devices I heard from users to be compatible to JErgometer, my open source ergometer software written in Java. By now I did not hear from any user that JErgometer did not work with his/her Kettler ergometer, but well, who knows?

Since JErgometer is licensed under GPLv2 you can use the code in your racing game as long as this game is licensed under GPLv2 too or any compatible license.

Of course you are also welcome to join the project if you like to extend it to a racing game or whatsoever. :-)

share|improve this answer
That sounds like exactly what I was looking for, thanks! I'll definitely have a look at JErgometer. – Kim Stebel Nov 6 '11 at 16:56

Most bicycle speedometers I've seen use a magnet on the wheel and a hall effect mounted to the fork. The microprocessor would then measure the time between the magnet rotating passed the sensor on the wheel. You can use this time measurement to calculate RPMs.

share|improve this answer
I thought about this design as well, but where would I mount such a sensor on the kind of "bicycle" used in fitness centers? – Kim Stebel May 10 '11 at 13:39
there is usually a flywheel of some kind. Or you can mount the magnet on the chainwheel. Cadence is proportional to wheel RPM on a fixed-gear bike like a fitness bike. – markrages May 10 '11 at 14:27
You say the bicycle already has a computer. Look for its speed sensor. If it is a magnet / reed switch, you can mount another reed switch nearby to be tripped by the same magnet. – markrages May 10 '11 at 14:27
Most of these bicycles (haven't decided which one to use) come with several resistance levels that make it harder/less hard to move the pedals (like driving in different gears). How would I get the speed if I did't know in which "gear" the bicycle is? In addition, it seems rather wasteful to me to duplicate what is already there. Thus I would really like to know if there is any solution that uses the speed computed by the bicycle's computer. – Kim Stebel May 10 '11 at 14:59
@Kim Stebel - are you sure they use gearing? I was under the impression they simply changed the friction factor. – JustJeff May 10 '11 at 20:55

You can sign up to read the ANT+ spec at http://thisisant.com. Then you can use off-the-shelf sensors for speed, cadence, or power. Buy an ANT receiver USB stick from Garmin and you have a wireless link to your computer. One stick can receive from multiple sensors as well, so you can receive from several bikes for a competition scenario. Recent builds of Golden Cheetah ( http://goldencheetah.org ) also have real-time ANT receiving built-in.

share|improve this answer
For reasons explained in other comments, I'd rather not use my own sensors. And wireless data transmission really isn't needed, at least not for now. – Kim Stebel May 10 '11 at 15:07

Since I've worked on embedded systems for yonks I'd find it easier to develop something from scratch using a suitable small MCU that took input from a sensor on the bike and input it to the PC. The only suitable interface on modern PCs is a USB port. I have designed this small prototyping board with a USB PIC to go with Brad Minch's USB software, that would be suitable. It costs about $10 to build.

The bike is on rollers, presumably, so you will need to compute the "road speed" from the wheel RPM, knowing the diameter of the wheel.

share|improve this answer
"suitable" is really dependent upon the hobbyist's comfort level with certain technologies. I think it's reasonable to say that RS232 is a good lowest-common-denominator PC interface, and FTDI chips make it very easy to implement serial interfaces when your PC only has a USB port. Bike stands are common as well, so the OP could use a stand + mjh2007's suggestion and the execution would probably be simpler than coming up with rollers and an additional support for the bike. – Dave May 10 '11 at 13:15

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.