Hello, (my first post here)
I want to tune the PID settings for gyro. What is the easiest way of having only 1 axis (pitch for example) active, all other axis are off.
I tried setting PID of roll & yaw to 0 (zero) but ideally the rx should also be turned off.
So the goal here is that only the pitch axis is enabled (sensors + rx) all other axis are completely off!
thanks
manu
disabling all sensors except 1 axis gyro
Re: disabling all sensors except 1 axis gyro
I've never heard of turning off any axis's but I don't think the copter would fly for very long at all with 2/3 axis turned off. If you want to isolate 2 axis the easiest way I can think of is to tie it up with string, I can't find the youtube tutorial but there are a few out there.
But assuming your copter is symmetrical in both layout and weight the pitch and roll pids should be the same. Yaw is normally pretty easy to tune.
But assuming your copter is symmetrical in both layout and weight the pitch and roll pids should be the same. Yaw is normally pretty easy to tune.
Re: disabling all sensors except 1 axis gyro
It is for tuning the PID on a test bank, between 2 ropes (not flying), and i don't want to get influences from the other axis.
Code: Select all
//in config.h
#define PITCHAXISONLY 1
// in main loop at the end
...
//**** PITCH & ROLL & YAW PID ****
for(axis=0;axis<3;axis++) {
...
axisPID[axis] = PTerm + ITerm - DTerm;
#if PITCHAXISONLY
if (axis>0) axisPID[axis]=0;
#endif
}
Re: disabling all sensors except 1 axis gyro
Ahh you are tieing the copter up, that makes more sense.
Re: disabling all sensors except 1 axis gyro
Still have to disable Rx commands for roll & yaw ...
Re: disabling all sensors except 1 axis gyro
Just take the props off the motors you don't want to have an effect on the airframe, would that work? or disconnect the motors all togeather
Re: disabling all sensors except 1 axis gyro
cardboard wrote:Just take the props off the motors you don't want to have an effect on the airframe, would that work? or disconnect the motors all togeather
No, you don't get it.
I hang the copter left and right wit a rope. My goal is to only PID tune 1 axis (pitch), and roll & yaw should be off (sensor : this is working with the modified code, rx not yet!)
see:
https://www.youtube.com/watch?v=YNzqTGE ... e=g-user-u
Re: disabling all sensors except 1 axis gyro
How is turning off the PID controllers different from taking the props off? For the rx stuff, just configure your rx to not send those channels or leave them on the center setting (gain -100?) ...
Re: disabling all sensors except 1 axis gyro
We don't know what type of copter he is using. If it was a quad + you could just remove a pair of props, if it is a quad x you can't do that as all the motors are used for any one axis.
Re: disabling all sensors except 1 axis gyro
Yep, its X4
With the changes posted above, its working for the sensors. Rx are still all active, but that's ok.
This method of tuning pid is the best imho.
manu
With the changes posted above, its working for the sensors. Rx are still all active, but that's ok.
This method of tuning pid is the best imho.
manu