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: mbed MODSERIAL QEI
Diff: main.cpp
- Revision:
- 9:4870f0e789f8
- Parent:
- 7:9dc08a9a5991
- Child:
- 10:06d0fe6b3bcf
--- a/main.cpp Fri Sep 30 09:56:19 2016 +0000
+++ b/main.cpp Fri Sep 30 11:29:25 2016 +0000
@@ -1,8 +1,8 @@
#include "mbed.h"
//#include "MODSERIAL.h"
-DigitalOut led(LED_RED);
-DigitalOut led2(LED_BLUE);
+//DigitalOut led(LED_RED);
+//DigitalOut led2(LED_BLUE);
InterruptIn sw3(SW3);
Serial pc(USBTX, USBRX);
DigitalOut motor1(D4);
@@ -33,7 +33,7 @@
pc.printf("up \n\r"); // print lijn "up"
motor1 = 1;
pwm_motor1 = 1;
- wait (0.05);
+ wait (0.03);
pwm_motor1 = 0;
}
@@ -43,7 +43,7 @@
pc.printf("left \n\r"); // print lijn "left"
motor2 = 1;
pwm_motor2 = 1;
- wait (0.05);
+ wait (0.03);
pwm_motor2 = 0;
}
@@ -56,7 +56,7 @@
pc.printf("down \n\r"); // print lijn "down"
motor1 = 0;
pwm_motor1 = 1;
- wait (0.05);
+ wait (0.03);
pwm_motor1 = 0;
}
@@ -66,7 +66,7 @@
pc.printf("right \n\r"); // print lijn "right"
motor2 = 0;
pwm_motor2 = 1;
- wait (0.05);
+ wait (0.03);
pwm_motor2=0;
}