faut que Val répare le truc

Dependencies:   mbed AX12

Revision:
16:1bbf7e4249d7
Parent:
15:ccfe333bcf76
Child:
17:9ba65b880f06
--- a/main.cpp	Mon Jun 08 13:38:53 2020 +0000
+++ b/main.cpp	Wed Jun 10 12:52:54 2020 +0000
@@ -1,19 +1,13 @@
 /* #include <mbed_events.h> */
 #include "mbed.h"
-<<<<<<< working copy
 
-#define adrr_queue  3
-#define adrr_gauche 4
-#define adrr_droite 2
-=======
 #define adrr_queue  2
 #define adrr_gauche 1
 #define adrr_droite 3
->>>>>>> merge rev
 
-#define hex_queue 0x03
-#define hex_gauche 0x04
-#define hex_droite 0x02
+#define hex_queue 0x02
+#define hex_gauche 0x01
+#define hex_droite 0x03
 
 
 DigitalOut alivenessLED(LED1);
@@ -168,20 +162,23 @@
     float wc = rapport_vitesse*( -0.5 * Vx + (root3 / 2) * Vy + 100 * gammaz);
     /*moteur a */
     SetCRSpeed(adrr_queue, wa);
+    wait(0.1)
     /*moteur b */
     SetCRSpeed(adrr_gauche, wb);
+    wait(0.1)
     /* moteur c */
     SetCRSpeed(adrr_droite, wc);
+    wait(0.1)
 }
 
 void send_stat()
 {
-    coach.printf("S%f,%f,%f,%f,%f \n", front, lat, rot, T_front, T_lat );
+    coach.printf("S%f,%f,%f,%f,%f \r\n", front, lat, rot, T_front, T_lat );
 }
 
 void send_roues()
 {
-    coach.printf("\n\r %5d ; %5d ; %5d ; %5d ; %5d ; %5d", position_1, delta_position_1, position_2, delta_position_2, position_3, delta_position_3);
+    coach.printf("\n\rR %5d ; %5d ; %5d ; %5d ; %5d ; %5d\r\n", position_1, delta_position_1, position_2, delta_position_2, position_3, delta_position_3);
 }
 
 void mise_a_zero_msg_0()
@@ -310,6 +307,7 @@
     delta_position_1 = 0;
     delta_position_2 = 0;
     delta_position_3 = 0;
+    
     while (true) {
         //on regarde la position des moteurs
         switch(etat) {