diff --git a/Asser_Position.c b/Asser_Position.c index 74870ff..671fd1f 100644 --- a/Asser_Position.c +++ b/Asser_Position.c @@ -47,9 +47,11 @@ void Asser_Position(struct position_t position_consigne){ avance_mm_s = delta_avance_mm * GAIN_P_POSITION; rotation_radian_s = delta_orientation_radian * GAIN_P_ORIENTATION; - if(delta_avance_mm < 10){ + /// TODO: Gérer correctement les fins de trajectoire sans que ça ait un impact sur le début + /// On a le cas d'une trajectoire circulaire qui saute au démarrage + /*if(delta_avance_mm < 10){ rotation_radian_s=0; - } + }*/ // Commande en vitesse commande_vitesse(avance_mm_s, rotation_radian_s); diff --git a/Strategie_PAMI.c b/Strategie_PAMI.c index 2b6d210..fedade3 100644 --- a/Strategie_PAMI.c +++ b/Strategie_PAMI.c @@ -51,7 +51,7 @@ void configure_trajet(int identifiant, int couleur){ case 6: break; case 7: - Trajet_config(TRAJECT_CONFIG_RAPIDE_ROUGE); + Trajet_config(200, 200); Localisation_set(100, 0, M_PI/2.); Trajectoire_circulaire(&trajectoire, 0, 0, 0, 360, 100, M_PI / 2., M_PI / 2.); break; @@ -99,9 +99,9 @@ void configure_trajet(int identifiant, int couleur){ case 6: break; case 7: - Trajet_config(200, 1200); - Localisation_set(50, 0, M_PI/2.); - Trajectoire_circulaire(&trajectoire, 0, 0, 0, 360, 50, M_PI / 2., M_PI / 2.); + Trajet_config(200, 200); + Localisation_set(100, 0, M_PI/2.); + Trajectoire_circulaire(&trajectoire, 0, 0, 0, 360, 100, M_PI / 2., M_PI / 2.); break; diff --git a/main.c b/main.c index b12dc22..58e7f9e 100644 --- a/main.c +++ b/main.c @@ -119,7 +119,7 @@ void main(void) if(temps_ms % step_ms == 0){ // Fonctions cycliques QEI_update(); - Localisation_gestion(); + Localisation_gestion(); // Stratégie if(etat_trajet != TRAJET_TERMINE){ @@ -176,7 +176,7 @@ void affichage_udp(void){ Teleplot_add_variable_float_2decimal("abs", abscisse); Teleplot_add_variable_float_2decimal("pos_x", position_actuelle.x_mm); Teleplot_add_variable_float_2decimal("pos_y", position_actuelle.y_mm); - Teleplot_add_variable_float_2decimal("pos_angle", position_actuelle.angle_radian); + Teleplot_add_variable_float_2decimal("pos_angle", Geometrie_get_angle_normalisee(position_actuelle.angle_radian)); Teleplot_add_variable_float_2decimal("con_x", point.point_xy.x); Teleplot_add_variable_float_2decimal("con_y", point.point_xy.y);