|
请问各位高手,小妹刚接触德国人的四旋翼飞控程序,有两个问题想咨询一下:
第一个,从FC.c文件中,没有找到具体的关于飞行器动力学模型中所需要的参量,例如:质量,杆长,等.那我进行程序移植时,程序中哪里体现了这些参量值呢?
第二个,输入到电机的变量Motorvalue值,是不是就是动力学模型中的旋翼转速?
第三个,下面这段代码,如何解释? 这里的Reading_GyroYaw (偏航角速度偏差值)与 Reading_GyroRoll 在动力学模型中如何体现的?
if(!Looping_Nick && !Looping_Roll && (ParamSet.GlobalConfig & CFG_AXIS_COUPLING_ACTIVE))
{
tmpl = (Reading_GyroYaw * Reading_IntegralGyroNick) / 2048L;
tmpl *= FCParam.Yaw_PosFeedback;
tmpl /= 4096L;
//tmpl=Yaw偏差值*Reading_IntegralGyroNick*90/2048/4096
tmpl2 = ( Reading_GyroYaw * Reading_IntegralGyroRoll) / 2048L;
tmpl2 *= FCParam.Yaw_PosFeedback;
tmpl2 /= 4096L;
}
Reading_GyroRoll += tmpl;
Reading_GyroRoll += (tmpl2 * FCParam.Yaw_NegFeedback) / 512L;
Reading_IntegralGyroRoll2 += Reading_GyroRoll;
Reading_IntegralGyroRoll += Reading_GyroRoll - AttitudeCorrectionRoll; |
阿莫论坛20周年了!感谢大家的支持与爱护!!
知道什么是神吗?其实神本来也是人,只不过神做了人做不到的事情 所以才成了神。 (头文字D, 杜汶泽)
|