You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If in the airframe you use the commands instead of actuator pprz, then here you can make
a nice switch using the command name directly instead of hardcoded numbers which can
lead to confusion. Something like:
for (i=0; i<EFF_MAT_COLS_NB; i++) {
switch (i) {
case (COMMAND_MOTOR_FRONT):
case (COMMAND_MOTOR_BACK):
case (COMMAND_MOTOR_RIGHT):
case (COMMAND_MOTOR_LEFT):
EFF_MAT_RW[RW_aN][i] = ... ;
break;
case (COMMAND_MOTOR_PUSHER):
EFF_MAT_RW[RW_aN][i] = ... ;
break;
case (COMMAND_ELEVATOR):
case (COMMAND_RUDDER):
case (COMMAND_AILERONS):
case (COMMAND_FLAPS):
EFF_MAT_RW[RW_aN][i] =0.0;
break;
case (COMMAND_ROLL):
EFF_MAT_RW[RW_ar][i] =0.0;
break;
case (COMMAND_PITCH):
EFF_MAT_RW[RW_ar][i] =0.0;
break;
default:
break;
}
No description provided.
The text was updated successfully, but these errors were encountered: