Pololu-Zumo-Shield-Arduino-boussole

De MCHobby - Wiki
Sauter à la navigation Sauter à la recherche

This example program demonstrates using the magnetometer in the Zumo Shield’s LSM303 3-axis compass module (described in section Section 3.d) to help the Zumo coordinate ninety-degree turns and drive in squares. With the Zumo Shield Arduino Libraries installed, the sketch file can be opened in Arduino by selecting Fichier > Exemples > ZumoExamples > Compass. This example also requires the bibliothèque LSM303 to be installed.

Because the batteries, motors, and motor current affect the z axis of the magnetometer much more strongly than the x and y axes, this program calculates the Zumo’s orientation using only the x and y readings from the magnetometer, assuming that the robot is always level. In order to prevent external, locally varying magnetic fields (e.g. from rebar in a concrete floor) from affecting the Zumo’s navigation too much, the program measures the magnetic heading before each turn, then turns ninety degrees relative to that heading.


Basé sur "Zumo Shield for Arduino" de Pololu (www.pololu.com/docs/0J57) - Traduit en Français par shop.mchobby.be CC-BY-SA pour la traduction
Toute copie doit contenir ce crédit, lien vers cette page et la section "crédit de traduction". Traduit avec l'autorisation expresse de Pololu (www.pololu.com)

Based on "Zumo Shield for Arduino" from Pololu (www.pololu.com/docs/0J57) - Translated to French by shop.mchobby.be CC-BY-SA for the translation
Copies must includes this credit, link to this page and the section "crédit de traduction" (translation credit). Translated with the Pololu's authorization (www.pololu.com)