0

Im using a handyboard and interactive c software and the task is to find the rpm of a lego motor in real time using an Infrared "Break Beam" Sensor on the wheel. I was thinking about finding the time interval between the beam being broken and then from there calculating the rpm but i cant figure out exactly how to do that. Any help would be much appreciated thanks.

4

3 に答える 3

1

次のような意味を持ってください:http ://www.cplusplus.com/reference/clibrary/ctime/

(ニールが示唆しているように)より良い解決策があると思いますが、これが最も簡単です。

于 2009-08-30T11:47:32.267 に答える
0

Win32 にアクセスできる場合は、QueryPerformanceFrequencyを使用して間隔の時間を計算できます。また、ゲームで 1 秒あたりのフレーム数を決定するためにもよく使用されるため、非常に正確です。

于 2009-08-30T11:51:28.123 に答える
0

あなたはv9モーターを使用しているので、私は自分で便利なボードを持っていますよね?モーターにかかる電圧から計算できると思います。さらに、良い参考文献、Robotic Exploration

于 2011-07-26T08:18:54.440 に答える