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:
- 1:9601b4b78de5
- Parent:
- 0:b7cb5d3978b5
- Child:
- 2:4dcdf7755a04
--- a/main.cpp Fri Sep 23 10:16:33 2016 +0000
+++ b/main.cpp Fri Sep 23 12:25:47 2016 +0000
@@ -22,33 +22,33 @@
}
else {
n=n;
- pc.printf("geen switch");
+ pc.printf("geen switch\r");
}
if (n%2 == 0) { //runt menuutje 1 als het even is
//menu 1
- pc.printf("n is even \n");
+ pc.printf("n is even \n\r");
wait (0.5);
char c = pc.getc();
if (c == 's'){
- pc.printf("up \n");
+ pc.printf("up \n\r");
wait (0.5);
}
else if (c == 'd'){
- pc.printf("down /n");
+ pc.printf("down \r\n");
wait (0.5);}
}
else { // runt menuutje 2 als het oneven is
// menu 2
- pc.printf("n is oneven \n");
+ pc.printf("n is oneven \n\r");
wait (0.5);
char c = pc.getc();
if (c == 's'){
- pc.printf("right \n");
+ pc.printf("right \n\r");
wait (0.5);}
else if (c == 'd'){
- pc.printf("left /n");
+ pc.printf("left \n\r");
wait (0.5);}
else {}