For adjusting the pid for quadcopter, how much speed of motors are required before adjusting the pid. Do we need to give so much offset speed so that it cancels weight? I am sure we cant start adjusting pid with zero speed of motors initially.
-
$\begingroup$ Consider better rephrasing your question. It is very much unclear what you want to achieve. English is also quite poor. $\endgroup$– Ugo PattaciniOct 3, 2015 at 11:09
-
$\begingroup$ There it is. I have edited it $\endgroup$– user10738Oct 3, 2015 at 11:11
2 Answers
For tuning PID controllers (and generally any linear controller) it is a very common practice to go through the following steps:
Let the system reach a steady-state condition, e.g. the quadcopter is stabilized at a given height, thus the motors are spinning with nonzero speed.
Superimpose a specified signal (step-wise, sinusoidal waveform ...) to the commands provided to the system, e.g. add up a step to the voltage used to command a given motor.
Measure back the response of the system to the injected signal, e.g. acquire the controlled variable of the quadcopter (i.e. position and/or velocity).
Come up with a linear model which best describes such a response. Of course, we have to subtract from the command and the response the terms that contribute to the steady-state.
Use this model to design/tune the PID according to one of the numerous techniques available (e.g. poles placement).
This approach assumes that the response of the system to the commands variations remains somewhat linear irrespective of the working point. This is generally a reasonable hypothesis, taking into account the fact that a robustly tuned PID is capable of compensating for quite huge nonlinearities in the system.
So basically, to answer your question, just double check that the steady-state speed of the motor required to keep the quadcopter stabilized in the air does correspond to a commanded voltage around which it is possible to carry out signal modulation without hitting the voltage limits.
-
$\begingroup$ In part1: let the copter to reach steady state. Means that cancel its weight by speed of motors? $\endgroup$ Oct 3, 2015 at 12:22
-
This is intended as a comment only and it is based on my limited experience working on this topic.
PID works based on the error that resulted from the difference between the actual value (from sensor) and the reference value (your goal). This error is calculated and then is fed into the PID controller. Whether or not the speed is zero, that is not the only determining factor as it also depends on your reference point.
-
$\begingroup$ Yes i know that. I am asking something else, $\endgroup$ Oct 3, 2015 at 8:03