This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Calculate the traveled angle from the gyro
#1
Hello Everyone,
i'd like to set up a custom experiment to improve the workflow.
But I don't fully understand the complex editor and need some help to make the right connections.

My Experiment:
My phone lies on the axis of a motor. With the Gyroscope Experiment I get the rate of rotation.
Now I would like to expand this experiment to plot the traveled angle.

In formulas it looks like this:

1. w [rad/s] -> p [°/s] ->DONE
p = w/(2*PI)*360

2. p [°/s] -> a [°] (absolute angle) -> IN PROGRESS
a = p * (actual time - last time) + last a

actual time is the time of the latest measurement
last time is the time of the last measurement
last a is the last calculated a

Where I need help:
- How to calculate (get) the timestamp of the last measurement (last time)?
- How to feed the second formula with the last calculated angle (last a)?

In the graph it would display the traveled angle (y-axis) and the time (x-axis)
I.e. "The motor reached 90° after 10s"

In Excel the formulas work fine and it seems to be very precise.

Thank you for all the help!
Reply


Messages In This Thread
Calculate the traveled angle from the gyro - by p.saal - 10-06-2023, 11:34 AM

Forum Jump: