Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: Motor.cpp
- Revision:
- 3:8f4f4d3a91bc
- Parent:
- 2:3bf51023ea23
- Child:
- 4:d5b4ba5454d4
- Child:
- 6:a9ab4e153009
diff -r 3bf51023ea23 -r 8f4f4d3a91bc Motor.cpp
--- a/Motor.cpp Mon Mar 23 19:06:20 2015 +0000
+++ b/Motor.cpp Sat Apr 25 02:42:23 2015 +0000
@@ -102,6 +102,8 @@
float delta_spd = target_spd - actual_spd;
+ //if delta_spd large, brake this cycle.
+
(*iState) += delta_spd;
if ((*iState)*ki > iLimit) {
(*iState) = iLimit;