In this Instructable, we will be building a compass using the TinyShield Compass as well as the Circle Edge Led shield. Before starting, the proper drivers must be installed to detect the COM ports. These drivers must be installed before downloading any codes from the codebender plugin. The drivers needed can be found here.
Step 1: Materials
Step 2: Programming the Tiny Duino
The code below was used for the TinyCompass and has comments throughout to help explain what is going on. The magnetometer used for our compass board is the HoneywellHMC5883L 3-axis compass. This code can be downloaded to your computer or directly uploaded to your TinyDuino processor board.
Step 3: Calibration
After your TinyDuino has been programmed you can remove the USB Shield. Each time you turn on or restart the processor, you will need to calibrate it. To calibrate, simply rotate it 360 degrees on each axis (the gifs above show exactly what to do). We now have fully functional compass that takes up less than a cubic inch of space! Because of how sensitive the HCM5883L chip is, ferromagnetic materials, magnetized or not, within a 2 inch radius of the chip will cause disturbances.
Reza Azar made it!