Hello guys,
Rushi here again. I am following to this post "Does being at high altitude may affect the throttle input in rise of quad? - Programming Questions - Arduino Forum" "Does being at high altitude may affect the throttle input in rise of quad?" since I made slight progress but wanted to post it separately because previous post has gone far down.
Previous I had a problem and a doubt if F450 with normal configuration as almost prefer lifts off. I had a rough time figuring that out with which first I thought it might battery weight issue that's dragging it to not to lift off but I am cleared that now.
Well I am still on testing phase and I tethered copter using ropes and hard cement bricks so that it can remain constrain. At first I was scared while increasing throttle but then I set all p_gains = 1 (yaw, pitch, roll) and all other gains = 0 and copter lifted off at around 50% - 55% of throttle input. It lifted off but wasn't stable and wobbling quite badly but it landed safely. Here is the short video quad liftoff test - YouTube
I am sure it is with PID tunning. Considering I have this at p_gain = 1 as mentioned earlier,
- How should I proceed with the gains?
- Is there anything else I should look into other than PID.
for the second question I am editing the signs as follows: but it gets worse.
if (start == 2){ //The motors are started.
if (throttle > 1800) throttle = 1800; //We need some room to keep full control at full throttle.
esc_1 = throttle - pid_output_pitch + pid_output_roll - pid_output_yaw; //Calculate the pulse for esc 1 (front-right - CCW)
esc_2 = throttle + pid_output_pitch + pid_output_roll + pid_output_yaw; //Calculate the pulse for esc 2 (rear-right - CW)
esc_3 = throttle + pid_output_pitch - pid_output_roll - pid_output_yaw; //Calculate the pulse for esc 3 (rear-left - CCW)
esc_4 = throttle - pid_output_pitch - pid_output_roll + pid_output_yaw; //Calculate the pulse for esc 4 (front-left - CW)
- Other than these 2 facts, what else should I look into?
Here is my code btw attached and following is the configuration:
10" x 4.5" props
A2212 13T 1000KV motors
30A ESCs
F450 frame
coding flight controller by myself using arduino uno r3 and IMU.
Thank you.
P.S. I apologize for posting it as a different post.