inkonova / cleanflight

Clean-code version of the baseflight flight controller firmware
http://cleanflight.com
GNU General Public License v3.0
6 stars 2 forks source link

Control theory #1

Open rustyoz opened 8 years ago

rustyoz commented 8 years ago

Hi, I was looking through your code to gain an insight into how you use the rc pitch channel to control the tilt angle but from what i can gather it is still fed into the pitch PID controller. Is the intended outcome that the copter still pitch in the intended direction of movement but that the tilting rotors provide most of the acceleration, instead of trying to maintain a level body independent of the rotor tilt angle?

MauroMombelli commented 8 years ago

hi,

we give full control over this using the pitch divider, see https://github.com/inkonova/cleanflight/blob/tilting-1.10.0/src/main/mw.c#L846

rustyoz commented 8 years ago

So you use a self leveling mode with a low proportion of pitch or zero fed into the pitch PID?

Is this only active in one direction of the pitch command? ie pitching forward is scaled down, but pitching back to brake isn't? https://github.com/inkonova/cleanflight/blob/tilting-1.10.0/src/main/mw.c#L851

MauroMombelli commented 8 years ago

no, we control the divider with a potentiometer (tiltArm.channel), if it is LOWER than mid range the pitch divider is used.

meanwhile the user input PITCH is saved into tmpPitch witch is used for later elaboration to find out how much move the servo.

2016-04-07 2:21 GMT+02:00 Russell Oliver notifications@github.com:

So you use a self leveling mode with a low proportion of pitch or zero fed into the pitch PID?

Is this only active in one direction of the pitch command? ie pitching forward is scaled down, but pitching back to brake isn't?

https://github.com/inkonova/cleanflight/blob/tilting-1.10.0/src/main/mw.c#L851

— You are receiving this because you commented. Reply to this email directly or view it on GitHub https://github.com/inkonova/cleanflight/issues/1#issuecomment-206632266