Simple test
------------

Ensure your device works with this simple test.

.. literalinclude:: ../examples/lis3mdl_simpletest.py
    :caption: examples/lis3mdl_simpletest.py
    :linenos:

Compass Example
---------------

Use the magnetometer to calculate compass headings.

.. literalinclude:: ../examples/lis3mdl_compass.py
    :caption: examples/lis3mdl_compass.py
    :linenos: