Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

metronome 1

Status
Not open for further replies.

turborob

Programmer
Dec 10, 2000
51
0
0
GB
could anyone point me in the right direction to produce a metronome program.
i dont know much on pascal so many thanks for in advance for a lot of info.
i need it to check my cadence on the indoor cycle trainer i have, or do you know of a site i could download a metronome prog from.
thanks....ROB
 
You can search on google to find an existing metronome application.
If you want to program one yourself, you can use the [tt]sound[/tt], [tt]nosound[/tt] and [tt]delay[/tt] functions of the [tt]crt[/tt] unit.

Regards,
Bert Vingerhoets
vingerhoetsbert@hotmail.com
Don't worry what people think about you. They're too busy wondering what you think about them.
 
Remember that the Pascal delay function is not very accurate on new computers.
 
Indeed, but you can overcome this problem by calibrating a correcting factor: perform a long delay and see how long it really takes with gettime.

Regards,
Bert Vingerhoets
vingerhoetsbert@hotmail.com
Don't worry what people think about you. They're too busy wondering what you think about them.
 
I'd be more concerned that crt on new, fast computers can be problematic (the well-known division by zero error). You can download a patch, or use the system time to make up your own reasonably reliable timer. But there are lots more ways to time things. Frankly if you're writing something for a bit of fun, to use on your own computer at home, purely for your own fitness training, you could even get away with the old-fashioned very large for-next loop and calibrate it with a stop watch. It'll be completely different on another machine, but that isn't going to be a problem for you.
Good luck!
 
Thanks for all your posts everyone.
I have taken bertv100's tip and gone for an existing metronome application.
Sorted.
ROB.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top