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: SensoryTest
Fork of btbee by
Revision 14:7ddbd9f475ad, committed 2014-05-21
- Comitter:
- mmpeter
- Date:
- Wed May 21 12:06:54 2014 +0000
- Parent:
- 13:4016c362b0d5
- Child:
- 15:cc5b8a858c6e
- Commit message:
- speed = 0.25, k =-0.3
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Wed May 21 11:58:27 2014 +0000
+++ b/main.cpp Wed May 21 12:06:54 2014 +0000
@@ -6,9 +6,9 @@
int main() {
- float speed = 0.5;
+ float speed = 0.25;
float correction;
- float k = -0.9;
+ float k = -0.3;
thinggy.locate(0,1);
@@ -19,7 +19,7 @@
thinggy.sensor_auto_calibrate();
while(1) {
- wait(0.05);
+
// -1.0 is far left, 1.0 is far right, 0.0 in the middle
float position = thinggy.line_position();
correction = k*(position);
