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: HIDScope MODSERIAL biquadFilter mbed
Diff: main.cpp
- Revision:
- 1:83f7e225f7a4
- Parent:
- 0:9033b790f263
- Child:
- 2:0c8c3ae5e1b7
diff -r 9033b790f263 -r 83f7e225f7a4 main.cpp
--- a/main.cpp Tue Nov 01 10:35:26 2016 +0000
+++ b/main.cpp Tue Nov 01 14:44:00 2016 +0000
@@ -9,7 +9,7 @@
AnalogIn emg1( A1 );
AnalogIn emg2( A2 );
MODSERIAL pc (USBTX, USBRX);
-InterruptIn knopje1 (D2);
+InterruptIn knopje1 (SW2);
Ticker sample_timer;
HIDScope scope( 3 ); // 3-channel HIDScope object
@@ -122,6 +122,7 @@
{
x++;
y = false;
+ pc.printf("GoOn x=%i en y=%i\n\r",x,y);
}
void StartMeting()
@@ -131,25 +132,29 @@
case 0:
pc.printf("case 0\n\r");
y = true;
- while(y == true) {}
+ while(y == true) {pc.printf("%i",y);}
+ break;
case 1:
pc.printf("case 1\n\r");
Spier1Max = GetMaximumSpier1();
pc.printf("Spier1Max = %f\n\r",Spier1Max);
y = true;
- while(y == true) {}
+ while(y == true) {pc.printf("%i",y);}
+ break;
case 2:
pc.printf("case 2\n\r");
Spier2Max = GetMaximumSpier2();
pc.printf("Spier2Max = %f\n\r",Spier2Max);
y = true;
- while (y == true) {}
+ while (y == true) {pc.printf("%i",y);}
+ break;
case 3:
pc.printf("case 3\n\r");
Spier3Max = GetMaximumSpier3();
pc.printf("Spier3Max = %f\n\r",Spier3Max);
y = true;
- while (y == true) {}
+ while (y == true) {pc.printf("%i",y);}
+ break;
case 4:
pc.printf("case 4\n\r");
break;
@@ -167,6 +172,9 @@
pc.printf("START\n\r");
knopje1.fall(GoOn);
StartMeting();
+ StartMeting();
+ StartMeting();
+ StartMeting();
pc.printf("Spiermax1 = %f\n\rSpiermax2 = %f\n\rSpier3max = %f\n\r\n\n",Spier1Max,Spier2Max,Spier3Max);
while(1) {} // Empty loop, sample() is executed periodically