Outils pour utilisateurs

Outils du site


robots:tondobot:tondobot

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
robots:tondobot:tondobot [09/2018] – [RC link] fredrobots:tondobot:tondobot [02/2019] (Version actuelle) – [a vide] fred
Ligne 1: Ligne 1:
 +====== meca ======
 +{{:robots:tondobot:demontee.jpg?600|}}
 +{{:robots:tondobot:arriere0.jpg?600|}}
 +{{:robots:tondobot:arriere_monte.jpg?600|}}
 +{{:robots:tondobot:face_monte.jpg?600|}}
 +
 +===== moteur d"essuie glace =====
 +==== a vide ====
 +  * 13v      0,9 amp      58t/mn
 +  * 6v       0,6 amp      16t/mn 
 +
 +test sur table a vide avec moteur de laguna: 
 +  * petite vitesse 17 tours pour 30s
 +  * grande vitesse 32 tours pour 30s
 ====== HW ====== ====== HW ======
   * https://www.ebay.fr/itm/Nano-V3-0-ATmega328P-with-USB-Cable-Compatible-for-Arduino-CH340G-Deutsche-Post/232271829785?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2057872.m2749.l2649   * https://www.ebay.fr/itm/Nano-V3-0-ATmega328P-with-USB-Cable-Compatible-for-Arduino-CH340G-Deutsche-Post/232271829785?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2057872.m2749.l2649
Ligne 25: Ligne 39:
 |Mot_G_L_EN|  PCINT0  |  PWM_T2  |  MOSI  |  11  ^** **|  3v3  |         | | |Mot_G_L_EN|  PCINT0  |  PWM_T2  |  MOSI  |  11  ^** **|  3v3  |         | |
 |Mot_G_R_EN|  PCINT0  |      MISO  |  12  ^** **|  13  |  LED /SCK  |  PCINT0  |LED_PCB  | |Mot_G_R_EN|  PCINT0  |      MISO  |  12  ^** **|  13  |  LED /SCK  |  PCINT0  |LED_PCB  |
 +
 +
 +==== Module BTS7960B ====
 +^  A. Nano  ^  FNC  ^  n  ^  n  ^  FNC  ^  A. Nano  |
 +|  Mot_X_R_EN  |  RPWM  ^  1  ^  2  |  LPWM  |  Mot_X_L_EN  |
 +|  Mot_X_PWM  |  R_EN  ^  3  ^  4  |  L_EN  |  Mot_X_PWM  |
 +|  Mot_X_IS_R  |  R_IS  ^  5  ^  6  |  L_IS  |  Mot_X_IS_L  |
 +|  VCC  |  VCC  ^  7  ^  8  |  GND  |  GND  |
 +
 +
  
 ====== SW ====== ====== SW ======
Ligne 152: Ligne 176:
 #define PIN_SERVO_GD 2 #define PIN_SERVO_GD 2
 #define PIN_SERVO_AVAR 3 #define PIN_SERVO_AVAR 3
 +
 #define PIN_MOT_D_PWM 9 #define PIN_MOT_D_PWM 9
 #define PIN_MOT_D_L_EN 7    //sens arriere #define PIN_MOT_D_L_EN 7    //sens arriere
 #define PIN_MOT_D_R_EN 8    //sens avant #define PIN_MOT_D_R_EN 8    //sens avant
 +
 #define PIN_MOT_G_PWM 10 #define PIN_MOT_G_PWM 10
 #define PIN_MOT_G_L_EN 11    //sens arriere #define PIN_MOT_G_L_EN 11    //sens arriere
 #define PIN_MOT_G_R_EN 12    //sens avant #define PIN_MOT_G_R_EN 12    //sens avant
 +
 #define PIN_MOT_D_L_IS A7     //sens arriere #define PIN_MOT_D_L_IS A7     //sens arriere
 #define PIN_MOT_G_L_IS A6     //sens arriere #define PIN_MOT_G_L_IS A6     //sens arriere
Ligne 188: Ligne 215:
   else   else
   {   {
-     analogWrite(PIN_MOT_D_PWM, cmd);+     analogWrite(PIN_MOT_D_PWM, abs(cmd));
      digitalWrite(PIN_MOT_D_R_EN, LOW);      digitalWrite(PIN_MOT_D_R_EN, LOW);
      digitalWrite(PIN_MOT_D_L_EN, HIGH);      digitalWrite(PIN_MOT_D_L_EN, HIGH);
Ligne 210: Ligne 237:
   else   else
   {   {
-     analogWrite(PIN_MOT_G_PWM, cmd);+     analogWrite(PIN_MOT_G_PWM, abs(cmd));
      digitalWrite(PIN_MOT_G_R_EN, LOW);      digitalWrite(PIN_MOT_G_R_EN, LOW);
      digitalWrite(PIN_MOT_G_L_EN, HIGH);      digitalWrite(PIN_MOT_G_L_EN, HIGH);
Ligne 286: Ligne 313:
     interrupts();     interrupts();
     //mise en borne et conversion des commande versos     //mise en borne et conversion des commande versos
-    if (SERVO_GD_Pulse_micros < 500) SERVO_GD_Pulse_micros = 1500;  // pour traiter le cas ou on a pas de servo connecté +    if (SERVO_GD_Pulse_micros < 850) SERVO_GD_Pulse_micros = 1500;  // pour traiter le cas ou on a pas de servo connecté 
-    if ((SERVO_GD_Pulse_micros > 1490) &&  (SERVO_GD_Pulse_micros < 1510))SERVO_GD_Pulse_micros = 1500; // pour avoir une zone neutre +    if (SERVO_GD_Pulse_micros > 2200) SERVO_GD_Pulse_micros = 1500;  // pour traiter le cas ou on a pas de servo connecté 
 +    if ((SERVO_GD_Pulse_micros > 1480) &&  (SERVO_GD_Pulse_micros < 1520))SERVO_GD_Pulse_micros = 1500; // pour avoir une zone neutre 
     SERVO_GD_Pulse_micros=constrain(SERVO_GD_Pulse_micros, 1000, 2000);     SERVO_GD_Pulse_micros=constrain(SERVO_GD_Pulse_micros, 1000, 2000);
     CMD_GD = map(SERVO_GD_Pulse_micros,1000,2000,-255,255);     CMD_GD = map(SERVO_GD_Pulse_micros,1000,2000,-255,255);
  
          
-    if (SERVO_AVAR_Pulse_micros < 500) SERVO_AVAR_Pulse_micros = 1500;  // pour traiter le cas ou on a pas de servo connecté +    if (SERVO_AVAR_Pulse_micros < 850) SERVO_AVAR_Pulse_micros = 1500;  // pour traiter le cas ou on a pas de servo connecté 
-    if ((SERVO_AVAR_Pulse_micros > 1490) &&  (SERVO_AVAR_Pulse_micros < 1510))SERVO_AVAR_Pulse_micros = 1500; // pour avoir une zone neutre +    if (SERVO_AVAR_Pulse_micros > 2200) SERVO_AVAR_Pulse_micros = 1500;  // pour traiter le cas ou on a pas de servo connecté 
 +    if ((SERVO_AVAR_Pulse_micros > 1480) &&  (SERVO_AVAR_Pulse_micros < 1520))SERVO_AVAR_Pulse_micros = 1500; // pour avoir une zone neutre 
     SERVO_AVAR_Pulse_micros=constrain(SERVO_AVAR_Pulse_micros, 1000, 2000);     SERVO_AVAR_Pulse_micros=constrain(SERVO_AVAR_Pulse_micros, 1000, 2000);
     CMD_AVAR = map(SERVO_AVAR_Pulse_micros,1000,2000,-255,255);     CMD_AVAR = map(SERVO_AVAR_Pulse_micros,1000,2000,-255,255);
          
-    MOT_D_CMD_s16 = CMD_GD; +    MOT_D_CMD_s16 = constrain(CMD_AVAR - CMD_GD,-255,255)
-    MOT_G_CMD_s16 = CMD_AVAR;+    MOT_G_CMD_s16 = constrain(CMD_AVAR + CMD_GD,-255,255);
          
     update_MOT_D_PWMs(MOT_D_CMD_s16);     update_MOT_D_PWMs(MOT_D_CMD_s16);
Ligne 322: Ligne 351:
     //Serial.print("\r");     //Serial.print("\r");
  
 +    
   } // end of task   } // end of task
      
 } }
 +
 </code> </code>
 +
 +====== idées ======
 +  * https://github.com/nasa-jpl/open-source-rover
 +    * https://www.pololu.com/product/2591 optical encoder
 +    * https://www.pololu.com/product/3081 magnetic encoder
 +  * http://www.robot-maker.com/forum/topic/6355-cede-robot-tondeuse-pour-somme-modique/
 +  * http://bennurre2.blogspot.com/
 +  * http://bennurre4.blogspot.com/
 +
robots/tondobot/tondobot.1537173427.txt.gz · Dernière modification : 09/2018 de fred