This forum is dedicated to software development related to MultiWii.
It is not the right place to submit a setup problem.
Software download
mgros
Posts: 90 Joined: Thu Jan 20, 2011 12:32 am
Post
by mgros » Sat Nov 16, 2013 11:39 am
In the new IMU.cpp in MultiWii_Shared i think there is a bug in line 286
line says:
Code: Select all
cosZ = EstG.V.Z / ACC_1G * 100.0f;
Should not it be?:
Code: Select all
cosZ = EstG16.V.Z / ACC_1G * 100.0f;
Only fails compilling with
Code: Select all
#define THROTTLE_ANGLE_CORRECTION
Hope help you.
mgros
Posts: 90 Joined: Thu Jan 20, 2011 12:32 am
Post
by mgros » Sat Nov 16, 2013 11:50 am
ATTENTION, do not compile with
Code: Select all
#define THROTTLE_ANGLE_CORRECTION
option , malfunction in the speed of the motors.
Alexinparis
Posts: 1630 Joined: Wed Jan 19, 2011 9:07 pm
Post
by Alexinparis » Sun Nov 17, 2013 2:31 pm
Hi, Good catch, just fixed. EstG16.V.Z / ACC_1G * 100.0f; => you need to isolate (ACC_1G * 100.0f) otherwise EstG16.V.Z / ACC_1G is evaluated first and is mostly 0.
mgros
Posts: 90 Joined: Thu Jan 20, 2011 12:32 am
Post
by mgros » Sun Nov 17, 2013 3:00 pm
Thanks Alex!
mgros
Posts: 90 Joined: Thu Jan 20, 2011 12:32 am
Post
by mgros » Sun Nov 17, 2013 7:25 pm
i have added parenthesis and the motor problem still exist Compiling with THROTTLE_ANGLE_CORRECTION results OK, but the power in motors jumps from idle to near max moving the throttle stick (not lineal). Probably the 40 value should be reduced.