From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
Hi, i am trying to get rotation angle of my robot with PmodCMPS. But i have only 3 coords X, Y and Z and don`t know what to do with it. How can i convert this coords to global rotation angle? I am using default example for compass in "Part II - NI myRIO Mechatronics Kit"
Just for clarification, are you wanting to convert the x, y, and z (Cartesian) coordinates to spherical coordinates? If so, there is a VI that you can use for that:
I just want to get angle to the global North to create rotation on some value of degrees for my robot. It`s like if I want to rotate on 90 degrees I have to move my motors and getting value from compass while delta of degrees is less then 90. Or maybe you have some better ideas how to rotate my robot? (I think getting value from encoders is not right way because it`s not too accurate if I will change size between wheels)
I actually haven't worked with the PmodCMPS before, so I may need to do a bit more research. In the meantime, have you taken a look at any of these examples?