LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

RC plane stabilization with IMU

I wanted to create an interesting topic because there is no labview example 🙂

 

Let's say that Euler angles, Quaternion, Rotation matrix information are read from IMU without any problem. There is no deviation in Yaw angle.
For example, what algorithm can be used if an RC plane needs to fix both the roll and yaw angles at 0 degrees while climbing upwards at a 90 degree pitch angle?
-It definitely sounds like Euler angles cannot be used due to the gimbal lock problem and therefore it should use Quaternions.
But another small question arises, how to send the quaternion information to the servo?
That is, how should I send the error between the desired position and the current position to the servo motor (1000-2000 pwm)?

 


It's nice to push the limits even if it sounds like a crazy idea 🙂
After doing a lot of research and even though the cells in my brain now smell of burning, I continue further.

I've looked at a few examples, but I don't understand much because they are not created with labview. Anyone have any ideas on this?

Message 1 of 5
(1,241 Views)

i don't have any answers, nor do I have any experience in this area, but I do applaud your efforts to expand your knowledge!

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 2 of 5
(1,225 Views)

Hi constructionworker,

 

This sounds like an interesting problem.  I don't have any suggestions as to what algorithms to use, but I can contribute to your servo motor problem.  Are you using a RC servo motor for your rudder?  You can translate the angle of the RC motor into the pulse width of the pulse train signal that you use to control the RC servo motor.  

I'm guessing you are using myRIO?  You can see here for a RC motor tutorial: 

https://www.theengineeringprojects.com/2017/08/servo-motor-control-using-myrio.html 

 

BR

John

Add motion to LabVIEW in 30min or less - TENET EMotion
Finding it hard to source NI hardware? Try NI Trading Post

 

0 Kudos
Message 3 of 5
(1,186 Views)

Thank you
Learning and knowing something makes me understand life better. (A little note: I have no choice but to learn) 🙂

 Thanks for trying to help RIObotics

I am using servo motor and myRIO. Controlling the servo via serial or PWM is not very important here, the important thing is to stabilize it with Quaternion or rotation matrices.So my main goal is to learn how to use this logic as a start.

If a stabilization with Euler angles is desired;

motor 1(Aileron)=desired angle-current angle

Here it is necessary to use a PID and convert the result from the PID to the desired values. If it is pwm, it should be a pwm between 1000-2000. If it is a positioning servo (180 degrees center angle, that is, the angle where the fin is straight), a value should be given accordingly.

But this only applies to euler angles. But Euler angles have a gimbal lock issue.
The real question here is how can it be done if it is meant to be done with Quaternion or rotation matrices?

 

0 Kudos
Message 4 of 5
(1,169 Views)

If anyone has anything to do with this topic, the code below is a code written for V-Tail.

Quat to PWM.png

I don't know if it's exactly right 🙂
I would be happy to hear any ideas or suggestions if anyone has knowledge and experience on this subject.

0 Kudos
Message 5 of 5
(1,127 Views)