2
$\begingroup$

I am bulding a quadcopter using these compenents:

  • Microcontroller: Tiva C Lanchpad (ARM Cortex M4 - 80 MHz), but running at 40MHz in my code
  • MPU 9150 - Sensorhub TI
  • ESC - Hobbywing Skywalker 40A

I use the sample project comp_dcm from Tivaware and use that angles for my PID which running at 100Hz

I test PID Control on 2 motors, but the motors oscillate as in the video i found on youtube from one guy!

Quadcopter Unbalance

$\endgroup$
  • 1
    $\begingroup$ I'll start with the obvious question: Have you tuned the PID? $\endgroup$ – Rocketmagnet Sep 4 '14 at 20:55
  • $\begingroup$ Looks like an unstable controller, just tune it. $\endgroup$ – TobiasK Sep 5 '14 at 5:15
  • $\begingroup$ we tune the PID so many times, and the same problems. Even though that the P Term is very small $\endgroup$ – Tuyen Vo Quang Sep 5 '14 at 12:50
  • $\begingroup$ Also the I term can make it unstable... just use a P term and rest to zero for first try $\endgroup$ – TobiasK Sep 5 '14 at 18:21
  • $\begingroup$ I tune the quadcopter with just P component, and the way i did is starting with very small kP to larger kP. But the same problem occurs, with very small kP, but the quadcopter cannot balance, and actually it oscillates as shown in the video! I think about many solutions such as: the angle updates too slow, or the MCU computation is too slow... $\endgroup$ – Tuyen Vo Quang Sep 6 '14 at 2:47
4
$\begingroup$

A couple possibilities come to mind,

  • PIDs need tuning, this is relatively simple (entire books have been written on it)

    • Basically, set the I and D terms to 0 and slowly move up the P term till it oscillates and turn it down again to just below that point
  • Your code is running too slowly (this can cause all kinds of odd errors)

| improve this answer | |
$\endgroup$
0
$\begingroup$

It looks like your I term is turned up too high. This can cause the system to overcompensate before it has even started to return to equilibrium.

| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.