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 QEI PTC3471 USBDevice
Diff: main.cpp
- Revision:
- 6:1e36bdd96b54
- Parent:
- 4:fce4df73faab
- Child:
- 7:661ef6a3c052
--- a/main.cpp Wed Sep 23 15:52:56 2020 +0000
+++ b/main.cpp Thu Oct 22 16:47:36 2020 +0000
@@ -41,7 +41,7 @@
double dth1_f = 0; // dth1 -> Velocidade do pêndulo c/ filtro
int16_t th0_f_int = 0, th1_f_int = 0; // Variável convertida para inteiro para ser
-int16_t dth0_f_int = 0, dth1_f_int = 0; // transmitida via serial (economia de banda)
+int16_t dth0_f_int = 0, dth1_f_int = 0, u_int = 0; // transmitida via serial (economia de banda)
double tau = 5e-2; // Cte de tempo do FPB
@@ -96,9 +96,13 @@
th1_f_int = th1_f*1000;
dth0_f_int = dth0_f*1000;
dth1_f_int = dth1_f*1000;
+ u_int = u*1000;
+
PlotCount = 0;
- pc.printf("%d \t %d \t %d \t %d\n\r", th0_f_int, dth0_f_int, th1_f_int, dth1_f_int);
-
+
+ pc.printf("%d \t %d \t %d \t %d \t %d\n\r", th0_f_int, th1_f_int, dth0_f_int, dth1_f_int, u_int);
+
+
}
Flag_Controle = false; // Sinaliza que deve-se esperar o próximo sinal da interrupção