Rover 5: how to determine direction with a compass (LSM303)
January 19, 2013
I recently bought a Rover 5 and an Arduino Uno and made my first sketches. My goal is to let the Rover drive standalone in our livingroom, avoiding objects, childrens and pets ;-).
I gave the Rover a pan/tilt-system with an ultrasonic sensor to measure “free distance”. I also installed a compass (on the pan/tilt-system) to determine the “direction of the free space” (https://www.sparkfun.com/products/10703). The idea is to direct the Rover to the found free space using the compass information (and encoder outputs of the motors).
The use and programming of the compass however is complex (underestimated that ;-) and the examples that I found are complicated. I would appreciate your help here. How to determine directions in a horizontal pane with my compass (X, Y coordinates only)?
Thanks in advance. Regards, Ko