Adjust Code

The original code from Carter's Triangle Time Thing learn guide will need to be modified slightly. The Feather Sense is mounted in a different orientation so the accelerometer coordinates will need to be changed in order to match the new position.

Look for line 42 in the code and update the following values to match the new coordinates.

# rotate coords
    xx = az - ay
    yy = az + ay
    zz = ax

Save the updated values to the file using Mu editor or your preferred text editor. Make sure the file has been updated on the CIRCUITPY drive.

This guide was first published on Jul 07, 2020. It was last updated on Nov 25, 2023.

This page (Modify Code) was last updated on Jul 06, 2020.

Text editor powered by tinymce.