开发者

iPad app for measuring the speed of a treadmill [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 10 years ago.

I would like to make an application on xCode for iPad to check the speed of person running on treadmill.

I am really getting no idea, how to do it? Can anyone give me some idea, sample codes etc. to do it? Should we have to use accelerometer/speedometer for this? If yes then how can we use accelerometer/speedometer?

I am very new to iPhone development. Any idea would be appreciated greatly开发者_Go百科 in this regards.


Put a constant tone generator of some sort on one or both shoes (maybe a piezo + 555 run by a coin cell). Record the sound on the iPad, and use a software PLL or FFT to measure the changes in the Doppler shift of the tone frequency as the shoe moves back at belt velocity and then forward again. Compensate for the height and horizontal position of the iPad mic in relation to the center of the treadmill belt, or put a headset mic directly in front or behind the axis of the running surface.


You'd need to be able to measure the strides. The Nike+ app uses a device placed on the shoe and bluetooth to communicate with the iPhone.

I've see similar ANT+ devices from third parties that have libraries and API you could use to develop. (e.g. Wahoo Fitness) that seem to be supported by the main running/fitness apps.

Once you have the timing of the person's strides you could combine that with the length of stride to get an indication your speed.


Here's how it can be done. The user will need to modify their treadmill.

  • Have the user place a strip of masking or duct tape across the treadmill belt. (similar to this 0:35, but only one) They can also paint it.
  • Have the user enter the length of the treadmill belt (front-back).
  • Have the user point their phone downwards at the treadmill, so that the tape fills the entire view of the iPhone camera. It will need to be close to the belt.
  • Your app should capture video of the treadmill belt.
  • You'll need a sophisticated image recognition software to detect when the image captured by the camera is no longer black (i.e. the tape has passed by). The time between when the tape passes is dt.
  • You get the user's speed by this formula: lengthOfBelt*2.0f/dt

Good luck.


Hummm, I think it will be hard to measure speed of a treadmill. Only the treadmill running. The top if the body if the person should be fixed. You will measure small acceleration, but no easy relation with speed (most of them will be vertical mouvement)...

If you fix the iPhone on the shoes, it is possible, but...


An object with constant speed has an acceleration of zero....


You can use the accelerometers.

Have an app that allows you to input the length of the treadmill then place the iPhone at the front of the treadmill. The iPhone will accelerate pretty rapidly up to the speed of the treadmill and this is the cue to for the app to start timing.

When it reaches the end of the treadmill, the iPhone will start accelerating downwards in accordance with Newton's Theory of Gravity. This is the cue for the app to stop timing, calculate its average speed and transfer its result to a server via wifi or Bluetooth.

The iPhone is almost certainly powerful enough to complete the transfer before hitting the ground and smashing into a million pieces.


Get location and save it. And after few second get location again.

Get distance between two point and device it by time gap. That's the running man's speed.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜