| Ligne 19 : |
Ligne 19 : |
| | <syntaxhighlight lang="c"> | | <syntaxhighlight lang="c"> |
| | /* | | /* |
| − | * Demo line-following code for the Pololu Zumo Robot | + | * Code de démo suiveur de ligne (line-following) pour le Robot Zumo de Polulo |
| | * | | * |
| − | * This code will follow a black line on a white background, using a | + | * Ce code suivra une ligne noire sur un fond blan et utilise un |
| − | * PID-based algorithm. It works decently on courses with smooth, 6" | + | * algorithme de type PID. Il fonctionne correctement sur des |
| − | * radius curves and has been tested with Zumos using 30:1 HP and | + | * circuits avec des courbes ayant un rayon de 15 cm. |
| − | * 75:1 HP motors. Modifications might be required for it to work | + | * L'algorithme à été testé sur Zumo avec des moteurs 30:1 HP et |
| − | * well on different courses or with different motors. | + | * 75:1 HP. Pourrait demander des modifications pour fonctionner |
| | + | * sur d'autres circuits ou avec d'autres moteurs. |
| | * | | * |
| | * http://www.pololu.com/catalog/product/2506 | | * http://www.pololu.com/catalog/product/2506 |
| | * http://www.pololu.com | | * http://www.pololu.com |
| | * http://forum.pololu.com | | * http://forum.pololu.com |
| | + | * |
| | + | * Zumo également disponible chez MC Hobby (le traducteur du tutoriel) |
| | + | * |
| | + | * http://shop.mchobby.be/product.php?id_product=448 |
| | */ | | */ |
| | | | |
| Ligne 45 : |
Ligne 50 : |
| | int lastError = 0; | | int lastError = 0; |
| | | | |
| − | // This is the maximum speed the motors will be allowed to turn. | + | // Ceci est la vitesse de rotation maximale des moteurs. |
| − | // (400 lets the motors go at top speed; decrease to impose a speed limit) | + | // (400 permet au moteur d'aller a vitesse max; diminuer la valeur pour imposer une vitesse limite) |
| | const int MAX_SPEED = 400; | | const int MAX_SPEED = 400; |
| | | | |