![]() If you decide to lift your micro:bit off the table, then you’ve just added another dimension, so insert the acceleration value for the Z axis into the equation: Strength2D = Math.sqrt((accelX * accelX) + (accelY * accelY)) ![]() You can find the acceleration in that direction just like how you calculate the long side of a triangle using the two shorter sides ( X and Y): If you put your micro:bit on a level table and push it diagonally, you have an acceleration in two dimensions. If the movement of an object isn’t exactly in the direction of one axis, we need a way to calculate its acceleration from the values measured for all the axes together. ![]() Since we don’t live on a flat world, forces happen in three dimensional space.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |