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.
Dependencies: biquadFilter mbed MODSERIAL
Diff: main.cpp
- Revision:
- 1:9e871647a074
- Parent:
- 0:51a6e38a4d4a
- Child:
- 2:bf1c9d7afabd
--- a/main.cpp Thu Oct 26 12:49:05 2017 +0000 +++ b/main.cpp Thu Oct 26 12:56:31 2017 +0000 @@ -311,16 +311,16 @@ double maxVelocity1=Vex*25+Vey*25; // max 8.4 in rad/s of course! referenceVelocity1 = (-1)*speedfactor1 * maxVelocity1; - if (Encoder1.getPulses() < (dcounto+10)) + if (dcounto < (10)) { speedfactor1 = 0.01; - if (Encoder1.getPulses() > (dcounto-10)) + if (dcounto > (-10)) { printf("kleiner111111111"); speedfactor1=0; } } - else if (Encoder1.getPulses() > (dcounto-10)) + else if (dcounto > (-10)) { speedfactor1 = -0.01; - if (Encoder1.getPulses() < (dcounto+10)) + if (dcounto < (10)) { printf("groter"); speedfactor1=0; }