Subversion Repositories FlightCtrl

Compare Revisions

Ignore whitespace Rev 2044 → Rev 2045

/branches/dongfang_FC_rewrite/uart0.c
87,7 → 87,7
"Yaw Term ", //15
"Throttle Term ",
"ControlAct/10 ",
"Acc. Vector ",
"RC Qual ",
"heightTrottleIn ",
"HeightdThrottle ", //20
"Height ",
96,11 → 96,12
"HeightPdThrottle",
"HeightIdThrottle", //25
"HeightDdThrottle",
"HeightPFactor ",
"HeightIFactor ",
"HeightDFactor ",
"Altitude ", //30
"AirpressADC " };
"NaviStickPitch ",
"NaviStickRoll ",
"StickPitch ",
"StickRoll ", //30
"navi mode "
};
 
/****************************************************************/
/* Initialization of the USART0 */
653,11 → 654,9
if (((data3D_interval && checkDelay(data3D_timer)) || request_data3D)
&& txd_complete) {
sendOutData('C', FC_ADDRESS, 1, (uint8_t *) &data3D, sizeof(data3D));
data3D.anglePitch = (int16_t) ((10 * angle[PITCH])
/ GYRO_DEG_FACTOR_PITCHROLL); // convert to multiple of 0.1°
data3D.angleRoll = (int16_t) ((10 * angle[ROLL])
/ GYRO_DEG_FACTOR_PITCHROLL); // convert to multiple of 0.1°
data3D.heading = (int16_t) ((10 * yawGyroHeading) / GYRO_DEG_FACTOR_YAW); // convert to multiple of 0.1°
data3D.anglePitch = (int16_t) (angle[PITCH] / (GYRO_DEG_FACTOR_PITCHROLL/10)); // convert to multiple of 0.1°
data3D.angleRoll = (int16_t) (angle[ROLL] / (GYRO_DEG_FACTOR_PITCHROLL/10)); // convert to multiple of 0.1°
data3D.heading = (int16_t) (yawGyroHeading / (GYRO_DEG_FACTOR_YAW/10)); // convert to multiple of 0.1°
data3D_timer = setDelay(data3D_interval);
request_data3D = FALSE;
}